Qpid
  1. Qpid
  2. QPID-4047

IoNetworkTransport doesn't use timeout on socket connect

    Details

    • Type: Bug Bug
    • Status: Resolved
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 0.17
    • Component/s: Java Common
    • Labels:
      None

      Description

      line 76 of org/apache/qpid/transport/network/io/IoNetworkTransport calls _socket.connect without supplying a timeout value. This is equivalent to an infinite timeout. Re-use the _timeout field within the same class that specifies a 60 second timeout for reads?

      I've attached a patch.

        Activity

        Hide
        Praveen Murugesan added a comment -

        Patch.

        Show
        Praveen Murugesan added a comment - Patch.
        Hide
        Rob Godfrey added a comment -

        Seems like a reasonable enhancement. Ideally we should also make the timeout configurable (and possibly have different timeouts for the socket connection and the AMQP connection establishment) however I think we can leave this for another JIRA.

        Show
        Rob Godfrey added a comment - Seems like a reasonable enhancement. Ideally we should also make the timeout configurable (and possibly have different timeouts for the socket connection and the AMQP connection establishment) however I think we can leave this for another JIRA.
        Hide
        Rob Godfrey added a comment -

        I've made an equivalent change (since the value of _timeout is fixed and cannot be changed I have made it a constant within the class).

        Thanks for spotting this Praveen

        Show
        Rob Godfrey added a comment - I've made an equivalent change (since the value of _timeout is fixed and cannot be changed I have made it a constant within the class). Thanks for spotting this Praveen
        Hide
        Praveen Murugesan added a comment -

        Rob, Thanks for getting to this immediately

        Show
        Praveen Murugesan added a comment - Rob, Thanks for getting to this immediately
        Hide
        Robbie Gemmell added a comment -

        After a little searching I figured out that I remembered the 'connecttimeout' URL option from some documentation changes Keith made earlier in the year. After examining the code a bit it seems that option is in need of repair, so I have raised QPID-4051 to cover it...and with that I think I'll begin my vacation

        Show
        Robbie Gemmell added a comment - After a little searching I figured out that I remembered the 'connecttimeout' URL option from some documentation changes Keith made earlier in the year. After examining the code a bit it seems that option is in need of repair, so I have raised QPID-4051 to cover it...and with that I think I'll begin my vacation

          People

          • Assignee:
            Rob Godfrey
            Reporter:
            Praveen Murugesan
          • Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development