File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes JSF and the fly likes JSF LifeCycle Understanding problem Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » JSF
Bookmark "JSF LifeCycle Understanding problem" Watch "JSF LifeCycle Understanding problem" New topic

JSF LifeCycle Understanding problem

Sandip Chaudhuri

Joined: Dec 27, 2004
Posts: 26
As per what i gather from JSF for nonbelievers for the lifecycle we have the 6 steps.

1. Restore view
2. Apply request values; process events
3. Process validations; process events
4. Update model values; process events
5. Invoke application; process events
6. Render response

Where restore view we have new view, initial view, and postback.
The form on submission will finally reach the Invoke application where the method called will be executed after which the navigation will be handeled. After that we have the render response phase.

Now if the navigation is going to another jsf. Is the new view created by the render Response? and the bean for the view populated?
What it seems to me is that the navigated to jsp is rendered but the view is not created. The values which were present in the initial bean gets carried over to the page but since it is of request scope it finishes there. So what i get on the navigated to jsp is that i can see the values but the view has actually not been created or is an initial view. So if i use any immediate=true link/action then all i get are null fields. Is my understanding of the lifecycle correct? please help.
I agree. Here's the link:
subject: JSF LifeCycle Understanding problem
It's not a secret anymore!