Tomcat is a mature, open source, lightweight, robust, and widely used application server. Explore the major components and what they do in this video.
- [Instructor] Tomcat is a lightweight and robust application server for Java. It's free and open source, written in Java, and designed for hosting Java applications. Tomcat has been around for a long time, over 20 years. It's widely used in production for a wide range of applications including non-Java applications written in languages that use the Java Virtual Machine, like JRuby and Closure. The primary way Tomcat interacts with the underlying system is through something called a servlet. Simply put, a servlet is a bit of compiled Java code that's been set up to interface with Tomcat. A servlet can do just about anything a Java application can do like interact with the database and it doesn't need to understand HTTP, URLs, et cetera. All of that is handled by Tomcat. Tomcat itself is made up of three main component parts, Catalina, Jasper, and Coyote. We won't exactly be interacting with these components individually, but you'll see the names from time to time in log files and error messages. Catalina is one of the most important. Catalina is the piece that handles the interface between servlets and the rest of Tomcat. It handles URLs routing to different servlets. Jasper is the component that compiles JSP files, or Java Server Pages, into servlets. JSP is kind of the Java equivalent of PHP or ASP. JSP lets you create HTML content that incorporates some Java. For example, iterating through a list of names to generate lines in a table. It's built to be a bit more user friendly that writing pure Java servlets when generating HTML content. The other major piece is Coyote. This is the part of Tomcat that handles the actual HTTP communication and lets the rest of the system act like a regular web server serving static files.
- What is Tomcat?
- Java servlets
- Creating your first Tomcat application
- Configuration settings for Tomcat logs
- Reading Tomcat logs
- Encrypting web traffic with Tomcat
- Deploying a web app using Tomcat Manager