Hello everyone,
What I need to get done:
- deploy several webservices on one
jboss server
- all of them have to provide a wsdl description file
- every one of them is using one class pt.iscte.fenix.util.PropertiesManager for getting configuration information from build.properties in the runtime
Problem description (short):
Every webservice uses the same instance of PropertiesManager (the one that was first loaded in the memory) which points to the wrong build.properties file (and every webservice has it's own build.properties files with different keys)
What I want to achieve:
I want to isolate webservices so that each of them is in their own sandbox.
Problem description(longer):
When I deploy one webservice packed as jar into jboss/server/deploy everything works as expected - the properties from build.properties are read properly. But when I deploy another webservice instead of using properties from its own build.properties it uses the ones that were used by the first webservice. So it obviously means that it has to use the PropertiesManager instance created by the first service.
A temporary solution would be to use different class names for PropertiesManager for every webservice (I've tried, it works), but that doesn't solve the main problem, which is namespace conflict. So I would like to put every jar into their own sanbox, so that I'm assured it only uses its own classes.
I've came across solution to put the jar file into ear and provide ear with META-INF/jboss-app.xml:
But since I'm counting on jbossws and annotations to create my wsdl, when I use a jar inside a ear jboss ejbdeployer doesn't generate a wsdl file for me.
I'm using jboss-4.2.3. Every webservice is zipped into jar and compose of at least 3 source files:
##Test1Agent.java:
##Test1AgentBean.java:
##PropertiesManager.java:
If I made anything unclear feel free to point it out. Thanks in advance.