This week's book giveaway is in the Agile and other Processes forum.
We're giving away four copies of The Mikado Method and have Ola Ellnestam and Daniel Brolund on-line!
See this thread for details.
The moose likes BEA/Weblogic and the fly likes How to get this directory into my classpath? Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login


Win a copy of The Mikado Method this week in the Agile and other Processes forum!
JavaRanch » Java Forums » Products » BEA/Weblogic
Reply Bookmark "How to get this directory into my classpath?" Watch "How to get this directory into my classpath?" New topic
Author

How to get this directory into my classpath?

Dave Alvarado
Ranch Hand

Joined: Jul 02, 2008
Posts: 434
Hi,

This may be better directed for another forum, but I'll start here. I'm using WL 9.2.2. I have a bunch of properties files I need to reference from my WAR file using ClassLoader's "getResourceAsStream". Problem is, I can't add the directory where the properties files live as a command line option to WL start up -- bureaucratic company policy.

Is there another way I can incorporate that directory into my classpath at run time?

Thanks, - Dave
Freddy Wong
Ranch Hand

Joined: Sep 11, 2006
Posts: 959

If you're able to read the properties files from the classpath. You can put them in the WEB-INF/classes.

Hope this helps.


SCJP 5.0, SCWCD 1.4, SCBCD 1.3, SCDJWS 1.4
My Blog
Mike McAngus
Greenhorn

Joined: Jun 04, 2005
Posts: 5
I have a similar issue. I need a work directory where my application can dynamically create and compile java classes. This directory needs to be in the classpath of the application so that the classes can be compiled with the jars that are included in my .war.

Any idea how one adds an external directory to the classpath of a web application run from a .war file in WebLogic 9.2.2?
 
I agree. Here's the link: http://zeroturnaround.com/jrebel - it saves me about five hours per week
 
subject: How to get this directory into my classpath?
 
Similar Threads
Referring property files
** Hola, i need help with hibernate !!!!
ResourceBundles & its properties files
Hot Deployment in Wenblogic 6.1
Twiddle Utility and Classpath