1 Reply Latest reply on Dec 30, 2009 6:31 PM by Wang Liyu

    Seam Test again

    Wang Liyu Apprentice
      I have create the unit test for EJB component, it works fine with the dummy code, but when we try to connect to the real backend (lagacy code can only deploy on JBoss4.0.5GA or JBoss4.2.0 with EJB2), it always failed, I tryed to use jbossall-client.jar from JBoss4.0.5 and JBoss5.1.0GA, it all failed:

         [testng] javax.naming.CommunicationException: Could not obtain connection to any of these urls: localhost:1199 and discovery failed with error: javax.naming.CommunicationExcepti
      on: Receive timed out [Root exception is java.net.SocketTimeoutException: Receive timed out] [Root exception is javax.naming.CommunicationException: Failed to connect to server localhost:1199 [Root exception is java.lang.ClassNotFoundException: org.jnp.server.NamingServer_Stub (no security manager: RMI class loader disabled)]]
         [testng]     at org.jnp.interfaces.NamingContext.checkRef(NamingContext.java:1601)
         [testng]     at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:636)
         [testng]     at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:629)
         [testng]     at javax.naming.InitialContext.lookup(InitialContext.java:392)

      This is the best I could get.

      Can anyone help?

        • 1. Re: Seam Test again
          Wang Liyu Apprentice
          I did a quick test, the embeded JBoss env seems doesn't work with JBossAS4.0.5GA, JBossAS4.2.3GA (exceptions are different), it works with JBossAS5.1.0GA though, I try to add some options and still got no luck, so far I have tried,
          jbossall-client.jar (JBoss4.0.5GA) to JBoss4.0.5GA(not working)
          jbossall-client.jar (JBoss5.1.0GA) to JBoss4.0.5GA(not working, -Djboss.remoting.pre_2_0_compatible=true and -Dorg.jboss.j2ee.Serialization=true)
          jbossall-client.jar (JBoss4.2.3GA) to JBoss4.2.3(not working)
          jbossall-client.jar (JBoss5.1.0GA) to JBoss4.2.3(not working, -Dorg.jboss.j2ee.Serialization=true)
          jbossall-client.jar (JBoss5.1.0GA) to JBoss5.1.0GA(working)

          Can anyone help?