1 2 Previous Next 25 Replies Latest reply on Nov 14, 2006 3:05 PM by Clebert Suconic Go to original post
      • 15. Re: Application Server Integration Tests
        Richard Achmatowicz Novice

        I'm having a problem with a Remoting exception when running a generic test case against the scoped meessaging deployment:

        16:14:04,084 INFO [ServerPeer] JBoss Messaging 1.0.1.GA server [server.0] started
        16:14:04,126 INFO [Queue] Queue[/queue/D] started, fullSize=75000, pageSize=2000, downCacheSize=2000
        16:14:04,155 INFO [Queue] Queue[/queue/ex] started, fullSize=75000, pageSize=2000, downCacheSize=2000
        16:14:04,169 INFO [Topic] Topic[/topic/testDurableTopic] started, fullSize=75000, pageSize=2000, downCacheSize=2000
        16:14:04,174 INFO [Queue] Queue[/queue/testQueue] started, fullSize=75000, pageSize=2000, downCacheSize=2000
        16:14:04,178 INFO [Topic] Topic[/topic/openTopic] started, fullSize=75000, pageSize=2000, downCacheSize=2000
        16:14:04,182 INFO [Queue] Queue[/queue/C] started, fullSize=75000, pageSize=2000, downCacheSize=2000
        16:14:04,186 INFO [Topic] Topic[/topic/securedTopic] started, fullSize=75000, pageSize=2000, downCacheSize=2000
        16:14:04,191 INFO [Queue] Queue[/queue/DLQ] started, fullSize=75000, pageSize=2000, downCacheSize=2000
        16:14:04,195 INFO [Queue] Queue[/queue/B] started, fullSize=75000, pageSize=2000, downCacheSize=2000
        16:14:04,627 INFO [ConnectionFactory] Connector socket://10.16.6.135:4457 has leasing enabled, lease period 20000 milliseco\nds
        16:14:04,627 INFO [ConnectionFactory] [/ConnectionFactory, /XAConnectionFactory, java:/ConnectionFactory, java:/XAConnectio\nFactory] deployed
        16:14:04,631 INFO [Topic] Topic[/topic/testTopic] started, fullSize=75000, pageSize=2000, downCacheSize=2000
        16:14:04,637 INFO [Queue] Queue[/queue/A] started, fullSize=75000, pageSize=2000, downCacheSize=2000
        16:14:04,653 INFO [ConnectionFactoryBindingService] Bound ConnectionManager 'jboss.jca:service=ConnectionFactoryBinding,nam\e=JmsXA' to JNDI name 'java:JmsXA'
        16:14:04,673 INFO [WebMetaData] WebMetaData:importJBossWebXml: maxActiveSessions = -1
        16:14:04,691 INFO [TomcatDeployer] deploy, ctxPath=/jmx-console, warUrl=.../deploy/jmx-console.war/
        16:14:05,106 INFO [Http11Protocol] Starting Coyote HTTP/1.1 on http-10.16.6.135-8080
        16:14:05,147 INFO [AjpProtocol] Starting Coyote AJP/1.3 on ajp-10.16.6.135-8009
        16:14:05,169 INFO [Server] JBoss (MX MicroKernel) [5.0.0.Beta (build: CVSTag=HEAD date=200610131450)] Started in 35s:956ms
        16:14:07,479 ERROR [ServerThread] failed to process invocation.
        java.io.IOException: Can not read data for version 6. Supported versions: 1,2
        at org.jboss.remoting.transport.socket.ServerThread.versionedRead(ServerThread.java:394)
        at org.jboss.remoting.transport.socket.ServerThread.processInvocation(ServerThread.java:446)
        at org.jboss.remoting.transport.socket.ServerThread.dorun(ServerThread.java:527)
        at org.jboss.remoting.transport.socket.ServerThread.run(ServerThread.java:261)
        16:14:08,373 INFO [Server] Shutting down the server, blockingShutdown: false

        I have seen this problem reported on the Messaging forums:
        http://www.jboss.org/index.html?module=bb&op=viewtopic&t=89684

        In my case, I am starting up AS with a scoped 1.0.1.GA messaging configuration and trying to execute the test case ConcurrentDeliveryTestCase. This test case happens to create temporary queues, but not with any provision for scoping, as far as I am aware. Would this be a possible cause of the problem?

        • 16. Re: Application Server Integration Tests
          Ovidiu Feodorov Master

          You get this kind of errors when the client-side remoting is incompatible from the server-side remoting, so I would assume you use a very old remoting version on the client-side.

          • 17. Re: Application Server Integration Tests
            Richard Achmatowicz Novice

            It seems to have been a classpath problem on the client side. I had jboss-messaging-client.jar in the client-side java.classpath *after* remoting, serialization, and trove. Changing its position fixed the problem.

            I'm basically ready to commit the changes to allow running generic test cases from testsuite/src/main/org/test/jbossmessaging, but i'll wait until Monday to do it, just incase there are any mistakes which need rectifying.


            • 18. Re: Application Server Integration Tests
              Tim Fox Master

              jboss-messaging-client.jar already contains the versions of remoting, serialization and trove required by messaging.

              This is a bit of a clunky solution but is the way we are currently doing it.

              There is therefore no need to explicit add them on the classpath. In your case you have added different versions before jboss-messaging-client hence your problem.

              • 19. Re: Application Server Integration Tests
                Richard Achmatowicz Novice

                I have a problem with the JBossMQ tests in package jmsra which needs some consideration.

                1. The testsuite uses by default a classpath called tests.classpath to execute client-side JUnit test cases. This classpath is constructed automatically, with the help of jbossbuild, and includes among other things jars from third-party products imported from the repository. This includes Messaging, so that jboss-messaging.jar is included on tests.classpath.

                In order to get the client side tests to work, I need to override the versions of remoting and serialization which get included on tests.classpath. I do this by using the following classpath for my tests:
                ${build.classes}
                ${build.resources}
                thirdparty/jboss-messaging-client.jar
                tests.classpath

                This works fine and makes sure that the client side tests get the right versions of remoting and serialization.

                2. Above and beyond this, the tests in package jmsra deploy a jar, jmsra.jar, which contains some EJBs used in the test; in particular, one called Publisher. When I run any test involving Publisher, I get the following remoting error:

                2006-11-13 10:33:03,930 ERROR [org.jboss.remoting.transport.socket.SocketClientInvoker] Got marshalling exception, exiting
                java.net.SocketException
                at org.jboss.remoting.transport.socket.MicroSocketClientInvoker.transport(MicroSocketClientInvoker.java:352)
                at org.jboss.remoting.MicroRemoteClientInvoker.invoke(MicroRemoteClientInvoker.java:125)
                at org.jboss.remoting.Client.invoke(Client.java:589)
                at org.jboss.remoting.Client.invoke(Client.java:581)
                at org.jboss.invocation.unified.interfaces.UnifiedInvokerProxy.invoke(UnifiedInvokerProxy.java:161)
                at org.jboss.invocation.InvokerInterceptor.invokeInvoker(InvokerInterceptor.java:241)
                at org.jboss.invocation.InvokerInterceptor.invoke(InvokerInterceptor.java:181)
                at org.jboss.proxy.TransactionInterceptor.invoke(TransactionInterceptor.java:61)
                at org.jboss.proxy.SecurityInterceptor.invoke(SecurityInterceptor.java:70)
                at org.jboss.proxy.ejb.HomeInterceptor.invoke(HomeInterceptor.java:184)
                at org.jboss.proxy.ClientContainer.invoke(ClientContainer.java:101)
                at $Proxy1.create(Unknown Source)
                at org.jboss.test.jbossmessaging.ra.RaJMSSessionUnitTestCase.testSendToQueueAndTopic(RaJMSSessionUnitTestCase.java:5\5)
                at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
                at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
                at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
                at java.lang.reflect.Method.invoke(Method.java:585)
                at junit.framework.TestCase.runTest(TestCase.java:154)

                The above error occurs when calling the Publisher home.create() method.

                I believe this may be due to jmsra.jar being deployed in such a way that it picks up the non-modified version of remoting. (Is this correct?) Therefore, I believe that I need to somehow arrange for jmsra.jar to be deployed within the same scoped classloading context as Messaging, so that it will pick up the correct (modified) version of Remoting.
                jmsra.jar is deployed using the method JBossTestCase.deploy() method, which makes a "deploy" invocation on the MBean jboss.system:service=MainDeployer.

                Does anyone know the best way to deploy this jar in such a way that it gets loaded using the scoped deployment? I'll keep on investigating..

                • 20. Re: Application Server Integration Tests
                  Richard Achmatowicz Novice

                  Just had a thought: would the solution here involve modifying the jboss.xml file in the jmsra.jar to specify scoped deployment?

                  • 21. Re: Application Server Integration Tests
                    Richard Achmatowicz Novice

                    I tried scoping the deployment of jmsra.jar by adding a <loader-repository> element to the jboss.xml file in the jar. It seems to deploy the jar in a scoped fashion:

                    2006-11-14 11:15:45,806 DEBUG [org.jboss.deployment.MainDeployer] Starting deployment of package: file:/home/rachmatowicz/jm\s-trunk/testsuite/output/lib/jmsra.jar
                    2006-11-14 11:15:45,806 DEBUG [org.jboss.deployment.MainDeployer] Starting deployment (init step) of package at: file:/home/\rachmatowicz/jms-trunk/testsuite/output/lib/jmsra.jar
                    2006-11-14 11:15:45,807 DEBUG [org.jboss.deployment.MainDeployer] Copying file:/home/rachmatowicz/jms-trunk/testsuite/output\/lib/jmsra.jar -> /home/rachmatowicz/jms-trunk/build/output/jboss-5.0.0.Beta/server/messaging/tmp/deploy/tmp50978jmsra.jar
                    2006-11-14 11:15:45,811 DEBUG [org.jboss.ejb3.deployment.EJB3ClientDeployer] accepts jmsra.jar
                    2006-11-14 11:15:45,866 DEBUG [org.jboss.deployment.MainDeployer] using deployer MBeanProxyExt[jboss.ejb:service=EJBDeployer\]
                    2006-11-14 11:15:45,866 DEBUG [org.jboss.ejb.EJBDeployer] init, jmsra.jar
                    2006-11-14 11:15:45,870 DEBUG [org.jboss.ejb.EJBDeployer] looking for nested deployments in : file:/home/rachmatowicz/jms-tr\unk/testsuite/output/lib/jmsra.jar
                    2006-11-14 11:15:45,872 DEBUG [org.jboss.deployment.DeploymentInfo] createLoaderRepository from config: LoaderRepositoryConf\ig(repositoryName: jboss.messaging:loader=ScopedLoaderRepository, repositoryClassName: org.jboss.mx.loading.HeirarchicalLoad\erRepository3, configParserClassName: org.jboss.mx.loading.HeirarchicalLoaderRepository3ConfigParser, repositoryConfig: java\2ParentDelegation=false)
                    2006-11-14 11:15:45,872 DEBUG [org.jboss.mx.loading.RepositoryClassLoader] setRepository, repository=org.jboss.mx.loading.He\irarchicalLoaderRepository3@178655, cl=org.jboss.mx.loading.UnifiedClassLoader3@205df9{ url=file:/home/rachmatowicz/jms-trun\k/build/output/jboss-5.0.0.Beta/server/messaging/tmp/deploy/tmp50978jmsra.jar ,addedOrder=0}
                    2006-11-14 11:15:45,873 DEBUG [org.jboss.mx.loading.RepositoryClassLoader] setRepository, repository=org.jboss.mx.loading.He\irarchicalLoaderRepository3@178655, cl=org.jboss.mx.loading.UnifiedClassLoader3@205df9{ url=file:/home/rachmatowicz/jms-trun\k/build/output/jboss-5.0.0.Beta/server/messaging/tmp/deploy/tmp50978jmsra.jar ,addedOrder=0}
                    2006-11-14 11:15:45,873 DEBUG [org.jboss.mx.loading.UnifiedLoaderRepository3] Adding org.jboss.mx.loading.UnifiedClassLoader\3@205df9{ url=file:/home/rachmatowicz/jms-trunk/build/output/jboss-5.0.0.Beta/server/messaging/tmp/deploy/tmp50978jmsra.jar \,addedOrder=0}
                    2006-11-14 11:15:45,877 DEBUG [org.jboss.deployment.MainDeployer] found 0 subpackages of file:/home/rachmatowicz/jms-trunk/t\estsuite/output/lib/jmsra.jar

                    Thus, unless i'm doing something wrong, Messaging is deployed in a scoped fashion, the destinations used in tests are deployed in a scoped fashion, and the jmsra.jar is deployed in a scoped fashion. All scoping using the same loader-repository: ScopedLoaderRepository.

                    But when the test is run, the same error appears.

                    11:15:46,279 INFO [EjbModule] Deploying PublisherCMP
                    11:15:46,428 INFO [EjbModule] Deploying JMSSession
                    11:15:46,453 INFO [EjbModule] Deploying QueuePublisher
                    11:15:46,465 INFO [EjbModule] Deploying TopicPublisher
                    11:15:46,477 INFO [EjbModule] Deploying QueueRec
                    11:15:46,485 INFO [EjbModule] Deploying TopicAdapter
                    11:15:47,453 INFO [ProxyFactory] Bound EJB Home 'PublisherCMP' to jndi 'PublisherCMP'
                    11:15:47,469 INFO [ProxyFactory] Bound EJB Home 'JMSSession' to jndi 'JMSSession'
                    11:15:47,488 INFO [ProxyFactory] Bound EJB Home 'QueuePublisher' to jndi 'TxPublisher'
                    11:15:47,496 INFO [ProxyFactory] Bound EJB Home 'TopicPublisher' to jndi 'TxTopicPublisher'
                    11:15:47,510 INFO [ProxyFactory] Bound EJB Home 'QueueRec' to jndi 'QueueRec'
                    11:15:48,959 INFO [EJBDeployer] Deployed: file:/home/rachmatowicz/jms-trunk/testsuite/output/lib/jmsra.jar
                    11:15:49,317 ERROR [ServerThread] failed to process invocation.
                    java.io.OptionalDataException
                    at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1316)
                    at java.io.ObjectInputStream.readObject(ObjectInputStream.java:348)
                    at org.jboss.remoting.serialization.impl.java.JavaSerializationManager.receiveObject(JavaSerializationManager.java:1\28)
                    at org.jboss.remoting.marshal.serializable.SerializableUnMarshaller.read(SerializableUnMarshaller.java:66)
                    at org.jboss.invocation.unified.marshall.InvocationUnMarshaller.read(InvocationUnMarshaller.java:48)
                    at org.jboss.remoting.transport.socket.ServerThread.processInvocation(ServerThread.java:350)
                    at org.jboss.remoting.transport.socket.ServerThread.dorun(ServerThread.java:398)

                    • 22. Re: Application Server Integration Tests
                      Scott Stark Master

                      The jms integration should not require scoping in jboss5.

                      • 23. Re: Application Server Integration Tests
                        Ovidiu Feodorov Master


                        Richard, what JMS artifacts are you using, precisely?

                        • 24. Re: Application Server Integration Tests
                          Clebert Suconic Master

                           

                          "scott.stark@jboss.org" wrote:
                          The jms integration should not require scoping in jboss5.


                          There is a problem with Remoting on Head.

                          We are using remoting 2.2.0.Alpha2 while Head still using 1.4.something.

                          I don't know what would take to synchronize that on head.

                          • 25. Re: Application Server Integration Tests
                            Clebert Suconic Master

                             

                            We are using remoting 2.2.0.Alpha2 while Head still using 1.4.something.


                            I'm working with Richard on this issue...
                            He was using an old version of Head because a broken build sometime ago...
                            We are updating his copy now to see what will happen afterwards.

                            So... Trunk is using 2.2.0.Alpha2... it shouldn't be an issue.

                            1 2 Previous Next