We have Seam application, we have following code
if( isLoginSuccess(userId,Passwor) ){
Identity.instance().login();
}
and in component.xml we have configuration
<event type="org.jboss.seam.security.loginSuccessful">
<action execute="#{defaultPageRedirector.returnToCapturedView()}"/>
</event>
Every time isLoginSuccess(userId,Passwor) return true ( we know that ) but only sometime ( randomly ) returnToCapturedView() is called , its happening randomly.
Could you please help me in this regards
If it is happening randomly there is something wrong with your defaultPageRedirector check seam redirect.
According to Seam Identity, This event raises only if user is not loggedIn Or user is loogedIn but siletnLogin attribute is set.