Access ServletContext from JAX-WS web service
Is there a way to access the ServletContext out of a deployed JAX-WS web service when NOT currently executing a web service request? Injection of the @Resource WebServiceContext works fine, but accessing the ServletContext from there only works in the WebMethods...
I would need to get the context (actually, the directory where my application was deployed) already at initialisation, such as in a @PostConstruct method, e.g. to access configuration files.
Is there any way to do this? I'd appreciate any help :)