|
21.What are the important directories of Apache Tomcat Web Server ?
During installation of tomcat web server, it creates following directories.
- bin: for Tomcat’s binaries and startup scripts.
- lib: Keeps the JAR-file that are available to all webapps. The default installation include servlet-api.jar (Servlet), jasper.jar (JSP) and jasper-el.jar (EL). You may also keep the JAR files of external package here, such as MySQL JDBC driver (mysql-connector-java-5.1.{xx}-bin.jar) and JSTL (jstl.jar and standard.jar).
- logs: contains the engine logfile Catalina.{yyyy-mm-dd}.log, host logfile localhost.{yyyy-mm-dd}.log, and other application logfiles such as manger and host-manager. The access log (created by the AccessLogValve) is also kept here.
- webapps: the default appBase – web applications base directory of the host localhost.
- work: contains the translated servlet source files and classes of JSP/JSF. Organized in hierarchy of engine name (Catalina), host name (localhost), webapp name, followed by the Java classes package structure.
- temp: temporary files
22.What is Tomcat Architecture ?
Tomcat is an HTTP server. Tomcat is also a servlet container that can execute Java Servlet, and converting JavaServer Pages (JSP) and JavaServerFaces (JSF) to Java Servlet. Tomcat employs a hierarchical and modular tomcat architecture as per below:
23.What type of connectors used in Tomcat ?
A Connector is associated with a TCP port to handle communications between the Service and the clients. The default configuration defines two Connectors:
- HTTP/1.1 Connector: Handle HTTP communication and enable Tomcat to be an HTTP server. Clients can issue HTTP requests to the server via this Connector, and receive the HTTP response messages.
- AJP/1.3 Connector: Apache JServ Protocol connector to handle communication between Tomcat server and Apache HTTP server, commonly implemented in Tomcat through the plug-in technology mod_jk.
24.What services does provided by Tomcat Webserver ?
- Life cycle Management
- Clustering
- Thread Management
- Connection pooling
- Handling Web Requests
25.What is Valve in Tomcat Server ?
A Valve in tomcat can capture HTTP asks for before sending them to the applications, for preprocessing the solicitations. A Valve can be characterized for any container, for example, Engine, Host, and Context, and Cluster.
26.What are type of Valve in Tomcat ?
- Access Log
- Remote Address Filter
- Remote Host Filter
- Request Dumper
27.What is Jasper in Tomcat Server ?
Jasper in tomcat is JSP Engine or program to read the .class files in binary format. This program can generate ASCII files , which can be used along with Jasmin Assembler. Jasper is intended for generating input into a class file browser which can produce the hierarchy of inheritance and composition maps from the .class files.
Jasper parses JSP files to compile them into Java code as servlets (that can be handled by Catalina). At runtime, Jasper detects changes to JSP files and recompiles them.
28.Define Tomcat Coyote ?
Tomcat Coyote is a Connector component for Tomcat server that supports the HTTP 1.1 protocol as a webserver. This allows Catalina, nominally a Java Servlet or JSP container, to also act as a plain web server that serves local files as HTTP documents.
Tomcat Coyote listens for incoming connections to the server on a specific TCP/IP port and forwards the request to the Tomcat Engine to process the request and send back a response to the requesting host. Another Coyote Connector, Coyote JK, listens similarly but instead forwards its requests to another webserver, such as Apache, using the JK protocol which usually offers better performance.
29.?
30.?
31.?
32.?
33.?
34.?
35.?
36.?
37.?
38.?
39.?
40.?
|