[wildfly-dev] Getting ManagedThreadFactory in a subsystem
Gytis Trikleris
gytis at redhat.com
Tue Jun 23 10:20:50 EDT 2015
Hello,
I’ve got an issue with my subsystem
(https://github.com/wildfly/wildfly/tree/master/transactions) where I
cannot access BeanManager or UserTransaction from JNDI (I can however
lookup datasources). This error is currently happening during periodic
recovery i.e. on PeriodicRecovery thread. My assumption is that the CDI
and EE JNDI environment are not initialized because PeriodicRecovery
extends Thread and was created with the “new” operator rather than
ManagedThreadFactory and I know that EE apps are meant to use this
approach to ensure their environments are initialized correctly - does
this restriction apply to subsystems too? One issue I am coming up
against during prototyping is that I’m not sure how to get the
ManagedThreadFactory during our subsystems boot time as it does not
appear in JNDI.
I would like to know if it is possible to inject the
ManagedThreadFactory into my subsystem so I am not reliant upon its
availability in JNDI.
Thanks,
Gytis
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/wildfly-dev/attachments/20150623/bb855283/attachment.html
More information about the wildfly-dev
mailing list