Uploaded image for project: 'Qpid Proton'
  1. Qpid Proton
  2. PROTON-264

Proton-J and Proton-C transports make inconsistent use of return values within methods input and output

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Minor
    • Resolution: Fixed
    • proton-0.4
    • proton-0.5
    • proton-c, proton-j
    • None

    Description

      This defect refers to the transport interface already in the process of being deprecated by PROTON-225. The scope of PROTON-225 has been increased (=noted in Jira) to ensure that this defect is not carried forward to the new interface and we end up with consistent behaviour.

      Currently, in Proton-C pn_transport_output() returns PN_EOS (=-1) to signal that the Transport will produce no further output, and pn_transport_input() returns PN_EOS to signal that the Transport will accept no further input. However, Proton-J, output always returns the number bytes output (even if zero), and input returns the number of bytes accepted (again even if zero).

      This difference presents a problem to tests utilising the Proton-JNI binding. As a temporary workaround, JNITransport class will changed to hide this difference from the caller.

      Attachments

        Issue Links

          Activity

            People

              kwall Keith Wall
              kwall Keith Wall
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: