2. WHAT IS APPLICATION SERVER
• An application server is a type of server designed to install, operate and host applications and
associated services for end users, IT services and organizations.
• It facilitates the hosting and delivery of high-end consumer or business applications, which are used by
multiple and simultaneously connected local or remote users.
@2020 copyright KalKey training
3. WHY USE AN APPLICATION SERVER? WHAT ARE THE
BENEFITS?
• Application servers are best used when there is the need to integrate with databases and servers, for
example, web servers, which have already been set up and are part of an organisation's existing IT
infrastructure.
BENEFITS:
• One of the predominant reasons for this is that an application server can serve as a means to provide
integrity to code and data by having an integrated and centralized approach to keeping applications
upgraded and updated.
@2020 copyright KalKey training
4. CONT…
• Another core reason to put an application server to use it that it provides your organization with an
additional layer of security. By sitting in between web pages and databases, an application server helps
act as an additional barrier to SQL injection cyber attacks, as there is no direct link between a web page
and a database. This separation carries the need for validation and/or a requirement to show business
logic, thereby ensuring that text entered into a form on a website is not being exploited as a malicious
SQL call.
@2020 copyright KalKey training
7. APACHE TOMCAT
• The Apache Tomcat software is an open source implementation of the Java Servlet, JavaServer Pages,
Java Expression Language and Java WebSocket technologies.
@2020 copyright KalKey training
8. APACHE TOMCAT COMPONENTS
• Catalina
• Coyote
• Jasper
• Cluster
• High Availability
• Web Application
@2020 copyright KalKey training
9. JASPER 2
• Jasper is the JSP Engine for Tomcat. Jasper is responsible for parsing JSP files and compilation of JSP’s
Java code as servlets.
• Jasper is capable of background compilation, which means if any changes are made to JSP files, then the
older versions of those JSP files are still retained by the server, until the updated JSP files are recompiled
@2020 copyright KalKey training
10. CATALINA
• Catalina is Tomcat’s servlet container. Catalina makes Tomcat a Web Server for dynamic content.
@2020 copyright KalKey training
11. COYOTE
• Coyote is the component that makes Tomcat capable as a HTTP Web Server. Coyote makes Catalina also
act as a server that serves static content.
@2020 copyright KalKey training
12. INSTALLATION OF TOMCAT
• Pre-requisites
EC2 instance with Java v1.8.x
Install Apache Tomcat
• Download tomcat packages from https://tomcat.apache.org/download-
80.cgi onto /opt on EC2 instance
# Create tomcat directory
• cd /opt
• Download from Internet “apache-tomcat-8.5.57.tar.gz”
• tar -xvzf /opt/apache-tomcat-8.5.57.tar.gz
• give executing permissions to startup.sh and shutdown.sh which are
under bin.
• chmod +x /opt/apache-tomcat-8.5.35/bin/startup.sh shutdown.sh
• Run ./startup.sh
@2020 copyright KalKey training
13. CHECK POINT
• Access tomcat application from browser on port 8080
• http://<Public_IP>:8080
• Using unique ports for each application is a best practice in an environment. But tomcat and Jenkins
runs on ports number 8080. Hence lets change tomcat port number to 8090.
• Change port number in conf/server.xml file under tomcat home
cd /opt/apache-tomcat-8.5.35/conf
• # update port number in the "connecter port" field in server.xml
• # restart tomcat after configuration update
• ./shutdown.sh
• ./startup.sh
@2020 copyright KalKey training