java.lang.ClassCastException: java.lang.String cannot be cast to java.lang.Integer

Terracotta Project Issue Tracker | Janos Biro | 7 years ago
  1. 0

    ehcache-web - "java.lang.String cannot be cast to java.lang.Integer"

    terracotta.org | 11 months ago
    java.lang.ClassCastException: java.lang.String cannot be cast to java.lang.Integer
  2. 0

    I'm trying to enable EHCache full pages caches within our app, but it seems to me that there is a serious bug in the implementation since when the Spring tries to add a header it throws the underlying exception, after some debugging it's not a bug suprise since net.sf.ehcache.constructs.web.GenericResponseWrapper.addHeader(String, String) expects an Integer value for each header key public void addHeader(final String name, final String value) { final String[] header = new String[]{name, value}; headers.add(header); super.addHeader(name, value); Integer count = (Integer) headerTracker.get(name.toLowerCase()); if (count == null) { count = new Integer(1); } else { count = new Integer(count.intValue() + 1); } headerTracker.put(name.toLowerCase(), count); } and of course it's not true at all (e.g Pragma and others operates with String values) the method net.sf.ehcache.constructs.web.GenericResponseWrapper.setHeader(String, String) puts the String value to headerTracker so it should be aware of this fact. public void setHeader(final String name, final String value) { super.setHeader(name, value); Integer count = (Integer) headerTracker.get(name); if (count != null && count.intValue() > 0) { for (int i = headers.size() - 1; i >= 0; i--) { String[] header = (String[]) headers.get(i); String hName = header[0]; if (hName.equalsIgnoreCase(name)) { if (count > 1) { headers.remove(i); count = count.intValue() - 1; headerTracker.put(name.toLowerCase(), new Integer(count)); } else { ((String[]) headers.get(i))[1] = value; } } } } else { headerTracker.put(name.toLowerCase(), value); } } java.lang.ClassCastException: java.lang.String cannot be cast to java.lang.Integer at net.sf.ehcache.constructs.web.GenericResponseWrapper.addHeader(GenericResponseWrapper.java:189) [ehcache-web-2.0.0.jar:na] at org.springframework.web.servlet.support.WebContentGenerator.preventCaching(WebContentGenerator.java:273) [spring-webmvc-2.5.6.jar:2.5.6] at org.springframework.web.servlet.support.WebContentGenerator.applyCacheSeconds(WebContentGenerator.java:346) [spring-webmvc-2.5.6.jar:2.5.6] at org.springframework.web.servlet.support.WebContentGenerator.checkAndPrepare(WebContentGenerator.java:255) [spring-webmvc-2.5.6.jar:2.5.6] at org.springframework.web.servlet.mvc.annotation.AnnotationMethodHandlerAdapter.handle(AnnotationMethodHandlerAdapter.java:294) [spring-webmvc-2.5.6.jar:2.5.6] at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:875) [spring-webmvc-2.5.6.jar:2.5.6] at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:807) [spring-webmvc-2.5.6.jar:2.5.6] at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:571) [spring-webmvc-2.5.6.jar:2.5.6] at org.springframework.web.servlet.FrameworkServlet.doGet(FrameworkServlet.java:501) [spring-webmvc-2.5.6.jar:2.5.6] at javax.servlet.http.HttpServlet.service(HttpServlet.java:617) [servlet-api.jar:na] at javax.servlet.http.HttpServlet.service(HttpServlet.java:717) [servlet-api.jar:na] at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290) [catalina.jar:na] at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) [catalina.jar:na] at net.sf.ehcache.constructs.web.filter.CachingFilter.buildPage(CachingFilter.java:263) [ehcache-web-2.0.0.jar:na] at net.sf.ehcache.constructs.web.filter.CachingFilter.buildPageInfo(CachingFilter.java:216) [ehcache-web-2.0.0.jar:na] at net.sf.ehcache.constructs.web.filter.CachingFilter.doFilter(CachingFilter.java:182) [ehcache-web-2.0.0.jar:na] at net.sf.ehcache.constructs.web.filter.Filter.doFilter(Filter.java:86) [ehcache-web-2.0.0.jar:na] at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235) [catalina.jar:na] at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) [catalina.jar:na] at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:630) [catalina.jar:na] at org.apache.catalina.core.ApplicationDispatcher.processRequest(ApplicationDispatcher.java:436) [catalina.jar:na] at org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationDispatcher.java:374) [catalina.jar:na] at org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDispatcher.java:302) [catalina.jar:na] at org.tuckey.web.filters.urlrewrite.NormalRewrittenUrl.doRewrite(NormalRewrittenUrl.java:195) [urlrewritefilter-3.1.0.jar:3.1.0] at org.tuckey.web.filters.urlrewrite.RuleChain.handleRewrite(RuleChain.java:159) [urlrewritefilter-3.1.0.jar:3.1.0] at org.tuckey.web.filters.urlrewrite.RuleChain.doRules(RuleChain.java:141) [urlrewritefilter-3.1.0.jar:3.1.0] at org.tuckey.web.filters.urlrewrite.UrlRewriter.processRequest(UrlRewriter.java:90) [urlrewritefilter-3.1.0.jar:3.1.0] at org.tuckey.web.filters.urlrewrite.UrlRewriteFilter.doFilter(UrlRewriteFilter.java:417) [urlrewritefilter-3.1.0.jar:3.1.0] at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235) [catalina.jar:na] at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) [catalina.jar:na] at org.springframework.security.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:378) [spring-security-core-2.0.5.RELEASE.jar:na] at org.springframework.security.intercept.web.FilterSecurityInterceptor.invoke(FilterSecurityInterceptor.java:109) [spring-security-core-2.0.5.RELEASE.jar:na] at org.springframework.security.intercept.web.FilterSecurityInterceptor.doFilter(FilterSecurityInterceptor.java:83) [spring-security-core-2.0.5.RELEASE.jar:na] at org.springframework.security.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:390) [spring-security-core-2.0.5.RELEASE.jar:na] at org.springframework.security.ui.SessionFixationProtectionFilter.doFilterHttp(SessionFixationProtectionFilter.java:67) [spring-security-core-2.0.5.RELEASE.jar:na] at org.springframework.security.ui.SpringSecurityFilter.doFilter(SpringSecurityFilter.java:53) [spring-security-core-2.0.5.RELEASE.jar:na] at org.springframework.security.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:390) [spring-security-core-2.0.5.RELEASE.jar:na] at org.springframework.security.ui.ExceptionTranslationFilter.doFilterHttp(ExceptionTranslationFilter.java:101) [spring-security-core-2.0.5.RELEASE.jar:na] at org.springframework.security.ui.SpringSecurityFilter.doFilter(SpringSecurityFilter.java:53) [spring-security-core-2.0.5.RELEASE.jar:na] at org.springframework.security.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:390) [spring-security-core-2.0.5.RELEASE.jar:na] at org.springframework.security.providers.anonymous.AnonymousProcessingFilter.doFilterHttp(AnonymousProcessingFilter.java:105) [spring-security-core-2.0.5.RELEASE.jar:na] at org.springframework.security.ui.SpringSecurityFilter.doFilter(SpringSecurityFilter.java:53) [spring-security-core-2.0.5.RELEASE.jar:na] at org.springframework.security.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:390) [spring-security-core-2.0.5.RELEASE.jar:na] at org.springframework.security.ui.rememberme.RememberMeProcessingFilter.doFilterHttp(RememberMeProcessingFilter.java:109) [spring-security-core-2.0.5.RELEASE.jar:na] at org.springframework.security.ui.SpringSecurityFilter.doFilter(SpringSecurityFilter.java:53) [spring-security-core-2.0.5.RELEASE.jar:na] at org.springframework.security.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:390) [spring-security-core-2.0.5.RELEASE.jar:na] at org.springframework.security.wrapper.SecurityContextHolderAwareRequestFilter.doFilterHttp(SecurityContextHolderAwareRequestFilter.java:91) [spring-security-core-2.0.5.RELEASE.jar:na] at org.springframework.security.ui.SpringSecurityFilter.doFilter(SpringSecurityFilter.java:53) [spring-security-core-2.0.5.RELEASE.jar:na] at org.springframework.security.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:390) [spring-security-core-2.0.5.RELEASE.jar:na] at org.springframework.security.ui.basicauth.BasicProcessingFilter.doFilterHttp(BasicProcessingFilter.java:174) [spring-security-core-2.0.5.RELEASE.jar:na] at org.springframework.security.ui.SpringSecurityFilter.doFilter(SpringSecurityFilter.java:53) [spring-security-core-2.0.5.RELEASE.jar:na] at org.springframework.security.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:390) [spring-security-core-2.0.5.RELEASE.jar:na] at org.springframework.security.ui.AbstractProcessingFilter.doFilterHttp(AbstractProcessingFilter.java:278) [spring-security-core-2.0.5.RELEASE.jar:na] at org.springframework.security.ui.SpringSecurityFilter.doFilter(SpringSecurityFilter.java:53) [spring-security-core-2.0.5.RELEASE.jar:na] at org.springframework.security.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:390) [spring-security-core-2.0.5.RELEASE.jar:na] at org.springframework.security.ui.logout.LogoutFilter.doFilterHttp(LogoutFilter.java:89) [spring-security-core-2.0.5.RELEASE.jar:na] at org.springframework.security.ui.SpringSecurityFilter.doFilter(SpringSecurityFilter.java:53) [spring-security-core-2.0.5.RELEASE.jar:na] at org.springframework.security.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:390) [spring-security-core-2.0.5.RELEASE.jar:na] at org.springframework.security.context.HttpSessionContextIntegrationFilter.doFilterHttp(HttpSessionContextIntegrationFilter.java:235) [spring-security-core-2.0.5.RELEASE.jar:na] at org.springframework.security.ui.SpringSecurityFilter.doFilter(SpringSecurityFilter.java:53) [spring-security-core-2.0.5.RELEASE.jar:na] at org.springframework.security.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:390) [spring-security-core-2.0.5.RELEASE.jar:na] at org.springframework.security.concurrent.ConcurrentSessionFilter.doFilterHttp(ConcurrentSessionFilter.java:99) [spring-security-core-2.0.5.RELEASE.jar:na] at org.springframework.security.ui.SpringSecurityFilter.doFilter(SpringSecurityFilter.java:53) [spring-security-core-2.0.5.RELEASE.jar:na] at org.springframework.security.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:390) [spring-security-core-2.0.5.RELEASE.jar:na] at org.springframework.security.util.FilterChainProxy.doFilter(FilterChainProxy.java:175) [spring-security-core-2.0.5.RELEASE.jar:na] at org.springframework.web.filter.DelegatingFilterProxy.invokeDelegate(DelegatingFilterProxy.java:236) [spring-2.5.6.jar:2.5.6] at org.springframework.web.filter.DelegatingFilterProxy.doFilter(DelegatingFilterProxy.java:167) [spring-2.5.6.jar:2.5.6] at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235) [catalina.jar:na] at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) [catalina.jar:na] at com.kiko.store.filters.KikoSecurityFilter.doFilter(KikoSecurityFilter.java:53) [KikoSecurityFilter.class:na] at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235) [catalina.jar:na] at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) [catalina.jar:na] at org.springframework.web.filter.CharacterEncodingFilter.doFilterInternal(CharacterEncodingFilter.java:96) [spring-2.5.6.jar:2.5.6] at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:76) [spring-2.5.6.jar:2.5.6] at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235) [catalina.jar:na] at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) [catalina.jar:na] at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233) [catalina.jar:na] at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191) [catalina.jar:na] at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:433) [catalina.jar:na] at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128) [catalina.jar:na] at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102) [catalina.jar:na] at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109) [catalina.jar:na] at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:286) [catalina.jar:na] at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:845) [tomcat-coyote.jar:na] at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:583) [tomcat-coyote.jar:na] at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447) [tomcat-coyote.jar:na]

    Terracotta Project Issue Tracker | 7 years ago | Janos Biro
    java.lang.ClassCastException: java.lang.String cannot be cast to java.lang.Integer
  3. 0

    I'm trying to enable EHCache full pages caches within our app, but it seems to me that there is a serious bug in the implementation since when the Spring tries to add a header it throws the underlying exception, after some debugging it's not a bug suprise since net.sf.ehcache.constructs.web.GenericResponseWrapper.addHeader(String, String) expects an Integer value for each header key public void addHeader(final String name, final String value) { final String[] header = new String[]{name, value}; headers.add(header); super.addHeader(name, value); Integer count = (Integer) headerTracker.get(name.toLowerCase()); if (count == null) { count = new Integer(1); } else { count = new Integer(count.intValue() + 1); } headerTracker.put(name.toLowerCase(), count); } and of course it's not true at all (e.g Pragma and others operates with String values) the method net.sf.ehcache.constructs.web.GenericResponseWrapper.setHeader(String, String) puts the String value to headerTracker so it should be aware of this fact. public void setHeader(final String name, final String value) { super.setHeader(name, value); Integer count = (Integer) headerTracker.get(name); if (count != null && count.intValue() > 0) { for (int i = headers.size() - 1; i >= 0; i--) { String[] header = (String[]) headers.get(i); String hName = header[0]; if (hName.equalsIgnoreCase(name)) { if (count > 1) { headers.remove(i); count = count.intValue() - 1; headerTracker.put(name.toLowerCase(), new Integer(count)); } else { ((String[]) headers.get(i))[1] = value; } } } } else { headerTracker.put(name.toLowerCase(), value); } } java.lang.ClassCastException: java.lang.String cannot be cast to java.lang.Integer at net.sf.ehcache.constructs.web.GenericResponseWrapper.addHeader(GenericResponseWrapper.java:189) [ehcache-web-2.0.0.jar:na] at org.springframework.web.servlet.support.WebContentGenerator.preventCaching(WebContentGenerator.java:273) [spring-webmvc-2.5.6.jar:2.5.6] at org.springframework.web.servlet.support.WebContentGenerator.applyCacheSeconds(WebContentGenerator.java:346) [spring-webmvc-2.5.6.jar:2.5.6] at org.springframework.web.servlet.support.WebContentGenerator.checkAndPrepare(WebContentGenerator.java:255) [spring-webmvc-2.5.6.jar:2.5.6] at org.springframework.web.servlet.mvc.annotation.AnnotationMethodHandlerAdapter.handle(AnnotationMethodHandlerAdapter.java:294) [spring-webmvc-2.5.6.jar:2.5.6] at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:875) [spring-webmvc-2.5.6.jar:2.5.6] at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:807) [spring-webmvc-2.5.6.jar:2.5.6] at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:571) [spring-webmvc-2.5.6.jar:2.5.6] at org.springframework.web.servlet.FrameworkServlet.doGet(FrameworkServlet.java:501) [spring-webmvc-2.5.6.jar:2.5.6] at javax.servlet.http.HttpServlet.service(HttpServlet.java:617) [servlet-api.jar:na] at javax.servlet.http.HttpServlet.service(HttpServlet.java:717) [servlet-api.jar:na] at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290) [catalina.jar:na] at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) [catalina.jar:na] at net.sf.ehcache.constructs.web.filter.CachingFilter.buildPage(CachingFilter.java:263) [ehcache-web-2.0.0.jar:na] at net.sf.ehcache.constructs.web.filter.CachingFilter.buildPageInfo(CachingFilter.java:216) [ehcache-web-2.0.0.jar:na] at net.sf.ehcache.constructs.web.filter.CachingFilter.doFilter(CachingFilter.java:182) [ehcache-web-2.0.0.jar:na] at net.sf.ehcache.constructs.web.filter.Filter.doFilter(Filter.java:86) [ehcache-web-2.0.0.jar:na] at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235) [catalina.jar:na] at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) [catalina.jar:na] at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:630) [catalina.jar:na] at org.apache.catalina.core.ApplicationDispatcher.processRequest(ApplicationDispatcher.java:436) [catalina.jar:na] at org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationDispatcher.java:374) [catalina.jar:na] at org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDispatcher.java:302) [catalina.jar:na] at org.tuckey.web.filters.urlrewrite.NormalRewrittenUrl.doRewrite(NormalRewrittenUrl.java:195) [urlrewritefilter-3.1.0.jar:3.1.0] at org.tuckey.web.filters.urlrewrite.RuleChain.handleRewrite(RuleChain.java:159) [urlrewritefilter-3.1.0.jar:3.1.0] at org.tuckey.web.filters.urlrewrite.RuleChain.doRules(RuleChain.java:141) [urlrewritefilter-3.1.0.jar:3.1.0] at org.tuckey.web.filters.urlrewrite.UrlRewriter.processRequest(UrlRewriter.java:90) [urlrewritefilter-3.1.0.jar:3.1.0] at org.tuckey.web.filters.urlrewrite.UrlRewriteFilter.doFilter(UrlRewriteFilter.java:417) [urlrewritefilter-3.1.0.jar:3.1.0] at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235) [catalina.jar:na] at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) [catalina.jar:na] at org.springframework.security.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:378) [spring-security-core-2.0.5.RELEASE.jar:na] at org.springframework.security.intercept.web.FilterSecurityInterceptor.invoke(FilterSecurityInterceptor.java:109) [spring-security-core-2.0.5.RELEASE.jar:na] at org.springframework.security.intercept.web.FilterSecurityInterceptor.doFilter(FilterSecurityInterceptor.java:83) [spring-security-core-2.0.5.RELEASE.jar:na] at org.springframework.security.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:390) [spring-security-core-2.0.5.RELEASE.jar:na] at org.springframework.security.ui.SessionFixationProtectionFilter.doFilterHttp(SessionFixationProtectionFilter.java:67) [spring-security-core-2.0.5.RELEASE.jar:na] at org.springframework.security.ui.SpringSecurityFilter.doFilter(SpringSecurityFilter.java:53) [spring-security-core-2.0.5.RELEASE.jar:na] at org.springframework.security.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:390) [spring-security-core-2.0.5.RELEASE.jar:na] at org.springframework.security.ui.ExceptionTranslationFilter.doFilterHttp(ExceptionTranslationFilter.java:101) [spring-security-core-2.0.5.RELEASE.jar:na] at org.springframework.security.ui.SpringSecurityFilter.doFilter(SpringSecurityFilter.java:53) [spring-security-core-2.0.5.RELEASE.jar:na] at org.springframework.security.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:390) [spring-security-core-2.0.5.RELEASE.jar:na] at org.springframework.security.providers.anonymous.AnonymousProcessingFilter.doFilterHttp(AnonymousProcessingFilter.java:105) [spring-security-core-2.0.5.RELEASE.jar:na] at org.springframework.security.ui.SpringSecurityFilter.doFilter(SpringSecurityFilter.java:53) [spring-security-core-2.0.5.RELEASE.jar:na] at org.springframework.security.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:390) [spring-security-core-2.0.5.RELEASE.jar:na] at org.springframework.security.ui.rememberme.RememberMeProcessingFilter.doFilterHttp(RememberMeProcessingFilter.java:109) [spring-security-core-2.0.5.RELEASE.jar:na] at org.springframework.security.ui.SpringSecurityFilter.doFilter(SpringSecurityFilter.java:53) [spring-security-core-2.0.5.RELEASE.jar:na] at org.springframework.security.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:390) [spring-security-core-2.0.5.RELEASE.jar:na] at org.springframework.security.wrapper.SecurityContextHolderAwareRequestFilter.doFilterHttp(SecurityContextHolderAwareRequestFilter.java:91) [spring-security-core-2.0.5.RELEASE.jar:na] at org.springframework.security.ui.SpringSecurityFilter.doFilter(SpringSecurityFilter.java:53) [spring-security-core-2.0.5.RELEASE.jar:na] at org.springframework.security.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:390) [spring-security-core-2.0.5.RELEASE.jar:na] at org.springframework.security.ui.basicauth.BasicProcessingFilter.doFilterHttp(BasicProcessingFilter.java:174) [spring-security-core-2.0.5.RELEASE.jar:na] at org.springframework.security.ui.SpringSecurityFilter.doFilter(SpringSecurityFilter.java:53) [spring-security-core-2.0.5.RELEASE.jar:na] at org.springframework.security.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:390) [spring-security-core-2.0.5.RELEASE.jar:na] at org.springframework.security.ui.AbstractProcessingFilter.doFilterHttp(AbstractProcessingFilter.java:278) [spring-security-core-2.0.5.RELEASE.jar:na] at org.springframework.security.ui.SpringSecurityFilter.doFilter(SpringSecurityFilter.java:53) [spring-security-core-2.0.5.RELEASE.jar:na] at org.springframework.security.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:390) [spring-security-core-2.0.5.RELEASE.jar:na] at org.springframework.security.ui.logout.LogoutFilter.doFilterHttp(LogoutFilter.java:89) [spring-security-core-2.0.5.RELEASE.jar:na] at org.springframework.security.ui.SpringSecurityFilter.doFilter(SpringSecurityFilter.java:53) [spring-security-core-2.0.5.RELEASE.jar:na] at org.springframework.security.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:390) [spring-security-core-2.0.5.RELEASE.jar:na] at org.springframework.security.context.HttpSessionContextIntegrationFilter.doFilterHttp(HttpSessionContextIntegrationFilter.java:235) [spring-security-core-2.0.5.RELEASE.jar:na] at org.springframework.security.ui.SpringSecurityFilter.doFilter(SpringSecurityFilter.java:53) [spring-security-core-2.0.5.RELEASE.jar:na] at org.springframework.security.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:390) [spring-security-core-2.0.5.RELEASE.jar:na] at org.springframework.security.concurrent.ConcurrentSessionFilter.doFilterHttp(ConcurrentSessionFilter.java:99) [spring-security-core-2.0.5.RELEASE.jar:na] at org.springframework.security.ui.SpringSecurityFilter.doFilter(SpringSecurityFilter.java:53) [spring-security-core-2.0.5.RELEASE.jar:na] at org.springframework.security.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:390) [spring-security-core-2.0.5.RELEASE.jar:na] at org.springframework.security.util.FilterChainProxy.doFilter(FilterChainProxy.java:175) [spring-security-core-2.0.5.RELEASE.jar:na] at org.springframework.web.filter.DelegatingFilterProxy.invokeDelegate(DelegatingFilterProxy.java:236) [spring-2.5.6.jar:2.5.6] at org.springframework.web.filter.DelegatingFilterProxy.doFilter(DelegatingFilterProxy.java:167) [spring-2.5.6.jar:2.5.6] at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235) [catalina.jar:na] at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) [catalina.jar:na] at com.kiko.store.filters.KikoSecurityFilter.doFilter(KikoSecurityFilter.java:53) [KikoSecurityFilter.class:na] at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235) [catalina.jar:na] at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) [catalina.jar:na] at org.springframework.web.filter.CharacterEncodingFilter.doFilterInternal(CharacterEncodingFilter.java:96) [spring-2.5.6.jar:2.5.6] at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:76) [spring-2.5.6.jar:2.5.6] at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235) [catalina.jar:na] at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) [catalina.jar:na] at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233) [catalina.jar:na] at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191) [catalina.jar:na] at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:433) [catalina.jar:na] at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128) [catalina.jar:na] at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102) [catalina.jar:na] at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109) [catalina.jar:na] at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:286) [catalina.jar:na] at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:845) [tomcat-coyote.jar:na] at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:583) [tomcat-coyote.jar:na] at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447) [tomcat-coyote.jar:na]

    Terracotta Project Issue Tracker | 7 years ago | Janos Biro
    java.lang.ClassCastException: java.lang.String cannot be cast to java.lang.Integer
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

  5. 0

    Execution Error, return code 2 while executing query in hive for twitter sentiment analysis

    Stack Overflow | 4 weeks ago | Ayushi Jain
    org.apache.hadoop.hive.ql.metadata.HiveException: org.apache.hadoop.hive.ql.metadata.HiveException: org.apache.hadoop.hive.ql.metadata.HiveException: java.lang.ClassCastException: java.lang.String cannot be cast to java.lang.Integer
  6. 0

    Bug on Adobe air for Android? - Pushwoosh Community

    pushwoosh.com | 7 days ago
    java.lang.ClassCastException: java.lang.Integer cannot be cast to java.lang.String

    Not finding the right solution?
    Take a tour to get the most out of Samebug.

    Tired of useless tips?

    Automated exception search integrated into your IDE

    Root Cause Analysis

    1. java.lang.ClassCastException

      java.lang.String cannot be cast to java.lang.Integer

      at net.sf.ehcache.constructs.web.GenericResponseWrapper.addHeader()
    2. Ehcache
      GenericResponseWrapper.addHeader
      1. net.sf.ehcache.constructs.web.GenericResponseWrapper.addHeader(GenericResponseWrapper.java:189)[ehcache-web-2.0.0.jar:na]
      1 frame
    3. Spring MVC
      FrameworkServlet.doGet
      1. org.springframework.web.servlet.support.WebContentGenerator.preventCaching(WebContentGenerator.java:273)[spring-webmvc-2.5.6.jar:2.5.6]
      2. org.springframework.web.servlet.support.WebContentGenerator.applyCacheSeconds(WebContentGenerator.java:346)[spring-webmvc-2.5.6.jar:2.5.6]
      3. org.springframework.web.servlet.support.WebContentGenerator.checkAndPrepare(WebContentGenerator.java:255)[spring-webmvc-2.5.6.jar:2.5.6]
      4. org.springframework.web.servlet.mvc.annotation.AnnotationMethodHandlerAdapter.handle(AnnotationMethodHandlerAdapter.java:294)[spring-webmvc-2.5.6.jar:2.5.6]
      5. org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:875)[spring-webmvc-2.5.6.jar:2.5.6]
      6. org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:807)[spring-webmvc-2.5.6.jar:2.5.6]
      7. org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:571)[spring-webmvc-2.5.6.jar:2.5.6]
      8. org.springframework.web.servlet.FrameworkServlet.doGet(FrameworkServlet.java:501)[spring-webmvc-2.5.6.jar:2.5.6]
      8 frames
    4. JavaServlet
      HttpServlet.service
      1. javax.servlet.http.HttpServlet.service(HttpServlet.java:617)[servlet-api.jar:na]
      2. javax.servlet.http.HttpServlet.service(HttpServlet.java:717)[servlet-api.jar:na]
      2 frames
    5. Glassfish Core
      ApplicationFilterChain.doFilter
      1. org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)[catalina.jar:na]
      2. org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)[catalina.jar:na]
      2 frames
    6. Ehcache Web Filters
      Filter.doFilter
      1. net.sf.ehcache.constructs.web.filter.CachingFilter.buildPage(CachingFilter.java:263)[ehcache-web-2.0.0.jar:na]
      2. net.sf.ehcache.constructs.web.filter.CachingFilter.buildPageInfo(CachingFilter.java:216)[ehcache-web-2.0.0.jar:na]
      3. net.sf.ehcache.constructs.web.filter.CachingFilter.doFilter(CachingFilter.java:182)[ehcache-web-2.0.0.jar:na]
      4. net.sf.ehcache.constructs.web.filter.Filter.doFilter(Filter.java:86)[ehcache-web-2.0.0.jar:na]
      4 frames
    7. Glassfish Core
      ApplicationDispatcher.forward
      1. org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)[catalina.jar:na]
      2. org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)[catalina.jar:na]
      3. org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:630)[catalina.jar:na]
      4. org.apache.catalina.core.ApplicationDispatcher.processRequest(ApplicationDispatcher.java:436)[catalina.jar:na]
      5. org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationDispatcher.java:374)[catalina.jar:na]
      6. org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDispatcher.java:302)[catalina.jar:na]
      6 frames
    8. UrlRewriteFilter
      UrlRewriteFilter.doFilter
      1. org.tuckey.web.filters.urlrewrite.NormalRewrittenUrl.doRewrite(NormalRewrittenUrl.java:195)[urlrewritefilter-3.1.0.jar:3.1.0]
      2. org.tuckey.web.filters.urlrewrite.RuleChain.handleRewrite(RuleChain.java:159)[urlrewritefilter-3.1.0.jar:3.1.0]
      3. org.tuckey.web.filters.urlrewrite.RuleChain.doRules(RuleChain.java:141)[urlrewritefilter-3.1.0.jar:3.1.0]
      4. org.tuckey.web.filters.urlrewrite.UrlRewriter.processRequest(UrlRewriter.java:90)[urlrewritefilter-3.1.0.jar:3.1.0]
      5. org.tuckey.web.filters.urlrewrite.UrlRewriteFilter.doFilter(UrlRewriteFilter.java:417)[urlrewritefilter-3.1.0.jar:3.1.0]
      5 frames
    9. Glassfish Core
      ApplicationFilterChain.doFilter
      1. org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)[catalina.jar:na]
      2. org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)[catalina.jar:na]
      2 frames
    10. spring-security-core
      FilterChainProxy$VirtualFilterChain.doFilter
      1. org.springframework.security.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:378)[spring-security-core-2.0.5.RELEASE.jar:na]
      1 frame
    11. org.springframework.security
      FilterSecurityInterceptor.doFilter
      1. org.springframework.security.intercept.web.FilterSecurityInterceptor.invoke(FilterSecurityInterceptor.java:109)[spring-security-core-2.0.5.RELEASE.jar:na]
      2. org.springframework.security.intercept.web.FilterSecurityInterceptor.doFilter(FilterSecurityInterceptor.java:83)[spring-security-core-2.0.5.RELEASE.jar:na]
      2 frames
    12. spring-security-core
      FilterChainProxy$VirtualFilterChain.doFilter
      1. org.springframework.security.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:390)[spring-security-core-2.0.5.RELEASE.jar:na]
      1 frame
    13. org.springframework.security
      SpringSecurityFilter.doFilter
      1. org.springframework.security.ui.SessionFixationProtectionFilter.doFilterHttp(SessionFixationProtectionFilter.java:67)[spring-security-core-2.0.5.RELEASE.jar:na]
      2. org.springframework.security.ui.SpringSecurityFilter.doFilter(SpringSecurityFilter.java:53)[spring-security-core-2.0.5.RELEASE.jar:na]
      2 frames
    14. spring-security-core
      FilterChainProxy$VirtualFilterChain.doFilter
      1. org.springframework.security.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:390)[spring-security-core-2.0.5.RELEASE.jar:na]
      1 frame
    15. org.springframework.security
      SpringSecurityFilter.doFilter
      1. org.springframework.security.ui.ExceptionTranslationFilter.doFilterHttp(ExceptionTranslationFilter.java:101)[spring-security-core-2.0.5.RELEASE.jar:na]
      2. org.springframework.security.ui.SpringSecurityFilter.doFilter(SpringSecurityFilter.java:53)[spring-security-core-2.0.5.RELEASE.jar:na]
      2 frames
    16. spring-security-core
      FilterChainProxy$VirtualFilterChain.doFilter
      1. org.springframework.security.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:390)[spring-security-core-2.0.5.RELEASE.jar:na]
      1 frame
    17. org.springframework.security
      SpringSecurityFilter.doFilter
      1. org.springframework.security.providers.anonymous.AnonymousProcessingFilter.doFilterHttp(AnonymousProcessingFilter.java:105)[spring-security-core-2.0.5.RELEASE.jar:na]
      2. org.springframework.security.ui.SpringSecurityFilter.doFilter(SpringSecurityFilter.java:53)[spring-security-core-2.0.5.RELEASE.jar:na]
      2 frames
    18. spring-security-core
      FilterChainProxy$VirtualFilterChain.doFilter
      1. org.springframework.security.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:390)[spring-security-core-2.0.5.RELEASE.jar:na]
      1 frame
    19. org.springframework.security
      SpringSecurityFilter.doFilter
      1. org.springframework.security.ui.rememberme.RememberMeProcessingFilter.doFilterHttp(RememberMeProcessingFilter.java:109)[spring-security-core-2.0.5.RELEASE.jar:na]
      2. org.springframework.security.ui.SpringSecurityFilter.doFilter(SpringSecurityFilter.java:53)[spring-security-core-2.0.5.RELEASE.jar:na]
      2 frames
    20. spring-security-core
      FilterChainProxy$VirtualFilterChain.doFilter
      1. org.springframework.security.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:390)[spring-security-core-2.0.5.RELEASE.jar:na]
      1 frame
    21. org.springframework.security
      SpringSecurityFilter.doFilter
      1. org.springframework.security.wrapper.SecurityContextHolderAwareRequestFilter.doFilterHttp(SecurityContextHolderAwareRequestFilter.java:91)[spring-security-core-2.0.5.RELEASE.jar:na]
      2. org.springframework.security.ui.SpringSecurityFilter.doFilter(SpringSecurityFilter.java:53)[spring-security-core-2.0.5.RELEASE.jar:na]
      2 frames
    22. spring-security-core
      FilterChainProxy$VirtualFilterChain.doFilter
      1. org.springframework.security.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:390)[spring-security-core-2.0.5.RELEASE.jar:na]
      1 frame
    23. org.springframework.security
      SpringSecurityFilter.doFilter
      1. org.springframework.security.ui.basicauth.BasicProcessingFilter.doFilterHttp(BasicProcessingFilter.java:174)[spring-security-core-2.0.5.RELEASE.jar:na]
      2. org.springframework.security.ui.SpringSecurityFilter.doFilter(SpringSecurityFilter.java:53)[spring-security-core-2.0.5.RELEASE.jar:na]
      2 frames
    24. spring-security-core
      FilterChainProxy$VirtualFilterChain.doFilter
      1. org.springframework.security.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:390)[spring-security-core-2.0.5.RELEASE.jar:na]
      1 frame
    25. org.springframework.security
      SpringSecurityFilter.doFilter
      1. org.springframework.security.ui.AbstractProcessingFilter.doFilterHttp(AbstractProcessingFilter.java:278)[spring-security-core-2.0.5.RELEASE.jar:na]
      2. org.springframework.security.ui.SpringSecurityFilter.doFilter(SpringSecurityFilter.java:53)[spring-security-core-2.0.5.RELEASE.jar:na]
      2 frames
    26. spring-security-core
      FilterChainProxy$VirtualFilterChain.doFilter
      1. org.springframework.security.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:390)[spring-security-core-2.0.5.RELEASE.jar:na]
      1 frame
    27. org.springframework.security
      SpringSecurityFilter.doFilter
      1. org.springframework.security.ui.logout.LogoutFilter.doFilterHttp(LogoutFilter.java:89)[spring-security-core-2.0.5.RELEASE.jar:na]
      2. org.springframework.security.ui.SpringSecurityFilter.doFilter(SpringSecurityFilter.java:53)[spring-security-core-2.0.5.RELEASE.jar:na]
      2 frames
    28. spring-security-core
      FilterChainProxy$VirtualFilterChain.doFilter
      1. org.springframework.security.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:390)[spring-security-core-2.0.5.RELEASE.jar:na]
      1 frame
    29. Spring Security - Portlet support
      HttpSessionContextIntegrationFilter.doFilterHttp
      1. org.springframework.security.context.HttpSessionContextIntegrationFilter.doFilterHttp(HttpSessionContextIntegrationFilter.java:235)[spring-security-core-2.0.5.RELEASE.jar:na]
      1 frame
    30. org.springframework.security
      SpringSecurityFilter.doFilter
      1. org.springframework.security.ui.SpringSecurityFilter.doFilter(SpringSecurityFilter.java:53)[spring-security-core-2.0.5.RELEASE.jar:na]
      1 frame
    31. spring-security-core
      FilterChainProxy$VirtualFilterChain.doFilter
      1. org.springframework.security.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:390)[spring-security-core-2.0.5.RELEASE.jar:na]
      1 frame
    32. org.springframework.security
      SpringSecurityFilter.doFilter
      1. org.springframework.security.concurrent.ConcurrentSessionFilter.doFilterHttp(ConcurrentSessionFilter.java:99)[spring-security-core-2.0.5.RELEASE.jar:na]
      2. org.springframework.security.ui.SpringSecurityFilter.doFilter(SpringSecurityFilter.java:53)[spring-security-core-2.0.5.RELEASE.jar:na]
      2 frames
    33. spring-security-core
      FilterChainProxy.doFilter
      1. org.springframework.security.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:390)[spring-security-core-2.0.5.RELEASE.jar:na]
      2. org.springframework.security.util.FilterChainProxy.doFilter(FilterChainProxy.java:175)[spring-security-core-2.0.5.RELEASE.jar:na]
      2 frames
    34. Spring
      DelegatingFilterProxy.doFilter
      1. org.springframework.web.filter.DelegatingFilterProxy.invokeDelegate(DelegatingFilterProxy.java:236)[spring-2.5.6.jar:2.5.6]
      2. org.springframework.web.filter.DelegatingFilterProxy.doFilter(DelegatingFilterProxy.java:167)[spring-2.5.6.jar:2.5.6]
      2 frames
    35. Glassfish Core
      ApplicationFilterChain.doFilter
      1. org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)[catalina.jar:na]
      2. org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)[catalina.jar:na]
      2 frames
    36. com.kiko.store
      KikoSecurityFilter.doFilter
      1. com.kiko.store.filters.KikoSecurityFilter.doFilter(KikoSecurityFilter.java:53)[KikoSecurityFilter.class:na]
      1 frame
    37. Glassfish Core
      ApplicationFilterChain.doFilter
      1. org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)[catalina.jar:na]
      2. org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)[catalina.jar:na]
      2 frames
    38. Spring
      OncePerRequestFilter.doFilter
      1. org.springframework.web.filter.CharacterEncodingFilter.doFilterInternal(CharacterEncodingFilter.java:96)[spring-2.5.6.jar:2.5.6]
      2. org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:76)[spring-2.5.6.jar:2.5.6]
      2 frames
    39. Glassfish Core
      CoyoteAdapter.service
      1. org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)[catalina.jar:na]
      2. org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)[catalina.jar:na]
      3. org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233)[catalina.jar:na]
      4. org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)[catalina.jar:na]
      5. org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:433)[catalina.jar:na]
      6. org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)[catalina.jar:na]
      7. org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)[catalina.jar:na]
      8. org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)[catalina.jar:na]
      9. org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:286)[catalina.jar:na]
      9 frames
    40. Grizzly HTTP
      JIoEndpoint$Worker.run
      1. org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:845)[tomcat-coyote.jar:na]
      2. org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:583)[tomcat-coyote.jar:na]
      3. org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)[tomcat-coyote.jar:na]
      3 frames