title: Getting Exception while starting Embedded tomcat of Spring-boot after adding spring-context-support dependency
body: <p>I am trying to create one spring-boot application.I need to use JavaMailSenderImpl class for my application. I have put the Maven dependency inside my pom.xml.</p>
  
  <pre><code>&lt;dependency&gt;
          &lt;groupId&gt;org.springframework&lt;/groupId&gt;
          &lt;artifactId&gt;spring-context-support&lt;/artifactId&gt;
  &lt;/dependency&gt;
  </code></pre>
  
  <p>When I run the command <code>mvn spring-boot:run</code> then it's throwing below mentioned exception:</p>
  
  <pre><code>org.springframework.context.ApplicationContextException: Unable to start embedded container; nested exception is org.springframework.boot.context.embedded.EmbeddedServletContainerException: Unable to start embedded Tomcat
          at org.springframework.boot.context.embedded.EmbeddedWebApplicationContext.onRefresh(EmbeddedWebApplicationContext.java:124)
          at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:474)
          at org.springframework.boot.context.embedded.EmbeddedWebApplicationContext.refresh(EmbeddedWebApplicationContext.java:109)
          at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:691)
          at org.springframework.boot.SpringApplication.run(SpringApplication.java:321)
          at org.springframework.boot.SpringApplication.run(SpringApplication.java:961)
          at org.springframework.boot.SpringApplication.run(SpringApplication.java:950)
          at com.userservice.UserServiceApplication.main(UserServiceApplication.java:20)
          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.springframework.boot.maven.RunMojo$LaunchRunner.run(RunMojo.java:408)
          at java.lang.Thread.run(Thread.java:744)
  Caused by: org.springframework.boot.context.embedded.EmbeddedServletContainerException: Unable to start embedded Tomcat
          at org.springframework.boot.context.embedded.tomcat.TomcatEmbeddedServletContainer.initialize(TomcatEmbeddedServletContainer.java:97)
          at org.springframework.boot.context.embedded.tomcat.TomcatEmbeddedServletContainer.&lt;init&gt;(TomcatEmbeddedServletContainer.java:74)
          at org.springframework.boot.context.embedded.tomcat.TomcatEmbeddedServletContainerFactory.getTomcatEmbeddedServletContainer(TomcatEmbeddedServletContainerFactory.java:374)
          at org.springframework.boot.context.embedded.tomcat.TomcatEmbeddedServletContainerFactory.getEmbeddedServletContainer(TomcatEmbeddedServletContainerFactory.java:150)
          at org.springframework.boot.context.embedded.EmbeddedWebApplicationContext.createEmbeddedServletContainer(EmbeddedWebApplicationContext.java:148)
          at org.springframework.boot.context.embedded.EmbeddedWebApplicationContext.onRefresh(EmbeddedWebApplicationContext.java:121)
          ... 13 common frames omitted
  Caused by: org.apache.catalina.LifecycleException: Failed to start component [StandardServer[-1]]
          at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:154)
          at org.apache.catalina.startup.Tomcat.start(Tomcat.java:339)
          at org.springframework.boot.context.embedded.tomcat.TomcatEmbeddedServletContainer.initialize(TomcatEmbeddedServletContainer.java:87)
          ... 18 common frames omitted
  Caused by: org.apache.catalina.LifecycleException: Failed to start component [StandardService[Tomcat]]
          at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:154)
          at org.apache.catalina.core.StandardServer.startInternal(StandardServer.java:760)
          at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
          ... 20 common frames omitted
  Caused by: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Tomcat]]
          at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:154)
          at org.apache.catalina.core.StandardService.startInternal(StandardService.java:439)
          at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
          ... 22 common frames omitted
  Caused by: org.apache.catalina.LifecycleException: A child container failed during start
          at org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:925)
          at org.apache.catalina.core.StandardEngine.startInternal(StandardEngine.java:262)
          at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
          ... 24 common frames omitted
  
  [WARNING]
  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.springframework.boot.maven.RunMojo$LaunchRunner.run(RunMojo.java:408)
          at java.lang.Thread.run(Thread.java:744)
  Caused by: org.springframework.context.ApplicationContextException: Unable to start embedded container; nested exception is org.springframework.boot.context.embedded.EmbeddedServletContainerException: Unable to start embedded Tomcat
          at org.springframework.boot.context.embedded.EmbeddedWebApplicationContext.onRefresh(EmbeddedWebApplicationContext.java:124)
          at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:474)
          at org.springframework.boot.context.embedded.EmbeddedWebApplicationContext.refresh(EmbeddedWebApplicationContext.java:109)
          at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:691)
          at org.springframework.boot.SpringApplication.run(SpringApplication.java:321)
          at org.springframework.boot.SpringApplication.run(SpringApplication.java:961)
          at org.springframework.boot.SpringApplication.run(SpringApplication.java:950)
          at com.userservice.UserServiceApplication.main(UserServiceApplication.java:20)
          ... 6 more
  Caused by: org.springframework.boot.context.embedded.EmbeddedServletContainerException: Unable to start embedded Tomcat
          at org.springframework.boot.context.embedded.tomcat.TomcatEmbeddedServletContainer.initialize(TomcatEmbeddedServletContainer.java:97)
          at org.springframework.boot.context.embedded.tomcat.TomcatEmbeddedServletContainer.&lt;init&gt;(TomcatEmbeddedServletContainer.java:74)
          at org.springframework.boot.context.embedded.tomcat.TomcatEmbeddedServletContainerFactory.getTomcatEmbeddedServletContainer(TomcatEmbeddedServletContainerFactory.java:374)
          at org.springframework.boot.context.embedded.tomcat.TomcatEmbeddedServletContainerFactory.getEmbeddedServletContainer(TomcatEmbeddedServletContainerFactory.java:150)
          at org.springframework.boot.context.embedded.EmbeddedWebApplicationContext.createEmbeddedServletContainer(EmbeddedWebApplicationContext.java:148)
          at org.springframework.boot.context.embedded.EmbeddedWebApplicationContext.onRefresh(EmbeddedWebApplicationContext.java:121)
          ... 13 more
  Caused by: org.apache.catalina.LifecycleException: Failed to start component [StandardServer[-1]]
          at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:154)
          at org.apache.catalina.startup.Tomcat.start(Tomcat.java:339)
          at org.springframework.boot.context.embedded.tomcat.TomcatEmbeddedServletContainer.initialize(TomcatEmbeddedServletContainer.java:87)
          ... 18 more
  Caused by: org.apache.catalina.LifecycleException: Failed to start component [StandardService[Tomcat]]
          at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:154)
          at org.apache.catalina.core.StandardServer.startInternal(StandardServer.java:760)
          at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
          ... 20 more
  Caused by: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Tomcat]]
          at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:154)
          at org.apache.catalina.core.StandardService.startInternal(StandardService.java:439)
          at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
          ... 22 more
  Caused by: org.apache.catalina.LifecycleException: A child container failed during start
          at org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:925)
          at org.apache.catalina.core.StandardEngine.startInternal(StandardEngine.java:262)
          at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
          ... 24 more
  [INFO] ------------------------------------------------------------------------
  [INFO] BUILD FAILURE
  [INFO] ------------------------------------------------------------------------
  [INFO] Total time: 15.312 s
  [INFO] Finished at: 2015-11-14T14:59:21+05:30
  [INFO] Final Memory: 59M/522M
  [INFO] ------------------------------------------------------------------------
  [ERROR] Failed to execute goal org.springframework.boot:spring-boot-maven-plugin:1.2.0.RELEASE:run (default-cli) on project UserService: An exception occured while running. null: InvocationTargetException: Unable to start embedded container; nested exception is org.springframework.boot.context.embed
  ded.EmbeddedServletContainerException: Unable to start embedded Tomcat: Failed to start component [StandardServer[-1]]: Failed to start component [StandardService[Tomcat]]: Failed to start component [StandardEngine[Tomcat]]: A child container failed during start -&gt; [Help 1]
  [ERROR]
  [ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
  [ERROR] Re-run Maven using the -X switch to enable full debug logging.
  [ERROR]
  [ERROR] For more information about the errors and possible solutions, please read the following articles:
  [ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException
  </code></pre>
  
  <p>My Pom.xml is:</p>
  
  <pre><code>&lt;project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
      xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd"&gt;
      &lt;modelVersion&gt;4.0.0&lt;/modelVersion&gt;
      &lt;groupId&gt;com.collegeDays&lt;/groupId&gt;
      &lt;artifactId&gt;UserService&lt;/artifactId&gt;
      &lt;packaging&gt;war&lt;/packaging&gt;
      &lt;version&gt;0.0.1-SNAPSHOT&lt;/version&gt;
      &lt;name&gt;UserService Maven Webapp&lt;/name&gt;
      &lt;url&gt;http://maven.apache.org&lt;/url&gt;
      &lt;parent&gt;
          &lt;groupId&gt;org.springframework.boot&lt;/groupId&gt;
          &lt;artifactId&gt;spring-boot-starter-parent&lt;/artifactId&gt;
          &lt;version&gt;1.2.0.RELEASE&lt;/version&gt;
      &lt;/parent&gt;
      &lt;dependencies&gt;
          &lt;dependency&gt;
              &lt;groupId&gt;junit&lt;/groupId&gt;
              &lt;artifactId&gt;junit&lt;/artifactId&gt;
              &lt;version&gt;3.8.1&lt;/version&gt;
              &lt;scope&gt;test&lt;/scope&gt;
          &lt;/dependency&gt;
          &lt;dependency&gt;
              &lt;groupId&gt;org.springframework.boot&lt;/groupId&gt;
              &lt;artifactId&gt;spring-boot-starter-web&lt;/artifactId&gt;
          &lt;/dependency&gt;
          &lt;dependency&gt;
              &lt;groupId&gt;org.springframework.boot&lt;/groupId&gt;
              &lt;artifactId&gt;spring-boot-starter-data-jpa&lt;/artifactId&gt;
          &lt;/dependency&gt;
          &lt;dependency&gt;
              &lt;groupId&gt;org.springframework.boot&lt;/groupId&gt;
              &lt;artifactId&gt;spring-boot-starter-actuator&lt;/artifactId&gt;
          &lt;/dependency&gt;
          &lt;dependency&gt;
              &lt;groupId&gt;org.springframework.boot&lt;/groupId&gt;
              &lt;artifactId&gt;spring-boot-starter-web&lt;/artifactId&gt;
          &lt;/dependency&gt;
          &lt;dependency&gt;
              &lt;groupId&gt;org.springframework.boot&lt;/groupId&gt;
              &lt;artifactId&gt;spring-boot-starter-tomcat&lt;/artifactId&gt;
          &lt;/dependency&gt;
          &lt;dependency&gt;
              &lt;groupId&gt;org.apache.tomcat.embed&lt;/groupId&gt;
              &lt;artifactId&gt;tomcat-embed-jasper&lt;/artifactId&gt;
          &lt;/dependency&gt;
          &lt;dependency&gt;
              &lt;groupId&gt;javax.servlet&lt;/groupId&gt;
              &lt;artifactId&gt;jstl&lt;/artifactId&gt;
          &lt;/dependency&gt;
          &lt;dependency&gt;
              &lt;groupId&gt;org.springframework.boot&lt;/groupId&gt;
              &lt;artifactId&gt;spring-boot-starter-security&lt;/artifactId&gt;
          &lt;/dependency&gt;
          &lt;dependency&gt;
              &lt;groupId&gt;org.springframework.boot&lt;/groupId&gt;
              &lt;artifactId&gt;spring-boot-starter-remote-shell&lt;/artifactId&gt;
          &lt;/dependency&gt;
          &lt;dependency&gt;
              &lt;groupId&gt;org.springframework.boot&lt;/groupId&gt;
              &lt;artifactId&gt;spring-boot-starter-aop&lt;/artifactId&gt;
          &lt;/dependency&gt;
          &lt;dependency&gt;
              &lt;groupId&gt;org.springframework.boot&lt;/groupId&gt;
              &lt;artifactId&gt;spring-boot-starter-test&lt;/artifactId&gt;
              &lt;scope&gt;test&lt;/scope&gt;
          &lt;/dependency&gt;
  
          &lt;dependency&gt;
              &lt;groupId&gt;org.hibernate&lt;/groupId&gt;
              &lt;artifactId&gt;hibernate-validator&lt;/artifactId&gt;
          &lt;/dependency&gt;
  
  
          &lt;dependency&gt;
              &lt;groupId&gt;mysql&lt;/groupId&gt;
              &lt;artifactId&gt;mysql-connector-java&lt;/artifactId&gt;
          &lt;/dependency&gt;
  
          &lt;dependency&gt;
              &lt;groupId&gt;org.apache.httpcomponents&lt;/groupId&gt;
              &lt;artifactId&gt;httpclient&lt;/artifactId&gt;
          &lt;/dependency&gt;
          &lt;dependency&gt;
              &lt;groupId&gt;org.apache.commons&lt;/groupId&gt;
              &lt;artifactId&gt;commons-lang3&lt;/artifactId&gt;
              &lt;version&gt;3.3.2&lt;/version&gt;
          &lt;/dependency&gt;
          &lt;dependency&gt;
              &lt;groupId&gt;org.springframework&lt;/groupId&gt;
              &lt;artifactId&gt;spring-oxm&lt;/artifactId&gt;
          &lt;/dependency&gt;
  
          &lt;dependency&gt;
              &lt;groupId&gt;mysql&lt;/groupId&gt;
              &lt;artifactId&gt;mysql-connector-java&lt;/artifactId&gt;
              &lt;version&gt;5.1.21&lt;/version&gt;
          &lt;/dependency&gt;
  
          &lt;dependency&gt;
              &lt;groupId&gt;javax.transaction&lt;/groupId&gt;
              &lt;artifactId&gt;jta&lt;/artifactId&gt;
              &lt;version&gt;1.1&lt;/version&gt;
          &lt;/dependency&gt;
          &lt;dependency&gt;
              &lt;groupId&gt;org.springframework&lt;/groupId&gt;
              &lt;artifactId&gt;spring-jdbc&lt;/artifactId&gt;
          &lt;/dependency&gt;
          &lt;dependency&gt;
              &lt;groupId&gt;org.springframework&lt;/groupId&gt;
              &lt;artifactId&gt;spring-orm&lt;/artifactId&gt;
          &lt;/dependency&gt;
          &lt;!-- &lt;dependency&gt; &lt;groupId&gt;org.springframework&lt;/groupId&gt; &lt;artifactId&gt;spring-context-support&lt;/artifactId&gt; 
              &lt;/dependency&gt; --&gt;
          &lt;dependency&gt;
              &lt;groupId&gt;javax.mail&lt;/groupId&gt;
              &lt;artifactId&gt;mail&lt;/artifactId&gt;
              &lt;version&gt;1.4.7&lt;/version&gt;
              &lt;scope&gt;provided&lt;/scope&gt;
          &lt;/dependency&gt;
          &lt;dependency&gt;
              &lt;groupId&gt;org.springframework&lt;/groupId&gt;
              &lt;artifactId&gt;spring-context-support&lt;/artifactId&gt;
              &lt;version&gt;4.2.2.RELEASE&lt;/version&gt;
          &lt;/dependency&gt;
  
          &lt;!-- &lt;dependency&gt; &lt;groupId&gt;org.apache.velocity&lt;/groupId&gt; &lt;artifactId&gt;velocity&lt;/artifactId&gt; 
              &lt;/dependency&gt; --&gt;
          &lt;dependency&gt;
              &lt;groupId&gt;com.h2database&lt;/groupId&gt;
              &lt;artifactId&gt;h2&lt;/artifactId&gt;
          &lt;/dependency&gt;
          &lt;dependency&gt;
              &lt;groupId&gt;io.jsonwebtoken&lt;/groupId&gt;
              &lt;artifactId&gt;jjwt&lt;/artifactId&gt;
              &lt;version&gt;0.4&lt;/version&gt;
          &lt;/dependency&gt;
          &lt;dependency&gt;
              &lt;groupId&gt;com.google.oauth-client&lt;/groupId&gt;
              &lt;artifactId&gt;google-oauth-client-servlet&lt;/artifactId&gt;
              &lt;version&gt;1.19.0&lt;/version&gt;
          &lt;/dependency&gt;
          &lt;!-- &lt;dependency&gt; &lt;groupId&gt;com.google.api-client&lt;/groupId&gt; &lt;artifactId&gt;google-api-client&lt;/artifactId&gt; 
              &lt;version&gt;1.19.1&lt;/version&gt; &lt;/dependency&gt; --&gt;
      &lt;/dependencies&gt;
  
  &lt;/project&gt;
  </code></pre>
  
  <p>Please give some sugestions.</p>