Qpid
  1. Qpid
  2. QPID-2137

StringIndexOutOfBounds when formating Connection Message during failed systest run.

    Details

    • Type: Bug Bug
    • Status: Resolved
    • Priority: Blocker Blocker
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 0.6, 0.7
    • Component/s: Java Tests
    • Labels:
      None

      Description

      This problem occured during a run of systests in the AcknowledgeAfterFailoverOnmessageTest. The test failed with a concurrent modification exception. However prior to that a StringIndexOutOfBounds during client connection establishment occured
      Then shortly afterwards a NullPointerException occured and repeated a number of times.

      Most likely what occured is the failed connection open was not correclty closed by mina and so the attempts to send on the socket resulted in the NPEs.

      Then the ConcurrentModException occured potentially as a result of a new getConnection() being called asynchronously via the onMessage when the close() was being called.

      Dispatcher-Channel-1 2009-10-12 16:25:36,694 ERROR [qpid.server.protocol.AMQPFastProtocolHandler] Exception caught inanonymous(17670761)(?, closing session explictly: java.lang.StringIndexOutOfBoundsException: String index out of range: 37
      java.lang.StringIndexOutOfBoundsException: String index out of range: 37
      at java.lang.String.substring(String.java:1934)
      at java.text.MessageFormat.subformat(MessageFormat.java:1208)
      at java.text.MessageFormat.format(MessageFormat.java:836)
      at java.text.Format.format(Format.java:140)
      at org.apache.qpid.server.logging.messages.ConnectionMessages.CON_1001(ConnectionMessages.java:141)

        Activity

        Transition Time In Source Status Execution Times Last Executer Last Execution Date
        Open Open In Progress In Progress
        93d 15m 1 Martin Ritchie 13/Jan/10 16:08
        In Progress In Progress Reviewable Reviewable
        25s 1 Martin Ritchie 13/Jan/10 16:08
        Reviewable Reviewable Resolved Resolved
        99d 23h 8m 1 Marnie McCormack 23/Apr/10 16:17
        Marnie McCormack made changes -
        Status Ready To Review [ 10006 ] Resolved [ 5 ]
        Resolution Fixed [ 1 ]
        Hide
        Marnie McCormack added a comment -

        LogMesssageTest.testSimultaneousLogging has a superfluous int LOG_COUNT. Aside from that commits look ok afaics thx.

        Show
        Marnie McCormack added a comment - LogMesssageTest.testSimultaneousLogging has a superfluous int LOG_COUNT. Aside from that commits look ok afaics thx.
        Andrew Stitcher made changes -
        Fix Version/s 0.7 [ 12314455 ]
        Hide
        Martin Ritchie added a comment -

        Merged to 0.6-release as directed by Andrew.

        Show
        Martin Ritchie added a comment - Merged to 0.6-release as directed by Andrew.
        Martin Ritchie made changes -
        Assignee Andrew Stitcher [ astitcher ] Martin Ritchie [ ritchiem ]
        Martin Ritchie made changes -
        Assignee Martin Ritchie [ ritchiem ] Andrew Stitcher [ astitcher ]
        Hide
        Martin Ritchie added a comment -

        Hi Andrew, can we please include this in 0.6. Without it Status logging will be unavailable.

        Show
        Martin Ritchie added a comment - Hi Andrew, can we please include this in 0.6. Without it Status logging will be unavailable.
        Martin Ritchie made changes -
        Status In Progress [ 3 ] Ready To Review [ 10006 ]
        Hide
        Martin Ritchie added a comment -

        Changes committed to trunk revision 898821.

        Show
        Martin Ritchie added a comment - Changes committed to trunk revision 898821.
        Martin Ritchie made changes -
        Status Open [ 1 ] In Progress [ 3 ]
        Martin Ritchie made changes -
        Attachment QPID-2137-LogMessages.vm.Update.patch [ 12430144 ]
        Hide
        Martin Ritchie added a comment -

        Add patch for inclusion review.

        Show
        Martin Ritchie added a comment - Add patch for inclusion review.
        Martin Ritchie made changes -
        Assignee Martin Ritchie [ ritchiem ]
        Martin Ritchie made changes -
        Fix Version/s 0.6 [ 12313728 ]
        Priority Minor [ 4 ] Blocker [ 1 ]
        Hide
        Martin Ritchie added a comment -

        Increasing level of this issue to blocker as this issue wlll preclude the use of status logging as the race condition could stop the broker.

        Show
        Martin Ritchie added a comment - Increasing level of this issue to blocker as this issue wlll preclude the use of status logging as the race condition could stop the broker.
        Martin Ritchie made changes -
        Hide
        Martin Ritchie added a comment -

        Attached log run from the failure.

        Show
        Martin Ritchie added a comment - Attached log run from the failure.
        Martin Ritchie created issue -

          People

          • Assignee:
            Martin Ritchie
            Reporter:
            Martin Ritchie
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development