Q)What are the system requirements to develop and run a Java web application? =>Install a Web Container. For eg, Tomcat Q)What is the hierarchy of servlet classes? DIAGRAM =>javax.servlet.Servlet is a library interface of Servlet API. =>javax.servlet.GenericServlet is the child class of Servlet interface. =>javax.servlet.http.HttpServlet is the child class of GenericServlet. =>A user defined servlet class never directly implements Servlet interface. =>GenericServlet is an abstract class. In this class service() method is absract. =>HttpServlet also is an abstract class. But no method is abstract in this class. Q)Develop a Java web application in which, a servlet produces a web page that displays "Hello Web World" to the the end-user. Step 1:- create a structured hierarchy of directories. hellowolrdapplication WEB-INF classes src lib Step 2:- Develop the web resources Note:- In this application, we have only one web resource. I.e. a servlet. //HelloWorldServlet.java import javax.servlet.*; import java.io.IOException; public class HelloWorldServlet extends GenericServlet { public void service(ServletRequest request,ServletResponse response)throws ServletException,IOException { System.out.println("Hello ! Web world"); } } Note:- Place servlet-api.jar file in class path before compiling this servlet. Step 3:- web.xml development one HelloWorldServlet one /hello Step 4:- configure the application files. =>Copy web.xml into WEB-INF =>Compile HelloWorldServlet.java and copy the .class file into classes folder. Q)How to deploy the above web application into Tomcat? Step 1:- Copy the entire directory structure(along with files) into "webapps" folder of Tomcat installation folder. Step 2:- start Tomcat web container Q)How to run the above servlet? =>Open the browser and specify the following URL. http://localhost:8081/helloworldapplication/hello