This is an automated email from the ASF dual-hosted git repository.
remm pushed a commit to branch 10.1.x
in repository https://gitbox.apache.org/repos/asf/tomcat.git
The following commit(s) were added to refs/heads/10.1.x by this push:
new b69a8a17be Clear out some fixmes
b69a8a17be is described below
commit b69a8a17be09bc316092a8b0ef726bea88d62bb4
Author: remm <[email protected]>
AuthorDate: Wed Feb 21 14:55:06 2024 +0100
Clear out some fixmes
---
.../org/apache/catalina/valves/rewrite/RewriteValve.java | 4 ++--
java/org/apache/coyote/http11/Http11Processor.java | 6 +++++-
java/org/apache/tomcat/util/compat/Jre22Compat.java | 16 ++--------------
java/org/apache/tomcat/util/modeler/BaseModelMBean.java | 2 --
4 files changed, 9 insertions(+), 19 deletions(-)
diff --git a/java/org/apache/catalina/valves/rewrite/RewriteValve.java
b/java/org/apache/catalina/valves/rewrite/RewriteValve.java
index 8beb2ac3ae..492d45e26d 100644
--- a/java/org/apache/catalina/valves/rewrite/RewriteValve.java
+++ b/java/org/apache/catalina/valves/rewrite/RewriteValve.java
@@ -621,8 +621,8 @@ public class RewriteValve extends ValveBase {
} else if (rewriteMapClassName.startsWith("rnd:")) {
map = new
RandomizedTextRewriteMap(rewriteMapClassName.substring("rnd:".length()), true);
} else if (rewriteMapClassName.startsWith("prg:")) {
- // FIXME:
https://httpd.apache.org/docs/2.4/rewrite/rewritemap.html#prg
- // Likely not worth implementing further since this is a
simpler CGI
+ //
https://httpd.apache.org/docs/2.4/rewrite/rewritemap.html#prg
+ // Not worth implementing further since this is a simpler
CGI
// piping stdin/stdout from an external native process
// Instead assume a class and use the RewriteMap interface
rewriteMapClassName =
rewriteMapClassName.substring("prg:".length());
diff --git a/java/org/apache/coyote/http11/Http11Processor.java
b/java/org/apache/coyote/http11/Http11Processor.java
index b505ed691d..87aa0da734 100644
--- a/java/org/apache/coyote/http11/Http11Processor.java
+++ b/java/org/apache/coyote/http11/Http11Processor.java
@@ -966,7 +966,11 @@ public class Http11Processor extends AbstractProcessor {
headers.addValue("Date").setString(FastHttpDateFormat.getCurrentDate());
}
- // FIXME: Add transfer encoding header
+ // Although using transfer-encoding for gzip would be doable and was
+ // the original intent (which means the compression would be from an
+ // endpoint to the next, so only for the current transmission), it
+ // has been found that using content-encoding (which is end to end
+ // compression) is more efficient and more reliable.
if ((entityBody) && (!contentDelimitation) || connectionClosePresent) {
// Disable keep-alive if:
diff --git a/java/org/apache/tomcat/util/compat/Jre22Compat.java
b/java/org/apache/tomcat/util/compat/Jre22Compat.java
index d685cd56ec..3bd43dd141 100644
--- a/java/org/apache/tomcat/util/compat/Jre22Compat.java
+++ b/java/org/apache/tomcat/util/compat/Jre22Compat.java
@@ -16,8 +16,6 @@
*/
package org.apache.tomcat.util.compat;
-import java.lang.reflect.Method;
-
import org.apache.juli.logging.Log;
import org.apache.juli.logging.LogFactory;
import org.apache.tomcat.util.res.StringManager;
@@ -31,24 +29,14 @@ public class Jre22Compat extends Jre21Compat {
static {
- // FIXME: Improve check using a new class in 22 later
Class<?> c1 = null;
- Class<?> c2 = null;
- Method m1 = null;
-
try {
- c1 = Class.forName("java.lang.foreign.MemorySegment");
- c2 = Class.forName("java.io.Console");
- m1 = c1.getMethod("getString", long.class);
- c2.getMethod("isTerminal");
+ c1 = Class.forName("java.text.ListFormat");
} catch (ClassNotFoundException e) {
// Must be pre-Java 22
log.debug(sm.getString("jre22Compat.javaPre22"), e);
- } catch (ReflectiveOperationException e) {
- // Likely a previous Panama API version
- log.debug(sm.getString("jre22Compat.unexpected"), e);
}
- hasPanama = (m1 != null);
+ hasPanama = (c1 != null);
}
static boolean isSupported() {
diff --git a/java/org/apache/tomcat/util/modeler/BaseModelMBean.java
b/java/org/apache/tomcat/util/modeler/BaseModelMBean.java
index 30760700d5..27561b2cc2 100644
--- a/java/org/apache/tomcat/util/modeler/BaseModelMBean.java
+++ b/java/org/apache/tomcat/util/modeler/BaseModelMBean.java
@@ -197,7 +197,6 @@ public class BaseModelMBean implements DynamicMBean,
MBeanRegistration,
}
// Return the results of this method invocation
- // FIXME - should we validate the return type?
return result;
}
@@ -316,7 +315,6 @@ public class BaseModelMBean implements DynamicMBean,
MBeanRegistration,
}
// Return the results of this method invocation
- // FIXME - should we validate the return type?
return result;
}
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]