You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by ma...@apache.org on 2020/12/01 10:27:44 UTC
[tomcat] branch master updated: Deprecate the APR/Native AJP and
HTTP connectors
This is an automated email from the ASF dual-hosted git repository.
markt pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/tomcat.git
The following commit(s) were added to refs/heads/master by this push:
new 72323cb Deprecate the APR/Native AJP and HTTP connectors
72323cb is described below
commit 72323cb76307698b66b0253a34bfbb4a9ea034fe
Author: Mark Thomas <ma...@apache.org>
AuthorDate: Tue Dec 1 10:27:16 2020 +0000
Deprecate the APR/Native AJP and HTTP connectors
Removal is planned for 10.1.x
---
conf/server.xml | 23 ++--------------------
java/org/apache/coyote/ajp/AjpAprProtocol.java | 4 ++++
.../apache/coyote/http11/Http11AprProtocol.java | 4 ++++
java/org/apache/tomcat/util/net/AprEndpoint.java | 4 ++++
java/org/apache/tomcat/util/net/AprSSLSupport.java | 4 ++++
webapps/docs/aio.xml | 5 ++---
webapps/docs/apr.xml | 3 +++
webapps/docs/changelog.xml | 4 ++++
webapps/docs/config/ajp.xml | 10 ++++++++--
webapps/docs/config/http.xml | 10 ++++++++--
webapps/docs/index.xml | 3 +--
webapps/docs/ssl-howto.xml | 12 +++++------
12 files changed, 50 insertions(+), 36 deletions(-)
diff --git a/conf/server.xml b/conf/server.xml
index 91bd415..dd4a73b 100644
--- a/conf/server.xml
+++ b/conf/server.xml
@@ -61,9 +61,8 @@
<!-- A "Connector" represents an endpoint by which requests are received
and responses are returned. Documentation at :
- Java HTTP Connector: /docs/config/http.html
- Java AJP Connector: /docs/config/ajp.html
- APR (HTTP/AJP) Connector: /docs/apr.html
+ HTTP Connector: /docs/config/http.html
+ AJP Connector: /docs/config/ajp.html
Define a non-SSL/TLS HTTP/1.1 Connector on port 8080
-->
<Connector port="8080" protocol="HTTP/1.1"
@@ -93,24 +92,6 @@
</SSLHostConfig>
</Connector>
-->
- <!-- Define an SSL/TLS HTTP/1.1 Connector on port 8443 with HTTP/2
- This connector uses the APR/native implementation which always uses
- OpenSSL for TLS.
- Either JSSE or OpenSSL style configuration may be used. OpenSSL style
- configuration is used below.
- -->
- <!--
- <Connector port="8443" protocol="org.apache.coyote.http11.Http11AprProtocol"
- maxThreads="150" SSLEnabled="true" >
- <UpgradeProtocol className="org.apache.coyote.http2.Http2Protocol" />
- <SSLHostConfig>
- <Certificate certificateKeyFile="conf/localhost-rsa-key.pem"
- certificateFile="conf/localhost-rsa-cert.pem"
- certificateChainFile="conf/localhost-rsa-chain.pem"
- type="RSA" />
- </SSLHostConfig>
- </Connector>
- -->
<!-- Define an AJP 1.3 Connector on port 8009 -->
<!--
diff --git a/java/org/apache/coyote/ajp/AjpAprProtocol.java b/java/org/apache/coyote/ajp/AjpAprProtocol.java
index 92ad9c0..34e34eb 100644
--- a/java/org/apache/coyote/ajp/AjpAprProtocol.java
+++ b/java/org/apache/coyote/ajp/AjpAprProtocol.java
@@ -23,7 +23,11 @@ import org.apache.tomcat.util.net.AprEndpoint;
/**
* This the APR/native based protocol handler implementation for AJP.
+ *
+ * @deprecated The APR/Native Connector will be removed in Tomcat 10.1.x
+ * onwards.
*/
+@Deprecated
public class AjpAprProtocol extends AbstractAjpProtocol<Long> {
private static final Log log = LogFactory.getLog(AjpAprProtocol.class);
diff --git a/java/org/apache/coyote/http11/Http11AprProtocol.java b/java/org/apache/coyote/http11/Http11AprProtocol.java
index 0311fb4..b3e681d 100644
--- a/java/org/apache/coyote/http11/Http11AprProtocol.java
+++ b/java/org/apache/coyote/http11/Http11AprProtocol.java
@@ -28,7 +28,11 @@ import org.apache.tomcat.util.net.AprEndpoint;
*
* @author Remy Maucherat
* @author Costin Manolache
+ *
+ * @deprecated The APR/Native Connector will be removed in Tomcat 10.1.x
+ * onwards.
*/
+@Deprecated
public class Http11AprProtocol extends AbstractHttp11Protocol<Long> {
private static final Log log = LogFactory.getLog(Http11AprProtocol.class);
diff --git a/java/org/apache/tomcat/util/net/AprEndpoint.java b/java/org/apache/tomcat/util/net/AprEndpoint.java
index 4ba3420..67381dd 100644
--- a/java/org/apache/tomcat/util/net/AprEndpoint.java
+++ b/java/org/apache/tomcat/util/net/AprEndpoint.java
@@ -76,7 +76,11 @@ import org.apache.tomcat.util.net.openssl.OpenSSLUtil;
*
* @author Mladen Turk
* @author Remy Maucherat
+ *
+ * @deprecated The APR/Native Connector will be removed in Tomcat 10.1.x
+ * onwards.
*/
+@Deprecated
public class AprEndpoint extends AbstractEndpoint<Long,Long> implements SNICallBack {
// -------------------------------------------------------------- Constants
diff --git a/java/org/apache/tomcat/util/net/AprSSLSupport.java b/java/org/apache/tomcat/util/net/AprSSLSupport.java
index 8f9be75..0e261b1 100644
--- a/java/org/apache/tomcat/util/net/AprSSLSupport.java
+++ b/java/org/apache/tomcat/util/net/AprSSLSupport.java
@@ -28,7 +28,11 @@ import org.apache.tomcat.jni.SSL;
* <p>
* TODO: Add a mechanism (or figure out how to use what we already have) to
* invalidate the session.
+ *
+ * @deprecated The APR/Native Connector will be removed in Tomcat 10.1.x
+ * onwards.
*/
+@Deprecated
public class AprSSLSupport implements SSLSupport {
private final AprEndpoint.AprSocketWrapper socketWrapper;
diff --git a/webapps/docs/aio.xml b/webapps/docs/aio.xml
index 3ea4836..291a7f7 100644
--- a/webapps/docs/aio.xml
+++ b/webapps/docs/aio.xml
@@ -45,9 +45,8 @@
<section name="Asynchronous writes">
<p>
- When using HTTP connectors (based on APR or NIO/NIO2),
- Tomcat supports using sendfile to send large static files.
- These writes, as soon as the system load increases, will be performed
+ When using HTTP connectors Tomcat supports using sendfile to send large
+ static files. These writes, as soon as the system load increases, will be performed
asynchronously in the most efficient way. Instead of sending a large response using
blocking writes, it is possible to write content to a static file, and write it
using a sendfile code. A caching valve could take advantage of this to cache the
diff --git a/webapps/docs/apr.xml b/webapps/docs/apr.xml
index b176402..21b2006 100644
--- a/webapps/docs/apr.xml
+++ b/webapps/docs/apr.xml
@@ -136,6 +136,9 @@
<section name="APR Connectors Configuration">
+ <p><strong>Note: The APR/Native AJP and HTTP Connectors are deprecated and
+ will be removed in Tomcat 10.1.x onwards.</strong></p>
+
<subsection name="HTTP/HTTPS">
<p>For HTTP configuration, see the <a href="config/http.html">HTTP</a>
diff --git a/webapps/docs/changelog.xml b/webapps/docs/changelog.xml
index c2f1404..7bfb427 100644
--- a/webapps/docs/changelog.xml
+++ b/webapps/docs/changelog.xml
@@ -136,6 +136,10 @@
</subsection>
<subsection name="Coyote">
<changelog>
+ <update>
+ The APR/Native Connectors for both HTTP and AJP have been deprecated and
+ will be removed in Apache Tomcat 10.1.x onwards. (markt)
+ </update>
<fix>
<bug>64944</bug>: Ensure that the bytesSent metric is correctly updated
when compression is enabled. (markt)
diff --git a/webapps/docs/config/ajp.xml b/webapps/docs/config/ajp.xml
index cd7a8ad..2d9aec8 100644
--- a/webapps/docs/config/ajp.xml
+++ b/webapps/docs/config/ajp.xml
@@ -36,6 +36,9 @@
<section name="Introduction">
+ <p><strong>Note: The APR/Native AJP Connector is deprecated and will be
+ removed in Tomcat 10.1.x onwards.</strong></p>
+
<p>The <strong>AJP Connector</strong> element represents a
<strong>Connector</strong> component that communicates with a web
connector via the <code>AJP</code> protocol. This is used for cases
@@ -200,7 +203,7 @@
<code>org.apache.coyote.ajp.AjpNio2Protocol</code>
- non blocking Java NIO2 connector.<br/>
<code>org.apache.coyote.ajp.AjpAprProtocol</code>
- - the APR/native connector.<br/>
+ - the APR/native connector (deprecated - will be removed in 10.1.x).<br/>
Custom implementations may also be used.<br/>
Take a look at our <a href="#Connector_Comparison">Connector
Comparison</a> chart.
@@ -793,6 +796,9 @@
<subsection name="APR/native specific configuration">
+ <p><strong>Note: The APR/Native AJP Connector is deprecated and will be
+ removed in Tomcat 10.1.x onwards.</strong></p>
+
<p>The APR/native implementation supports the following attributes in
addition to the common Connector and AJP attributes listed above.</p>
@@ -853,7 +859,7 @@
<th />
<th style="text-align: center;">Java Nio Connector<br />NIO</th>
<th style="text-align: center;">Java Nio2 Connector<br />NIO2</th>
- <th style="text-align: center;">APR/native Connector<br />APR</th>
+ <th style="text-align: center;">APR/native Connector<br />APR<br />(deprecated)</th>
</tr>
<tr>
<th>Classname</th>
diff --git a/webapps/docs/config/http.xml b/webapps/docs/config/http.xml
index 33cdecc..ae5fd8a 100644
--- a/webapps/docs/config/http.xml
+++ b/webapps/docs/config/http.xml
@@ -36,6 +36,9 @@
<section name="Introduction">
+ <p><strong>Note: The APR/Native HTTP Connector is deprecated and will be
+ removed in Tomcat 10.1.x onwards.</strong></p>
+
<p>The <strong>HTTP Connector</strong> element represents a
<strong>Connector</strong> component that supports the HTTP/1.1 protocol.
It enables Catalina to function as a stand-alone web server, in addition
@@ -227,7 +230,7 @@
<code>org.apache.coyote.http11.Http11Nio2Protocol</code> -
non blocking Java NIO2 connector<br/>
<code>org.apache.coyote.http11.Http11AprProtocol</code> -
- the APR/native connector.<br/>
+ the APR/native connector (deprecated - will be removed in 10.1.x).<br/>
Custom implementations may also be used.<br/>
Take a look at our <a href="#Connector_Comparison">Connector
Comparison</a> chart. The configuration for both Java connectors is
@@ -984,6 +987,9 @@
<subsection name="APR/native specific configuration">
+ <p><strong>Note: The APR/Native HTTP Connector is deprecated and will be
+ removed in Tomcat 10.1.x onwards.</strong></p>
+
<p>The following attributes are specific to the APR/native connector.</p>
<attributes>
@@ -1624,7 +1630,7 @@
<th />
<th style="text-align: center;">Java Nio Connector<br />NIO</th>
<th style="text-align: center;">Java Nio2 Connector<br />NIO2</th>
- <th style="text-align: center;">APR/native Connector<br />APR</th>
+ <th style="text-align: center;">APR/native Connector<br />APR<br />(deprecated)</th>
</tr>
<tr>
<th>Classname</th>
diff --git a/webapps/docs/index.xml b/webapps/docs/index.xml
index 7990281..aa07fc0 100644
--- a/webapps/docs/index.xml
+++ b/webapps/docs/index.xml
@@ -119,8 +119,7 @@ Apache Tomcat, and using many of the Apache Tomcat features.</p>
<li><a href="logging.html"><strong>Logging</strong></a> -
Configuring logging in Apache Tomcat.</li>
<li><a href="apr.html"><strong>Apache Portable Runtime</strong></a> -
- Using APR to provide superior performance, scalability and better
- integration with native server technologies.</li>
+ Using APR to provide access to OpenSSL for TLS support.</li>
<li><a href="virtual-hosting-howto.html"><strong>Virtual Hosting</strong></a> -
Configuring virtual hosting in Apache Tomcat.</li>
<li><a href="aio.html"><strong>Advanced IO</strong></a> -
diff --git a/webapps/docs/ssl-howto.xml b/webapps/docs/ssl-howto.xml
index 65708b4..0d50cd9 100644
--- a/webapps/docs/ssl-howto.xml
+++ b/webapps/docs/ssl-howto.xml
@@ -115,10 +115,10 @@ for your version of Java for details on protocol and algorithm support.</p>
the <a href="https://www.openssl.org/">OpenSSL</a> cryptographic provider
through JCA/JCE/JSSE which may provide a different selection of cryptographic
algorithms and/or performance benefits relative to the SunJCE provider.
-You can also use <code>tcnative</code> to enable the <a href="apr.html">APR</a>
-connector which uses OpenSSL for its cryptographic operations. Check the
-documentation for your version of OpenSSL for details on protocol and
-algorithm support.</p>
+You can also use <code>tcnative</code> to enable the deprecated
+<a href="apr.html">APR</a> connector which uses OpenSSL for its
+cryptographic operations. Check the documentation for your version of OpenSSL
+for details on protocol and algorithm support.</p>
</section>
@@ -259,7 +259,7 @@ Tomcat can use three different implementations of SSL:
<ul>
<li>JSSE implementation provided as part of the Java runtime</li>
<li>JSSE implementation that uses OpenSSL</li>
-<li>APR implementation, which uses the OpenSSL engine by default</li>
+<li>APR implementation (deprecated), which uses the OpenSSL engine by default</li>
</ul>
<p>
The exact configuration details depend on which implementation is being used.
@@ -298,7 +298,7 @@ both types in the same SSLHostConfig or Connector element.</p>
sslImplementationName="org.apache.tomcat.util.net.openssl.OpenSSLImplementation"
.../>]]></source>
-<p>Alternatively, to specify an APR connector (the APR library must be available) use:</p>
+<p>Alternatively, to specify a deprecated APR connector (the APR library must be available) use:</p>
<source><![CDATA[<!-- Define an HTTP/1.1 Connector on port 8443, APR implementation -->
<Connector protocol="org.apache.coyote.http11.Http11AprProtocol"
port="8443" .../>]]></source>
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org