my prod environment
ubuntu 804 server
java 16
velo 15

my code to initialize

Properties props = new Properties();
props.setProperty(RuntimeConstants.FILE_RESOURCE_LOADER_PATH,
"/usr/share/tomcat6/webapps/my/WEB-INF/classes");
Velocity.init(props);

the code to call the vm

    StringWriter writer = new StringWriter();
    org.apache.velocity.Template template =
Velocity.getTemplate("/myfolder/mytemplate.vm");
    template.merge(this.context, writer);

this throws
org.apache.velocity.exception.ResourceNotFoundException: Unable to
find resource '/usr/share/tomcat6/webapps/my/
WEB-INF/classes/myfolder/mytemplate.vm'
obviously the file is there. :)

also I tried with:

no setting any FILE_RESOURCE_LOADER_PATH , doesn't work
passing the absolute url like '/usr/share/tomcat6/webapps/my/
WEB-INF/classes/myfolder/mytemplate.vm, also doesn't work

all this variations works perfectly in windows

any clue ????
thanks guys

Rodrigo Asensio
[EMAIL PROTECTED]
http://www.rodrigoasensio.com
"To err is human, but to really screw up requires the root password."

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to