Uploaded image for project: 'Camel'
  1. Camel
  2. CAMEL-5404

MinaProducer does not disconnect on response timeouts

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • 2.9.2
    • 2.8.6, 2.9.3, 2.10.1
    • camel-mina
    • None
    • Unknown

    Description

      When MinaProducer is configured with

      sync=true&disconnect=true&disconnectOnNoReply=true&timeout=X

      and a timeout occurs, the connection is not disconnected.

      First of all disconnectOnNoReply only applies to consumers, which can be (and was) very confusing. Allthough this is according to documentation.

      Secondly this might (and did!) lead to wrong response messages set on an Exchange. The following scenario:
      1. Client sends a request and waits for a response (InOut) on exchange A.
      2. Client times out waiting for a response after X milliseconds.
      3. Client sends another request on exchange B.
      4. Server sends the response for exchange A.
      5. Client gets response for exchange A on exchange B (disaster!).

      This happens because the producer reuses exchange A's connection for exchange B, because it was not disconnected when exchange A timed out.

      Attachments

        Activity

          People

            davsclaus Claus Ibsen
            thxmasj Thomas Johansen
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: