Mantis - Resin
Viewing Issue Advanced Details
1842 major always 07-02-07 00:57 07-30-07 11:25
sergek  
ferg  
normal  
closed 3.1.2  
fixed  
none    
none 3.1.3  
0001842: Environment variables no longer work in resin.conf
In the 3.1.2 snapshot, you can no longer pass environment variables into the conf file to use as EL. Here is an example that works in 3.0.x and 3.1.1 and earlier.

httpd.exe -DDEV_HOME=%CD%

resin.conf
<web-app id="/" root-directory="${DEV_HOME}/site-public" />
Tested against snapshot on 6/18.

Notes
(0002096)
ferg   
07-02-07 08:41   
In Resin 3.1, you need -J-DDEV_HOME. The top-level -D would only affect the watchdog manager.

I'm leaving this bug open in case it's possible to propagate the -D directly to the child without the -J.
(0002097)
sergek   
07-02-07 08:47   
Thanks for the explanation. The -D works in 3.1.0 and 3.1.1, and it's only the snapshot that this doesn't work. I also tried passing the value explicitly in <jvm-args> and that didn't get it picked up either.
(0002098)
sergek   
07-02-07 22:02   
Just confirmed that -D works in 3.1.1 but not 3.1.2 snapshot. The -J-D works in 3.1.1 and 3.1.2.

Assuming you intend to leave this change going forward, then you probably want to change the documentation in httpd.exe -h as well as http://www.caucho.com/resin-3.1/doc/resin-web-server.xtp#JDK%20arguments [^]

Thanks.
(0002154)
ferg   
07-30-07 09:52   
The -J-D will have to be the replacement. There doesn't appear to be a way to find out the -D arguments directly, and any heuristic propagation of System.getProperty values would introduce more uncertainty about the normal operation.
(0002155)
ferg   
07-30-07 11:25   
The arguments are available through JMX.