In this maven tutorial, learn to add and configure tomcat plugin to pom.xml and use it deploy the web application without any tomcat installation in machine.
Mostly for logging and security purpose, we need the information of IP address for incoming requests. In any java web application, you can get IP address using getRemoteAddr() method. String httpServletAddress = request.getRemoteAddr(); BUT, if your application is running behind a load balancer proxy and you would like to translate the real request IP that […]
When your application is deployed in tomcat webserver and you request a URL which refers to a directory instead of a file, e.g., http://host:port/helloWorldApp/, you can configure Tomcat to serve the directory listing, or a welcome file, or issue error “404 Page Not Found”. Let’s see how you can enable or disable directory listing in […]
Secure Socket Layer (SSL) is a secure transfer protocol used for communication on the Internet using cryptographic methods. The main purpose of the SSL protocol is to guarantee that no one can tamper with the communication between a browser and the server where the web application is deployed. Another purpose of secure communication is the […]
By default, tomcat is configured to run on port 8080. That’s why all your deployed web applications are accessible though URLs like http://localhost:8080/yourapp. If you want to run your applications on URL like http://localhost/yourapp, then you will need to change the default port 8080 to 80, which is default port for HTTP connectors. To make […]