Apache JServ Protocol (AJP)

來源:互聯網
上載者:User

標籤:style   http   io   使用   ar   for   div   sp   cti   

The Apache JServ Protocol (AJP) is a binary protocol that can proxy inbound requests from a web server through to an application server

that sits behind the web server.

It also supports some monitoring in that the web server can ping the application server. Web implementors typically use AJP in a

load-balanced deployment where one or more front-end web servers feed requests into one or more application servers. Sessions

are redirected to the correct application server using a routing mechanism wherein each application server instance gets a name (

called a route). In this scenario the web server functions as a reverse proxy for the application server.

 

AJP runs in Apache HTTP Server 1.x using the mod_jk plugin and in Apache 2.x using the provided Proxy AJP, mod_proxy and proxy

balancer modules together. Implementations exist for the lighttpd 1.5, nginx, Grizzly 2.1, and the Internet Information Server.

Both the Apache Tomcat servlet container as well as the Jetty servlet container support AJP.

 

AJP是定向包協議。因為效能原因,使用二進位格式來傳輸可讀性文本。WEB伺服器通過TCP串連和SERVLET容器串連。為了減少進程產生socket的花費,WEB伺服器和SERVLET容器之間嘗試保持持久性的TCP串連,對多個請求/回複迴圈重用一個串連。一旦串連分配給一個特定的請求,在請求處理迴圈結束之前不會在分配。換句話說,在串連上,請求不是多元的。這個是串連兩端的編碼變得容易,雖然這導致在一時刻會有很多串連。 一旦WEB伺服器開啟了一個到SERVLET容器的串連,串連處於空閑狀態或已指派狀態 一旦一個串連被分配給一個特定的請求,在串連上發送的基本請求資訊是高度壓縮的。在這點,SERVLET容器大概準備開始處理請求,當它處理的時候,它能發回下面的資訊給WEB伺服器:(1)SEND_HEADERS、(2)SEND_BODY_CHUNK、(3)GET_BODY_CHUNK、(4)END_RESPONSE ajp協議的設計 http://httpd.apache.org/docs/2.2/mod/mod_proxy_ajp.html

Apache JServ Protocol (AJP)

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.