myfaces-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Yannick Le Teigner <>
Subject Drilldown type app. without session bean?
Date Mon, 05 Dec 2005 23:04:22 GMT

I am trying to remove as many beans as possible from the session scope, 
and I am facing some difficulties with drilldown pages.

Let's say I have a page listing some users in a dataTable. Clicking on a 
user (commandLink), will bring you to a page where you can edit some 
parameters about this user.

Up until today the selected user was placed in session scope.

Now, after changing the scope to request in faces-config, if I try to 
put the user in the request map during the INVOKE_APPLICATION phase 
(when the action of my commandLink is called), then another user (empty 
this one) gets created during the RENDER_RESPONSE phase. The edit page 
displays an empty user.

If I use the t:saveState component (putting one on the listing page, and 
one on the edit page), the one on the listing page is created empty, and 
it is re-created as empty on the edit page...

The code in the action of my commandLink is something along the lines:
FacesContext ctx = FacesContext.getCurrentInstance();
ctx.getExternalContext().getRequestMap().put("#{User}", new User(id));

Anyone knows the correct way of handling this?

Thank you,

View raw message