Improved: LoginWorker.autoLoginCheck performance improvement
LoginWorker.autoLoginCheck does not check if the attribute "autoUserLogin" is
not already filled and executes even if it is not needed. A check on the
attribute beforehand can improve performance significantly.
Thanks: Benjamin Jugl
@@ -1004,6 +1004,11 @@ public class LoginWorker {
Delegator delegator = (Delegator) request.getAttribute("delegator");
HttpSession session = request.getSession();
+ GenericValue autoUserLogin = (GenericValue) session.getAttribute("autoUserLogin");
+ if (autoUserLogin != null){
+ return "success";
+ }
+
return autoLoginCheck(delegator, session, getAutoUserLoginId(request));
}
