webtier@glassfish.java.net

Re: [webtier] Re: serving images with glassfish

From: <webtier_at_javadesktop.org>
Date: Fri, 06 Feb 2009 21:33:39 PST

Hi, Is it possible to utilize JSTL and system properties within the sun-web.xml for the alternate docroot? Since our application will be deployed for multiple scenarios, this could change on each and I'd rather have a system property that is altered as opposed to a hard coded path within the sun-web.xml, currenlty it appears that it cannot (or rather it didn't translate my paramater).

Example: System property defined as: my_alt_docroot=/var/altdocroot

Then in sun-web.xml:
  <property name="alternatedocroot_1" value="from=/text/* dir=${my_alt_docroot}/text">
    <description>External Text Directory Mapping</description>
  </property>

What I am seeing is the following error:
[#|2009-02-06T21:08:32.878-0800|SEVERE|sun-appserver9.1|org.apache.catalina.core.StandardContext|_ThreadID=13;_ThreadName=pool-1-thread-13;_RequestID=a713cc60-6135-40f2-bc9d-c37466c1c3a2;|PWC4430: Document base /opt/glassfish/nodeagents/g1-a1/g1-i1/${my_alt_docroot}/text does not exist or is not a readable directory|#]


On the above, /opt/glassfish/nodeagents/g1-a1/g1-i1 is the ${com.sun.aas.instanceRoot} so I'm not certain why that is trying to factor into the equation as I don't have that there...

On a side note my context root is "/", does this have any affect?
[Message sent by forum member 'dominic_mcginnis' (dominic_mcginnis)]

http://forums.java.net/jive/thread.jspa?messageID=330638