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/01/15 09:36:36 UTC

[tomcat] branch master updated (46fbf32 -> 01717bb)

This is an automated email from the ASF dual-hosted git repository.

markt pushed a change to branch master
in repository https://gitbox.apache.org/repos/asf/tomcat.git.


    from 46fbf32  Remove the deprecated JmxRemoteLifecycleListener
     new d9b030c  Delete some deprecated code planned for removal in Tomcat 10
     new 01717bb  Delete some deprecated code planned for removal in Tomcat 10

The 2 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


Summary of changes:
 java/org/apache/catalina/realm/JNDIRealm.java      |  1 -
 java/org/apache/catalina/realm/RealmBase.java      | 22 ----------
 java/org/apache/coyote/http11/Constants.java       | 15 -------
 java/org/apache/jasper/JspC.java                   | 24 -----------
 java/org/apache/tomcat/jni/OS.java                 |  7 ----
 java/org/apache/tomcat/util/buf/ByteChunk.java     | 47 ---------------------
 java/org/apache/tomcat/util/buf/CharChunk.java     | 30 -------------
 java/org/apache/tomcat/util/compat/TLS.java        | 49 ----------------------
 .../tomcat/util/http/FastHttpDateFormat.java       | 40 ------------------
 .../apache/tomcat/util/net/AbstractEndpoint.java   | 31 --------------
 10 files changed, 266 deletions(-)
 delete mode 100644 java/org/apache/tomcat/util/compat/TLS.java


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


[tomcat] 02/02: Delete some deprecated code planned for removal in Tomcat 10

Posted by ma...@apache.org.
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

commit 01717bb1fa872208c63ca9757567bb2ee5dc2fb2
Author: Mark Thomas <ma...@apache.org>
AuthorDate: Wed Jan 15 09:35:05 2020 +0000

    Delete some deprecated code planned for removal in Tomcat 10
---
 java/org/apache/coyote/http11/Constants.java       | 15 -------
 java/org/apache/jasper/JspC.java                   | 24 -----------
 java/org/apache/tomcat/jni/OS.java                 |  7 ----
 java/org/apache/tomcat/util/buf/ByteChunk.java     | 47 ---------------------
 java/org/apache/tomcat/util/buf/CharChunk.java     | 30 -------------
 java/org/apache/tomcat/util/compat/TLS.java        | 49 ----------------------
 .../tomcat/util/http/FastHttpDateFormat.java       | 40 ------------------
 .../apache/tomcat/util/net/AbstractEndpoint.java   | 31 --------------
 8 files changed, 243 deletions(-)

diff --git a/java/org/apache/coyote/http11/Constants.java b/java/org/apache/coyote/http11/Constants.java
index 7c8bff2..700834c 100644
--- a/java/org/apache/coyote/http11/Constants.java
+++ b/java/org/apache/coyote/http11/Constants.java
@@ -103,22 +103,7 @@ public final class Constants {
     /* Various constant "strings" */
     public static final String CONNECTION = "Connection";
     public static final String CLOSE = "close";
-    /**
-     * @deprecated Unused. Will be removed in Tomcat 10.
-     */
-    @Deprecated
-    public static final byte[] CLOSE_BYTES = ByteChunk.convertToBytes(CLOSE);
-    /**
-     * @deprecated Unused. Will be removed in Tomcat 10.
-     */
-    @Deprecated
-    public static final String KEEPALIVE = "keep-alive";
     public static final String KEEP_ALIVE_HEADER_VALUE_TOKEN = "keep-alive";
-    /**
-     * @deprecated Unused. Will be removed in Tomcat 10.
-     */
-    @Deprecated
-    public static final byte[] KEEPALIVE_BYTES = ByteChunk.convertToBytes(KEEPALIVE);
     public static final String CHUNKED = "chunked";
     public static final byte[] ACK_BYTES = ByteChunk.convertToBytes("HTTP/1.1 100 " + CRLF + CRLF);
     public static final String TRANSFERENCODING = "Transfer-Encoding";
diff --git a/java/org/apache/jasper/JspC.java b/java/org/apache/jasper/JspC.java
index 6bbb1b3..c973f29 100644
--- a/java/org/apache/jasper/JspC.java
+++ b/java/org/apache/jasper/JspC.java
@@ -1036,18 +1036,6 @@ public class JspC extends Task implements Options {
     }
 
     /**
-     * File where we generate a web.xml fragment with the class definitions.
-     * @param s New value
-     * @deprecated Will be removed in Tomcat 10.
-     *             Use {@link #setWebXmlInclude(String)}
-     */
-    @Deprecated
-    public void setWebXmlFragment( String s ) {
-        webxmlFile=resolveFile(s).getAbsolutePath();
-        webxmlLevel=INC_WEBXML;
-    }
-
-    /**
      * File where we generate configuration with the class definitions to be
      * included in a web.xml file.
      * @param s New value
@@ -1393,18 +1381,6 @@ public class JspC extends Task implements Options {
         }
     }
 
-    /**
-     * Locate all jsp files in the webapp. Used if no explicit
-     * jsps are specified.
-     * @param base Base path
-     *
-     * @deprecated This will be removed in Tomcat 10. Use {@link #scanFiles()}
-     */
-    @Deprecated
-    public void scanFiles(File base) {
-        scanFiles();
-    }
-
 
     /**
      * Locate all jsp files in the webapp. Used if no explicit jsps are
diff --git a/java/org/apache/tomcat/jni/OS.java b/java/org/apache/tomcat/jni/OS.java
index 6796f23..c93a07b 100644
--- a/java/org/apache/tomcat/jni/OS.java
+++ b/java/org/apache/tomcat/jni/OS.java
@@ -46,13 +46,6 @@ public class OS {
     private static native boolean is(int type);
 
     public static final boolean IS_UNIX    = is(UNIX);
-    /**
-     * @deprecated Hard-coded to false since there has not been a supported
-     *             Netware platform for many years.
-     *             This will be removed in Tomcat 10 onwards
-     */
-    @Deprecated
-    public static final boolean IS_NETWARE = false;
     public static final boolean IS_WIN32   = is(WIN32);
     public static final boolean IS_WIN64   = is(WIN64);
     public static final boolean IS_LINUX   = is(LINUX);
diff --git a/java/org/apache/tomcat/util/buf/ByteChunk.java b/java/org/apache/tomcat/util/buf/ByteChunk.java
index da188ad..aa268ef 100644
--- a/java/org/apache/tomcat/util/buf/ByteChunk.java
+++ b/java/org/apache/tomcat/util/buf/ByteChunk.java
@@ -389,15 +389,6 @@ public final class ByteChunk extends AbstractChunk {
 
     // -------------------- Removing data from the buffer --------------------
 
-    /*
-     * @deprecated Use {@link #subtract()}.
-     *             This method will be removed in Tomcat 10
-     */
-    @Deprecated
-    public int substract() throws IOException {
-        return subtract();
-    }
-
     public int subtract() throws IOException {
         if (checkEof()) {
             return -1;
@@ -405,15 +396,6 @@ public final class ByteChunk extends AbstractChunk {
         return buff[start++] & 0xFF;
     }
 
-    /*
-     * @deprecated Use {@link #subtractB()}.
-     *             This method will be removed in Tomcat 10
-     */
-    @Deprecated
-    public byte substractB() throws IOException {
-        return subtractB();
-    }
-
     public byte subtractB() throws IOException {
         if (checkEof()) {
             return -1;
@@ -422,15 +404,6 @@ public final class ByteChunk extends AbstractChunk {
     }
 
 
-    /*
-     * @deprecated Use {@link #subtract(byte[],int,int)}.
-     *             This method will be removed in Tomcat 10
-     */
-    @Deprecated
-    public int substract(byte dest[], int off, int len) throws IOException {
-        return subtract(dest, off, len);
-    }
-
     public int subtract(byte dest[], int off, int len) throws IOException {
         if (checkEof()) {
             return -1;
@@ -455,26 +428,6 @@ public final class ByteChunk extends AbstractChunk {
      * @return an integer specifying the actual number of bytes read, or -1 if
      *         the end of the stream is reached
      * @throws IOException if an input or output exception has occurred
-     *
-     * @deprecated Use {@link #subtract(ByteBuffer)}.
-     *             This method will be removed in Tomcat 10
-     */
-    @Deprecated
-    public int substract(ByteBuffer to) throws IOException {
-        return subtract(to);
-    }
-
-
-    /**
-     * Transfers bytes from the buffer to the specified ByteBuffer. After the
-     * operation the position of the ByteBuffer will be returned to the one
-     * before the operation, the limit will be the position incremented by the
-     * number of the transfered bytes.
-     *
-     * @param to the ByteBuffer into which bytes are to be written.
-     * @return an integer specifying the actual number of bytes read, or -1 if
-     *         the end of the stream is reached
-     * @throws IOException if an input or output exception has occurred
      */
     public int subtract(ByteBuffer to) throws IOException {
         if (checkEof()) {
diff --git a/java/org/apache/tomcat/util/buf/CharChunk.java b/java/org/apache/tomcat/util/buf/CharChunk.java
index 70818df..51fa204 100644
--- a/java/org/apache/tomcat/util/buf/CharChunk.java
+++ b/java/org/apache/tomcat/util/buf/CharChunk.java
@@ -290,15 +290,6 @@ public final class CharChunk extends AbstractChunk implements CharSequence {
 
     // -------------------- Removing data from the buffer --------------------
 
-    /*
-     * @deprecated Use {@link #subtract()}.
-     *             This method will be removed in Tomcat 10
-     */
-    @Deprecated
-    public int substract() throws IOException {
-        return subtract();
-    }
-
     public int subtract() throws IOException {
         if (checkEof()) {
             return -1;
@@ -307,15 +298,6 @@ public final class CharChunk extends AbstractChunk implements CharSequence {
     }
 
 
-    /*
-     * @deprecated Use {@link #subtract(char[],int,int)}.
-     *             This method will be removed in Tomcat 10
-     */
-    @Deprecated
-    public int substract(char dest[], int off, int len) throws IOException {
-        return subtract(dest, off, len);
-    }
-
     public int subtract(char dest[], int off, int len) throws IOException {
         if (checkEof()) {
             return -1;
@@ -666,16 +648,4 @@ public final class CharChunk extends AbstractChunk implements CharSequence {
     public int length() {
         return end - start;
     }
-
-    /**
-     * NO-OP.
-     *
-     * @param optimizedWrite Ignored
-     *
-     * @deprecated Unused code. This is now a NO-OP and will be removed without
-     *             replacement in Tomcat 10.
-     */
-    @Deprecated
-    public void setOptimizedWrite(boolean optimizedWrite) {
-    }
 }
diff --git a/java/org/apache/tomcat/util/compat/TLS.java b/java/org/apache/tomcat/util/compat/TLS.java
deleted file mode 100644
index 53c1c44..0000000
--- a/java/org/apache/tomcat/util/compat/TLS.java
+++ /dev/null
@@ -1,49 +0,0 @@
-/*
- *  Licensed to the Apache Software Foundation (ASF) under one or more
- *  contributor license agreements.  See the NOTICE file distributed with
- *  this work for additional information regarding copyright ownership.
- *  The ASF licenses this file to You under the Apache License, Version 2.0
- *  (the "License"); you may not use this file except in compliance with
- *  the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- *  Unless required by applicable law or agreed to in writing, software
- *  distributed under the License is distributed on an "AS IS" BASIS,
- *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- *  See the License for the specific language governing permissions and
- *  limitations under the License.
- */
-package org.apache.tomcat.util.compat;
-
-import java.security.NoSuchAlgorithmException;
-
-import javax.net.ssl.SSLContext;
-
-import org.apache.tomcat.util.net.Constants;
-
-/**
- * This class checks for the availability of TLS features.
- *
- * @deprecated Unused. This will be removed in Tomcat 10.
- */
-@Deprecated
-public class TLS {
-
-    private static final boolean tlsv13Available;
-
-    static {
-        boolean ok = false;
-        try {
-            SSLContext.getInstance(Constants.SSL_PROTO_TLSv1_3);
-            ok = true;
-        } catch (NoSuchAlgorithmException ex) {
-        }
-        tlsv13Available = ok;
-    }
-
-    public static boolean isTlsv13Available() {
-        return tlsv13Available;
-    }
-
-}
diff --git a/java/org/apache/tomcat/util/http/FastHttpDateFormat.java b/java/org/apache/tomcat/util/http/FastHttpDateFormat.java
index a546ee6..f052474 100644
--- a/java/org/apache/tomcat/util/http/FastHttpDateFormat.java
+++ b/java/org/apache/tomcat/util/http/FastHttpDateFormat.java
@@ -16,7 +16,6 @@
  */
 package org.apache.tomcat.util.http;
 
-import java.text.DateFormat;
 import java.text.ParseException;
 import java.util.Date;
 import java.util.Locale;
@@ -39,14 +38,6 @@ public final class FastHttpDateFormat {
         Integer.parseInt(System.getProperty("org.apache.tomcat.util.http.FastHttpDateFormat.CACHE_SIZE", "1000"));
 
 
-    /**
-     * The only date format permitted when generating HTTP headers.
-     *
-     * @deprecated Unused. This will be removed in Tomcat 10.
-     */
-    @Deprecated
-    public static final String RFC1123_DATE = "EEE, dd MMM yyyy HH:mm:ss zzz";
-
     // HTTP date formats
     private static final String DATE_RFC5322 = "EEE, dd MMM yyyy HH:mm:ss z";
     private static final String DATE_OBSOLETE_RFC850 = "EEEEEE, dd-MMM-yy HH:mm:ss zzz";
@@ -114,21 +105,6 @@ public final class FastHttpDateFormat {
     /**
      * Get the HTTP format of the specified date.
      * @param value The date
-     * @param threadLocalformat Ignored. The local ConcurrentDateFormat will
-     *                          always be used.
-     * @return the HTTP date
-     *
-     * @deprecated Unused. This will be removed in Tomcat 10
-     */
-    @Deprecated
-    public static final String formatDate(long value, DateFormat threadLocalformat) {
-        return formatDate(value);
-    }
-
-
-    /**
-     * Get the HTTP format of the specified date.
-     * @param value The date
      * @return the HTTP date
      */
     public static final String formatDate(long value) {
@@ -147,22 +123,6 @@ public final class FastHttpDateFormat {
     /**
      * Try to parse the given date as an HTTP date.
      * @param value The HTTP date
-     * @param threadLocalformats Ignored. The local array of
-     *                           ConcurrentDateFormat will always be used.
-     * @return the date as a long
-     *
-     * @deprecated Unused. This will be removed in Tomcat 10
-     *             Use {@link #parseDate(String)}
-     */
-    @Deprecated
-    public static final long parseDate(String value, DateFormat[] threadLocalformats) {
-        return parseDate(value);
-    }
-
-
-    /**
-     * Try to parse the given date as an HTTP date.
-     * @param value The HTTP date
      * @return the date as a long or <code>-1</code> if the value cannot be
      *         parsed
      */
diff --git a/java/org/apache/tomcat/util/net/AbstractEndpoint.java b/java/org/apache/tomcat/util/net/AbstractEndpoint.java
index db9fa70..2a60011 100644
--- a/java/org/apache/tomcat/util/net/AbstractEndpoint.java
+++ b/java/org/apache/tomcat/util/net/AbstractEndpoint.java
@@ -101,17 +101,6 @@ public abstract class AbstractEndpoint<S,U> {
 
 
         /**
-         * Obtain the currently open sockets.
-         *
-         * @return The sockets for which the handler is tracking a currently
-         *         open connection
-         * @deprecated Unused, will be removed in Tomcat 10, replaced
-         *         by AbstractEndpoint.getConnections
-         */
-        @Deprecated
-        public Set<S> getOpenSockets();
-
-        /**
          * Release any resources associated with the given SocketWrapper.
          *
          * @param socketWrapper The socketWrapper to release resources for
@@ -424,26 +413,6 @@ public abstract class AbstractEndpoint<S,U> {
      */
     protected int acceptorThreadCount = 1;
 
-    /**
-     * NO-OP.
-     *
-     * @param acceptorThreadCount Unused
-     *
-     * @deprecated Will be removed in Tomcat 10.
-     */
-    @Deprecated
-    public void setAcceptorThreadCount(int acceptorThreadCount) {}
-
-    /**
-     * Always returns 1.
-     *
-     * @return Always 1.
-     *
-     * @deprecated Will be removed in Tomcat 10.
-     */
-    @Deprecated
-    public int getAcceptorThreadCount() { return 1; }
-
 
     /**
      * Priority of the acceptor threads.


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


[tomcat] 01/02: Delete some deprecated code planned for removal in Tomcat 10

Posted by ma...@apache.org.
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

commit d9b030cfb24555169c49da3306110f8f21d5cc23
Author: Mark Thomas <ma...@apache.org>
AuthorDate: Wed Jan 15 09:29:43 2020 +0000

    Delete some deprecated code planned for removal in Tomcat 10
---
 java/org/apache/catalina/realm/JNDIRealm.java |  1 -
 java/org/apache/catalina/realm/RealmBase.java | 22 ----------------------
 2 files changed, 23 deletions(-)

diff --git a/java/org/apache/catalina/realm/JNDIRealm.java b/java/org/apache/catalina/realm/JNDIRealm.java
index 375edc7..b814b00 100644
--- a/java/org/apache/catalina/realm/JNDIRealm.java
+++ b/java/org/apache/catalina/realm/JNDIRealm.java
@@ -2261,7 +2261,6 @@ public class JNDIRealm extends RealmBase {
         return getPrincipal(name, gssCredential);
     }
 
-    @Override
     protected Principal getPrincipal(String username,
             GSSCredential gssCredential) {
 
diff --git a/java/org/apache/catalina/realm/RealmBase.java b/java/org/apache/catalina/realm/RealmBase.java
index d9917cf..7d3464b 100644
--- a/java/org/apache/catalina/realm/RealmBase.java
+++ b/java/org/apache/catalina/realm/RealmBase.java
@@ -1224,28 +1224,6 @@ public abstract class RealmBase extends LifecycleMBeanBase implements Realm {
 
 
     /**
-     * Get the principal associated with the specified user name.
-     *
-     * @param username The user name
-     * @param gssCredential the GSS credential of the principal
-     * @return the principal associated with the given user name.
-     * @deprecated This will be removed in Tomcat 10 onwards. Use
-     *             {@link #getPrincipal(GSSName, GSSCredential)} instead.
-     */
-    @Deprecated
-    protected Principal getPrincipal(String username,
-            GSSCredential gssCredential) {
-        Principal p = getPrincipal(username);
-
-        if (p instanceof GenericPrincipal) {
-            ((GenericPrincipal) p).setGssCredential(gssCredential);
-        }
-
-        return p;
-    }
-
-
-    /**
      * Get the principal associated with the specified {@link GSSName}.
      *
      * @param gssName The GSS name


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org