1 of 1 people found this helpful
you'll have to activate/deactive the request context manually. The CDI spec does not define any portable way for manipulating contexts so you will have to use Weld API (there's an example in Weld docs, 19.1. Managing the built in contexts: http://docs.jboss.org/weld/reference/latest/en-US/html/contexts.html#d0e5607). If working with Java SE, DeltaSpike ContainerControl module might be the best way (makes use of Weld API under the hood). You may also have a look at cdiqi - a simple prove of concept for Quartz Scheduler CDI integration (it supports request context during job execution).
Thanks Martin , i will try it .