title: Starting tomcat server getting SEVERE: Context initialization failed
body: <p><strong>Error I am facing is that when I start my tomcat server getting this error after successful deployment using ant.</strong></p>
  <p><strong>Jars</strong></p>
  <blockquote>
  <p>org.springframework.beans_3.0.5.RELEASE.jar</p>
  <p>org.springframework.context-3.2.0.release.jar</p>
  <p>org.springframework.jdbc.jar</p>
  <p>org.springframework.orm.jar</p>
  <p>org.springframework.transaction_3.0.5.RELEASE.jar</p>
  <p>spring-core-3.1.1.RELEASE.jar</p>
  <p>spring-dao-2.0.7.jar</p>
  <p>spring-test-4.0.0.RELEASE.jar</p>
  <p>spring-web-3.2.1.RELEASE-sources.jar</p>
  <p>spring-webmvc.jar</p>
  </blockquote>
  <p><strong>ERROR</strong></p>
  <pre><code>  Sep 06, 2014 8:39:18 PM org.apache.catalina.core.AprLifecycleListener init
      INFO: Loaded APR based Apache Tomcat Native library 1.1.30 using APR version 1.4.8.
      Sep 06, 2014 8:39:18 PM org.apache.catalina.core.AprLifecycleListener init
      INFO: APR capabilities: IPv6 [true], sendfile [true], accept filters [false], random [true].
      Sep 06, 2014 8:39:20 PM org.apache.catalina.core.AprLifecycleListener initializeSSL
      INFO: OpenSSL successfully initialized (OpenSSL 1.0.1g 7 Apr 2014)
      Sep 06, 2014 8:39:21 PM org.apache.coyote.AbstractProtocol init
      INFO: Initializing ProtocolHandler [&quot;http-apr-8090&quot;]
      Sep 06, 2014 8:39:21 PM org.apache.coyote.AbstractProtocol init
      INFO: Initializing ProtocolHandler [&quot;ajp-apr-8009&quot;]
      Sep 06, 2014 8:39:21 PM org.apache.catalina.startup.Catalina load
      INFO: Initialization processed in 3466 ms
      Sep 06, 2014 8:39:21 PM org.apache.catalina.core.StandardService startInternal
      INFO: Starting service Catalina
      Sep 06, 2014 8:39:21 PM org.apache.catalina.core.StandardEngine startInternal
      INFO: Starting Servlet Engine: Apache Tomcat/8.0.9
      Sep 06, 2014 8:39:21 PM org.apache.catalina.startup.HostConfig deployWAR
      INFO: Deploying web application archive C:\Users\Chander\apache-tomcat8\webapps\springapp.war
      Sep 06, 2014 8:39:25 PM org.apache.catalina.core.ApplicationContext log
      INFO: Initializing Spring root WebApplicationContext
      Sep 06, 2014 8:39:25 PM org.springframework.web.context.ContextLoader initWebApplicationContext
      INFO: Root WebApplicationContext: initialization started
      Sep 06, 2014 8:39:25 PM org.springframework.web.context.support.XmlWebApplicationContext prepareRefresh
      INFO: Refreshing org.springframework.web.context.support.XmlWebApplicationContext@4359712c: display name [Root WebApplicationContext]; startup date [Sat Sep 06 20:39:25 IST 2014]; root of context hierarchy
      Sep 06, 2014 8:39:26 PM org.springframework.beans.factory.xml.XmlBeanDefinitionReader loadBeanDefinitions
      INFO: Loading XML bean definitions from ServletContext resource [/WEB-INF/springapp-servlet.xml]
      Sep 06, 2014 8:39:28 PM org.springframework.web.context.ContextLoader initWebApplicationContext
      SEVERE: Context initialization failed
      org.springframework.beans.factory.BeanDefinitionStoreException: Unexpected exception parsing XML document from ServletContext resource [/WEB-INF/springapp-servlet.xml]; nested exception is java.lang.IllegalStateException: Context namespace element 'component-scan' and its parser class [org.springframework.context.annotation.ComponentScanBeanDefinitionParser] are only available on JDK 1.5 and higher
          at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.doLoadBeanDefinitions(XmlBeanDefinitionReader.java:420)
          at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.loadBeanDefinitions(XmlBeanDefinitionReader.java:342)
          at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.loadBeanDefinitions(XmlBeanDefinitionReader.java:310)
          at org.springframework.beans.factory.support.AbstractBeanDefinitionReader.loadBeanDefinitions(AbstractBeanDefinitionReader.java:143)
          at org.springframework.beans.factory.support.AbstractBeanDefinitionReader.loadBeanDefinitions(AbstractBeanDefinitionReader.java:178)
          at org.springframework.beans.factory.support.AbstractBeanDefinitionReader.loadBeanDefinitions(AbstractBeanDefinitionReader.java:149)
          at org.springframework.web.context.support.XmlWebApplicationContext.loadBeanDefinitions(XmlWebApplicationContext.java:124)
          at org.springframework.web.context.support.XmlWebApplicationContext.loadBeanDefinitions(XmlWebApplicationContext.java:92)
          at org.springframework.context.support.AbstractRefreshableApplicationContext.refreshBeanFactory(AbstractRefreshableApplicationContext.java:123)
          at org.springframework.context.support.AbstractApplicationContext.obtainFreshBeanFactory(AbstractApplicationContext.java:422)
          at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:352)
          at org.springframework.web.context.ContextLoader.createWebApplicationContext(ContextLoader.java:255)
          at org.springframework.web.context.ContextLoader.initWebApplicationContext(ContextLoader.java:199)
          at org.springframework.web.context.ContextLoaderListener.contextInitialized(ContextLoaderListener.java:45)
          at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:4760)
          at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5184)
          at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
          at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:724)
          at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:700)
          at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:714)
          at org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:919)
          at org.apache.catalina.startup.HostConfig$DeployWar.run(HostConfig.java:1704)
          at java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source)
          at java.util.concurrent.FutureTask.run(Unknown Source)
          at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
          at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
          at java.lang.Thread.run(Unknown Source)
      Caused by: java.lang.IllegalStateException: Context namespace element 'component-scan' and its parser class [org.springframework.context.annotation.ComponentScanBeanDefinitionParser] are only available on JDK 1.5 and higher
          at org.springframework.context.config.ContextNamespaceHandler$1.parse(ContextNamespaceHandler.java:65)
          at org.springframework.beans.factory.xml.NamespaceHandlerSupport.parse(NamespaceHandlerSupport.java:69)
          at org.springframework.beans.factory.xml.BeanDefinitionParserDelegate.parseCustomElement(BeanDefinitionParserDelegate.java:1297)
          at org.springframework.beans.factory.xml.BeanDefinitionParserDelegate.parseCustomElement(BeanDefinitionParserDelegate.java:1287)
          at org.springframework.beans.factory.xml.DefaultBeanDefinitionDocumentReader.parseBeanDefinitions(DefaultBeanDefinitionDocumentReader.java:135)
          at org.springframework.beans.factory.xml.DefaultBeanDefinitionDocumentReader.registerBeanDefinitions(DefaultBeanDefinitionDocumentReader.java:92)
          at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.registerBeanDefinitions(XmlBeanDefinitionReader.java:507)
          at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.doLoadBeanDefinitions(XmlBeanDefinitionReader.java:398)
          ... 26 more
      
      Sep 06, 2014 8:39:28 PM org.apache.catalina.core.StandardContext listenerStart
      SEVERE: Exception sending context initialized event to listener instance of class org.springframework.web.context.ContextLoaderListener
      org.springframework.beans.factory.BeanDefinitionStoreException: Unexpected exception parsing XML document from ServletContext resource [/WEB-INF/springapp-servlet.xml]; nested exception is java.lang.IllegalStateException: Context namespace element 'component-scan' and its parser class [org.springframework.context.annotation.ComponentScanBeanDefinitionParser] are only available on JDK 1.5 and higher
          at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.doLoadBeanDefinitions(XmlBeanDefinitionReader.java:420)
          at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.loadBeanDefinitions(XmlBeanDefinitionReader.java:342)
          at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.loadBeanDefinitions(XmlBeanDefinitionReader.java:310)
          at org.springframework.beans.factory.support.AbstractBeanDefinitionReader.loadBeanDefinitions(AbstractBeanDefinitionReader.java:143)
          at org.springframework.beans.factory.support.AbstractBeanDefinitionReader.loadBeanDefinitions(AbstractBeanDefinitionReader.java:178)
          at org.springframework.beans.factory.support.AbstractBeanDefinitionReader.loadBeanDefinitions(AbstractBeanDefinitionReader.java:149)
          at org.springframework.web.context.support.XmlWebApplicationContext.loadBeanDefinitions(XmlWebApplicationContext.java:124)
          at org.springframework.web.context.support.XmlWebApplicationContext.loadBeanDefinitions(XmlWebApplicationContext.java:92)
          at org.springframework.context.support.AbstractRefreshableApplicationContext.refreshBeanFactory(AbstractRefreshableApplicationContext.java:123)
          at org.springframework.context.support.AbstractApplicationContext.obtainFreshBeanFactory(AbstractApplicationContext.java:422)
          at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:352)
          at org.springframework.web.context.ContextLoader.createWebApplicationContext(ContextLoader.java:255)
          at org.springframework.web.context.ContextLoader.initWebApplicationContext(ContextLoader.java:199)
          at org.springframework.web.context.ContextLoaderListener.contextInitialized(ContextLoaderListener.java:45)
          at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:4760)
          at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5184)
          at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
          at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:724)
          at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:700)
          at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:714)
          at org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:919)
          at org.apache.catalina.startup.HostConfig$DeployWar.run(HostConfig.java:1704)
          at java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source)
          at java.util.concurrent.FutureTask.run(Unknown Source)
          at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
          at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
          at java.lang.Thread.run(Unknown Source)
      Caused by: java.lang.IllegalStateException: Context namespace element 'component-scan' and its parser class [org.springframework.context.annotation.ComponentScanBeanDefinitionParser] are only available on JDK 1.5 and higher
          at org.springframework.context.config.ContextNamespaceHandler$1.parse(ContextNamespaceHandler.java:65)
          at org.springframework.beans.factory.xml.NamespaceHandlerSupport.parse(NamespaceHandlerSupport.java:69)
          at org.springframework.beans.factory.xml.BeanDefinitionParserDelegate.parseCustomElement(BeanDefinitionParserDelegate.java:1297)
          at org.springframework.beans.factory.xml.BeanDefinitionParserDelegate.parseCustomElement(BeanDefinitionParserDelegate.java:1287)
          at org.springframework.beans.factory.xml.DefaultBeanDefinitionDocumentReader.parseBeanDefinitions(DefaultBeanDefinitionDocumentReader.java:135)
          at org.springframework.beans.factory.xml.DefaultBeanDefinitionDocumentReader.registerBeanDefinitions(DefaultBeanDefinitionDocumentReader.java:92)
          at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.registerBeanDefinitions(XmlBeanDefinitionReader.java:507)
          at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.doLoadBeanDefinitions(XmlBeanDefinitionReader.java:398)
          ... 26 more
      
      Sep 06, 2014 8:39:28 PM org.apache.catalina.core.StandardContext startInternal
      SEVERE: Error listenerStart
      Sep 06, 2014 8:39:29 PM org.apache.catalina.util.SessionIdGenerator createSecureRandom
      INFO: Creation of SecureRandom instance for session ID generation using [SHA1PRNG] took [431] milliseconds.
      Sep 06, 2014 8:39:29 PM org.apache.catalina.core.StandardContext startInternal
      SEVERE: Context [/springapp] startup failed due to previous errors
      Sep 06, 2014 8:39:29 PM org.apache.catalina.core.ApplicationContext log
      INFO: Closing Spring root WebApplicationContext
      Sep 06, 2014 8:39:29 PM org.apache.catalina.startup.HostConfig deployWAR
      INFO: Deployment of web application archive C:\Users\Chander\apache-tomcat8\webapps\springapp.war has finished in 7,903 ms
      Sep 06, 2014 8:39:29 PM org.apache.catalina.startup.HostConfig deployDirectory
      INFO: Deploying web application directory C:\Users\Chander\apache-tomcat8\webapps\docs
      Sep 06, 2014 8:39:29 PM org.apache.catalina.startup.HostConfig deployDirectory
      INFO: Deployment of web application directory C:\Users\Chander\apache-tomcat8\webapps\docs has finished in 127 ms
      Sep 06, 2014 8:39:29 PM org.apache.catalina.startup.HostConfig deployDirectory
      INFO: Deploying web application directory C:\Users\Chander\apache-tomcat8\webapps\examples
      Sep 06, 2014 8:39:31 PM org.apache.catalina.core.ApplicationContext log
      INFO: ContextListener: contextInitialized()
      Sep 06, 2014 8:39:31 PM org.apache.catalina.core.ApplicationContext log
      INFO: SessionListener: contextInitialized()
      Sep 06, 2014 8:39:31 PM org.apache.catalina.startup.HostConfig deployDirectory
      INFO: Deployment of web application directory C:\Users\Chander\apache-tomcat8\webapps\examples has finished in 1,841 ms
      Sep 06, 2014 8:39:31 PM org.apache.catalina.startup.HostConfig deployDirectory
      INFO: Deploying web application directory C:\Users\Chander\apache-tomcat8\webapps\host-manager
      Sep 06, 2014 8:39:31 PM org.apache.catalina.startup.HostConfig deployDirectory
      INFO: Deployment of web application directory C:\Users\Chander\apache-tomcat8\webapps\host-manager has finished in 121 ms
      Sep 06, 2014 8:39:31 PM org.apache.catalina.startup.HostConfig deployDirectory
      INFO: Deploying web application directory C:\Users\Chander\apache-tomcat8\webapps\manager
      Sep 06, 2014 8:39:31 PM org.apache.catalina.startup.HostConfig deployDirectory
      INFO: Deployment of web application directory C:\Users\Chander\apache-tomcat8\webapps\manager has finished in 121 ms
      Sep 06, 2014 8:39:31 PM org.apache.catalina.startup.HostConfig deployDirectory
      INFO: Deploying web application directory C:\Users\Chander\apache-tomcat8\webapps\ROOT
      Sep 06, 2014 8:39:31 PM org.apache.catalina.startup.HostConfig deployDirectory
      INFO: Deployment of web application directory C:\Users\Chander\apache-tomcat8\webapps\ROOT has finished in 89 ms
      Sep 06, 2014 8:39:31 PM org.apache.coyote.AbstractProtocol start
      INFO: Starting ProtocolHandler [&quot;http-apr-8090&quot;]
      Sep 06, 2014 8:39:31 PM org.apache.coyote.AbstractProtocol start
      INFO: Starting ProtocolHandler [&quot;ajp-apr-8009&quot;]
      Sep 06, 2014 8:39:31 PM org.apache.catalina.startup.Catalina start
      INFO: Server startup in 10412 ms
  </code></pre>