Win a copy of Mesos in Action this week in the Cloud/Virtualizaton forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

How to get this directory into my classpath?

 
Dave Alvarado
Ranch Hand
Posts: 436
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
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
Posts: 959
Eclipse IDE Java Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
If you're able to read the properties files from the classpath. You can put them in the WEB-INF/classes.

Hope this helps.
 
Mike McAngus
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
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?
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic