Locale locale = (Locale) httpSession.getAttribute(Action.LOCALE_KEY); if (locale == null) { httpSession.setAttribute(Action.LOCALE_KEY, Locale.getDefault()); } locale = (Locale) httpSession.getAttribute(Globals.LOCALE_KEY); if (locale == null) { httpSession.setAttribute(Globals.LOCALE_KEY, Locale.getDefault()); }
FenixRequestProcessor.setLocal(request, httpSession);
    protected boolean processPreprocess(HttpServletRequest request, HttpServletResponse response) {        HttpSession httpSession = request.getSession(false);        Locale locale = (Locale) httpSession.getAttribute(Action.LOCALE_KEY);        if (locale == null) {            httpSession.setAttribute(Action.LOCALE_KEY, Locale.getDefault());        }        locale = (Locale) httpSession.getAttribute(Globals.LOCALE_KEY);        if (locale == null) {            httpSession.setAttribute(Globals.LOCALE_KEY, Locale.getDefault());        }        String uri = request.getRequestURI();        if (((uri.indexOf("login.do") == -1) && (uri.indexOf("showErrorPage.do") == -1) && (uri                .indexOf("/publico/index.do") == -1)) && (uri.indexOf("/manager/manageCache.do") == -1)                && (uri.indexOf("/isAlive.do") == -1)) {            if (request.getRemoteUser() == null) {                ActionErrors errors = new ActionErrors();                errors.add("error.invalid.session", new ActionError("error.invalid.session"));                request.setAttribute(Globals.ERROR_KEY, errors);                String uri2Forward = "/loginPage.jsp";                String applicationPrefix = "";                if (uri.indexOf("publico") != -1) {                    applicationPrefix = "/publico";                    uri2Forward = "/publico/index.jsp";                }                RequestUtils.selectModule(applicationPrefix, request, this.getServletContext());                try {                    doForward(uri2Forward, request, response);                } catch (IOException e) {                    e.printStackTrace();                    throw new RuntimeException(e);                } catch (ServletException e) {                    e.printStackTrace();                    throw new RuntimeException(e);                }                return false;            }        }        return true;    }