Log In | Sign Up   View a printable version of the current page.
  Dashboard > flexive > ... > Checking out and working with the sources > JVM Arguments

Added by Markus Plesser, last edited by Markus Plesser on Dec 07, 2007
Labels: 
(None)

During development, you may or may not wish to use some of the following system properties that may be set before launching [fleXive].

The JAVA_OPTS environment variable is evaluated by the JBoss launcher, if you use another application server, you may need to set the properties in other places. Also, bash syntax is used for setting environment variables.

  • Specify the maximum heap size:
    In this example, we allow for a maximum heap size of 512 megabytes and enable AWT headless support:
    export JAVA_OPTS="$JAVA_OPTS -Djava.awt.headless=true -Xmx512m -Xms128m"
    
  • Enable remote debugging:
    For debugging via an IDE, turn on remote debugging. You can then connect with your debugger to the specified port on your server and set breakpoints in your code:
    export JAVA_OPTS="$JAVA_OPTS -Djdbc.connection.debug=true -Xdebug -Xnoagent -Djava.compiler=NONE \
    -Xrunjdwp:transport=dt_socket,server=y,suspend=n,address=5005"
    

    Note that "-Djava.compiler=NONE" disables the JIT compiler and results in much lower performance, so you don't want to use that in a production environment.

Site running on a free Atlassian Confluence Open Source Project License granted to [fleXive] . Evaluate Confluence today.
Powered by Atlassian Confluence, the Enterprise Wiki. (Version: 2.6.1 Build:#916 Nov 09, 2007) - Bug/feature request - Contact Administrators