Apache Tomcat

Web/WAS 2012. 2. 5. 12:14

Apache Tomcat (or Jakarta Tomcat or simply Tomcat) is an open source web server and servlet containerdeveloped by the Apache Software Foundation (ASF). Tomcat implements the Java Servlet and the JavaServer Pages (JSP) specifications from Oracle Corporation, and provides a "pure JavaHTTP web server environment forJava code to run.

Tomcat should not be confused with the Apache web server, which is a C implementation of an HTTP web server; these two web servers are not bundled together, although they are frequently used together as part of a serverapplication stack. Apache Tomcat includes tools for configuration and management, but can also be configured by editing XML configuration files.

Contents

  [hide

[edit]Components

Tomcat4.x was released with Catalina ( servlet container), Coyote (an HTTP connector) and Jasper (a JSP engine).

[edit]Catalina

Catalina is Tomcat's servlet container. Catalina implements Sun Microsystems' specifications for servlet and JavaServer Pages (JSP). In Tomcat, a Realm element represents a "database" of usernames, passwords, and roles (similar to Unix groups) assigned to those users. Different implementations of Realm allow Catalina to be integrated into environments where such authentication information is already being created and maintained, and then utilize that information to implement Container Managed Security as described in the Servlet Specification.To implement the Java based applications HTTP webserver..[2]

[edit]Coyote

Coyote is Tomcat's HTTP Connector component that supports the HTTP 1.1 protocol for the web server or application container. Coyote listens for incoming connections on a specific TCP port on the server and forwards the request to the Tomcat Engine to process the request and send back a response to the requesting client.

[edit]Jasper

Jasper is Tomcat's JSP Engine. Tomcat 5.x uses Jasper 2, which is an implementation of the Sun Microsystems's JavaServer Pages 2.0 specification. 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.

[edit]Jasper 2

From Jasper to Jasper 2, important features were added:

  • JSP Tag library pooling - Each tag markup in JSP file is handled by a tag handler class. Tag handler class objects can be pooled and reused in the whole JSP servlet.
  • Background JSP compilation - While recompiling modified JSP Java code, the older version is still available for server requests. The older JSP servlet is deleted once the new JSP servlet has finished being recompiled.
  • Recompile JSP when included page changes - Pages can be inserted and included into a JSP at runtime. The JSP will not only be recompiled with JSP file changes but also with included page changes.
  • JDT Java compiler - Jasper 2 can use the Eclipse JDT (Java Development Tools) Java compiler instead of Ant and javac.

[edit]Features

Tomcat 7.x implements the Servlet 3.0 and JSP 2.2 specifications.[3] It requires Java version 1.6, although previous versions have run on Java 1.1 through 1.5. Versions 5 through 6 saw improvements in garbage collection, JSP parsing, performance and scalability. Native wrappers, known as "Tomcat Native", are available for Microsoft Windows and Unix for platform integration.

[edit]Deployment

Experienced users can build and install Tomcat manually from source code after installing such dependencies as the Java Development Kit and the Apache Ant build tool.

Depending on the usage requirements, Tomcat may either be deployed as a standalone pure-Java web server or as a component in a more complex configuration in which it serves as a back-end which handles requests passed to it from a general purpose web server such as Apache, using a connector such as mod_jk supplied by the Apache Tomcat team, or mod_proxy an optional module for the Apache HTTP Server supplied by the Apache HTTP Server team.

[edit]History

Tomcat started off as a servlet reference implementation by James Duncan Davidson, a software architect at Sun Microsystems. He later helped make the project open source and played a key role in its donation by Sun to the Apache Software Foundation. The Apache Ant software build automation tool was developed as a side-effect of the creation of Tomcat as an open source project.

Davidson had initially hoped that the project would become open sourced and, since many open source projects had O'Reilly books associated with them featuring an animal on the cover, he wanted to name the project after an animal. He came up with Tomcat since he reasoned the animal represented something that could fend for itself. Although the tomcat was already in use for another O'Reilly title, his wish to see an animal cover eventually came true when O'Reilly published their Tomcat book with a snow leopard on the cover.[4]

[edit]Releases

VersionRelease DateDescription
Apache Tomcat versions
3.0.x. (initial release) 1999 Merger of donated Sun Java Web Server code and ASF and Implements Servlet 2.2 and JSP 1.1 specifications.
3.3.2 2004-03-09 Latest 3.x release.
4.1.31 2004-10-11
4.1.36 2008-03-24
4.1.39 2008-12-03
4.1.40 2009-06-25 Latest 4.x release.
5.0.0 2002-10-09
5.0.23
5.0.24 2004-05-09
5.0.28 2004-08-28
5.0.30 2004-08-30 Latest 5.0.x release
5.5.0 2004-08-31
5.5.1 2004-09-07
5.5.4 2004-11-10
5.5.7 2005-01-30
5.5.9 2005-04-11
5.5.12 2005-10-09
5.5.15 2006-01-21
5.5.16 2006-03-16
5.5.17 2006-04-28
5.5.20 2006-09-01
5.5.23 2007-03
5.5.25 2007-09
5.5.26 2008-02
5.5.27 2008-09-08
5.5.28 2009-09-04
5.5.30 2010-07-09
5.5.31 2010-09-16
5.5.32 2011-02-01
5.5.33 2011-02-10
5.5.34 2011-09-22
5.5.35 2012-01-16 Latest 5.5.x release
6.0.0 2006-12-01
6.0.10 2007-03-01
6.0.13 2007-05-15
6.0.14 2007-08-13
6.0.16 2008-02-07
6.0.18 2008-07-31
6.0.20 2009-06-03
6.0.24 2010-01-21
6.0.26 2010-03-11
6.0.28 2010-07-09
6.0.29 2010-07-22
6.0.30 2011-01-13
6.0.32 2011-02-03
6.0.33 2011-08-18
6.0.35 2011-11-28 Latest 6.x release.
7.0.0 beta 2010-06-29 First Apache Tomcat release to support the Servlet 3.0JSP 2.2, and EL 2.2 specifications.
7.0.4 beta 2010-10-21
7.0.5 beta 2010-12-01
7.0.6 2011-01-14
7.0.8 2011-02-05
7.0.10 2011-03-07
7.0.11 2011-03-11
7.0.12 2011-04-06
7.0.14 2011-05-12
7.0.16 2011-06-17
7.0.19 2011-07-19
7.0.20 2011-08-11
7.0.21 2011-09-01
7.0.22 2011-10-01
7.0.23 2011-11-20 Fourth stable version.
7.0.25 2012-01-21 Current stable version.

[edit]Communities

Apache software is built in a community process, with both user and developer mailing lists. The developer list is where discussion on building and testing the next release takes place, while the user list is where users can discuss their problems with the developers and other users.

Some of the free Apache Tomcat resources and communities include Tomcatexpert.com (a SpringSource sponsored community for developers and operators who are running Apache Tomcat in large-scale production environments) and MuleSoft's Apache Tomcat Resource Center (which has instructional guides on installing, updating, configuring, monitoring, troubleshooting and securing various versions of Tomcat).

[edit]Apache TomEE

Apache TomEE (pronounced "Tommy") is the Java Enterprise Edition of Apache Tomcat (Tomcat + Java EE = TomEE) that combines several Java enterprise projects including Apache OpenEJB, Apache OpenWebBeans, Apache OpenJPAApache MyFaces and others.[5] In October 2011, the project obtained certification by Oracle Corporation as a compatible implementation of the Java EE 6 Web Profile.[6][7]

[edit]See also

[edit]References


==============================================================================================

Apache Tomcat (아파치 톰캣)은 Java Servlet 과 JavaServer Pages (JSP)를 실행하는 서블릿 컨테이너 (서블릿 엔진)이다. Apache License, Version 2.0을 채용한 오픈 소스 소프트웨어 이며 상용 이용도 많다.Java Servlet 3.0, JavaServer Pages 2.2 대응. 버전 7.0은 JDK 6 이상이 필요합니다.

Apache 소프트웨어 재단 의 최상위 프로젝트의 하나인 Apache Tomcat Project에서 개발되고있다. 이전Jakarta 프로젝트 에서 개발되고 있었다.

목차

  [ 숨기기 ] 

구성 편집 ]

Tomcat 5.0에서 Jasper2을 포함한다.

  • Catalina - Servlet 컨테이너
  • Coyote - HTTP 서버
  • Jasper, Jasper2 - JavaServer Pages

참조 구현으로 Apache Tomcat 편집 ]

서블릿과 JSP의 공식적인 참조 구현 에 사용되고 있지만, 레퍼런스 구현 자체는 아니다.

Web 서버와 연계 편집 ]

Apache Tomcat은 안정적으로 동작하고 정적 콘텐츠 HTTP 서버로 사용할 수 있으므로 별도로 사용할 수도있다. 또한 Tomcat 이외의 HTTP 서버가 HTTP 요청을 받아 필요한 경우 서블릿 컨테이너에 요청을 전달하는 구성으로 HTTP 서버 와 연계해서 사용할 수도있다. 그러나 다른 HTTP 서버와 커넥터 제휴를하면 Advanced IO ( Comet ) 등 일부 기능을 사용할 수 없게된다. 예를 들어, Apache HTTP Server 와 커넥터 모듈을 사용하여 통합하는 경우 Apache Tomcat 측면에서 mod_jk 커넥터로 배포하고있다. 또한 Apache 2.2은 mod_jk과는 다른 방법으로 mod_proxy_ajp 모듈을 이용하는 방법도있다.

외부 링크 편집 ]



================================================================================================

아파치 톰캣(Apache Tomcat)은 아파치 소프트웨어 재단에서 개발된 서블릿 컨테이너(또는 웹 컨테이너)만 있는 웹 애플리케이션 서버이다.

톰캣은 웹 서버와 연동하여 실행할 수 있는 자바 환경을 제공하여 자바 서버 페이지(JSP)와 자바 서블릿이 실행할 수 있는 환경을 제공하고 있다. 톰캣은 관리툴을 통해 설정을 변경할 수 있지만, XML 파일을 편집하여 설정할 수도 있다. 그리고, 톰캣은 HTTP 서버도 자체 내장하기도 한다.

아파치 톰캣은 Apache Licence, Version 2를 채용한 오픈소스 소프트웨어로써 서블릿이나 JSP를 실행하기 위한 서블릿 컨테이너를 제공하며, 상용 웹 애플리케이션 서버에서도 서블릿 컨테이너로 사용하는 경우가 많다. 버전 5.5이후는 기본적으로 Java SE 5.0 이후를 대응한다.

(Tomcat은 사전적 의미로 '수고양이'를 뜻함.)

[편집]웹 서버와의 연동

아파치 톰캣에 내장된 웹 서버로만 웹 시스템을 구성할 수 있지만, 대규모의 사용자가 사용하는 시스템을 구축하려면 웹 서버와 연동하는 안정적인 시스템을 구축해야 한다. 이때, 웹 서버인 아파치 웹 서버와는 연동모듈을 사용하여 연동하고, 연동모듈로는 버전 1.3, 2.0은 mod_jk를 이용하고, 버전 2.2 이후는 mod_proxy_ajp 모듈을 사용한다.

[편집]톰캣의 단점

톰캣은 웹 서버로 사용되기보다는 was로 사용된다. html같은 정적 페이지를 로딩하는데 웹 서버보다 수행 속도가 느리다. 이를 해결하기 위해서 아파치와 연동한다. 아파치는 html같은 정적인 페이지를 로드하는데에 사용되는 웹 서버이다. 원리는 아파치가 실행되면 아파치는 html파일은 자신이 수행하고 jsp파일은 톰캣으로 넘겨서 톰캣이 수행하게 만든다. 또한 톰캣은 java언어만 해석이 가능하기 때문에 톰캣에 자체 내장되어 있는 http서버를 사용할경우 php언어로 작성된 서버 페이지와 통신이 불가능하다. 아파치안에 php,jsp를 넣으면 둘다 수행 가능하게 만들수있기 때문에 이 둘은 상호 보완적이라고 볼수 있다.




'Web > WAS' 카테고리의 다른 글

mod_jk 사용법  (0) 2012.02.10
Jakarta Project  (0) 2012.02.05
Tomcat 무분별하게 catalina.out 크기 커지는것 막기  (0) 2012.02.04
tomcat - crossContext, emptySessionPath, sessionCookiePath  (0) 2012.02.02
tomcat - server.xml 설정  (0) 2012.01.20
Posted by linuxism
,