geronimo-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From David Jencks <>
Subject Re: Don't find a place to set the class path
Date Fri, 22 Jun 2007 20:14:08 GMT

On Jun 22, 2007, at 1:49 PM, Jerry Luo wrote:

> I am trying to deploy a application on geronimo 1.1.1. And the  
> application
> needs to visit some resource files, and the resource files are in a  
> path.
> But I didn't find any place to set the path into the class path. In  
> WEBLOGIC, I can add the path to class path by modifying its start  
> up script.
> But I don't know how to add it into Geronimo start up script. I  
> tried to add
> 'CLASSPATH' to geronimo.bat, but it didn't work.

There are two recommended ways to do this in geronimo:

1. If your resources can be relocated and are in a jar file, install  
the jar file at an appropriate location in the geronimo repository  
and include a dependency on the jar file in your geronimo deployment  
plan.  For instance your plan might start something like this:

<web-app xmlns="">
     <environment xmlns=" 

2. If you can't move the resources into the geronimo repo or they  
aren't in a jar file, add a SharedLib gbean to your geronimo  
deployment plan, and point it to where you want to put the files.   
For instance the configuration might look like:

     <gbean name="SharedLib"  
         <attribute name="classesDirs">/absolute/path/to/the/ 
         <reference name="ServerInfo">

Both of these methods get the resources into the classloader of your  
app without forcing them into every application running in geronimo.

hope this helps
david jencks

> -- 
> View this message in context: 
> place-to-set-the-class-path-tf3966076s134.html#a11257037
> Sent from the Apache Geronimo - Users mailing list archive at  

View raw message