Uploaded image for project: 'Codehaus Cargo'
  1. CARGO-557

The Xmx and the Xms JVM arguments seem to be hardcoded for the JBoss server

    Details

    • Type: Bug
    • Status: Closed (View workflow)
    • Priority: Major
    • Resolution: Fixed
    • Affects versions: 0.9
    • Fix versions: 1.0
    • Components: JBoss
    • Labels:
      None
    • Environment:

      Any

      Description

      What I needed to do is to start an existing server configuration of the JBoss server using an Ant target (please check the end of the post).
      I use the "cargo.jvmargs" property to set the JVM arguments, but when I checked the Cargo log file, I can see the following
      16:19:35.453debugtalledLocalContainer Executing 'c:\Java\jdk1.5.0\jre\bin\java.exe' with arguments:
      '-Xdebug'
      '-Xrunjdwp:transport=dt_socket,address=8787,server=y,suspend=n'
      '-Dprogram.name=run.bat'
      '-XX:NewSize=128m'
      '-XX:SurvivorRatio=16'
      '-XX:MaxNewSize=164m'
      '-Xms164m'
      '-Xmx512m'
      '-XX:PermSize=128m'
      '-Dsun.rmi.dgc.client.gcInterval=300000'
      '-Dsun.rmi.dgc.server.gcInterval=300000'
      '-Xms128m'
      '-Xmx512m'
      '-DCLASSPATH=c:\Java\jdk1.5.0\lib\tools.jar;c:/Java/jboss-4.0.4.GA/bin/run.jar'
      '-Djava.endorsed.dirs=c:\Java\jboss-4.0.4.GA\lib\endorsed'
      '-Djboss.home.dir=c:/Java/jboss-4.0.4.GA'
      '-Djboss.server.home.dir=c:/Java/jboss-4.0.4.GA/server/ers'
      '-Djboss.server.home.url=file:/c:/Java/jboss-4.0.4.GA/server/ers/'
      '-Djboss.server.name=jboss4x'
      '-Djboss.server.lib.url=file:/c:/Java/jboss-4.0.4.GA/server/ers/lib/'
      '-classpath'
      'c:\Java\jboss-4.0.4.GA\bin\run.jar;c:\Java\jdk1.5.0\lib\tools.jar'
      'org.jboss.Main'
      '--configuration=jboss4x'

      It seems for me that the '-Xms128m' and '-Xmx512m' JVM arguments are hard coded and what is wrong is that they overwrite my values specified from the Ant target.

      The ant target:
      <target name="start_jboss">
      <property environment="env" />
      <property name="jboss.home" value="c:/Java/jboss-4.0.4.GA"></property>

      <cargo containerId="jboss4x" home="$

      {jboss.home}" action="start" wait="false"
      log="cargo.log" loglevel="debug">
      <sysproperty key="CLASSPATH" value="${env.JAVA_HOME}\lib\tools.jar;${jboss.home}

      /bin/run.jar" />

      <configuration type="existing" home="$

      {jboss.home}/server/ers">
      <property name="cargo.jvmargs" value="-Xdebug -Xrunjdwp:transport=dt_socket,address=8787,server=y,suspend=n -Dprogram.name=run.bat -XX:NewSize=128m -XX:SurvivorRatio=16 -XX:MaxNewSize=164m -Xms164m -Xmx512m -XX:PermSize=128m -Dsun.rmi.dgc.client.gcInterval=300000 -Dsun.rmi.dgc.server.gcInterval=300000" />
      <property name="cargo.jboss.configuration" value="ers" />
      <property name="java.endorsed.dirs" value="${jboss.home}

      /lib/endorsed" />
      </configuration>
      </cargo>
      </target>

        Attachments

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              cristianbotezan Cristian Botezan (Inactive)
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: