Ok, I finished this. EJB 2.1 and EJB 3.0 are now unified. WAR still has to implement
push/pop of ENC ID, but EJB invoking on a servlet in the same thread should be impossible
right now.
so the way it works is EJB(2 or 3) pushes its ID (ObjectName) onto a stack stored in a
ThreadLocal before it does an invocation (callback, whatever). It pops this ID from the
stack when finished.
java:comp ObjectFactory looks to see if there is something pushed onto the stack, if there
isn't, then it uses the old classloader way.
Ran EJB ENC test, seems to work ok. What I did was search for setContextClassLoader calls
in the EJB codebase and added push/pop where appropriate. (destroyService also cleans up
the ENC).
View the original post :
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3995724#...
Reply to the post :
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&a...