title: Setting multiple truststore on the same JVM
body: <p>I have an Java application running on a weblogic server. The application has two distinct modules which use SSL to connect to external web services - let's say module A and module B.</p>
  
  <p>Module A - Built on Axis - Uses truststore A
  Moudle B - Built on Spring-ws - Uses truststore B.</p>
  
  <p>Module A is existing. Module B is being introduced.</p>
  
  <p>I need to be able to set the truststore dynamically in the JVM based on which module is being invoked. </p>
  
  <p>Due to some constraints I do not have the option
  - to create a custom key manager.
  - use one truststore</p>
  
  <p>I tried to use System.setProperty im Module B codebase to set truststore. However it works only if Module B got invoked first. For example - Say 
  I have a fresh restart of the JVM
  then I invoke module A - it set's it's own truststore in the JVM
  then I invoke module B - It fails - it's does not set it's own truststore in the JVM even though I have used System.setProperty method.</p>
  
  <p>Am I missing something or it's just that System.setProperty doesn't override existing set values. If so what are my options here.</p>