2 Replies Latest reply on Oct 10, 2005 8:29 AM by Kevin Lam

    JBoss variables

    Kevin Lam Newbie

      Hi All,

      Sorry to cross post here and in the beginner's corner. I really need to know how to create a variable in JBoss (i.e. ${jboss.server.home.dir}) which can let me specify a file in the log4j.properties.

      Many thx


        • 1. Re: JBoss variables
          Andy Nguyen Newbie

          From what I've seen, log4j will automatically replace ${...} with the corresponding value in system properties. So if you include ${my.log.dir} as a value in your log4j.properties, you could specify -Dmy.log.dir=/path/to/log/dir in the command line and /path/to/log/dir will be substitued for ${my.log.dir} by log4j.

          You could also create a properties file that contains my.log.dir=/path/to/log/dir and pass it to JBoss's main program using -P my.properties.

          • 2. Re: JBoss variables
            Kevin Lam Newbie

            Thx for your reply, I am a bit confused... How to start JBoss with the -D or -P options?

            I am using eclipse plugin for starting JBoss at the moment.

            Also, is there not a kind of xml configuration file which I can specifies the variables name? :)