I have been trying all day to understand exactly where and when Shale 
injects into the JSF life cycle and I think i'm almost there..:) But I do 
have one question which reads rather long, so please bear with me. 

Here's what I do with my Tiles+Shale webapp:

1. Acces it via: http://www.myContext/
index.jsp is wired to forward to logon.faces which in turn displays a 
tiles def for /login. which displays my logon page.
debug stmts I get during this access are:

in init of login! and ispostback is: false
in prerender of login! and ispostback is: false

Makes perfect sense.

2. Next I authenticate by submitting the logon page.
Backing bean for logon is LogActions and LogActions.logon() returns the 
String "authenticated" which is mapped in faces-config to /worklist.jsp
debug stmts I get during this whole procedure are:

in init of login! and ispostback is: true
in preprocess of login! and ispostback is: true
in init of worklist! and ispostback is: false
in prerender of worklist! and ispostback is: false

Again, fine so far.

3. Next I click on logoff and this is where stuff gets goofy.
Logoff link points to "logon.logoff". LogActions.logoff() does some stuff 
and then returns "unauthenticated" which is mapped in faces-config.xml to 
/failure.jsp which in turn displays a tiles def for /login - which again 
displays my logon page fine.
But see what my debug statements say:

in init of worklist! and ispostback is: true
in preprocess of worklist! and ispostback is: true
in prerender of worklist! and ispostback is: true

The last statement is what i don't get. According to 
http://struts.apache.org/shale/features.html#view this is the "Postback 
processed by page A, which then navigates to page B" case of processing 
where worklist.jsp is "A" and logon.jsp is "B". 
So my thought is that third statement should read: 

in prerender of login! and ispostback is: false

So why is prerender of worklist() being called? Can anybody shed some 
light on this?
Thanks very much in advance!
Geeta

Reply via email to