tomcat 架构

Tomcat架构:

tomcat组成:JWS(Sun)+Jserv(ASF)

tomcat的安装软件:jdk+tomcat

tomcat组件:

        server,service,connector,engine,host,context


Tomcat Instance:运行中的tomcat进程(JAVA进程)

       一台服务器上可以运行多个实例,每个实例对应一个server

            server:tomcat的一个实例,tomcat自身

             Engine:Tomcat的核心组件,用于运行jsp和servlet代码

            connector:接收并解析用户的请求,将用户请求转发到引擎,由引擎运行代码,将运行后的结果构建成响应报文,并返回给用户

            service:用于将connector与engine 关联起来,一个service内部只能有一个engine组件和一个或多个connector组件

            Host:类似httpd中的虚拟主机

            context:将一个路径部署为单独的一个应用程序,单独管理,类似于httpd中的alias,映射路径

                        http://www.linuxmysql.com/context

            一个connector只能属于一个engine

            一个engine可以有多个connector

            一个service内部只能有一个engine

            注意:每个组件都由类来实现,有些组件的实现还止一种

                        分类:

                                    顶级类组件:server

                                    服务类组件:service

                                    容器类组件:即可以部署webapp的组件,engine,host,context

                                    连接器组件:connector

                                    被嵌套类组件:valve,logger,realm

                        <server>

                                    <service>

                                                <connector/>

                                                <connector/>

                                                ....

                                                <engine>

                                                            <host>

                                                                        <context/>

                                                                        ...

                                                            </host>

                                                            ...

                                                </engine>

                                    </service>

                        </server>

 

Tomcat的运行模式:

standalone:(单独):通过内置的web server(http connector)来接收客户端请求

            

 

进程间配置:

            Proxy:由专门的web  server服务客户端的http请求

                        in-process:部署于同一主机

                        network:部署于不同的主机

            

 独立/网络配置:

 

                 

          

 

            

   

                       

                  

 

 

 

 

 

分割线
感谢打赏
江西数库信息技术有限公司
YWSOS.COM 平台代运维解决方案
 评论
 发表评论
姓   名:

Powered by AKCMS