boolean initialized = SpringContextSingleton.getInstance().isInitialized();
try {
if (initialized) {
try {
sessionFactory.setCurrentUser(null);
authPipeline.invoke(new AuthValveContext((HttpServletRequest) servletRequest,
(HttpServletResponse) servletResponse, sessionFactory));
} catch (PipelineException pe) {
logger.error("Error while authorizing user", pe);
}
}