Return-Path: X-Original-To: apmail-tomcat-users-archive@www.apache.org Delivered-To: apmail-tomcat-users-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 8D3FDFB8C for ; Tue, 9 Apr 2013 16:21:29 +0000 (UTC) Received: (qmail 2621 invoked by uid 500); 9 Apr 2013 16:21:26 -0000 Delivered-To: apmail-tomcat-users-archive@tomcat.apache.org Received: (qmail 2559 invoked by uid 500); 9 Apr 2013 16:21:25 -0000 Mailing-List: contact users-help@tomcat.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: "Tomcat Users List" Delivered-To: mailing list users@tomcat.apache.org Received: (qmail 2547 invoked by uid 99); 9 Apr 2013 16:21:25 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 09 Apr 2013 16:21:25 +0000 X-ASF-Spam-Status: No, hits=-0.0 required=5.0 tests=SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of aw@ice-sa.com designates 212.85.38.228 as permitted sender) Received: from [212.85.38.228] (HELO tor.combios.es) (212.85.38.228) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 09 Apr 2013 16:21:19 +0000 Received: from [192.168.245.129] (p549E8F4F.dip0.t-ipconnect.de [84.158.143.79]) (Authenticated sender: andre.warnier@ice-sa.com) by tor.combios.es (Postfix) with ESMTPA id ABFB33C26F1 for ; Tue, 9 Apr 2013 18:21:23 +0200 (CEST) Message-ID: <51643FE7.6040009@ice-sa.com> Date: Tue, 09 Apr 2013 18:20:55 +0200 From: =?ISO-8859-1?Q?Andr=E9_Warnier?= Reply-To: Tomcat Users List User-Agent: Thunderbird 2.0.0.23 (Windows/20090812) MIME-Version: 1.0 To: Tomcat Users List Subject: Re: connectors - what are JK, AJP, APR References: In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked by ClamAV on apache.org Oh my.. Jakub 1983 wrote: > ) > http://tomcat.apache.org/tomcat-7.0-doc/config/ajp.html states: > > The *AJP Connector* element represents a *Connector* component that > communicates with a web connector via the AJP protocol. This is used for > cases where you wish to invisibly integrate Tomcat into an existing (or > new) Apache installation, and you want Apache to handle the static content > contained in the web application, and/or utilize Apache's SSL processing. > > This connector supports load balancing when used in conjunction with the > jvmRoute attribute of the > Engine > . > > The *native connectors* supported with this Tomcat release are: > > - JK 1.2.x with any of the supported servers. See the JK > docsfor details. > - mod_proxy on Apache httpd 2.x (included by default in Apache HTTP > Server 2.2), with AJP enabled: see the httpd > docsfor > details. > > *Other native connectors supporting AJP may work, but are no longer > supported.* > > > 1) what does it mean in some other words ?? > 2) what does "native conntectors" mean here ? > 3) what is JK ? and what is mod_proxy ? are both of them some alternative > implementations of ajp ? who uses them, tomcat or apache http*d* web server > ? > > 4) pieces of server.xml > > connectionTimeout="20000" > redirectPort="443" /> > > > > > 5) how should I define JK connector ? > 6) what JK has to do with AJP ? > 7) which terms concern tomcat and which apache httpd server ? > > 8) where is *APR* in above context ? > 9) how do I define APR connector (is it possible)? > > > 10) > http://tomcat.apache.org/tomcat-7.0-doc/apr.html#APR_Connectors_Configurationstates: > > *AJP* > > For AJP configuration, see the > AJPconnector > configuration documentation. > > it redirects to > http://tomcat.apache.org/tomcat-7.0-doc/config/ajp.htmlwhich states > nothing about apr, > so what is apr ? > > 11 how can it be put simple in several words ? > The simple answer is that it cannot, there would be too many words anyway. But the good thing is that a lot of it is already described on-line. Do you know Wikipedia ? For APR : http://en.wikipedia.org/wiki/Apache_Portable_Runtime For AJP : http://en.wikipedia.org/wiki/Apache_JServ_Protocol When you connect to a server program (like Apache httpd or Apache Tomcat), you connect to a TCP listening port (http://en.wikipedia.org/wiki/TCP_port). In Tomcat, such a listening port is created and opened by a specific part of the Tomcat code, known as a "connector". Some such "connectors" are written purely in Java code, so they are totally portable to any machine that runs a Java Virtual Machine (JVM, see here : http://en.wikipedia.org/wiki/Java_virtual_machine). Others are written so that they use a part that is not written in Java, but is specific to the particular OS under which you run Tomcat (for OS, see http://en.wikipedia.org/wiki/Operating_system). These are called "native", because they use "native code" (code that works only under one OS). AJP is a communications protocol (like HTTP or Telnet or FTP). It is different from HTTP, but it can carry the same kind of information as HTTP (HTTP requests, headers, body,..). It is the protocol used in some cases when you "connect" a front-end httpd server (like Apache httpd or Microsoft IIS) with a back-end Tomcat server. For example, when you connect Apache httpd to Tomcat, you have this kind of setup : Browser <-HTTP-> Apache httpd + mod_jk <--AJP--> Tomcat AJP Connector + Tomcat So, on the Apache httpd side, you have the mod_jk module, which knows the AJP protocol, and which translates the browser request into "AJP language" to pass it to Tomcat. And on the Tomcat side, you have an AJP Connector, which also understands the "AJP language" and translates the request from AJP to something that Tomcat understands. You can also connect Apache httpd to Tomcat in a different way, using this setup : Browser <-HTTP-> Apache httpd + mod_proxy <--HTTP--> Tomcat HTTP Connector + Tomcat mod_proxy does not understand AJP, it only understands and talks HTTP. So on the Tomcat side, you also need a Connector that understands HTTP, not AJP. Sometimes one way is better, sometimes the other. It is your choice. Does this help ? --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org For additional commands, e-mail: users-help@tomcat.apache.org