users@jax-ws.java.net

RE: Re: WebServiceContext not being injected

From: Crampton, Eric <esc_at_amazon.com>
Date: Wed, 11 Jan 2006 13:37:39 -0800

> Can you access WebServiceContext from a web service
> method(not from constructor)? The injection is done after the
> endpoint object is created. Let us know if that works.

Yes, I figured out that this was the problem. (This actually works much like other dependency injection mechanisms like Spring.) So, the rule of thumb is that you shouldn't use your WebServiceContext until after your object has been fully constructed. Makes perfect sense.

--Eric