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

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Minor Minor
    • Resolution: Fixed
    • Affects Version/s: 0.4
    • Fix Version/s: 0.5
    • Component/s: proton-c, proton-j
    • Labels:
      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.

        Issue Links

          Activity

          Hide
          Keith Wall added a comment -

          Change committed at rev. 1453849

          Show
          Keith Wall added a comment - Change committed at rev. 1453849

            People

            • Assignee:
              Keith Wall
              Reporter:
              Keith Wall
            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Development