Rop
Rop

Reputation: 3409

Separating property-files from war-file in WebLogic

I am building a war-application for WebLogic.

I have some property files I would like to keep separate from the war-file, so I can deploy the same war in different environments.

I tried to solve it by putting

Class-Path: /opt/myapp/config

in the war MANIFEST, and then put the property-files in that directory, but that doesnt seem to work in WebLogic? The property-files apparently are not found by the application...

I read some posts, that not all Java EE-containers implement this feature. Is it correct that WebLogic does not (we are using 10.3.0), or is this supposed to work?

If not, what is the best way to solve this issue?

Upvotes: 0

Views: 4774

Answers (1)

JoseK
JoseK

Reputation: 31371

This should work if the properties are found in the System classpath so your options are

1) Try with the property file placed in the Domain_home at this path $WEBLOGIC_HOME/user_projects/domains/YOURDOMAIN

2) Use the Weblogic feature of Generic File Loading Overrides: http://download.oracle.com/docs/cd/E21764_01/web.1111/e13702/config.htm#i1066493

Upvotes: 1

Related Questions