3 Replies Latest reply on Jan 6, 2014 3:53 AM by kpiwko

    run arquillian on remote cloud machine

    shashanksingal

      I am able to run arquillian tests on my local machine using eclipse/terminal. I tried running arquillian from my local machine to jboss deployed on cloud server. I am sure that the dependencies are properly added.

      This is how I login to cloud server:

       

      `ssh -p xxxx root@cloud.abcd.pqr.wxy.xyz`

       

      Part of my `arquillian.xml`:

       

      <container qualifier="jboss_remote" default="true">

             

       

          <container qualifier="jboss_remote" default="true">

              <configuration>

                  <property name="managementAddress">cloud.abcd.pqr.wxy.xyz</property>

                  <property name="managementPort ">9999</property>

                  <property name="username">root</property>

                  <property name="password">shroot</property>

                 

              </configuration>

          </container>

       

      Please see the console output when I run arquillian tests

       

          org.jboss.arquillian.container.spi.client.container.LifecycleException: Could not start container

              at org.jboss.as.arquillian.container.managed.ManagedDeployableContainer.startInternal(ManagedDeployableContainer.java:167)

              at org.jboss.as.arquillian.container.CommonDeployableContainer.start(CommonDeployableContainer.java:113)

              at org.jboss.arquillian.container.impl.ContainerImpl.start(ContainerImpl.java:199)

          Caused by: java.util.concurrent.TimeoutException: Managed server was not started within [60] s

              at org.jboss.as.arquillian.container.managed.ManagedDeployableContainer.startInternal(ManagedDeployableContainer.java:163)

              ... 77 more

        • 1. Re: run arquillian on remote cloud machine
          shashanksingal

          Another thing I noticed is that in arquillian.xml when I give managementAddress and managementPort as 127.0.0.1:9999, it works .
          but when I try putting managementAddress and managementPort as myIP:9999, it doesnt work

          Is there some configuration I have skipped?
          I have added a management user that can use jboss remotely with name jenkins and updated my arquillian.xml with credenials.

          • 2. Re: run arquillian on remote cloud machine
            shashanksingal

            The issue why I was not able to deploy using arquillian to remote Jboss with managementAddress and managementPort as myIP:9999 was I did not configured my standalone.xml properly, this is what I have modified in standalone.xml

            <interfaces>

                    <interface name="management">

                        <any-address/>

                    </interface>

                    <interface name="public">

                        <any-address/>

                    </interface>

                    <interface name="unsecure">

                        <any-address/>

                    </interface>

                </interfaces>

             

            Now when I am trying to run arquillian tests on remote jboss, arquillian deploys the shrinkwrap ear but unable to run test cases. This is the exception I am getting:

            Tests run: 5, Failures: 0, Errors: 5, Skipped: 0, Time elapsed: 5.118 sec <<< FAILURE!

            basicSanitytest(test.integration.pm.parser.ejb.PMFileParserTest)  Time elapsed: 0.019 sec  <<< ERROR!

            java.lang.IllegalStateException: Error launching test test.integration.pm.parser.ejb.PMFileParserTest public void test.integration.pm.parser.ejb.PMFileParserTest.basicSanitytest()

                at org.jboss.arquillian.protocol.servlet.ServletMethodExecutor.invoke(ServletMethodExecutor.java:126)

                at org.jboss.arquillian.container.test.impl.execution.RemoteTestExecuter.execute(RemoteTestExecuter.java:120)

            ..........

            Caused by: java.lang.IllegalStateException: Error launching request at http://0.0.0.0:8080/test/ArquillianServletRunner?outputMode=serializedObject&className=test.integration.pm.parser.ejb.PMFileParserTest&methodName=basicSanitytest. No result returned

                at org.jboss.arquillian.protocol.servlet.ServletMethodExecutor.executeWithRetry(ServletMethodExecutor.java:162)

                at org.jboss.arquillian.protocol.servlet.ServletMethodExecutor.invoke(ServletMethodExecutor.java:122)

                ... 90 more

            • 3. Re: Re: run arquillian on remote cloud machine
              kpiwko

              Hi Shashank,

               

              my guess is that 0.0.0.0 as binding address is the problem. Could you please try to add:

               

              <property name="javaVmArguments">-Xmx512m -XX:MaxPermSize=128m -Djboss.bind.address=${ip.jboss}</property>
              

               

              into container configuration, replace ${ip.jboss} with a real IP address where server will be run to see whether it helps you?

               

              Thanks,

               

              Karel