The try...finally block ensures that the restore is done even if doSomeOperation terminates abnormally (with an exception).
A thread can consult its own context using ThreadContext.get(myKey). The result is the value that was most recently pushed with the given key.
A thread cannot read or modify the context of another thread.
The try...finally block ensures that the restore is done even if doSomeOperation terminates abnormally (with an exception).
A thread can consult its own context using ThreadContext.get(myKey). The result is the value that was most recently pushed with the given key.
A thread cannot read or modify the context of another thread.
This API is a Sun Microsystems internal API and is subject to change without notice.
{@link org.araneaframework.framework.router.StandardThreadServiceRouterService} adds aThreadContext.class to the environment for the children to be able to access.
@author "Toomas Römer"This component contains all the variables of type {@link ThreadLocal} hold by a {@link ThreadContextHolder}This component has not been designed to be thread safe so ensure that you create a new instance each time you use it. Moreover for security reason, when the {@link SecurityManager} is installed we check the {@link RuntimePermission}manageThreadLocal only within the constructor of a ThreadContext.
@author Nicolas Filotto @version $Id$ | |
| |
| |
| |
| |
| |
| |
| |
| |
| |