Server Basics in Java

  • WEB Server – The server which provides the environment for running web application is called as web server.

  • Web server can only run web application only.

  • It can provide the support to only JSP, Html, Servlet etc.
    e.g. Tomcat (Apache).

  • Application Server – The server which provides the environment for running enterprise application is called as app server.

  • App server can run any J2EE technologies such as EJB, JMS etc.

  • It can support to JSP, Html, Server (Web Server) + EJB, JMS etc.
    e.g. JBoss (Red Hat).

After installation of this server we will observe following folders in installation directory.

Apache Tomcat Server Directory

  • bin – From this we can start or stop the server.

  • conf – From this we can change the server configuration such as server port, username, password, etc.

  • lib – Here all the libraries/jar files are present which required for web application.

  • logs – Here we can check the logs of server during running server which can be used to check server errors.

  • webapps – Here all the web application i.e our projects are present. For deploying web projects we have put into this folder.

For deployment of our project we should have following Folder Structure:

Folder Structure for Deployment of Project in Java