Tagged: #tomcat

Deploy JAX-WS service on tomcat

This tutorial provides a step-by-step guide on how to build and deploy JAX-WS web service on Tomcat. Throughout this tutorial, we create a very simple SOAP web service and finally deploy it on Tomcat application server. Prerequisites: Eclipse IDE (Neon release) Java 1.8 Apache Tomcat 8 1. Create Maven web project Create a maven web project using this tutorial and name your...

Deploy Spring Boot application on external Tomcat

Spring Boot provides an embedded servlet container which makes it very easy to setup and deploy web applications, by default all Spring Boot applications are exported as a runnable jar file and developers would only need to run this jar file on a java environment without the need to worry about installing and setting up servlet containers. However, the embedded...

Build REST web service using Spring

This tutorial provides a step-by-step guide on how to build REST web service using Spring framework. Prerequisites: Eclipse IDE (Mars release) Java 1.8 Apache tomcat 8  1. Create Maven web project Create a maven web project using this tutorial and name your project as SpringRestService. The structure of the generated project looks like the following: 2. Add Spring dependencies After creating...

How to create a web project using Maven in Eclipse

In this tutorial, we provide a step-by-step guide on how to create a web project using Maven in Eclipse. Prerequisites: Eclipse IDE (Mars release) Java 1.8 Apache tomcat 8 1. Step-1 Open eclipse, then select File -> New -> Maven Project. 2. Step-2 In the next screen, select the workspace of the project and keep the other options as default then...

How to setup Tomcat in Eclipse

In this tutorial, we provide a step-by-step guide on how to setup and configure Tomcat in Eclipse. Prerequisites: Eclipse IDE (Mars release) Java 1.8 Step-1 Download and install Apache Tomcat 8 using this tutorial. Step-2 Open eclipse, Window -> Show View -> Other -> Servers Click “OK”. Step-3 Inside Servers view, right click -> New -> Server -> Tomcat v8.0...

Building REST web service using RESTEasy

RESTEasy is yet another popular framework which implements JAX-RS specification and is widely used for building REST web services in java. In this tutorial, we provide a step-by-step guide for building a REST web service using RESTEasy framework, we provide different ways to configure RESTEasy with both Servlet 3.0 and Servlet 2.0. If you’re interested in Jersey, check this tutorial. Prerequisites: Eclipse IDE...

Building REST web service using Jersey

Since Java 5, JAX-RS specification has been announced in order to support building REST web services according to the REST architectural pattern. JAX-RS is a set of interfaces or APIs which provides the building blocks for building REST services in java. Although you can’t build a fully functional RESTful service using these interfaces, there exists a lot of popular frameworks...

Load balancing tomcat with Apache

In some circumstances, it is mandatory to deploy your application on multiple tomcat instances instead of a single one, this usually happens when working with a heavy application which consumes a big amount of memory storage and has a big number of active users. The main advantage of using multiple instances is to distribute the requests and the load on...

Configure tomcat memory usage

By default, the memory size allocated for tomcat is not enough to handle heavy applications which require high memory usage, several OutOfMemoryError exceptions will be thrown if you keep the default tomcat configuration. In order to set the appropriate heap size and perm gen size, tomcat requires a file named as setenv.sh in unix environments and setenv.bat in windows. This file is not included in the...

Step-by-step guide for installing tomcat on unix

Here below we provide a step-by-step guide for installing and setting up tomcat in unix environment, for those who are interested in windows machines you can refer to this guide. 1. Prerequisite Tomcat doesn’t work without java, so before installing tomcat on the machine, you should install a compatible java runtime version and setup JAVA_HOME environment variable. Both java and tomcat versions should...