[jbossws-dev] [Design of JBoss Web Services] - Re: WSContractConsumer API in a seam app

jason.greene@jboss.com do-not-reply at jboss.com
Tue Feb 27 15:12:09 EST 2007


Apparently we do use the context loader on the client side. So you will need to change it, however restore it immediately after obtaining the port:


  | ClassLoader oldLoader = Thread.currentThread().getContextClassLoader();
  | 
  | Foo foo;
  | 
  | try
  | {
  |    Thread.currentThread().setContextClassLoader(newLoader);
  |    foo = FooService.getPort();
  | }
  | finally
  | {
  |    Thread.currentThread().setContextClassLoader(oldLoader);
  | }
  | 
  | 

Make sure to remove the JMX classloader calls as well. If it still fails I would need to see the stack trace of the CNFE.

-Jason

View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4023261#4023261

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4023261



More information about the jbossws-dev mailing list