Cover image for Tomcat 6 Developer's Guide : Implement a Production-grade Servlet Container using Apache Tomcat.
Tomcat 6 Developer's Guide : Implement a Production-grade Servlet Container using Apache Tomcat.
Title:
Tomcat 6 Developer's Guide : Implement a Production-grade Servlet Container using Apache Tomcat.
Author:
Chetty, Damodar.
ISBN:
9781847197290
Personal Author:
Edition:
1st ed.
Physical Description:
1 online resource (452 pages)
Contents:
Tomcat 6 Developer's Guide -- Table of Contents -- Tomcat 6 Developer's Guide -- Credits -- About the author -- Acknowledgement -- About the reviewers -- Preface -- What this book covers -- What you need for this book -- Who this book is for -- Conventions -- Reader feedback -- Customer support -- Errata -- Piracy -- Questions -- 1. Introduction to Tomcat -- What's the story behind Tomcat? -- What exactly is Tomcat? -- JSPs -- Servlet container -- Why this book? -- Gathering our tools -- Java Development Kit (JDK) 6.0 -- Verifying downloaded files -- Apache Ant -- Subversion -- Obtaining the Tomcat source code -- Using Subversion -- Tomcat source distribution -- Getting ready to build Tomcat -- Downloading dependencies -- Building Tomcat -- Starting up your shiny new Tomcat -- Eclipse -- Summary -- 2. Servlet API Overview -- Java Community Process -- Java Enterprise Edition platform -- What is an enterprise application? -- Simultaneous users -- Highly available, reliable, and scalable -- Heterogeneous environment -- Distributed nature -- Java EE architecture -- Java based -- Generic APIs -- Java EE containers and container services -- Java EE components and their APIs -- Java EE Service APIs -- What is a typical Java EE application architecture? -- Hypertext Transfer Protocol (HTTP) -- Uniform Resource Locator, URL -- HTTP methods -- GET (HTTP/0.9) -- POST (HTTP/1.0) -- PUT (HTTP/1.1) -- DELETE (HTTP/1.1) -- TRACE (HTTP/1.1) -- OPTIONS (HTTP/1.1) -- HEAD (HTTP/1.0) -- HTTP requests -- HTTP responses -- The response line -- Response headers -- Spying on HTTP -- What is the Servlet API? -- Servlet container -- Core servlet classes -- Servlets -- ServletConfig interface -- ServletContext interface -- Multithreading in servlets -- Request -- Request parameters and attributes -- Protocol and URI details -- Reading request data.

Connection information -- HTTP specific information -- Response -- Sessions -- Filters -- Listeners -- Web applications -- Deployment descriptors -- Summary -- 3. Servlet Container Overview -- Component taxonomy -- Architectural benefits -- Top Level Components -- Server -- Service -- Connectors -- Container components -- Engine -- Virtual host -- Basic concepts -- Virtual host techniques -- IP-based virtual hosting -- Name-based virtual hosting -- Virtual host aliasing -- Context -- Context configuration -- Wrapper -- Nested components -- Valve -- Realm -- Executor -- Listener -- Manager -- Loader -- Delegation model -- Java EE class loading -- Tomcat's additional class loaders -- Class reloading in web applications -- Logger -- Resources -- Summary -- 4. Starting Up Tomcat -- Using scripts -- Setting up the environment -- Executing the requested command -- Setting up your project -- Modifying the Run/Debug configuration -- Bootstrapping Tomcat -- Bootstrapping environment variables -- Bootstrapping class loading -- Bootstrapping the embedded container -- Bootstrapping the Tomcat component hierarchy -- Commons Digester -- The pattern -- The rule -- The object stack -- Using the Digester -- The server.xml Digester -- Parsing the server.xml file -- Initializing the Server -- Adding a new web application to Tomcat in Eclipse -- Summary -- 5. The Server and Service Components -- Setting up your project -- Installing MySQL -- Installing the MySQL driver -- Enhancing the devguide web application -- server.xml -- Context fragment -- Web application deployment descriptor -- The contact list servlet -- Additional notes -- JNDI service -- Basic JNDI concepts -- Context -- InitialContext -- Environment naming context -- JNDI URLs -- Initializing an InitialContext -- Looking up names -- Using multiple naming implementations.

URL context factory lookup implementation details -- References -- JNDI resources -- Using JNDI -- Component developer responsibilities -- Using JNDI within a web application component -- Publishing logical references -- -- -- -- Application deployer responsibilities -- Resource definition levels -- Binding logical references -- -- -- -- StandardServer -- Lifecycle -- Shutdown -- JNDI implementation -- Structural relationships -- NamingContext -- References -- Factories -- URL context factory -- StandardService -- Summary -- 6. The Connector Component -- Connector classification -- Usage scenario -- Tomcat with external web server -- mod_jk -- mod_proxy -- Tomcat in standalone mode -- Protocol -- Implementation architecture -- Apache Portable Runtime Connector -- JIO Connector aka Coyote -- NIO connector -- Connector configuration -- Binding attributes -- Socket attributes -- Thread parameters -- The connector subsystem-a structural perspective -- Objective 1: Collection point -- Objective 2: Establishing relationships -- Objective 3: Accept incoming connections -- Objective 4: Maintain a pool of worker threads -- Objective 5: Maintain a mapping of request processing components -- Objective 6: Insulate the engine from the outside world -- Modeling the Request and Response -- Coyote and Catalina -- Request classes -- Coyote Request -- Catalina Request -- Response classes -- HTTP classes -- MimeHeaders -- Parameters and ParameterMap -- Cookies and ServerCookie -- Stream classes -- InternalInputBuffer -- InternalOutputBuffer -- InputBuffer -- OutputBuffer -- ServletInputStream and CoyoteInputStream -- ServletOutputStream and CoyoteOutputStream -- Helper classes -- ByteChunk and CharChunk -- MessageBytes -- Socket programming -- Socket options -- SO_TIMEOUT.

TCP_NODELAY -- SO_LINGER -- The connector subsystem-a dynamic perspective -- Initializing the Apache Portable Runtime (APR) -- Instantiating a Connector -- Initializing the Mapper -- Receiving a request -- Thread notification -- End point -- Connection handler -- ConcurrentLinkedQueue -- Http11Processor -- CoyoteAdapter -- Completing the request -- Summary -- 7. The Engine Component -- Containers -- Nested components -- Engine -- Configuring an Engine -- Implementation details -- StandardEngine -- Container interface -- ContainerBase abstract class -- Parent and child relationships -- Nested components -- Valve management -- Life cycle methods -- Listener management -- Background processing -- Pipeline -- Pipeline execution scope -- Valve execution order -- StandardPipeline -- Valve manipulation -- Lifecycle methods -- Valve -- ValveBase -- StandardEngineValve -- Request Dumper Valve -- Request Filter Valve -- AccessLogValve -- Valve instantiation -- AccessLogElement -- Named patterns -- Valve startup -- Valve invocation -- Summary -- 8. The Host Component -- Virtual hosts -- Tomcat virtual hosts -- Virtual hosting scenarios -- Case 1: Name-based virtual hosting -- Aliasing: Multiple domains to a single set of content -- Case 2: IP-based virtual hosting -- Configuring a host -- StandardHost -- HostConfig -- Contexts and context fragments -- DeployedApplication -- Lifecycle events -- Deploying context fragments -- Deploying WAR files and exploded directories -- Periodic events -- Examples of name-based virtual hosting -- Web Application Deployment Descriptor (web.xml) -- Context Fragment (context.xml) -- webapp1/index.html -- build.xml -- Aliasing -- Name-based virtual hosting -- IP-based virtual hosting -- StandardHostValve -- The servlet error handling mechanism -- Exception processing -- Finding a custom error page by exception type.

Finding a custom error page by response status code -- Setting request attributes -- Forwarding to the error resource -- Method termination -- ErrorReportValve -- Error page mechanism example -- Summary -- 9. The Context Component -- Aspects of the Context component -- The Context aspect -- Configuration files -- Document base and context path -- Context children -- WatchedResource -- Loader -- Resources -- ResourceLink -- Context parameters -- Environment variables -- Valves -- Manager -- Realm -- Web application aspect -- Configuration files -- Web application resources -- Resources -- Resource cache -- Resource retrieval -- BaseDirContext -- FileDirContext -- ProxyDirContext -- Looking up resources -- Cache lookup -- Miscellaneous methods -- Shared library mechanism -- Manifest file format -- URLs and protocol handlers -- Accessing resources -- Protocol handlers -- java.net.URL -- java.net.URLStreamHandler -- java.net.URLConnection -- java.net.URLStreamHandlerFactory -- Protocol handler implementation -- Locating a stream handler -- The jndi protocol -- DirContextURLStreamHandlerFactory -- DirContextURLStreamHandler -- DirContextURLConnection -- Java class loading -- Advantages of dynamic class loading -- Class loader hierarchy -- Class loader rules -- Implicit and explicit class loading -- Tomcat class loading -- Implementing a custom class loader -- Making a class available -- The custom web application class loader -- Class loader initialization -- ResourceEntry -- loadClass() -- findClass() -- getResource() -- Context initialization and startup -- Context initialization -- Digesting the context fragment -- Setting the document base -- Context startup -- Anti resource locking -- Setting up the Context's resources -- Setting up the Context's Loader -- Publish the work directory -- Setting up a servlet context -- Validating optional JARs.

Naming context.
Abstract:
Build better web applications by learning how a servlet container actually works.
Local Note:
Electronic reproduction. Ann Arbor, Michigan : ProQuest Ebook Central, 2017. Available via World Wide Web. Access may be limited to ProQuest Ebook Central affiliated libraries.
Electronic Access:
Click to View
Holds: Copies: