JAVA SERVLET ARCHITECTURE
- amilu B
- Sep 29, 2018
- 3 min read
The architecture, here, discusses the communication interface, protocol used, requirements of client and server, the programming with the languages and software involved.

Ø In the communication through the Web, the client and the server use the Web (Internet) as an interface (medium) of communication. That is, both the client and the server must connect to the Web (in spite of an Internet service provider) to communicate, that is, they cannot communicate. When connected, the simple client system can be called "Web client" and the server can be called "Web server". Another way of saying simply, any client and server connected to the Web are known as "Web Client" and "Web Server".
Ø The standard protocol used in the Web, nowadays, is the HTTP protocol (HyperText Transfer Protocol). For this reason, the container and the server can also be called "HTTP client" and "HTTP server".
Ø When connected, the client sends a request and answers from the server. In the Web terminology, use only the request and response words (do not use as client and server responses). It is known as a request / response paradigm (style).
Ø To send a request, the software to be loaded in the Web cleint is "Browser"
(the same browser that is used to connect to the Internet). In the same way, the necessary software in the Web server is "Web server software". To obtain the Web server software (or servlet container), the most commonly used server is Tomcat (from Apache), Weblogic (from BEA, now acquired by Oracle) and WebSphere (from IBM), etc.
Ø Responsibilities of the Web Client
• Must be able to receive requests from the client showing some GUI environment (such as username and password as in the login screen).
• Extract the data entered by the user and send them to the Web server as an application.
• Must be able to receive what the server responds to and show the user.
Ø Now, choose a software of this type in the client that can meet the above requirements. Obviously, it is the browser. The browser represents the client's system. When I say the client, that means that I am talking about the browser in the client. The client sends a request medium, the browser in the client sends. Write a program that can meet the above requirements in a language so you understand the browser. The easiet language programmer prefers HTML. For GUI, HTML comes with the <FORM> tag. Then, the client program is written in HTML (alternatively, you can use a Java Applet as well).
Ø Web server responsibilities
• You must receive the request sent by the Web client.
• According to the order, load an appropriate servlet, execute it and send the output of the execution in response to the client.
• When the answer is delivered, close the connection.
On the web server side, I prefer to use the popular Tomcat. Tomcat understands Servlets and JSPaparten other structures such as Struts. Servlets are written in Java according to the specifications of the Servlet API (rules) stipulated by Sun Microsystems. Now, with that knowledge, we are going to write a small program of Login validations in which the client sends (as request) the username and password, the server validates and the valid or invalid answers.
To getting expert-level training for Java Training in your location – java training in chennai | java training in bangalore | java training in pune | java training in chennai | java training in bangalore | java training in tambaram | java training in omr | java training in velachery | java training in annanagar | java training in chennai | java training in marathahalli | java training in btm layout | java training in jayanagar | java training in chennai | java training in usa | For getting java online training | java online training
Comments