Qpid
  1. Qpid
  2. QPID-3263

Java (org.apache.qpid.client) XAResourceImpl always returns false for isSameRM

    Details

    • Type: Bug Bug
    • Status: Resolved
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 0.11
    • Fix Version/s: 0.14
    • Component/s: Java Client
    • Labels:
      None
    • Environment:

      All OS/hardware platforms as well as current brokers.

      Description

      The isSameRM method of org.apache.qpid.client.XAResourceImpl always returns
      false.

      The javadoc for isSameRM says ..

      "This method is called to determine if the resource manager instance
      represented by the target object is the same as the resource manager instance
      represented by the parameter xares ."

      which means isSameRM has to return true when invoked with identical objects
      (Java identity). Clearly, these two XA resources are backed by the same
      resource manager.

      //xaResource1 == xaResource2
      XAResource xaResource1 = jmsXAResource;
      XAResource xaResource2 = jmsXAResource;

      // xaResource1.isSameRM(xaResource2) should be true

      Because the Qpid implementation always returns false, it affects resource
      enlistment/delistment.

      The source code (lines 213 - 217) of org.apache.qpid.client.XAResourceImpl
      suggests that this method has not been fully completed.

      public boolean isSameRM(XAResource xaResource) throws XAException

      { // TODO : get the server identity of xaResource and compare it with our own one return false; }
      1. qpid3263.patch
        9 kB
        Weston M. Price
      2. MRG-00471937.zip
        3 kB
        Weston M. Price

        Activity

        Weston M. Price created issue -
        Weston M. Price made changes -
        Field Original Value New Value
        Attachment MRG-00471937.zip [ 12479623 ]
        Weston M. Price made changes -
        Attachment qpid3263.patch [ 12482928 ]
        Rajith Attapattu made changes -
        Status Open [ 1 ] Resolved [ 5 ]
        Fix Version/s 0.14 [ 12316855 ]
        Fix Version/s 0.11 [ 12316272 ]
        Resolution Fixed [ 1 ]

          People

          • Assignee:
            Unassigned
            Reporter:
            Weston M. Price
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Time Tracking

              Estimated:
              Original Estimate - 24h
              24h
              Remaining:
              Remaining Estimate - 24h
              24h
              Logged:
              Time Spent - Not Specified
              Not Specified

                Development