Status: New
Owner: ----
New issue 523 by karve.amod: Injection support for spawned threads (Request
scoped)
http://code.google.com/p/google-guice/issues/detail?id=523
I often find myself programming servlets where I need to spawn of worker
threads to get a job done. It seems that GuiceFilter uses a ThreadLocal
object to store the context. This means that request scoping doesn't carry
over to spawned threads.
It would be very helpful if GuiceFilter provided a ThreadFactory which
could be used while spawning worker threads. The threadlocal context for
this worker thread could then be initialized by GuiceFilter to the same
context as the parent thread.
Does this seem like a reasonable approach? If so, I would be willing to
help implement this feature if you point me in the right direction.
--
You received this message because you are subscribed to the Google Groups
"google-guice-dev" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/google-guice-dev?hl=en.