"Thiago H. de Paula Figueiredo" <[email protected]> schrieb am 01.10.2009
15:52:51:
>
> > @Scope( ScopeConstants.PERTHREAD)
> > class OssoAccessControllerImpl {...}
>
> I can't see why it should be per thread.
The OssoAccessControllerImpl gets some authentication info from the
request and creates a User object.
I want(ed) to store this object into the session, so I need an
ApplicationStateManager, because the @Session annotation can't be used
here (we're in a service). The ApplicationStateManager can be injected
into the OssoAccessControllerImpl constructor, so the latter must be
request specifice, i.e. per thread.
However, your comment made it clear to me that I could put the User object
into the request instead of into the session. Then, I can fetch it via the
Request service which can be injected wherever I would have used @Session
private User user; ! This is much better! Thanks!
>
> Requests for assets (CSS, JavaScript, etc) are requests too.
>
I'm still astonished there are so many of them.
Dirk
BGS Beratungsgesellschaft
Software Systemplanung AG
Niederlassung Köln/Bonn
Grantham-Allee 2-8
53757 Sankt Augustin
Fon: +49 (0) 2241 / 166-500
Fax: +49 (0) 2241 / 166-680
www.bgs-ag.de
Geschäftssitz Mainz
Registergericht
Amtsgericht Mainz
HRB 62 50
Aufsichtsratsvorsitzender
Klaus Hellwig
Vorstand
Hermann Kiefer
Nils Manegold
Thomas Reitz