2

Debugging remote container jboss7.1.1 fails with arquillian. I set the debugging conf in the standalone.conf.bat as described here https://community.jboss.org/wiki/WhyDontBreakPointsWorkWhenDebugging. But that doesn't starts the jboss in debugging mode. Consoleoutput:

INFO: Starting container with: [D:\java\jdk1.6.0_22\bin\java, -Xmx512m,
 -XX:MaxPermSize=128m, -ea, -Djboss.home.dir=target/jboss-as-7.1.1.Final,
...

Using arquillian 1.0.3.Final.

Michael K.
  • 1,738
  • 2
  • 17
  • 35
  • Are you using standalone.bat to start the server? If not, the settings in standalone.conf.bat would not be applied. Running standalone.bat should print out the `JAVA_OPTS` environment variable to the console (unlike your snippet). – Vineet Reynolds Oct 26 '12 at 08:52
  • Arquillian, which is a test-framework for enterprise applications, starts the server. I have no influence. I did it as described in this tutorial: http://arquillian.org/guides/getting_started/?utm_source=cta – Michael K. Oct 26 '12 at 12:17
  • 1
    So you're using a managed container? If so, see [here](https://docs.jboss.org/author/display/ARQ/JBoss+AS+7.1%2C+JBoss+EAP+6.0+-+Managed) for the 7.1.x managed container config reference. You need to set the `javaVmArguments` in arquillian.xml – Vineet Reynolds Oct 26 '12 at 19:33
  • Thanks. That has helped. If you write it as answer I can accept it if you like. – Michael K. Oct 29 '12 at 12:24
  • Is there a definitive simple answer for this? – jacktrades Jan 24 '13 at 23:33

1 Answers1

3

If you use a managed container and arquillian is starting JBoss AS for you, you need to add the option to arquillian.xml. Something like:

<arquillian xmlns="http://jboss.org/schema/arquillian"
            xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
            xsi:schemaLocation="http://jboss.org/schema/arquillian
        http://jboss.org/schema/arquillian/arquillian_1_0.xsd">

    <engine>
        <property name="deploymentExportPath">target/</property>
    </engine>

    <container qualifier="jboss" default="true">
        <protocol type="jmx-as7">
            <property name="executionType">REMOTE</property>
        </protocol>
        <configuration>
            <property name="jbossHome">${basedir}/target/jboss-as-${jbossas.version}</property>
            <property name="javaVmArguments">-Xrunjdwp:transport=dt_socket,address=5005,server=y,suspend=y -Xmx512m -XX:MaxPermSize=128m</property>
        </configuration>
    </container>

</arquillian>
Hardy
  • 18,659
  • 3
  • 49
  • 65