Uploaded image for project: 'JBoss Enterprise Application Platform'
  1. JBoss Enterprise Application Platform
  2. JBEAP-2851

A-MQ appclient throws wrong exception types after the session was closed in TCK tests

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Done
    • Icon: Critical Critical
    • 7.1.0.GA
    • 7.0.0.ER4
    • A-MQ RA
    • None

      TCK module jms/ee/all has various tests checking the client throws proper exception type. When connecting with appclient, the application client throws incorrect exception type in cases when the connection was closed.

      This affects A-MQ 6.2.1 with EAP 7.0.0.ER4 (note that this is regression from A-MQ 6.2.0, where all these TCK tests passed, with same appclient configuration).

      Also note that this is only problem for application client. Same tests ran from servlet or EJB work as expected.

      The client throws this exception, instead of whatever is expected:

      [javatest.batch] �[0m�[0m05:18:38,205 INFO  [stdout] (Thread-59) 01-18-2016 05:18:38:  ERROR: Failed to create topic sessiondue to 
      [javatest.batch] �[0m�[0m05:18:38,207 INFO  [stdout] (Thread-59) 01-18-2016 05:18:38:  ERROR: javax.jms.InvalidClientIDException: Broker: localhost - Client: cts already connected from vm://localhost#14
      [javatest.batch] �[0m�[0m05:18:38,207 INFO  [stdout] (Thread-59) 	at org.apache.activemq.broker.region.RegionBroker.addConnection(RegionBroker.java:255)
      [javatest.batch] �[0m�[0m05:18:38,207 INFO  [stdout] (Thread-59) 	at org.apache.activemq.broker.jmx.ManagedRegionBroker.addConnection(ManagedRegionBroker.java:230)
      [javatest.batch] �[0m�[0m05:18:38,207 INFO  [stdout] (Thread-59) 	at org.apache.activemq.broker.BrokerFilter.addConnection(BrokerFilter.java:97)
      [javatest.batch] �[0m�[0m05:18:38,207 INFO  [stdout] (Thread-59) 	at org.apache.activemq.advisory.AdvisoryBroker.addConnection(AdvisoryBroker.java:93)
      [javatest.batch] �[0m�[0m05:18:38,207 INFO  [stdout] (Thread-59) 	at org.apache.activemq.broker.BrokerFilter.addConnection(BrokerFilter.java:97)
      [javatest.batch] �[0m�[0m05:18:38,207 INFO  [stdout] (Thread-59) 	at org.apache.activemq.broker.BrokerFilter.addConnection(BrokerFilter.java:97)
      [javatest.batch] �[0m�[0m05:18:38,208 INFO  [stdout] (Thread-59) 	at org.apache.activemq.broker.MutableBrokerFilter.addConnection(MutableBrokerFilter.java:102)
      [javatest.batch] �[0m�[0m05:18:38,208 INFO  [stdout] (Thread-59) 	at org.apache.activemq.broker.TransportConnection.processAddConnection(TransportConnection.java:817)
      [javatest.batch] �[0m�[0m05:18:38,208 INFO  [stdout] (Thread-59) 	at org.apache.activemq.broker.jmx.ManagedTransportConnection.processAddConnection(ManagedTransportConnection.java:77)
      [javatest.batch] �[0m�[0m05:18:38,208 INFO  [stdout] (Thread-59) 	at org.apache.activemq.command.ConnectionInfo.visit(ConnectionInfo.java:139)
      [javatest.batch] �[0m�[0m05:18:38,208 INFO  [stdout] (Thread-59) 	at org.apache.activemq.broker.TransportConnection.service(TransportConnection.java:338)
      [javatest.batch] �[0m�[0m05:18:38,208 INFO  [stdout] (Thread-59) 	at org.apache.activemq.broker.TransportConnection$1.onCommand(TransportConnection.java:188)
      [javatest.batch] �[0m�[0m05:18:38,208 INFO  [stdout] (Thread-59) 	at org.apache.activemq.transport.MutexTransport.onCommand(MutexTransport.java:50)
      [javatest.batch] �[0m�[0m05:18:38,209 INFO  [stdout] (Thread-59) 	at org.apache.activemq.transport.WireFormatNegotiator.onCommand(WireFormatNegotiator.java:113)
      [javatest.batch] �[0m�[0m05:18:38,209 INFO  [stdout] (Thread-59) 	at org.apache.activemq.transport.AbstractInactivityMonitor.onCommand(AbstractInactivityMonitor.java:300)
      [javatest.batch] �[0m�[0m05:18:38,209 INFO  [stdout] (Thread-59) 	at org.apache.activemq.transport.TransportSupport.doConsume(TransportSupport.java:83)
      [javatest.batch] �[0m�[0m05:18:38,210 INFO  [stdout] (Thread-59) 	at org.apache.activemq.transport.tcp.TcpTransport.doRun(TcpTransport.java:214)
      [javatest.batch] �[0m�[0m05:18:38,210 INFO  [stdout] (Thread-59) 	at org.apache.activemq.transport.tcp.TcpTransport.run(TcpTransport.java:196)
      [javatest.batch] �[0m�[0m05:18:38,210 INFO  [stdout] (Thread-59) 	at java.lang.Thread.run(Thread.java:745)
      

      Example of the test that failed with 6.2.1:

      TopicConnectionFactory cf = (TopicConnectionFactory) context.lookup("java:comp/env/jms/MyTopicConnectionFactory");
      TopicConnection tConnection = (TopicConnection) cf.createTopicConnection();
      TopicSession tSession = tConnection.createTopicSession(true, Session.AUTO_ACKNOWLEDGE);
      
      tConnection.start();
      tSession.close();
      
      tSession.commit() // javax.jms.IllegalStateException is expected here
      

      Note: there are variants of this test, where some other method is called instead of commit() (like createDurableSubscriber(), createTopic(), createPublisher() etc).

      List of failing tests from module jms/ee/all:

      FAILED........com/sun/ts/tests/jms/ee/all/closedtopicsessiontests/ClosedTopicSessionTests.java#closedTopicSessionCommitTest_from_appclient
      FAILED........com/sun/ts/tests/jms/ee/all/closedtopicsessiontests/ClosedTopicSessionTests.java#closedTopicSessionCreateBytesMessageTest_from_appclient
      FAILED........com/sun/ts/tests/jms/ee/all/closedtopicsessiontests/ClosedTopicSessionTests.java#closedTopicSessionCreateDurableSubscriberMsgSelectorTest_from_appclient
      FAILED........com/sun/ts/tests/jms/ee/all/closedtopicsessiontests/ClosedTopicSessionTests.java#closedTopicSessionCreateDurableSubscriberTest_from_appclient
      FAILED........com/sun/ts/tests/jms/ee/all/closedtopicsessiontests/ClosedTopicSessionTests.java#closedTopicSessionCreateMapMessageTest_from_appclient
      FAILED........com/sun/ts/tests/jms/ee/all/closedtopicsessiontests/ClosedTopicSessionTests.java#closedTopicSessionCreateMessageTest_from_appclient
      FAILED........com/sun/ts/tests/jms/ee/all/closedtopicsessiontests/ClosedTopicSessionTests.java#closedTopicSessionCreateObject2MessageTest_from_appclient
      FAILED........com/sun/ts/tests/jms/ee/all/closedtopicsessiontests/ClosedTopicSessionTests.java#closedTopicSessionCreateObjectMessageTest_from_appclient
      FAILED........com/sun/ts/tests/jms/ee/all/closedtopicsessiontests/ClosedTopicSessionTests.java#closedTopicSessionCreatePublisherTest_from_appclient
      FAILED........com/sun/ts/tests/jms/ee/all/closedtopicsessiontests/ClosedTopicSessionTests.java#closedTopicSessionCreateStreamMessageTest_from_appclient
      FAILED........com/sun/ts/tests/jms/ee/all/closedtopicsessiontests/ClosedTopicSessionTests.java#closedTopicSessionCreateSubscriberMsgSelectorTest_from_appclient
      FAILED........com/sun/ts/tests/jms/ee/all/closedtopicsessiontests/ClosedTopicSessionTests.java#closedTopicSessionCreateSubscriberTest_from_appclient
      FAILED........com/sun/ts/tests/jms/ee/all/closedtopicsessiontests/ClosedTopicSessionTests.java#closedTopicSessionCreateTempTopicTest_from_appclient
      FAILED........com/sun/ts/tests/jms/ee/all/closedtopicsessiontests/ClosedTopicSessionTests.java#closedTopicSessionCreateText2MessageTest_from_appclient
      FAILED........com/sun/ts/tests/jms/ee/all/closedtopicsessiontests/ClosedTopicSessionTests.java#closedTopicSessionCreateTextMessageTest_from_appclient
      FAILED........com/sun/ts/tests/jms/ee/all/closedtopicsessiontests/ClosedTopicSessionTests.java#closedTopicSessionCreateTopicTest_from_appclient
      FAILED........com/sun/ts/tests/jms/ee/all/closedtopicsessiontests/ClosedTopicSessionTests.java#closedTopicSessionGetDeliveryModeTest_from_appclient
      FAILED........com/sun/ts/tests/jms/ee/all/closedtopicsessiontests/ClosedTopicSessionTests.java#closedTopicSessionGetDisableMessageIDTest_from_appclient
      FAILED........com/sun/ts/tests/jms/ee/all/closedtopicsessiontests/ClosedTopicSessionTests.java#closedTopicSessionGetDisableMessageTimestampTest_from_appclient
      FAILED........com/sun/ts/tests/jms/ee/all/closedtopicsessiontests/ClosedTopicSessionTests.java#closedTopicSessionGetMessageSelectorTest_from_appclient
      FAILED........com/sun/ts/tests/jms/ee/all/closedtopicsessiontests/ClosedTopicSessionTests.java#closedTopicSessionGetNoLocalTest_from_appclient
      FAILED........com/sun/ts/tests/jms/ee/all/closedtopicsessiontests/ClosedTopicSessionTests.java#closedTopicSessionGetPriorityTest_from_appclient
      FAILED........com/sun/ts/tests/jms/ee/all/closedtopicsessiontests/ClosedTopicSessionTests.java#closedTopicSessionGetTimeToLiveTest_from_appclient
      FAILED........com/sun/ts/tests/jms/ee/all/closedtopicsessiontests/ClosedTopicSessionTests.java#closedTopicSessionGetTransactedTest_from_appclient
      FAILED........com/sun/ts/tests/jms/ee/all/closedtopicsessiontests/ClosedTopicSessionTests.java#closedTopicSessionPublish1Test_from_appclient
      FAILED........com/sun/ts/tests/jms/ee/all/closedtopicsessiontests/ClosedTopicSessionTests.java#closedTopicSessionPublish2Test_from_appclient
      FAILED........com/sun/ts/tests/jms/ee/all/closedtopicsessiontests/ClosedTopicSessionTests.java#closedTopicSessionPublisherCloseTest_from_appclient
      FAILED........com/sun/ts/tests/jms/ee/all/closedtopicsessiontests/ClosedTopicSessionTests.java#closedTopicSessionPublisherGetTopicTest_from_appclient
      FAILED........com/sun/ts/tests/jms/ee/all/closedtopicsessiontests/ClosedTopicSessionTests.java#closedTopicSessionReceiveNoWaitTest_from_appclient
      FAILED........com/sun/ts/tests/jms/ee/all/closedtopicsessiontests/ClosedTopicSessionTests.java#closedTopicSessionReceiveTest_from_appclient
      FAILED........com/sun/ts/tests/jms/ee/all/closedtopicsessiontests/ClosedTopicSessionTests.java#closedTopicSessionReceiveTimeoutTest_from_appclient
      FAILED........com/sun/ts/tests/jms/ee/all/closedtopicsessiontests/ClosedTopicSessionTests.java#closedTopicSessionRecoverTest_from_appclient
      FAILED........com/sun/ts/tests/jms/ee/all/closedtopicsessiontests/ClosedTopicSessionTests.java#closedTopicSessionRollbackTest_from_appclient
      FAILED........com/sun/ts/tests/jms/ee/all/closedtopicsessiontests/ClosedTopicSessionTests.java#closedTopicSessionSetDeliveryModeTest_from_appclient
      FAILED........com/sun/ts/tests/jms/ee/all/closedtopicsessiontests/ClosedTopicSessionTests.java#closedTopicSessionSetDisableMessageIDTest_from_appclient
      FAILED........com/sun/ts/tests/jms/ee/all/closedtopicsessiontests/ClosedTopicSessionTests.java#closedTopicSessionSetDisableMessageTimestampTest_from_appclient
      FAILED........com/sun/ts/tests/jms/ee/all/closedtopicsessiontests/ClosedTopicSessionTests.java#closedTopicSessionSetPriorityTest_from_appclient
      FAILED........com/sun/ts/tests/jms/ee/all/closedtopicsessiontests/ClosedTopicSessionTests.java#closedTopicSessionSetTimeToLiveTest_from_appclient
      FAILED........com/sun/ts/tests/jms/ee/all/closedtopicsessiontests/ClosedTopicSessionTests.java#closedTopicSessionSubscriberCloseTest_from_appclient
      FAILED........com/sun/ts/tests/jms/ee/all/closedtopicsessiontests/ClosedTopicSessionTests.java#closedTopicSessionSubscriberGetTopicTest_from_appclient
      FAILED........com/sun/ts/tests/jms/ee/all/closedtopicsessiontests/ClosedTopicSessionTests.java#closedTopicSessionUnsubscribeTest_from_appclient
      FAILED........com/sun/ts/tests/jms/ee/all/exceptiontopictests/ExceptionTopicTests.java#xIllegalStateExceptionTopicTest_from_appclient
      FAILED........com/sun/ts/tests/jms/ee/all/exceptiontopictests/ExceptionTopicTests.java#xInvalidDestinationExceptionTopicTest_from_appclient
      FAILED........com/sun/ts/tests/jms/ee/all/exceptiontopictests/ExceptionTopicTests.java#xInvalidSelectorExceptionTopicTest_from_appclient
      FAILED........com/sun/ts/tests/jms/ee/all/exceptiontopictests/ExceptionTopicTests.java#xMessageEOFExceptionTTestforBytesMessage_from_appclient
      FAILED........com/sun/ts/tests/jms/ee/all/exceptiontopictests/ExceptionTopicTests.java#xMessageEOFExceptionTTestforStreamMessage_from_appclient
      FAILED........com/sun/ts/tests/jms/ee/all/exceptiontopictests/ExceptionTopicTests.java#xMessageFormatExceptionTTestforBytesMessage_from_appclient
      FAILED........com/sun/ts/tests/jms/ee/all/exceptiontopictests/ExceptionTopicTests.java#xMessageFormatExceptionTTestforStreamMessage_from_appclient
      FAILED........com/sun/ts/tests/jms/ee/all/exceptiontopictests/ExceptionTopicTests.java#xMessageNotReadableExceptionTopicTest_from_appclient
      FAILED........com/sun/ts/tests/jms/ee/all/exceptiontopictests/ExceptionTopicTests.java#xMessageNotWriteableExceptionTestforBytesMessage_from_appclient
      FAILED........com/sun/ts/tests/jms/ee/all/exceptiontopictests/ExceptionTopicTests.java#xMessageNotWriteableExceptionTTestforMapMessage_from_appclient
      FAILED........com/sun/ts/tests/jms/ee/all/exceptiontopictests/ExceptionTopicTests.java#xMessageNotWriteableExceptionTTestforStreamMessage_from_appclient
      FAILED........com/sun/ts/tests/jms/ee/all/exceptiontopictests/ExceptionTopicTests.java#xMessageNotWriteableExceptionTTestforTextMessage_from_appclient
      FAILED........com/sun/ts/tests/jms/ee/all/exceptiontopictests/ExceptionTopicTests.java#xNullPointerExceptionTopicTest_from_appclient
      FAILED........com/sun/ts/tests/jms/ee/all/sessiontests/SessionTests.java#InvalidSelectorTests_from_appclient
      FAILED........com/sun/ts/tests/jms/ee/all/topicconntests/TopicConnTests.java#connNotStartedTopicTest_from_appclient
      FAILED........com/sun/ts/tests/jms/ee/all/topictests/TopicTests.java#durableSubscriberChangeSelectorTest_from_appclient
      FAILED........com/sun/ts/tests/jms/ee/all/topictests/TopicTests.java#durableSubscriberNewTopicTest_from_appclient
      FAILED........com/sun/ts/tests/jms/ee/all/topictests/TopicTests.java#durableSubscriberTopicNoLocalTest_from_appclient
      FAILED........com/sun/ts/tests/jms/ee/all/topictests/TopicTests.java#inactiveDurableSubscriberTopicRecTest_from_appclient
      FAILED........com/sun/ts/tests/jms/ee/all/topictests/TopicTests.java#noLocalDeliveryTopicTest_from_appclient
      FAILED........com/sun/ts/tests/jms/ee/all/topictests/TopicTests.java#simpleDurableSubscriberTopicTest_from_appclient
      FAILED........com/sun/ts/tests/jms/ee/all/topictests/TopicTests.java#temporaryTopicConnectionClosesTest_from_appclient
      FAILED........com/sun/ts/tests/jms/ee/all/topictests/TopicTests.java#temporaryTopicNotConsumableTest_from_appclient
      

              rh-ee-ataylor Andy Taylor
              msvehla@redhat.com Martin Svehla
              Martin Svehla Martin Svehla
              Martin Svehla Martin Svehla
              Votes:
              0 Vote for this issue
              Watchers:
              7 Start watching this issue

                Created:
                Updated:
                Resolved: