Spring Boot Apache Tomcat
Posted onby admin
There are some issue that you might find when you first time spin-up springBoot application in tomcat.

Create stand-alone Spring applications Embed Tomcat, Jetty or Undertow directly (no need to deploy WAR files) Provide opinionated 'starter' dependencies to simplify your build configuration Automatically configure Spring and 3rd party libraries whenever possible.

- Spring Boot includes an embedded Tomcat server which makes it easy to run web applications. The application code, libraries, and embedded Tomcat server are packaged in an executable JAR that can be run from the command-line without any additional server setup.
- Spring Boot (Gradle 2): Hello world with Authentication Spring Boot: Deploying War file to Tomcat 8's webapps How to Setup Apache as Reverse Proxy for Tomcat Server using mod proxy Maven: mvn command cheat sheet Spring-Boot REST API with CORS App Maven war file deploy to Tomcat Spring-Boot / Spring Security with AngularJS - Part I (Introduction).

Spring Boot Tomcat Log

- First fact is you need to build as war if you want to deploy to tomcat because tomcat does not accept jar.
- You might see this error when you spin up the tomcat server :
- SEVERE: The ServletContentInitializer [# Licensed to the Apache Software Foundation (ASF) under one or more] could not be created
- java.lang.ClassNotFoundException: # Licensed to the Apache Software Foundation (ASF) under one or more
Spring Boot Apache Tomcat
- If you see this error do not worry. It happens because there is springBoot library that conflicted. All you need to do is exclude it. I solved my issue by updating my build.gradle to :
Spring Boot Apache Tomcat Tutorial
- dependencies {compile(‘org.springframework.boot:spring-boot-starter-web’) {exclude module: ‘spring-boot-starter-tomcat’}}