protected boolean doRememberMe ( ID userId , String expireDate , RememberMeLoginSpecifiedOption option ) { final boolean updateToken = option . isUpdateToken ( ) ; final boolean silentLogin = option . isSilentLogin ( ) ; if ( logger . isDebugEnabled ( ) ) { final StringBuilder sb = new StringBuilder ( ) ; sb . append ( "...Doing remember-me: user=" ) . append ( userId ) ; sb . append ( ", expire=" ) . append ( expireDate ) ; if ( updateToken ) { sb . append ( ", updateToken" ) ; } if ( silentLogin ) { sb . append ( ", silently" ) ; } logger . debug ( sb . toString ( ) ) ; } try { identityLogin ( userId , op -> op . rememberMe ( updateToken ) . silentLogin ( silentLogin ) ) ; return true ; } catch ( NumberFormatException invalidUserKey ) { // just in case // to know invalid user key or bug logger . debug ( "*The user key might be invalid: {}, {}" , userId , invalidUserKey . getMessage ( ) ) ; return false ; } catch ( LoginFailureException autoLoginFailed ) { return false ; } }
Do actually remember - me for the user .