users@glassfish.java.net

Re: problem with _at_SessionScope annotation

From: <glassfish_at_javadesktop.org>
Date: Thu, 08 Apr 2010 08:47:51 PDT

I finally found the problem..

As you can see I used:
[i]
<h:outputLink [b]value="#{userManager.logout()}"[/b]
  rendered="#{userManager.isAuthenticated()}">
    Logout
</h:outputLink>[/i]

This was always calling the logout() action when a page was loaded. This was causing my @SessionScoped annotated bean to be removed and I was getting all the time another one.

I changed it with:
[i]<h:commandLink action="#{userManager.logout()}"
  rendered="#{userManager.isAuthenticated()}"
  value="Logout"/>
[/i]
and now it works just fine.

Thank you !
[Message sent by forum member 'sionut']

http://forums.java.net/jive/thread.jspa?messageID=395954