Configuração da JVM

Posted on July 7, 2008. Filed under: coldfusion, j2ee | Tags: |

1. Internacionalização

Para quem desenvolve aplicações ColdFusion JEE para público alvo brasileiro, é necessário “internacionalizar” a JVM (acentuação e formatos de data, hora e moeda).  Observação: parãmetros válidos para a Sun’s HotSpot™ Java Virtual Machin.

No arquivo run.conf:

JAVA_OPTS=”-Xms1024m -Xmx1024m -Xmn512m -Xss128k -Dsun.rmi.dgc.client.gcInterval=3600000 -Dsun.rmi.dgc.server.gcInterval=3600000 -XX:MaxPermSize=128m -XX:+UseParallelGC -XX:+UseParallelOldGC -Djava.awt.headless=true -Djava.net.preferIPv4Stack=true -Dsun.lang.ClassLoader.allowArraySyntax=true “

Acrescentar uma linha com:

JAVA_OPTS=%JAVA_OPTS% -Duser.language=pt -Duser.country=BR -Duser.timezone=Etc/GMT+3  -Dfile.encoding=iso_8859_1

Curiosidade: muitos textos em inglês se referem a internacionalização como “i18n”, porque a palavra “internationalization” começa com a letra “i”, termina a letra com “n”, e possui 18 caracteres entre elas.

2. Habilitar o agente jconsole localmente

Acrescentar uma linha com:

set JAVA_OPTS=%JAVA_OPTS% -Dcom.sun.management.jmxremote

3. Habilitar o agente jconsole remotamente sem utilizar seguraça nem ssl

set JAVA_OPTS=%JAVA_OPTS% -Dcom.sun.management.jmxremote.port=12345″

set JAVA_OPTS=%JAVA_OPTS% -Dcom.sun.management.jmxremote.authenticate=false”

set JAVA_OPTS=%JAVA_OPTS% -Dcom.sun.management.jmxremote.ssl=false”

Refs:

http://java.sun.com/javase/technologies/hotspot/vmoptions.jsp

http://java.sun.com/performance/reference/whitepapers/tuning.html

http://www.jboss.org/community/wiki/UseJDK5JConsole


# Enable the jconsole agent remotely on port 12345
JAVA_OPTS=”$JAVA_OPTS -Dcom.sun.management.jmxremote.port=12345″
JAVA_OPTS=”$JAVA_OPTS -Dcom.sun.management.jmxremote.authenticate=false”
JAVA_OPTS=”$JAVA_OPTS -Dcom.sun.management.jmxremote.ssl=false”

Make a Comment

Make a Comment: ( None so far )

blockquote and a tags work here.

    About

    on the way to run ColdFusion on a JEE application server

    RSS

    Subscribe Via RSS

    • Subscribe with Bloglines
    • Add your feed to Newsburst from CNET News.com
    • Subscribe in Google Reader
    • Add to My Yahoo!
    • Subscribe in NewsGator Online
    • The latest comments to all posts in RSS
    • Subscribe in Rojo

    Meta

  • Categories

Liked it here?
Why not try sites on the blogroll...