Thanks.
Pretty much as soon as I sent the mail I did wonder about using the ThreadContext directly instead of the user session (which would be stored within the Thread context anyway).. glad to hear someone else doing the same thing J, seems a fair approach. From: Chin Huang [mailto:[email protected]] Sent: 15 August 2012 17:12 To: [email protected] Subject: Re: Subject user session thread local in stateless service On Wed, Aug 15, 2012 at 6:33 AM, Marcus Bond <[email protected]> wrote: > I'd like to avoid having to implement my own ThreadLocal and the > corresponding clearing after the request since Shiro already has this built > in. I also wanted to avoid implementing my own ThreadLocal, so I put my application data in Shiro's ThreadContext <http://shiro.apache.org/static/current/apidocs/org/apache/shiro/util/Thread Context.html> , which Shiro clears after the request.
