Divenire_Z
2015-01-11 22:07
一月 11, 2015 10:05:44 下午 org.apache.tomcat.util.digester.Digester endElement 严重: End event threw exception java.lang.reflect.InvocationTargetException at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:606) at org.apache.tomcat.util.IntrospectionUtils.callMethodN(IntrospectionUtils.java:905) at org.apache.tomcat.util.digester.CallMethodRule.end(CallMethodRule.java:532) at org.apache.tomcat.util.digester.Digester.endElement(Digester.java:1063) at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.endElement(AbstractSAXParser.java:609) at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanEndElement(XMLDocumentFragmentScannerImpl.java:1782) at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl$FragmentContentDriver.next(XMLDocumentFragmentScannerImpl.java:2973) at com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl.next(XMLDocumentScannerImpl.java:606) at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanDocument(XMLDocumentFragmentScannerImpl.java:510) at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:848) at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:777) at com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(XMLParser.java:141) at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.parse(AbstractSAXParser.java:1213) at com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl$JAXPSAXParser.parse(SAXParserImpl.java:648) at org.apache.tomcat.util.digester.Digester.parse(Digester.java:1561) at org.apache.catalina.startup.ContextConfig.parseWebXml(ContextConfig.java:1825) at org.apache.catalina.startup.ContextConfig.webConfig(ContextConfig.java:1263) at org.apache.catalina.startup.ContextConfig.configureStart(ContextConfig.java:889) at org.apache.catalina.startup.ContextConfig.lifecycleEvent(ContextConfig.java:386) at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:117) at org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:90) at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5380) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150) at org.apache.catalina.core.StandardContext.reload(StandardContext.java:4009) at org.apache.catalina.startup.HostConfig.reload(HostConfig.java:1479) at org.apache.catalina.startup.HostConfig.checkResources(HostConfig.java:1462) at org.apache.catalina.startup.HostConfig.check(HostConfig.java:1646) at org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:328) at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:117) at org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:90) at org.apache.catalina.core.ContainerBase.backgroundProcess(ContainerBase.java:1374) at org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1546) at org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1556) at org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.run(ContainerBase.java:1524) at java.lang.Thread.run(Thread.java:745) Caused by: java.lang.NumberFormatException: For input string: "0.5" at java.lang.NumberFormatException.forInputString(NumberFormatException.java:65) at java.lang.Integer.parseInt(Integer.java:492) at java.lang.Integer.valueOf(Integer.java:582) at org.apache.catalina.deploy.SessionConfig.setSessionTimeout(SessionConfig.java:45) ... 38 more 一月 11, 2015 10:05:44 下午 org.apache.catalina.startup.ContextConfig parseWebXml 严重: Parse error in application web.xml file at jndi:/localhost/Test_Listener/WEB-INF/web.xml org.xml.sax.SAXParseException; systemId: jndi:/localhost/Test_Listener/WEB-INF/web.xml; lineNumber: 24; columnNumber: 44; Error at (24, 44) : For input string: "0.5" at org.apache.tomcat.util.digester.Digester.createSAXException(Digester.java:2711) at org.apache.tomcat.util.digester.Digester.createSAXException(Digester.java:2743) at org.apache.tomcat.util.digester.Digester.endElement(Digester.java:1066) at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.endElement(AbstractSAXParser.java:609) at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanEndElement(XMLDocumentFragmentScannerImpl.java:1782) at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl$FragmentContentDriver.next(XMLDocumentFragmentScannerImpl.java:2973) at com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl.next(XMLDocumentScannerImpl.java:606) at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanDocument(XMLDocumentFragmentScannerImpl.java:510) at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:848) at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:777) at com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(XMLParser.java:141) at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.parse(AbstractSAXParser.java:1213) at com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl$JAXPSAXParser.parse(SAXParserImpl.java:648) at org.apache.tomcat.util.digester.Digester.parse(Digester.java:1561) at org.apache.catalina.startup.ContextConfig.parseWebXml(ContextConfig.java:1825) at org.apache.catalina.startup.ContextConfig.webConfig(ContextConfig.java:1263) at org.apache.catalina.startup.ContextConfig.configureStart(ContextConfig.java:889) at org.apache.catalina.startup.ContextConfig.lifecycleEvent(ContextConfig.java:386) at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:117) at org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:90) at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5380) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150) at org.apache.catalina.core.StandardContext.reload(StandardContext.java:4009) at org.apache.catalina.startup.HostConfig.reload(HostConfig.java:1479) at org.apache.catalina.startup.HostConfig.checkResources(HostConfig.java:1462) at org.apache.catalina.startup.HostConfig.check(HostConfig.java:1646) at org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:328) at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:117) at org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:90) at org.apache.catalina.core.ContainerBase.backgroundProcess(ContainerBase.java:1374) at org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1546) at org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1556) at org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.run(ContainerBase.java:1524) at java.lang.Thread.run(Thread.java:745) Caused by: java.lang.NumberFormatException: For input string: "0.5" at java.lang.NumberFormatException.forInputString(NumberFormatException.java:65) at java.lang.Integer.parseInt(Integer.java:492) at java.lang.Integer.valueOf(Integer.java:582) at org.apache.catalina.deploy.SessionConfig.setSessionTimeout(SessionConfig.java:45) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:606) at org.apache.tomcat.util.IntrospectionUtils.callMethodN(IntrospectionUtils.java:905) at org.apache.tomcat.util.digester.CallMethodRule.end(CallMethodRule.java:532) at org.apache.tomcat.util.digester.Digester.endElement(Digester.java:1063) ... 31 more
您好,如果在web.xml里面设置的话,只能配置整数(以分钟为单位),负数或0为不限制session失效时间.
如果想涉及到秒,可以通过Java代码设置,如下:
session.setMaxInactiveInterval(30*60);//以秒为单位
JAVA Web开发技术应用——监听器
76033 学习 · 155 问题
相似问题