<rt id="bn8ez"></rt>
<label id="bn8ez"></label>

  • <span id="bn8ez"></span>

    <label id="bn8ez"><meter id="bn8ez"></meter></label>

    隨筆 - 53, 文章 - 0, 評論 - 3, 引用 - 0
    數據加載中……

    Tomcat Source Code Reading

    0. I am reading the source code of Tomcat 6.0.26. To pay off the effort,
    I documents some notes for record. Thanks for the articles about Tomcat
    source code, especially the book <<How Tomcat works>>.

    1. They are two concepts about server, one is called Server, which
    is for managing the Tomcat (start and stop); another is called Connector,
    which is the server to serve the application request. they are on the different
    ports. The server.xml clearly show the difference.

    <Server port="8005" shutdown="SHUTDOWN">
      <Service name="Catalina">
        <Connector port="8080" protocol="HTTP/1.1"
                   connectionTimeout="20000"
                   redirectPort="8443" />
        <Connector port="8009" protocol="AJP/1.3" redirectPort="8443" />

    although the server is the top level element, logically it should not be.
    Actually in code, Bootstrap starts the service first, which
    in turn start the Server and server's services.

    2. My focus in on Connector part. I care how the request is services by the
    Tomcat. Here are some key classes.

    Connector --> ProtocolHandler (HttpProtocol
                            and AjpProtocol)                       --> JIoEndPoint
                                                                               --> Handler(Http11ConnectionHandler
                                                                               and AjpConnectionHandler)
                                                      
                                                      
    3. Connector is most obervious class, but the entry point is not here.
    The sequence is like this.

    Connector.Acceptor.run()
    --> JioEndPoint.processSocke(Socket socket)
        -->SockeProcess.run()
            -->Http11ConnectorHandler.process(Socket socket)
                -->Http11Processor.process(Socket socket)
                    -->CoyoteAdapter.service(Request req, Response res)       

    The core logic is in method Http11Processor.process(Socket socket)                                                  

    CoyoteAdapter.service(Request req, Response res) bridges between Connector module and Container module.

    Any comments are welcome. I may continue the source code reading and dig deeper into it if time permit.


    posted on 2010-03-30 17:11 InPractice 閱讀(607) 評論(0)  編輯  收藏


    只有注冊用戶登錄后才能發表評論。


    網站導航:
     
    主站蜘蛛池模板: 88av免费观看| 国产大片线上免费观看| 亚洲资源在线观看| 成年女人免费v片| 四虎一区二区成人免费影院网址 | 四虎影永久在线高清免费| 国产精品免费一区二区三区| 亚洲视频在线免费观看| 免费欧洲美女牲交视频| 中国毛片免费观看| 亚洲日本VA午夜在线电影| 国产亚洲福利精品一区| 日韩在线免费电影| 亚洲视频在线观看免费视频| 羞羞视频免费网站入口| 亚洲黄色中文字幕| 亚洲一区二区视频在线观看| 亚洲男人天堂影院| 亚洲人成网站在线观看青青| 97在线线免费观看视频在线观看| 国产日韩精品无码区免费专区国产 | 91免费人成网站在线观看18| 美女被羞羞网站免费下载| 亚洲综合激情六月婷婷在线观看| 亚洲AV成人精品日韩一区18p| 免费观看四虎精品成人| 亚洲国产成AV人天堂无码| 成年午夜视频免费观看视频| 热99RE久久精品这里都是精品免费| 亚洲国产精华液2020| 中文字幕亚洲专区| 免费高清在线爱做视频| 亚洲免费电影网站| 国产免费无码一区二区| 九一在线完整视频免费观看| 亚洲国产AV一区二区三区四区| 久久久久久久亚洲Av无码 | 亚洲av无码一区二区三区人妖| 亚洲色图国产精品| 久久精品国产亚洲AV果冻传媒| 成人免费在线看片|