public String getValueFromCookieOrProperties(String key, HttpServletRequest request) { Cookie cookie = CookieSupport.getCookie(key, request); if (cookie != null) { return cookie.getValue(); } XPlannerProperties xplannerProperties = new XPlannerProperties(); return xplannerProperties.getProperty(key); }