Re: User data during request of AuthenticatedWebSession

2013-04-24 Thread Andre Schütz
Hello, thank you for the answers. I created my own RequestCycleListener and have another question. public MyRequestCycleListener extends AbstractRequestCycleListener { public onBeginRequest(RequestCycle cycle) { super.onBeginRequest(cycle); MyAuthenticatedSession session =

Re: User data during request of AuthenticatedWebSession

2013-04-24 Thread Bas Gooren
Andre, Your listener will also be called for resources served by wicket, so my guess is you have 1-7 resources on your page which are served by wicket. E.g. resources you store next to your pages (inside the same java package). So my guess is that you're not seeing multiple hits to

Re: User data during request of AuthenticatedWebSession

2013-04-24 Thread vineet semwal
what Bas said .. also i think it will be better to load data lazily instead of using listener for performance ,pseudocode below just call LazyLoad.getData(cycle,mailId) when there is a need .. public class LazyLoad implements Serializable{ public static final MetaDataKeyUserData KEY=

User data during request of AuthenticatedWebSession

2013-04-21 Thread Andre Schütz
I plan to implement a project with AuthenticatedWebApplication. The users have to sign up for an account. My question is regarding the user data that I have to load during each request of the single pages. The project will be as follows: (1) User logs into the system (2) The dashboard will be

Re: User data during request of AuthenticatedWebSession

2013-04-21 Thread Andrea Del Bene
Hi, you could use session's metadata to store user-relative data (provided that they are serializable) when she/he successfully logs in. IMHO creating a custom WebRequestCycle is not necessary. I plan to implement a project with AuthenticatedWebApplication. The users have to sign up for an

Re: User data during request of AuthenticatedWebSession

2013-04-21 Thread vineet semwal
yes,you can store some key in session like emailId and then retrieve and store the user and related data in request cycle metadata ,as you are storing in requestcycle metadata ,scope of the data will be for the whole request only . no need to create your own requestcycle for that,create your