svn commit: r1636524 - /tomcat/trunk/test/org/apache/tomcat/util/buf/TestUtf8.java
Author: markt Date: Tue Nov 4 09:14:22 2014 New Revision: 1636524 URL: http://svn.apache.org/r1636524 Log: Update UTF-8 test to take account of recent(ish) Java 8 fixes for UTF-8. Modified: tomcat/trunk/test/org/apache/tomcat/util/buf/TestUtf8.java Modified: tomcat/trunk/test/org/apache/tomcat/util/buf/TestUtf8.java URL: http://svn.apache.org/viewvc/tomcat/trunk/test/org/apache/tomcat/util/buf/TestUtf8.java?rev=1636524&r1=1636523&r2=1636524&view=diff == --- tomcat/trunk/test/org/apache/tomcat/util/buf/TestUtf8.java (original) +++ tomcat/trunk/test/org/apache/tomcat/util/buf/TestUtf8.java Tue Nov 4 09:14:22 2014 @@ -59,8 +59,8 @@ public class TestUtf8 { private static int workAroundCount = 0; static { -// Future proof test and assume some UTF-8 bugs won't get fixed until -// Java 9 or later +// All known issues have been fixed in Java 8 +// https://bugs.openjdk.java.net/browse/JDK-8039751 // Base assumption in Java 7 int javaVersion = 7; try { @@ -69,8 +69,6 @@ public class TestUtf8 { } catch (Exception e) { // Ignore } -// TODO Identify a class to test for Java 9 -//javaVersion = 9; Utf8TestCase testCase = null; @@ -99,14 +97,14 @@ public class TestUtf8 { new int[] {0xF0, 0x90, 0x90, 0x80}, -1, "\uD801\uDC00")); -// Java 7/8 JVM decoder does not report error until all 4 bytes are +// Java 7 JVM decoder does not report error until all 4 bytes are // available testCase = new Utf8TestCase( "Invalid code point - out of range", new int[] {0x41, 0xF4, 0x90, 0x80, 0x80, 0x41}, 2, "A\uFFFD\uFFFD\uFFFD\uFFFDA"); -if (javaVersion < 9) { +if (javaVersion < 8) { testCase.addForJvm(ERROR_POS_PLUS2); } TEST_CASES.add(testCase); @@ -133,14 +131,14 @@ public class TestUtf8 { } TEST_CASES.add(testCase); -// Java 7/8 JVM decoder does not report error until all 4 bytes are +// Java 7 JVM decoder does not report error until all 4 bytes are // available testCase = new Utf8TestCase( "Valid sequence padded from one byte to four", new int[] {0x41, 0xF0, 0x80, 0x80, 0xC1, 0x41}, 2, "A\uFFFD\uFFFD\uFFFD\uFFFDA"); -if (javaVersion < 9) { +if (javaVersion < 8) { testCase.addForJvm(ERROR_POS_PLUS2); } TEST_CASES.add(testCase); @@ -352,7 +350,7 @@ public class TestUtf8 { new int[] {0x61, 0xF0, 0x80, 0x80, 0x80, 0x61}, 2, "a\uFFFD\uFFFD\uFFFD\uFFFDa"); -if (javaVersion < 9) { +if (javaVersion < 8) { testCase.addForJvm(ERROR_POS_PLUS2); } TEST_CASES.add(testCase); @@ -362,7 +360,7 @@ public class TestUtf8 { new int[] {0x61, 0xF0, 0x80, 0x81, 0xBF, 0x61}, 2, "a\uFFFD\uFFFD\uFFFD\uFFFDa"); -if (javaVersion < 9) { +if (javaVersion < 8) { testCase.addForJvm(ERROR_POS_PLUS2); } TEST_CASES.add(testCase); @@ -372,7 +370,7 @@ public class TestUtf8 { new int[] {0x61, 0xF0, 0x80, 0x9F, 0xBF, 0x61}, 2, "a\uFFFD\uFFFD\uFFFD\uFFFDa"); -if (javaVersion < 9) { +if (javaVersion < 8) { testCase.addForJvm(ERROR_POS_PLUS2); } TEST_CASES.add(testCase); @@ -382,7 +380,7 @@ public class TestUtf8 { new int[] {0x61, 0xF0, 0x8F, 0xBF, 0xBF, 0x61}, 2, "a\uFFFD\uFFFD\uFFFD\uFFFDa"); -if (javaVersion < 9) { +if (javaVersion < 8) { testCase.addForJvm(ERROR_POS_PLUS2); } TEST_CASES.add(testCase); - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
svn commit: r1636525 - in /tomcat/tc8.0.x/trunk: ./ test/org/apache/tomcat/util/buf/TestUtf8.java
Author: markt Date: Tue Nov 4 09:16:29 2014 New Revision: 1636525 URL: http://svn.apache.org/r1636525 Log: Update UTF-8 test to take account of recent(ish) Java 8 fixes for UTF-8. Modified: tomcat/tc8.0.x/trunk/ (props changed) tomcat/tc8.0.x/trunk/test/org/apache/tomcat/util/buf/TestUtf8.java Propchange: tomcat/tc8.0.x/trunk/ -- svn:mergeinfo = /tomcat/trunk:1636524 Modified: tomcat/tc8.0.x/trunk/test/org/apache/tomcat/util/buf/TestUtf8.java URL: http://svn.apache.org/viewvc/tomcat/tc8.0.x/trunk/test/org/apache/tomcat/util/buf/TestUtf8.java?rev=1636525&r1=1636524&r2=1636525&view=diff == --- tomcat/tc8.0.x/trunk/test/org/apache/tomcat/util/buf/TestUtf8.java (original) +++ tomcat/tc8.0.x/trunk/test/org/apache/tomcat/util/buf/TestUtf8.java Tue Nov 4 09:16:29 2014 @@ -59,8 +59,8 @@ public class TestUtf8 { private static int workAroundCount = 0; static { -// Future proof test and assume some UTF-8 bugs won't get fixed until -// Java 9 or later +// All known issues have been fixed in Java 8 +// https://bugs.openjdk.java.net/browse/JDK-8039751 // Base assumption in Java 7 int javaVersion = 7; try { @@ -69,8 +69,6 @@ public class TestUtf8 { } catch (Exception e) { // Ignore } -// TODO Identify a class to test for Java 9 -//javaVersion = 9; Utf8TestCase testCase = null; @@ -99,14 +97,14 @@ public class TestUtf8 { new int[] {0xF0, 0x90, 0x90, 0x80}, -1, "\uD801\uDC00")); -// Java 7/8 JVM decoder does not report error until all 4 bytes are +// Java 7 JVM decoder does not report error until all 4 bytes are // available testCase = new Utf8TestCase( "Invalid code point - out of range", new int[] {0x41, 0xF4, 0x90, 0x80, 0x80, 0x41}, 2, "A\uFFFD\uFFFD\uFFFD\uFFFDA"); -if (javaVersion < 9) { +if (javaVersion < 8) { testCase.addForJvm(ERROR_POS_PLUS2); } TEST_CASES.add(testCase); @@ -133,14 +131,14 @@ public class TestUtf8 { } TEST_CASES.add(testCase); -// Java 7/8 JVM decoder does not report error until all 4 bytes are +// Java 7 JVM decoder does not report error until all 4 bytes are // available testCase = new Utf8TestCase( "Valid sequence padded from one byte to four", new int[] {0x41, 0xF0, 0x80, 0x80, 0xC1, 0x41}, 2, "A\uFFFD\uFFFD\uFFFD\uFFFDA"); -if (javaVersion < 9) { +if (javaVersion < 8) { testCase.addForJvm(ERROR_POS_PLUS2); } TEST_CASES.add(testCase); @@ -352,7 +350,7 @@ public class TestUtf8 { new int[] {0x61, 0xF0, 0x80, 0x80, 0x80, 0x61}, 2, "a\uFFFD\uFFFD\uFFFD\uFFFDa"); -if (javaVersion < 9) { +if (javaVersion < 8) { testCase.addForJvm(ERROR_POS_PLUS2); } TEST_CASES.add(testCase); @@ -362,7 +360,7 @@ public class TestUtf8 { new int[] {0x61, 0xF0, 0x80, 0x81, 0xBF, 0x61}, 2, "a\uFFFD\uFFFD\uFFFD\uFFFDa"); -if (javaVersion < 9) { +if (javaVersion < 8) { testCase.addForJvm(ERROR_POS_PLUS2); } TEST_CASES.add(testCase); @@ -372,7 +370,7 @@ public class TestUtf8 { new int[] {0x61, 0xF0, 0x80, 0x9F, 0xBF, 0x61}, 2, "a\uFFFD\uFFFD\uFFFD\uFFFDa"); -if (javaVersion < 9) { +if (javaVersion < 8) { testCase.addForJvm(ERROR_POS_PLUS2); } TEST_CASES.add(testCase); @@ -382,7 +380,7 @@ public class TestUtf8 { new int[] {0x61, 0xF0, 0x8F, 0xBF, 0xBF, 0x61}, 2, "a\uFFFD\uFFFD\uFFFD\uFFFDa"); -if (javaVersion < 9) { +if (javaVersion < 8) { testCase.addForJvm(ERROR_POS_PLUS2); } TEST_CASES.add(testCase); - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
[Bug 57142] JSP 2.3 & EL 3.0 - %page import directive & EL ImportHandler
https://issues.apache.org/bugzilla/show_bug.cgi?id=57142 --- Comment #5 from Mark Thomas --- Those are all good points. Please can you add them to https://java.net/jira/browse/JSP-44 ? -- You are receiving this mail because: You are the assignee for the bug. - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
svn commit: r1636533 - /tomcat/trunk/java/org/apache/catalina/manager/ManagerServlet.java
Author: markt Date: Tue Nov 4 10:04:32 2014 New Revision: 1636533 URL: http://svn.apache.org/r1636533 Log: Fix a typo Modified: tomcat/trunk/java/org/apache/catalina/manager/ManagerServlet.java Modified: tomcat/trunk/java/org/apache/catalina/manager/ManagerServlet.java URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/catalina/manager/ManagerServlet.java?rev=1636533&r1=1636532&r2=1636533&view=diff == --- tomcat/trunk/java/org/apache/catalina/manager/ManagerServlet.java (original) +++ tomcat/trunk/java/org/apache/catalina/manager/ManagerServlet.java Tue Nov 4 10:04:32 2014 @@ -102,7 +102,7 @@ import org.apache.tomcat.util.res.String * (fully qualified Java class name), if available. * /serverinfo - Display system OS and JVM properties. * /sessions - Deprecated. Use expire. - * /expire?path=/xxx - List session idle timeinformation about the + * /expire?path=/xxx - List session idle time information about the * web application attached to context path /xxx for this * virtual host. * /expire?path=/xxx&idle=mm - Expire sessions - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
svn commit: r1636534 - in /tomcat/trunk/java/org/apache/catalina: Manager.java session/ManagerBase.java
Author: markt Date: Tue Nov 4 10:27:47 2014 New Revision: 1636534 URL: http://svn.apache.org/r1636534 Log: Remove deprecated code from Manager interface Modified: tomcat/trunk/java/org/apache/catalina/Manager.java tomcat/trunk/java/org/apache/catalina/session/ManagerBase.java Modified: tomcat/trunk/java/org/apache/catalina/Manager.java URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/catalina/Manager.java?rev=1636534&r1=1636533&r2=1636534&view=diff == --- tomcat/trunk/java/org/apache/catalina/Manager.java (original) +++ tomcat/trunk/java/org/apache/catalina/Manager.java Tue Nov 4 10:27:47 2014 @@ -46,29 +46,6 @@ public interface Manager { // - Properties - -/** - * Return the Container with which this Manager is associated. - * - * @deprecated Use {@link #getContext()}. This method will be removed in - * Tomcat 9 onwards. - */ -@Deprecated -public Container getContainer(); - - -/** - * Set the Container with which this Manager is associated. - * - * @param container The newly associated Container - * - * @deprecated Use {@link #setContext(Context)}. This method will be removed in - * Tomcat 9 onwards. - */ -@Deprecated -public void setContainer(Container container); - - /** * Return the Context with which this Manager is associated. */ @@ -131,32 +108,6 @@ public interface Manager { /** - * Gets the session id length (in bytes) of Sessions created by - * this Manager. - * - * @deprecated Use {@link SessionIdGenerator#getSessionIdLength()}. - * This method will be removed in Tomcat 9 onwards. - * - * @return The session id length - */ -@Deprecated -public int getSessionIdLength(); - - -/** - * Sets the session id length (in bytes) for Sessions created by this - * Manager. - * - * @deprecated Use {@link SessionIdGenerator#setSessionIdLength(int)}. - * This method will be removed in Tomcat 9 onwards. - * - * @param idLength The session id length - */ -@Deprecated -public void setSessionIdLength(int idLength); - - -/** * Returns the total number of sessions created by this manager. * * @return Total number of sessions created by this manager. Modified: tomcat/trunk/java/org/apache/catalina/session/ManagerBase.java URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/catalina/session/ManagerBase.java?rev=1636534&r1=1636533&r2=1636534&view=diff == --- tomcat/trunk/java/org/apache/catalina/session/ManagerBase.java (original) +++ tomcat/trunk/java/org/apache/catalina/session/ManagerBase.java Tue Nov 4 10:27:47 2014 @@ -215,25 +215,6 @@ public abstract class ManagerBase extend // - Properties @Override -@Deprecated -public Container getContainer() { -return getContext(); -} - - -@Override -@Deprecated -public void setContainer(Container container) { - -if (container instanceof Context || container == null) { -setContext((Context) container); -} else { -log.warn(sm.getString("managerBase.container.noop")); -} -} - - -@Override public Context getContext() { return context; } @@ -249,8 +230,6 @@ public abstract class ManagerBase extend Context oldContext = this.context; this.context = context; support.firePropertyChange("context", oldContext, this.context); -// TODO - delete the line below in Tomcat 9 onwards -support.firePropertyChange("container", oldContext, this.context); // Register with the new Context (if any) if (this.context != null) { @@ -328,46 +307,6 @@ public abstract class ManagerBase extend /** - * Gets the session id length (in bytes) of Sessions created by - * this Manager. - * - * @deprecated Use {@link SessionIdGenerator#getSessionIdLength()}. - * This method will be removed in Tomcat 9 onwards. - * - * @return The session id length - */ -@Override -@Deprecated -public int getSessionIdLength() { - -return (this.sessionIdLength); - -} - - -/** - * Sets the session id length (in bytes) for Sessions created by this - * Manager. - * - * @deprecated Use {@link SessionIdGenerator#setSessionIdLength(int)}. - * This method will be removed in Tomcat 9 onwards. - * - * @param idLength The session id length - */ -@Override -@Deprecated -public void setSessionIdLength(int idLength) { - -int oldSessionIdLength = this.sessionId
svn commit: r1636537 - /tomcat/trunk/java/org/apache/catalina/Manager.java
Author: markt Date: Tue Nov 4 10:46:57 2014 New Revision: 1636537 URL: http://svn.apache.org/r1636537 Log: Clean-up. No functional change - whitespace fixes - Java8 Javadoc fixes Modified: tomcat/trunk/java/org/apache/catalina/Manager.java Modified: tomcat/trunk/java/org/apache/catalina/Manager.java URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/catalina/Manager.java?rev=1636537&r1=1636536&r2=1636537&view=diff == --- tomcat/trunk/java/org/apache/catalina/Manager.java (original) +++ tomcat/trunk/java/org/apache/catalina/Manager.java Tue Nov 4 10:46:57 2014 @@ -14,15 +14,11 @@ * See the License for the specific language governing permissions and * limitations under the License. */ - - package org.apache.catalina; - import java.beans.PropertyChangeListener; import java.io.IOException; - /** * A Manager manages the pool of Sessions that are associated with a * particular Container. Different Manager implementations may support @@ -43,11 +39,12 @@ import java.io.IOException; */ public interface Manager { - // - Properties /** - * Return the Context with which this Manager is associated. + * Get the Context with which this Manager is associated. + * + * @return The associated Context */ public Context getContext(); @@ -61,16 +58,18 @@ public interface Manager { /** - * Return the distributable flag for the sessions supported by - * this Manager. + * Is this Manager marked as using distributable sessions? + * + * @return {@code true} if this manager is marked as distributable otherwise + * {@code false} */ public boolean getDistributable(); /** - * Set the distributable flag for the sessions supported by this - * Manager. If this flag is set, all user data objects added to - * sessions associated with this manager must implement Serializable. + * Configure whether this manager uses distributable sessions. If this flag + * is set, all user data objects added to sessions associated with this + * manager must implement Serializable. * * @param distributable The new distributable flag */ @@ -78,8 +77,10 @@ public interface Manager { /** - * Return the default maximum inactive interval (in seconds) - * for Sessions created by this Manager. + * Get the default time in seconds before a session managed by this manager + * will be considered inactive. + * + * @return The default maximum inactive interval in seconds */ public int getMaxInactiveInterval(); @@ -94,7 +95,7 @@ public interface Manager { /** - * return the session id generator + * @return the session id generator */ public SessionIdGenerator getSessionIdGenerator(); @@ -222,9 +223,10 @@ public interface Manager { * @return The current rate (in sessions per minute) of session expiration */ public int getSessionExpireRate(); -// - Public Methods +// - Public Methods + /** * Add this Session to the set of active Sessions for this Manager. * @@ -263,6 +265,8 @@ public interface Manager { * Get a session from the recycled ones or create a new empty one. * The PersistentManager manager does not need to create session data * because it reads it from the Store. + * + * @return An empty Session object */ public Session createEmptySession(); @@ -280,6 +284,9 @@ public interface Manager { * method of the returned session. * @exception IllegalStateException if a new session cannot be * instantiated for any reason + * + * @return An empty Session object with the given ID or a newly created + * session ID if none was specified */ public Session createSession(String sessionId); @@ -294,6 +301,9 @@ public interface Manager { * instantiated for any reason * @exception IOException if an input/output error occurs while * processing this request + * + * @return the request session or {@code null} if a session with the + * requested ID could not be found */ public Session findSession(String id) throws IOException; @@ -301,6 +311,8 @@ public interface Manager { /** * Return the set of active Sessions associated with this Manager. * If this Manager has no active Sessions, a zero-length array is returned. + * + * @return All the currently active sessions managed by this manager */ public Session[] findSessions(); @@ -351,11 +363,11 @@ public interface Manager { */ public void unload() throws IOException; - /** - * This method
svn commit: r1636541 - /tomcat/trunk/java/org/apache/catalina/util/SessionIdGeneratorBase.java
Author: markt Date: Tue Nov 4 11:06:12 2014 New Revision: 1636541 URL: http://svn.apache.org/r1636541 Log: Add getters. Improve Javadoc. Modified: tomcat/trunk/java/org/apache/catalina/util/SessionIdGeneratorBase.java Modified: tomcat/trunk/java/org/apache/catalina/util/SessionIdGeneratorBase.java URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/catalina/util/SessionIdGeneratorBase.java?rev=1636541&r1=1636540&r2=1636541&view=diff == --- tomcat/trunk/java/org/apache/catalina/util/SessionIdGeneratorBase.java (original) +++ tomcat/trunk/java/org/apache/catalina/util/SessionIdGeneratorBase.java Tue Nov 4 11:06:12 2014 @@ -48,36 +48,10 @@ public abstract class SessionIdGenerator */ private final Queue randoms = new ConcurrentLinkedQueue<>(); - -/** - * The Java class name of the secure random number generator class to be - * used when generating session identifiers. The random number generator - * class must be self-seeding and have a zero-argument constructor. If not - * specified, an instance of {@link SecureRandom} will be generated. - */ private String secureRandomClass = null; - -/** - * The name of the algorithm to use to create instances of - * {@link SecureRandom} which are used to generate session IDs. If no - * algorithm is specified, SHA1PRNG is used. To use the platform default - * (which may be SHA1PRNG), specify the empty string. If an invalid - * algorithm and/or provider is specified the {@link SecureRandom} instances - * will be created using the defaults. If that fails, the {@link - * SecureRandom} instances will be created using platform defaults. - */ private String secureRandomAlgorithm = "SHA1PRNG"; - -/** - * The name of the provider to use to create instances of - * {@link SecureRandom} which are used to generate session IDs. If - * no algorithm is specified the of SHA1PRNG default is used. If an invalid - * algorithm and/or provider is specified the {@link SecureRandom} instances - * will be created using the defaults. If that fails, the {@link - * SecureRandom} instances will be created using platform defaults. - */ private String secureRandomProvider = null; @@ -90,7 +64,21 @@ public abstract class SessionIdGenerator /** - * Specify a non-default @{link {@link SecureRandom} implementation to use. + * Get the class name of the {@link SecureRandom} implementation used to + * generate session IDs. + * + * @return The fully qualified class name. {@code null} indicates that the + * JRE provided {@link SecureRandom} implementation will be used + */ +public String getSecureRandomClass() { +return secureRandomClass; +} + + +/** + * Specify a non-default {@link SecureRandom} implementation to use. The + * implementation must be self-seeding and have a zero-argument constructor. + * If not specified, an instance of {@link SecureRandom} will be generated. * * @param secureRandomClass The fully-qualified class name */ @@ -100,7 +88,26 @@ public abstract class SessionIdGenerator /** - * Specify a non-default algorithm to use to generate random numbers. + * Get the name of the algorithm used to create the {@link SecureRandom} + * instances which generate new session IDs. + * + * @return The name of the algorithm. {@code null} or the empty string means + * that platform default will be used + */ +public String getSecureRandomAlgorithm() { +return secureRandomAlgorithm; +} + + +/** + * Specify a non-default algorithm to use to create instances of + * {@link SecureRandom} which are used to generate session IDs. If no + * algorithm is specified, SHA1PRNG is used. To use the platform default + * (which may be SHA1PRNG), specify {@code null} or the empty string. If an + * invalid algorithm and/or provider is specified the {@link SecureRandom} + * instances will be created using the defaults for this + * {@link SessionIdGenerator} implementation. If that fails, the + * {@link SecureRandom} instances will be created using platform defaults. * * @param secureRandomAlgorithm The name of the algorithm */ @@ -110,7 +117,26 @@ public abstract class SessionIdGenerator /** - * Specify a non-default provider to use to generate random numbers. + * Get the name of the provider used to create the {@link SecureRandom} + * instances which generate new session IDs. + * + * @return The name of the provider. {@code null} or the empty string means + * that platform default will be used + */ +public String getSecureRandomProvider() { +return secureRandomProvider; +} + + +/** + * Specify a non-default provider to use to c
Re: svn commit: r1636347 - /tomcat/trunk/TOMCAT-NEXT.txt
2014-11-03 14:16 GMT+01:00 : > + 3. Remove Comet support. > Are you actively working on it right now, or is there room for participation for this item ? Rémy
Re: svn commit: r1636347 - /tomcat/trunk/TOMCAT-NEXT.txt
On 04/11/2014 11:08, Rémy Maucherat wrote: > 2014-11-03 14:16 GMT+01:00 : > >> + 3. Remove Comet support. >> > > Are you actively working on it right now, or is there room for > participation for this item ? I have a commit sat in my local git repo that removes all the Comet stuff. Let me commit that. I suspect that commit will result in some further unused code that can be removed but haven't run the unused code detector over the code base yet. Mark - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
svn commit: r1636547 [2/2] - in /tomcat/trunk: ./ conf/ java/org/apache/catalina/ java/org/apache/catalina/comet/ java/org/apache/catalina/connector/ java/org/apache/catalina/core/ java/org/apache/cat
Modified: tomcat/trunk/java/org/apache/coyote/http11/AbstractHttp11Processor.java URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/coyote/http11/AbstractHttp11Processor.java?rev=1636547&r1=1636546&r2=1636547&view=diff == --- tomcat/trunk/java/org/apache/coyote/http11/AbstractHttp11Processor.java (original) +++ tomcat/trunk/java/org/apache/coyote/http11/AbstractHttp11Processor.java Tue Nov 4 11:54:58 2014 @@ -150,12 +150,6 @@ public abstract class AbstractHttp11Proc /** - * Comet used. - */ -protected boolean comet = false; - - -/** * Regular expression that defines the restricted user agents. */ protected Pattern restrictedUserAgents = null; @@ -976,7 +970,6 @@ public abstract class AbstractHttp11Proc // Flags keepAlive = true; -comet = false; openSocket = false; sendfileInProgress = false; readComplete = true; @@ -990,7 +983,7 @@ public abstract class AbstractHttp11Proc socketWrapper.setKeepAliveLeft(0); } -while (!getErrorState().isError() && keepAlive && !comet && !isAsync() && +while (!getErrorState().isError() && keepAlive && !isAsync() && httpUpgradeHandler == null && !endpoint.isPaused()) { // Parsing the request header @@ -1095,7 +1088,6 @@ public abstract class AbstractHttp11Proc statusDropsConnection(response.getStatus() { setErrorState(ErrorState.CLOSE_CLEAN, null); } -setCometTimeouts(socketWrapper); } catch (InterruptedIOException e) { setErrorState(ErrorState.CLOSE_NOW, e); } catch (HeadersTooLargeException e) { @@ -1123,7 +1115,7 @@ public abstract class AbstractHttp11Proc // Finish the handling of the request rp.setStage(org.apache.coyote.Constants.STAGE_ENDINPUT); -if (!isAsync() && !comet) { +if (!isAsync()) { if (getErrorState().isError()) { // If we know we are closing the connection, don't drain // input. This way uploading a 100GB file doesn't tie up the @@ -1152,7 +1144,7 @@ public abstract class AbstractHttp11Proc } request.updateCounters(); -if (!isAsync() && !comet || getErrorState().isError()) { +if (!isAsync() || getErrorState().isError()) { if (getErrorState().isIoAllowed()) { getInputBuffer().nextRequest(); getOutputBuffer().nextRequest(); @@ -1178,7 +1170,7 @@ public abstract class AbstractHttp11Proc if (getErrorState().isError() || endpoint.isPaused()) { return SocketState.CLOSED; -} else if (isAsync() || comet) { +} else if (isAsync()) { return SocketState.LONG; } else if (isUpgrade()) { return SocketState.UPGRADING; @@ -1711,12 +1703,6 @@ public abstract class AbstractHttp11Proc @Override -public boolean isComet() { -return comet; -} - - -@Override public boolean isUpgrade() { return httpUpgradeHandler != null; } @@ -1745,12 +1731,6 @@ public abstract class AbstractHttp11Proc protected abstract void resetTimeouts(); -/** - * Provides a mechanism for those connectors (currently only NIO) that need - * that need to set comet timeouts. - */ -protected abstract void setCometTimeouts(SocketWrapper socketWrapper); - public void endRequest() { // Finish the handling of the request @@ -1807,7 +1787,6 @@ public abstract class AbstractHttp11Proc asyncStateMachine.recycle(); } httpUpgradeHandler = null; -comet = false; resetErrorState(); recycleInternal(); } Modified: tomcat/trunk/java/org/apache/coyote/http11/Http11AprProcessor.java URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/coyote/http11/Http11AprProcessor.java?rev=1636547&r1=1636546&r2=1636547&view=diff == --- tomcat/trunk/java/org/apache/coyote/http11/Http11AprProcessor.java (original) +++ tomcat/trunk/java/org/apache/coyote/http11/Http11AprProcessor.java Tue Nov 4 11:54:58 2014 @@ -18,13 +18,11 @@ package org.apache.coyote.http11; import java.io.ByteArrayInputStream; import java.io.IOException; -import java.io.InterruptedIOException; import java.security.cert.CertificateFactory; import java.security.cert.X509Certificate; import org.apache.coyote.ActionCode; import org.apache.coyote.ErrorState; -import org.apache.coyote.RequestInfo; import org.apache.coyote.http11.filters.BufferedInputFilter; import org.apache.juli.logging.Log; import org.apache.juli.log
svn commit: r1636547 [1/2] - in /tomcat/trunk: ./ conf/ java/org/apache/catalina/ java/org/apache/catalina/comet/ java/org/apache/catalina/connector/ java/org/apache/catalina/core/ java/org/apache/cat
Author: markt Date: Tue Nov 4 11:54:58 2014 New Revision: 1636547 URL: http://svn.apache.org/r1636547 Log: Remove Comet Removed: tomcat/trunk/java/org/apache/catalina/comet/CometEvent.java tomcat/trunk/java/org/apache/catalina/comet/CometFilter.java tomcat/trunk/java/org/apache/catalina/comet/CometFilterChain.java tomcat/trunk/java/org/apache/catalina/comet/CometProcessor.java tomcat/trunk/java/org/apache/catalina/connector/CometEventImpl.java tomcat/trunk/java/org/apache/catalina/valves/CometConnectionManagerValve.java tomcat/trunk/test/org/apache/catalina/comet/TestCometProcessor.java tomcat/trunk/webapps/examples/WEB-INF/classes/chat/ChatServlet.java tomcat/trunk/webapps/examples/servlets/chat/index.jsp tomcat/trunk/webapps/examples/servlets/chat/login.jsp tomcat/trunk/webapps/examples/servlets/chat/post.jsp Modified: tomcat/trunk/NOTICE tomcat/trunk/TOMCAT-NEXT.txt tomcat/trunk/conf/catalina.policy tomcat/trunk/conf/context.xml tomcat/trunk/java/org/apache/catalina/Globals.java tomcat/trunk/java/org/apache/catalina/Valve.java tomcat/trunk/java/org/apache/catalina/connector/CoyoteAdapter.java tomcat/trunk/java/org/apache/catalina/connector/InputBuffer.java tomcat/trunk/java/org/apache/catalina/connector/LocalStrings.properties tomcat/trunk/java/org/apache/catalina/connector/LocalStrings_es.properties tomcat/trunk/java/org/apache/catalina/connector/OutputBuffer.java tomcat/trunk/java/org/apache/catalina/connector/Request.java tomcat/trunk/java/org/apache/catalina/connector/Response.java tomcat/trunk/java/org/apache/catalina/core/ApplicationFilterChain.java tomcat/trunk/java/org/apache/catalina/core/ApplicationFilterFactory.java tomcat/trunk/java/org/apache/catalina/core/StandardContextValve.java tomcat/trunk/java/org/apache/catalina/core/StandardEngineValve.java tomcat/trunk/java/org/apache/catalina/core/StandardHostValve.java tomcat/trunk/java/org/apache/catalina/core/StandardWrapperValve.java tomcat/trunk/java/org/apache/catalina/filters/FailedRequestFilter.java tomcat/trunk/java/org/apache/catalina/filters/RemoteAddrFilter.java tomcat/trunk/java/org/apache/catalina/filters/RemoteHostFilter.java tomcat/trunk/java/org/apache/catalina/filters/RequestFilter.java tomcat/trunk/java/org/apache/catalina/valves/LocalStrings.properties tomcat/trunk/java/org/apache/catalina/valves/LocalStrings_es.properties tomcat/trunk/java/org/apache/catalina/valves/ValveBase.java tomcat/trunk/java/org/apache/coyote/AbstractProcessor.java tomcat/trunk/java/org/apache/coyote/AbstractProtocol.java tomcat/trunk/java/org/apache/coyote/ActionCode.java tomcat/trunk/java/org/apache/coyote/Adapter.java tomcat/trunk/java/org/apache/coyote/Constants.java tomcat/trunk/java/org/apache/coyote/Processor.java tomcat/trunk/java/org/apache/coyote/ProtocolHandler.java tomcat/trunk/java/org/apache/coyote/ajp/AbstractAjpProcessor.java tomcat/trunk/java/org/apache/coyote/ajp/AjpNio2Protocol.java tomcat/trunk/java/org/apache/coyote/ajp/LocalStrings.properties tomcat/trunk/java/org/apache/coyote/http11/AbstractHttp11Processor.java tomcat/trunk/java/org/apache/coyote/http11/Http11AprProcessor.java tomcat/trunk/java/org/apache/coyote/http11/Http11AprProtocol.java tomcat/trunk/java/org/apache/coyote/http11/Http11Nio2Processor.java tomcat/trunk/java/org/apache/coyote/http11/Http11Nio2Protocol.java tomcat/trunk/java/org/apache/coyote/http11/Http11NioProcessor.java tomcat/trunk/java/org/apache/coyote/http11/Http11NioProtocol.java tomcat/trunk/java/org/apache/coyote/http11/Http11Processor.java tomcat/trunk/java/org/apache/coyote/http11/LocalStrings.properties tomcat/trunk/java/org/apache/coyote/http11/upgrade/AbstractProcessor.java tomcat/trunk/java/org/apache/coyote/spdy/SpdyProcessor.java tomcat/trunk/java/org/apache/tomcat/util/net/AbstractEndpoint.java tomcat/trunk/java/org/apache/tomcat/util/net/AprEndpoint.java tomcat/trunk/java/org/apache/tomcat/util/net/JIoEndpoint.java tomcat/trunk/java/org/apache/tomcat/util/net/Nio2Endpoint.java tomcat/trunk/java/org/apache/tomcat/util/net/NioEndpoint.java tomcat/trunk/java/org/apache/tomcat/util/net/SecureNio2Channel.java tomcat/trunk/java/org/apache/tomcat/util/net/SocketWrapper.java tomcat/trunk/webapps/docs/aio.xml tomcat/trunk/webapps/docs/changelog.xml tomcat/trunk/webapps/docs/config/http.xml tomcat/trunk/webapps/examples/WEB-INF/web.xml tomcat/trunk/webapps/examples/servlets/index.html Modified: tomcat/trunk/NOTICE URL: http://svn.apache.org/viewvc/tomcat/trunk/NOTICE?rev=1636547&r1=1636546&r2=1636547&view=diff == --- tomcat/trunk/NOTICE (original) +++ tomcat/trunk/NOTICE Tue Nov 4 11:54:58 2014 @@ -15,13 +15,6 @@ which is open source software. Th
svn commit: r1636553 - in /tomcat/trunk: java/org/apache/catalina/comet/ test/org/apache/catalina/comet/ webapps/examples/WEB-INF/classes/chat/ webapps/examples/servlets/chat/
Author: markt Date: Tue Nov 4 12:13:13 2014 New Revision: 1636553 URL: http://svn.apache.org/r1636553 Log: Remove some empty directories git left behind Removed: tomcat/trunk/java/org/apache/catalina/comet/ tomcat/trunk/test/org/apache/catalina/comet/ tomcat/trunk/webapps/examples/WEB-INF/classes/chat/ tomcat/trunk/webapps/examples/servlets/chat/ - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
svn commit: r1636556 - /tomcat/trunk/java/org/apache/catalina/connector/Request.java
Author: markt Date: Tue Nov 4 12:16:31 2014 New Revision: 1636556 URL: http://svn.apache.org/r1636556 Log: Remove unused methods identified by the UCDetector Modified: tomcat/trunk/java/org/apache/catalina/connector/Request.java Modified: tomcat/trunk/java/org/apache/catalina/connector/Request.java URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/catalina/connector/Request.java?rev=1636556&r1=1636555&r2=1636556&view=diff == --- tomcat/trunk/java/org/apache/catalina/connector/Request.java (original) +++ tomcat/trunk/java/org/apache/catalina/connector/Request.java Tue Nov 4 12:16:31 2014 @@ -523,18 +523,8 @@ public class Request } -/** - * Clear cached encoders (to save memory for async requests). - */ -public boolean read() -throws IOException { -return (inputBuffer.realReadBytes(null, 0, 0) > 0); -} - - // Request Methods - /** * Associated Catalina connector. */ @@ -3131,17 +3121,6 @@ public class Request } -protected static final boolean isAlpha(String value) { -for (int i = 0; i < value.length(); i++) { -char c = value.charAt(i); -if (!((c >= 'a' && c <= 'z') || (c >= 'A' && c <= 'Z'))) { -return false; -} -} -return true; -} - - // - Special attributes handling private static interface SpecialAttributeAdapter { - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
svn commit: r1636558 - /tomcat/trunk/java/org/apache/coyote/http11/upgrade/AbstractServletInputStream.java
Author: markt Date: Tue Nov 4 12:27:41 2014 New Revision: 1636558 URL: http://svn.apache.org/r1636558 Log: Remove unused methods identified by the UCDetector Modified: tomcat/trunk/java/org/apache/coyote/http11/upgrade/AbstractServletInputStream.java Modified: tomcat/trunk/java/org/apache/coyote/http11/upgrade/AbstractServletInputStream.java URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/coyote/http11/upgrade/AbstractServletInputStream.java?rev=1636558&r1=1636557&r2=1636558&view=diff == --- tomcat/trunk/java/org/apache/coyote/http11/upgrade/AbstractServletInputStream.java (original) +++ tomcat/trunk/java/org/apache/coyote/http11/upgrade/AbstractServletInputStream.java Tue Nov 4 12:27:41 2014 @@ -167,21 +167,6 @@ public abstract class AbstractServletInp } -protected final void onAllDataRead() throws IOException { -if (listener == null) { -return; -} -Thread thread = Thread.currentThread(); -ClassLoader originalClassLoader = thread.getContextClassLoader(); -try { -thread.setContextClassLoader(applicationLoader); -listener.onAllDataRead(); -} finally { -thread.setContextClassLoader(originalClassLoader); -} -} - - protected final void onDataAvailable() throws IOException { if (listener == null) { return; - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
svn commit: r1636563 - /tomcat/trunk/java/org/apache/tomcat/util/net/Constants.java
Author: markt Date: Tue Nov 4 12:40:06 2014 New Revision: 1636563 URL: http://svn.apache.org/r1636563 Log: Remove unused code identified by the UCDetector Modified: tomcat/trunk/java/org/apache/tomcat/util/net/Constants.java Modified: tomcat/trunk/java/org/apache/tomcat/util/net/Constants.java URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/tomcat/util/net/Constants.java?rev=1636563&r1=1636562&r2=1636563&view=diff == --- tomcat/trunk/java/org/apache/tomcat/util/net/Constants.java (original) +++ tomcat/trunk/java/org/apache/tomcat/util/net/Constants.java Tue Nov 4 12:40:06 2014 @@ -23,11 +23,4 @@ public class Constants { * the tomcat instance installation path */ public static final String CATALINA_BASE_PROP = "catalina.base"; - - -/** - * Has security been turned on? - */ -public static final boolean IS_SECURITY_ENABLED = -(System.getSecurityManager() != null); } - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
svn commit: r1636565 - /tomcat/trunk/TOMCAT-NEXT.txt
Author: markt Date: Tue Nov 4 12:48:34 2014 New Revision: 1636565 URL: http://svn.apache.org/r1636565 Log: Something else that struck me while looking through the code Modified: tomcat/trunk/TOMCAT-NEXT.txt Modified: tomcat/trunk/TOMCAT-NEXT.txt URL: http://svn.apache.org/viewvc/tomcat/trunk/TOMCAT-NEXT.txt?rev=1636565&r1=1636564&r2=1636565&view=diff == --- tomcat/trunk/TOMCAT-NEXT.txt (original) +++ tomcat/trunk/TOMCAT-NEXT.txt Tue Nov 4 12:48:34 2014 @@ -24,7 +24,7 @@ Notes of things to consider for the next 3. DONE. Remove Comet support. - 4. Refactor the connectors to minimise code duplication + 4. Refactor the connectors to minimise code duplication. - All implementation specific per connector code -> Endpoint - All implementation specific per connection code -> SocketWrapper @@ -42,4 +42,7 @@ Notes of things to consider for the next the Servlet API. 10. Remove the use of system properties to control configuration wherever - possible \ No newline at end of file +possible. + +11. Reduce instances of setters and getters for the same property existing on an +object and its parent. This may require new objects to be exposed via JMX. - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
Re: svn commit: r1636565 - /tomcat/trunk/TOMCAT-NEXT.txt
2014-11-04 13:48 GMT+01:00 : > +11. Reduce instances of setters and getters for the same property > existing on an > +object and its parent. This may require new objects to be exposed via > JMX. > > This sounds like changing the management interface for a very trivial reason. Rémy
Re: [VOTE] Release Apache Tomcat 8.0.15
On Mon, Nov 3, 2014 at 4:51 AM, Mark Thomas wrote: ... > The proposed 8.0.15 release is: > [ ] Broken - do not release > [ X ] Stable - go ahead and release as 8.0.14 Yee-haw. - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
Re: [VOTE] Release Apache Tomcat 8.0.15
2014-11-03 10:51 GMT+01:00 Mark Thomas : > The proposed 8.0.15 release is: > [ ] Broken - do not release > [X] Stable - go ahead and release as 8.0.15 > > Rémy
Re: svn commit: r1636565 - /tomcat/trunk/TOMCAT-NEXT.txt
On 04/11/2014 13:34, Rémy Maucherat wrote: > 2014-11-04 13:48 GMT+01:00 : > >> +11. Reduce instances of setters and getters for the same property >> existing on an >> +object and its parent. This may require new objects to be exposed via >> JMX. > > This sounds like changing the management interface for a very trivial > reason. Fair point. I think there are some cases (e.g. Manager/SessionIdGenerator - the one that got me thinking along these lines) that make more sense than others. Happy to look at them on a case by case basis. Mark - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
svn commit: r1636582 - in /tomcat/trunk: java/org/apache/catalina/session/ManagerBase.java webapps/docs/config/cluster-manager.xml webapps/docs/config/manager.xml
Author: markt Date: Tue Nov 4 14:08:11 2014 New Revision: 1636582 URL: http://svn.apache.org/r1636582 Log: Follow-up to 1636534 Remove additional references to setting session ID length on the Manager. Modified: tomcat/trunk/java/org/apache/catalina/session/ManagerBase.java tomcat/trunk/webapps/docs/config/cluster-manager.xml tomcat/trunk/webapps/docs/config/manager.xml Modified: tomcat/trunk/java/org/apache/catalina/session/ManagerBase.java URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/catalina/session/ManagerBase.java?rev=1636582&r1=1636581&r2=1636582&view=diff == --- tomcat/trunk/java/org/apache/catalina/session/ManagerBase.java (original) +++ tomcat/trunk/java/org/apache/catalina/session/ManagerBase.java Tue Nov 4 14:08:11 2014 @@ -89,17 +89,6 @@ public abstract class ManagerBase extend */ protected int maxInactiveInterval = 30 * 60; - -protected static final int SESSION_ID_LENGTH_UNSET = -1; - -/** - * The session id length of Sessions created by this Manager. - * The length should be set directly on the SessionIdGenerator. - * Setting it here is deprecated. - */ -protected int sessionIdLength = SESSION_ID_LENGTH_UNSET; - - /** * The Java class name of the secure random number generator class to be * used when generating session identifiers. The random number generator @@ -544,9 +533,6 @@ public abstract class ManagerBase extend setSessionIdGenerator(sessionIdGenerator); } -if (sessionIdLength != SESSION_ID_LENGTH_UNSET) { -sessionIdGenerator.setSessionIdLength(sessionIdLength); -} sessionIdGenerator.setJvmRoute(getJvmRoute()); if (sessionIdGenerator instanceof SessionIdGeneratorBase) { SessionIdGeneratorBase sig = (SessionIdGeneratorBase)sessionIdGenerator; Modified: tomcat/trunk/webapps/docs/config/cluster-manager.xml URL: http://svn.apache.org/viewvc/tomcat/trunk/webapps/docs/config/cluster-manager.xml?rev=1636582&r1=1636581&r2=1636582&view=diff == --- tomcat/trunk/webapps/docs/config/cluster-manager.xml (original) +++ tomcat/trunk/webapps/docs/config/cluster-manager.xml Tue Nov 4 14:08:11 2014 @@ -97,13 +97,6 @@ varied by a servlet via the setMaxInactiveInterval method of the HttpSession object. - - The length of session ids created by this Manager, measured in bytes, -excluding subsequent conversion to a hexadecimal string and -excluding any JVM route information used for load balancing. -This attribute is deprecated. Set the length on a nested -SessionIdGenerator element instead. - Frequency of the session expiration, and related manager operations. Manager operations will be done once for the specified amount of Modified: tomcat/trunk/webapps/docs/config/manager.xml URL: http://svn.apache.org/viewvc/tomcat/trunk/webapps/docs/config/manager.xml?rev=1636582&r1=1636581&r2=1636582&view=diff == --- tomcat/trunk/webapps/docs/config/manager.xml (original) +++ tomcat/trunk/webapps/docs/config/manager.xml Tue Nov 4 14:08:11 2014 @@ -99,15 +99,6 @@ varied by a servlet via the setMaxInactiveInterval method of the HttpSession object. - - - The length of session ids created by this Manager, measured in bytes, -excluding subsequent conversion to a hexadecimal string and -excluding any JVM route information used for load balancing. -This attribute is deprecated. Set the length on a nested -SessionIdGenerator element instead. - - - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
Re: [VOTE] Release Apache Tomcat 8.0.15
[X] Stable - go ahead and release as 8.0.15 Martin Grigorov Wicket Training and Consulting https://twitter.com/mtgrigorov On Tue, Nov 4, 2014 at 3:54 PM, Rémy Maucherat wrote: > 2014-11-03 10:51 GMT+01:00 Mark Thomas : > > > The proposed 8.0.15 release is: > > [ ] Broken - do not release > > [X] Stable - go ahead and release as 8.0.15 > > > > Rémy >
svn commit: r1636588 - /tomcat/trunk/java/org/apache/coyote/spdy/SpdyProxyProtocol.java
Author: markt Date: Tue Nov 4 14:34:29 2014 New Revision: 1636588 URL: http://svn.apache.org/r1636588 Log: Untested (since SPDY/2 is obsolete and unsupported by current browsers) migration of SPDY proxy from BIO to NIO. Modified: tomcat/trunk/java/org/apache/coyote/spdy/SpdyProxyProtocol.java Modified: tomcat/trunk/java/org/apache/coyote/spdy/SpdyProxyProtocol.java URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/coyote/spdy/SpdyProxyProtocol.java?rev=1636588&r1=1636587&r2=1636588&view=diff == --- tomcat/trunk/java/org/apache/coyote/spdy/SpdyProxyProtocol.java (original) +++ tomcat/trunk/java/org/apache/coyote/spdy/SpdyProxyProtocol.java Tue Nov 4 14:34:29 2014 @@ -17,7 +17,9 @@ package org.apache.coyote.spdy; import java.io.IOException; -import java.net.Socket; +import java.nio.channels.SocketChannel; + +import javax.net.ssl.SSLEngine; import org.apache.coyote.AbstractProtocol; import org.apache.coyote.ajp.Constants; @@ -29,7 +31,8 @@ import org.apache.tomcat.spdy.SpdyContex import org.apache.tomcat.spdy.SpdyContext.SpdyHandler; import org.apache.tomcat.spdy.SpdyStream; import org.apache.tomcat.util.net.AbstractEndpoint.Handler; -import org.apache.tomcat.util.net.JIoEndpoint; +import org.apache.tomcat.util.net.NioChannel; +import org.apache.tomcat.util.net.NioEndpoint; import org.apache.tomcat.util.net.SSLImplementation; import org.apache.tomcat.util.net.SocketStatus; import org.apache.tomcat.util.net.SocketWrapper; @@ -40,7 +43,7 @@ import org.apache.tomcat.util.net.Socket * a reverse proxy ( apache, etc ). * * To configure: - *+ * * * To test, use * chrome --use-spdy=no-compress,no-ssl [--enable-websocket-over-spdy] @@ -48,18 +51,23 @@ import org.apache.tomcat.util.net.Socket * TODO: Remote information (client ip, certs, etc ) will be sent in X- headers. * TODO: if spdy->spdy proxy, info about original spdy stream for pushes. * + * TODO: This proxy implementation was refactored to use NIO instead of BIO. It + * is untested as SPDY/2 is now obsolete and is not supported by current + * browsers. This code should be reviewed when work starts on the HTTP/2 + * implementation. + * */ -public class SpdyProxyProtocol extends AbstractProtocol { +public class SpdyProxyProtocol extends AbstractProtocol { private static final Log log = LogFactory.getLog(SpdyProxyProtocol.class); -private final JIoEndpoint.Handler cHandler = new TomcatJioHandler(); +private final NioEndpoint.Handler cHandler = new TomcatNioHandler(); private SpdyContext spdyContext; private boolean compress = false; public SpdyProxyProtocol() { -endpoint = new JIoEndpoint(); -((JIoEndpoint) endpoint).setHandler(cHandler); +endpoint = new NioEndpoint(); +((NioEndpoint) endpoint).setHandler(cHandler); setSoLinger(Constants.DEFAULT_CONNECTION_LINGER); setSoTimeout(Constants.DEFAULT_CONNECTION_TIMEOUT); setTcpNoDelay(Constants.DEFAULT_TCP_NO_DELAY); @@ -72,7 +80,7 @@ public class SpdyProxyProtocol extends A @Override protected String getNamePrefix() { -return "spdy2-jio"; +return "spdy2-nio"; } @Override @@ -93,7 +101,7 @@ public class SpdyProxyProtocol extends A spdyContext.setHandler(new SpdyHandler() { @Override public void onStream(SpdyConnection con, SpdyStream ch) throws IOException { -SpdyProcessor sp = new SpdyProcessor<>(con, endpoint); +SpdyProcessor sp = new SpdyProcessor<>(con, endpoint); sp.setAdapter(getAdapter()); sp.onSynStream(ch); } @@ -110,7 +118,7 @@ public class SpdyProxyProtocol extends A this.compress = compress; } -public class TomcatJioHandler implements JIoEndpoint.Handler { +public class TomcatNioHandler implements NioEndpoint.Handler { @Override public Object getGlobal() { @@ -122,7 +130,7 @@ public class SpdyProxyProtocol extends A } @Override -public SocketState process(SocketWrapper socket, +public SocketState process(SocketWrapper socket, SocketStatus status) { spdyContext.getNetSupport().onAccept(socket.getSocket()); @@ -135,8 +143,18 @@ public class SpdyProxyProtocol extends A } @Override -public void beforeHandshake(SocketWrapper socket) { +public void release(SocketWrapper socket) { +// TODO Auto-generated method stub } +@Override +public void release(SocketChannel socket) { +// TODO Auto-generated method stub +} + +@Override +public void onC
Re: Tomcat 9 work started
On 03/11/2014 22:08, Mark Thomas wrote: > I've been spending the last hour or so looking at our current SPDY > implementation. We are going to have issues there as well. It targets > SPDY/2 which most browsers no longer support. Servlet 4.0 is targeting > HTTP/2 which is going to be roughly SPDY/4+ > > I don't know how much of the existing SPDY code is going to make sense > with HTTP/2 but I do know what we currently have is broken with most > browsers. I'm currently leaning towards excluding the current SDPY code > from the build until the connector refactoring is complete and then look > at it more closely to figure out what we can keep, what needs > refactoring and what needs to go. I found an alternative solution. I've performed an untested migration of the SPDY/2 proxy (the bit that depended on BIO) to NIO so we can leave the SPDY code alone for the initial connector refactoring and come back to it when work starts on HTTP/2. Mark - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
svn commit: r1636594 - /tomcat/trunk/test/org/apache/coyote/http11/TestGzipOutputFilter.java
Author: markt Date: Tue Nov 4 14:49:02 2014 New Revision: 1636594 URL: http://svn.apache.org/r1636594 Log: Fix comment typos Modified: tomcat/trunk/test/org/apache/coyote/http11/TestGzipOutputFilter.java Modified: tomcat/trunk/test/org/apache/coyote/http11/TestGzipOutputFilter.java URL: http://svn.apache.org/viewvc/tomcat/trunk/test/org/apache/coyote/http11/TestGzipOutputFilter.java?rev=1636594&r1=1636593&r2=1636594&view=diff == --- tomcat/trunk/test/org/apache/coyote/http11/TestGzipOutputFilter.java (original) +++ tomcat/trunk/test/org/apache/coyote/http11/TestGzipOutputFilter.java Tue Nov 4 14:49:02 2014 @@ -35,7 +35,7 @@ import org.apache.tomcat.util.buf.ByteCh public class TestGzipOutputFilter { /* - * Test the interaction betwen gzip and flushing. The idea is to: 1. create + * Test the interaction between gzip and flushing. The idea is to: 1. create * a internal output buffer, response, and attach an active gzipoutputfilter * to the output buffer 2. set the output stream of the internal buffer to * be a ByteArrayOutputStream so we can inspect the output bytes 3. write a @@ -75,7 +75,7 @@ public class TestGzipOutputFilter { // out (flushed) byte[] dataFound = bos.toByteArray(); -// find out what's expected by wrting to GZIPOutputStream and close it +// find out what's expected by writing to GZIPOutputStream and close it // (to force flushing) ByteArrayOutputStream gbos = new ByteArrayOutputStream(1024); GZIPOutputStream gos = new GZIPOutputStream(gbos); - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
svn commit: r1636600 - in /tomcat/trunk/test/org/apache/coyote/http11: TestGzipOutputFilter.java filters/TestGzipOutputFilter.java filters/TesterOutputBuffer.java
Author: markt Date: Tue Nov 4 15:10:50 2014 New Revision: 1636600 URL: http://svn.apache.org/r1636600 Log: Remove dependency on BIO OutputBuffer impl Added: tomcat/trunk/test/org/apache/coyote/http11/filters/TestGzipOutputFilter.java - copied, changed from r1636598, tomcat/trunk/test/org/apache/coyote/http11/TestGzipOutputFilter.java tomcat/trunk/test/org/apache/coyote/http11/filters/TesterOutputBuffer.java - copied, changed from r1636598, tomcat/trunk/java/org/apache/coyote/http11/InternalOutputBuffer.java Removed: tomcat/trunk/test/org/apache/coyote/http11/TestGzipOutputFilter.java Copied: tomcat/trunk/test/org/apache/coyote/http11/filters/TestGzipOutputFilter.java (from r1636598, tomcat/trunk/test/org/apache/coyote/http11/TestGzipOutputFilter.java) URL: http://svn.apache.org/viewvc/tomcat/trunk/test/org/apache/coyote/http11/filters/TestGzipOutputFilter.java?p2=tomcat/trunk/test/org/apache/coyote/http11/filters/TestGzipOutputFilter.java&p1=tomcat/trunk/test/org/apache/coyote/http11/TestGzipOutputFilter.java&r1=1636598&r2=1636600&rev=1636600&view=diff == --- tomcat/trunk/test/org/apache/coyote/http11/TestGzipOutputFilter.java (original) +++ tomcat/trunk/test/org/apache/coyote/http11/filters/TestGzipOutputFilter.java Tue Nov 4 15:10:50 2014 @@ -15,7 +15,7 @@ * limitations under the License. */ -package org.apache.coyote.http11; +package org.apache.coyote.http11.filters; import java.io.ByteArrayOutputStream; import java.util.zip.GZIPOutputStream; @@ -25,7 +25,6 @@ import static org.junit.Assert.assertTru import org.junit.Test; import org.apache.coyote.Response; -import org.apache.coyote.http11.filters.GzipOutputFilter; import org.apache.tomcat.util.buf.ByteChunk; /** @@ -52,7 +51,7 @@ public class TestGzipOutputFilter { public void testFlushingWithGzip() throws Exception { // set up response, InternalOutputBuffer, and ByteArrayOutputStream Response res = new Response(); -InternalOutputBuffer iob = new InternalOutputBuffer(res, 8 * 1024); +TesterOutputBuffer iob = new TesterOutputBuffer(res, 8 * 1024); ByteArrayOutputStream bos = new ByteArrayOutputStream(); iob.outputStream = bos; res.setOutputBuffer(iob); Copied: tomcat/trunk/test/org/apache/coyote/http11/filters/TesterOutputBuffer.java (from r1636598, tomcat/trunk/java/org/apache/coyote/http11/InternalOutputBuffer.java) URL: http://svn.apache.org/viewvc/tomcat/trunk/test/org/apache/coyote/http11/filters/TesterOutputBuffer.java?p2=tomcat/trunk/test/org/apache/coyote/http11/filters/TesterOutputBuffer.java&p1=tomcat/trunk/java/org/apache/coyote/http11/InternalOutputBuffer.java&r1=1636598&r2=1636600&rev=1636600&view=diff == --- tomcat/trunk/java/org/apache/coyote/http11/InternalOutputBuffer.java (original) +++ tomcat/trunk/test/org/apache/coyote/http11/filters/TesterOutputBuffer.java Tue Nov 4 15:10:50 2014 @@ -15,7 +15,7 @@ * limitations under the License. */ -package org.apache.coyote.http11; +package org.apache.coyote.http11.filters; import java.io.IOException; import java.io.OutputStream; @@ -23,6 +23,7 @@ import java.net.Socket; import org.apache.coyote.OutputBuffer; import org.apache.coyote.Response; +import org.apache.coyote.http11.AbstractOutputBuffer; import org.apache.tomcat.util.buf.ByteChunk; import org.apache.tomcat.util.net.AbstractEndpoint; import org.apache.tomcat.util.net.SocketWrapper; @@ -32,7 +33,7 @@ import org.apache.tomcat.util.net.Socket * * @author mailto:r...@apache.org";>Remy Maucherat */ -public class InternalOutputBuffer extends AbstractOutputBuffer +public class TesterOutputBuffer extends AbstractOutputBuffer implements ByteChunk.ByteOutputChannel { // --- Constructors @@ -40,7 +41,7 @@ public class InternalOutputBuffer extend /** * Default constructor. */ -public InternalOutputBuffer(Response response, int headerBufferSize) { +public TesterOutputBuffer(Response response, int headerBufferSize) { super(response, headerBufferSize); @@ -120,14 +121,14 @@ public class InternalOutputBuffer extend // HTTP/1.1 Output Methods /** - * Send an acknowledgment. + * Send an acknowledgement. */ @Override public void sendAck() throws IOException { if (!committed) -outputStream.write(Constants.ACK_BYTES); +outputStream.write(org.apache.coyote.http11.Constants.ACK_BYTES); } - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
svn commit: r1636606 - in /tomcat/trunk/test/org/apache/coyote/http11/filters: TestGzipOutputFilter.java TesterOutputBuffer.java
Author: markt Date: Tue Nov 4 15:25:23 2014 New Revision: 1636606 URL: http://svn.apache.org/r1636606 Log: Simplify Modified: tomcat/trunk/test/org/apache/coyote/http11/filters/TestGzipOutputFilter.java tomcat/trunk/test/org/apache/coyote/http11/filters/TesterOutputBuffer.java Modified: tomcat/trunk/test/org/apache/coyote/http11/filters/TestGzipOutputFilter.java URL: http://svn.apache.org/viewvc/tomcat/trunk/test/org/apache/coyote/http11/filters/TestGzipOutputFilter.java?rev=1636606&r1=1636605&r2=1636606&view=diff == --- tomcat/trunk/test/org/apache/coyote/http11/filters/TestGzipOutputFilter.java (original) +++ tomcat/trunk/test/org/apache/coyote/http11/filters/TestGzipOutputFilter.java Tue Nov 4 15:25:23 2014 @@ -51,28 +51,26 @@ public class TestGzipOutputFilter { public void testFlushingWithGzip() throws Exception { // set up response, InternalOutputBuffer, and ByteArrayOutputStream Response res = new Response(); -TesterOutputBuffer iob = new TesterOutputBuffer(res, 8 * 1024); -ByteArrayOutputStream bos = new ByteArrayOutputStream(); -iob.outputStream = bos; -res.setOutputBuffer(iob); +TesterOutputBuffer tob = new TesterOutputBuffer(res, 8 * 1024); +res.setOutputBuffer(tob); -// set up GzipOutputFilter to attach to the InternalOutputBuffer +// set up GzipOutputFilter to attach to the TesterOutputBuffer GzipOutputFilter gf = new GzipOutputFilter(); -iob.addFilter(gf); -iob.addActiveFilter(gf); +tob.addFilter(gf); +tob.addActiveFilter(gf); // write a chunk out ByteChunk chunk = new ByteChunk(1024); byte[] d = "Hello there tomcat developers, there is a bug in JDK".getBytes(); chunk.append(d, 0, d.length); -iob.doWrite(chunk, res); +tob.doWrite(chunk, res); // flush the InternalOutputBuffer -iob.flush(); +tob.flush(); // read from the ByteArrayOutputStream to find out what's being written // out (flushed) -byte[] dataFound = bos.toByteArray(); +byte[] dataFound = tob.toByteArray(); // find out what's expected by writing to GZIPOutputStream and close it // (to force flushing) Modified: tomcat/trunk/test/org/apache/coyote/http11/filters/TesterOutputBuffer.java URL: http://svn.apache.org/viewvc/tomcat/trunk/test/org/apache/coyote/http11/filters/TesterOutputBuffer.java?rev=1636606&r1=1636605&r2=1636606&view=diff == --- tomcat/trunk/test/org/apache/coyote/http11/filters/TesterOutputBuffer.java (original) +++ tomcat/trunk/test/org/apache/coyote/http11/filters/TesterOutputBuffer.java Tue Nov 4 15:25:23 2014 @@ -17,8 +17,8 @@ package org.apache.coyote.http11.filters; +import java.io.ByteArrayOutputStream; import java.io.IOException; -import java.io.OutputStream; import java.net.Socket; import org.apache.coyote.OutputBuffer; @@ -29,12 +29,9 @@ import org.apache.tomcat.util.net.Abstra import org.apache.tomcat.util.net.SocketWrapper; /** - * Output buffer. - * - * @author mailto:r...@apache.org";>Remy Maucherat + * Output buffer for use in unit tests. This is a minimal implementation. */ -public class TesterOutputBuffer extends AbstractOutputBuffer -implements ByteChunk.ByteOutputChannel { +public class TesterOutputBuffer extends AbstractOutputBuffer { // --- Constructors @@ -42,46 +39,14 @@ public class TesterOutputBuffer extends * Default constructor. */ public TesterOutputBuffer(Response response, int headerBufferSize) { - super(response, headerBufferSize); - outputStreamOutputBuffer = new OutputStreamOutputBuffer(); - -socketBuffer = new ByteChunk(); -socketBuffer.setByteOutputChannel(this); } /** - * Underlying output stream. Note: protected to assist with unit testing - */ -protected OutputStream outputStream; - - -/** - * Socket buffer. - */ -private final ByteChunk socketBuffer; - - -/** - * Socket buffer (extra buffering to reduce number of packets sent). + * Underlying output stream. */ -private boolean useSocketBuffer = false; - - -/** - * Set the socket buffer size. - */ -@Override -public void setSocketBuffer(int socketBufferSize) { - -if (socketBufferSize > 500) { -useSocketBuffer = true; -socketBuffer.allocate(socketBufferSize, socketBufferSize); -} else { -useSocketBuffer = false; -} -} +private ByteArrayOutputStream outputStream = new ByteArrayOutputStream(); // - Public Methods @@ -89,8 +54,7 @@ public class TesterOutpu
svn commit: r1636618 - in /tomcat/trunk: ./ java/org/apache/catalina/connector/ java/org/apache/coyote/ java/org/apache/coyote/ajp/ java/org/apache/coyote/http11/ java/org/apache/coyote/http11/upgrade
Author: markt Date: Tue Nov 4 15:53:34 2014 New Revision: 1636618 URL: http://svn.apache.org/r1636618 Log: First pass at removing the BIO code. Some unused/unnecessary code remains and will be removed next. Removed: tomcat/trunk/java/org/apache/coyote/ajp/AjpProcessor.java tomcat/trunk/java/org/apache/coyote/ajp/AjpProtocol.java tomcat/trunk/java/org/apache/coyote/http11/Http11Processor.java tomcat/trunk/java/org/apache/coyote/http11/Http11Protocol.java tomcat/trunk/java/org/apache/coyote/http11/InternalInputBuffer.java tomcat/trunk/java/org/apache/coyote/http11/InternalOutputBuffer.java tomcat/trunk/java/org/apache/coyote/http11/upgrade/BioProcessor.java tomcat/trunk/java/org/apache/coyote/http11/upgrade/BioServletInputStream.java tomcat/trunk/java/org/apache/coyote/http11/upgrade/BioServletOutputStream.java tomcat/trunk/java/org/apache/tomcat/util/net/JIoEndpoint.java Modified: tomcat/trunk/BUILDING.txt tomcat/trunk/build.properties.default tomcat/trunk/build.xml tomcat/trunk/java/org/apache/catalina/connector/InputBuffer.java tomcat/trunk/java/org/apache/coyote/AbstractProtocol.java tomcat/trunk/java/org/apache/tomcat/util/net/AbstractEndpoint.java tomcat/trunk/test/org/apache/catalina/mbeans/TestRegistration.java tomcat/trunk/test/org/apache/catalina/nonblocking/TestNonBlockingAPI.java tomcat/trunk/test/org/apache/coyote/ajp/TestAbstractAjpProcessor.java tomcat/trunk/test/org/apache/tomcat/websocket/TestWebSocketFrameClientSSL.java tomcat/trunk/test/org/apache/tomcat/websocket/TestWsWebSocketContainer.java tomcat/trunk/webapps/docs/changelog.xml tomcat/trunk/webapps/docs/config/ajp.xml tomcat/trunk/webapps/docs/config/http.xml tomcat/trunk/webapps/docs/manager-howto.xml tomcat/trunk/webapps/docs/ssl-howto.xml tomcat/trunk/webapps/docs/web-socket-howto.xml Modified: tomcat/trunk/BUILDING.txt URL: http://svn.apache.org/viewvc/tomcat/trunk/BUILDING.txt?rev=1636618&r1=1636617&r2=1636618&view=diff == --- tomcat/trunk/BUILDING.txt (original) +++ tomcat/trunk/BUILDING.txt Tue Nov 4 15:53:34 2014 @@ -292,15 +292,14 @@ directory: output/build/logs -By default the testsuite is run four times to test 4 different -implementations of Tomcat connectors: BIO, NIO, NIO2 and APR. (If you are not +By default the testsuite is run three times to test 3 different +implementations of Tomcat connectors: NIO, NIO2 and APR. (If you are not familiar with Tomcat connectors, see config/http.html in documentation for details). -The 4 runs are enabled and disabled individually by the following +The 3 runs are enabled and disabled individually by the following properties, which all are "true" by default: -execute.test.bio=true execute.test.nio=true execute.test.nio2=true execute.test.apr=true Modified: tomcat/trunk/build.properties.default URL: http://svn.apache.org/viewvc/tomcat/trunk/build.properties.default?rev=1636618&r1=1636617&r2=1636618&view=diff == --- tomcat/trunk/build.properties.default (original) +++ tomcat/trunk/build.properties.default Tue Nov 4 15:53:34 2014 @@ -32,7 +32,6 @@ version.suffix=-dev # - Build control flags - # Note enabling validation uses Checkstyle which is LGPL licensed execute.validate=false -execute.test.bio=true execute.test.nio=true execute.test.nio2=true # Still requires APR/native library to be present Modified: tomcat/trunk/build.xml URL: http://svn.apache.org/viewvc/tomcat/trunk/build.xml?rev=1636618&r1=1636617&r2=1636618&view=diff == --- tomcat/trunk/build.xml (original) +++ tomcat/trunk/build.xml Tue Nov 4 15:53:34 2014 @@ -1337,17 +1337,11 @@ + depends="test-nio,test-nio2,test-apr,cobertura-report" > - - - - http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/catalina/connector/InputBuffer.java?rev=1636618&r1=1636617&r2=1636618&view=diff == --- tomcat/trunk/java/org/apache/catalina/connector/InputBuffer.java (original) +++ tomcat/trunk/java/org/apache/catalina/connector/InputBuffer.java Tue Nov 4 15:53:34 2014 @@ -284,8 +284,6 @@ public class InputBuffer extends Reader if (coyoteRequest.getReadListener() == null) { throw new IllegalStateException("not in non blocking mode."); } -// Need to check is finished before we check available() as BIO always -// returns 1 for isAvailable() if (isFinished()) { // If this is a non-container thread, need to trigger a read // which will eventually lead to a call to onAllDataRead() via a Modified: tomcat/trunk/java/org/apache/coyote
Re: Tomcat 9 work started
Filip, On 11/3/14 10:15 PM, Filip Hanik wrote: > I honestly don't see the value of keeping BIO around. At this point in > time, there can be little else other than an emotional attachment to it. As > mentioned in this thread, the APIs and need for more functionality in the > connectors have rendered the BIO connector obsolete. If we believe that a > Tomcat 9 user would choose BIO for stability (which may have been the case > early NIO days), then the solution to that is to fix the NIO connector. The > solution should not be supporting the BIO with hacks. > > I don't feel this thread has provided any real use cases that would justify > BIO remaining alive. > > For example: > >> We use the BIO AJP connector because we don't need >> to handle huge numbers of requests and deal with keepalive timeouts and >> all that stuff: the web server handles that for us > > ok, fair enough. I actually don't know the state of the NIO AJP connector. > And I don't know what level of async or HTTP2 features AJP would even > support. > >> The NIO sim-blocking (which being practical, in contrast to the >> impractical sim-non-blocking achieved by untold evils in the BIO >> connector) is kind of hacky and burns unnecessary CPU time when no >> asynchronous operations are involved. > > Seems to be a contradiction to the previous statement where load was not an > issue. I truly don't see how these extra CPU cycles are an issue. And if > measured, would they even be noticeable. No, what I meant was that connection-load was not an issue (e.g. we wouldn't have to configure 1M connections just to support keepalive timeouts, etc. that plague BIO configurations). Each individual NIO thread takes more CPU resources due to the sim-blocking that is required to perform blocking I/O for the original stream-based APIs for servlets. The testing that jfclere and I did and presented at last year's ApacheCon NA showed a detectible difference in CPU load for the NIO versus BIO connectors for the same real load (req/sec). We didn't do any testing to determine if that represented a real effect on other processes that needed to accomplish work, but it did have a pretty significant impact on the system's "busy" versus "idle" percentages. > Having to reimplement BIO, then add hacks around new API's seems like one > step forward two steps backwards. I agree. My proposal was to not really hack anything if at all possible. Instead, just drop BIO support for those items which require a hack. Supporting BIO for the stream-based I/O (blocking) APIs seems like it shouldn't really require Earth-moving equipment. > Sometimes it may benefit us all to embrace change I'm happy to let the BIO connectors die if nobody wants to support them. I just wanted to point-out that there are real use cases for their continued existence. (And I happen to fit into one of those use-cases :) -chris signature.asc Description: OpenPGP digital signature
svn commit: r1636631 - in /tomcat/trunk/java/org/apache: coyote/http11/ tomcat/util/net/
Author: markt Date: Tue Nov 4 16:13:55 2014 New Revision: 1636631 URL: http://svn.apache.org/r1636631 Log: With removal of BIO, all endpoints support polling Modified: tomcat/trunk/java/org/apache/coyote/http11/AbstractHttp11Processor.java tomcat/trunk/java/org/apache/coyote/http11/AbstractHttp11Protocol.java tomcat/trunk/java/org/apache/tomcat/util/net/AbstractEndpoint.java tomcat/trunk/java/org/apache/tomcat/util/net/AprEndpoint.java tomcat/trunk/java/org/apache/tomcat/util/net/Nio2Endpoint.java tomcat/trunk/java/org/apache/tomcat/util/net/NioEndpoint.java Modified: tomcat/trunk/java/org/apache/coyote/http11/AbstractHttp11Processor.java URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/coyote/http11/AbstractHttp11Processor.java?rev=1636631&r1=1636630&r2=1636631&view=diff == --- tomcat/trunk/java/org/apache/coyote/http11/AbstractHttp11Processor.java (original) +++ tomcat/trunk/java/org/apache/coyote/http11/AbstractHttp11Processor.java Tue Nov 4 16:13:55 2014 @@ -973,11 +973,7 @@ public abstract class AbstractHttp11Proc openSocket = false; sendfileInProgress = false; readComplete = true; -if (endpoint.getUsePolling()) { -keptAlive = false; -} else { -keptAlive = socketWrapper.isKeptAlive(); -} +keptAlive = false; if (disableKeepAlive()) { socketWrapper.setKeepAliveLeft(0); Modified: tomcat/trunk/java/org/apache/coyote/http11/AbstractHttp11Protocol.java URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/coyote/http11/AbstractHttp11Protocol.java?rev=1636631&r1=1636630&r2=1636631&view=diff == --- tomcat/trunk/java/org/apache/coyote/http11/AbstractHttp11Protocol.java (original) +++ tomcat/trunk/java/org/apache/coyote/http11/AbstractHttp11Protocol.java Tue Nov 4 16:13:55 2014 @@ -16,7 +16,6 @@ */ package org.apache.coyote.http11; - import org.apache.coyote.AbstractProtocol; public abstract class AbstractHttp11Protocol extends AbstractProtocol { Modified: tomcat/trunk/java/org/apache/tomcat/util/net/AbstractEndpoint.java URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/tomcat/util/net/AbstractEndpoint.java?rev=1636631&r1=1636630&r2=1636631&view=diff == --- tomcat/trunk/java/org/apache/tomcat/util/net/AbstractEndpoint.java (original) +++ tomcat/trunk/java/org/apache/tomcat/util/net/AbstractEndpoint.java Tue Nov 4 16:13:55 2014 @@ -821,7 +821,6 @@ public abstract class AbstractEndpointhttp://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/tomcat/util/net/AprEndpoint.java?rev=1636631&r1=1636630&r2=1636631&view=diff == --- tomcat/trunk/java/org/apache/tomcat/util/net/AprEndpoint.java (original) +++ tomcat/trunk/java/org/apache/tomcat/util/net/AprEndpoint.java Tue Nov 4 16:13:55 2014 @@ -159,10 +159,6 @@ public class AprEndpoint extends Abstrac public boolean getUseSendfile() { return useSendfile; } -@Override -public boolean getUsePolling() { return true; } // Always supported - - /** * Sendfile thread count. */ Modified: tomcat/trunk/java/org/apache/tomcat/util/net/Nio2Endpoint.java URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/tomcat/util/net/Nio2Endpoint.java?rev=1636631&r1=1636630&r2=1636631&view=diff == --- tomcat/trunk/java/org/apache/tomcat/util/net/Nio2Endpoint.java (original) +++ tomcat/trunk/java/org/apache/tomcat/util/net/Nio2Endpoint.java Tue Nov 4 16:13:55 2014 @@ -151,9 +151,6 @@ public class Nio2Endpoint extends Abstra public Handler getHandler() { return handler; } -@Override -public boolean getUsePolling() { return true; } // Always supported - public void setSocketProperties(SocketProperties socketProperties) { this.socketProperties = socketProperties; } Modified: tomcat/trunk/java/org/apache/tomcat/util/net/NioEndpoint.java URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/tomcat/util/net/NioEndpoint.java?rev=1636631&r1=1636630&r2=1636631&view=diff == --- tomcat/trunk/java/org/apache/tomcat/util/net/NioEndpoint.java (original) +++ tomcat/trunk/java/org/apache/tomcat/util/net/NioEndpoint.java Tue Nov 4 16:13:55 2014 @@ -183,10 +183,6 @@ public class NioEndpoint extends Abstrac public Handler getHandler() { return handler; } -@Override -public boolean getUsePolling() { return true; } // Always supported - - /** * Poller thread count. */ - To un
[Bug 54618] Add filter implementing HTTP Strict Transport Security (HSTS) [PATCH]
https://issues.apache.org/bugzilla/show_bug.cgi?id=54618 Matafagafo changed: What|Removed |Added CC||matafag...@yahoo.com -- You are receiving this mail because: You are the assignee for the bug. - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
svn commit: r1636730 - /tomcat/trunk/java/org/apache/catalina/startup/Tomcat.java
Author: markt Date: Tue Nov 4 20:49:52 2014 New Revision: 1636730 URL: http://svn.apache.org/r1636730 Log: Remove commented out code Modified: tomcat/trunk/java/org/apache/catalina/startup/Tomcat.java Modified: tomcat/trunk/java/org/apache/catalina/startup/Tomcat.java URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/catalina/startup/Tomcat.java?rev=1636730&r1=1636729&r2=1636730&view=diff == --- tomcat/trunk/java/org/apache/catalina/startup/Tomcat.java (original) +++ tomcat/trunk/java/org/apache/catalina/startup/Tomcat.java Tue Nov 4 20:49:52 2014 @@ -404,7 +404,6 @@ public class Tomcat { // and for the use case the speed benefit wouldn't matter. connector = new Connector("HTTP/1.1"); -// connector = new Connector("org.apache.coyote.http11.Http11Protocol"); connector.setPort(port); service.addConnector( connector ); return connector; @@ -645,7 +644,7 @@ public class Tomcat { } static final String[] silences = new String[] { -"org.apache.coyote.http11.Http11Protocol", +"org.apache.coyote.http11.Http11NioProtocol", "org.apache.catalina.core.StandardService", "org.apache.catalina.core.StandardEngine", "org.apache.catalina.startup.ContextConfig", - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
svn commit: r1636748 - /tomcat/trunk/java/org/apache/tomcat/util/net/NioEndpoint.java
Author: markt Date: Tue Nov 4 21:59:03 2014 New Revision: 1636748 URL: http://svn.apache.org/r1636748 Log: Restore "cometNotify" that is part of the callback mechanism used in the async code as well as Comet Modified: tomcat/trunk/java/org/apache/tomcat/util/net/NioEndpoint.java Modified: tomcat/trunk/java/org/apache/tomcat/util/net/NioEndpoint.java URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/tomcat/util/net/NioEndpoint.java?rev=1636748&r1=1636747&r2=1636748&view=diff == --- tomcat/trunk/java/org/apache/tomcat/util/net/NioEndpoint.java (original) +++ tomcat/trunk/java/org/apache/tomcat/util/net/NioEndpoint.java Tue Nov 4 21:59:03 2014 @@ -605,6 +605,7 @@ public class NioEndpoint extends Abstrac if (attachment == null) { return false; } +attachment.setCometNotify(false); //will get reset upon next reg SocketProcessor sc = processorCache.pop(); if ( sc == null ) sc = new SocketProcessor(attachment, status); else sc.reset(attachment, status); @@ -787,12 +788,18 @@ public class NioEndpoint extends Abstrac final KeyAttachment att = (KeyAttachment) key.attachment(); if ( att!=null ) { //handle callback flag +if ((interestOps & OP_CALLBACK) == OP_CALLBACK ) { +att.setCometNotify(true); +} else { +att.setCometNotify(false); +} interestOps = (interestOps & (~OP_CALLBACK));//remove the callback flag att.access();//to prevent timeout //we are registering the key to start with, reset the fairness counter. int ops = key.interestOps() | interestOps; att.interestOps(ops); -key.interestOps(ops); +if (att.getCometNotify()) key.interestOps(0); +else key.interestOps(ops); } else { cancel = true; } @@ -1256,6 +1263,12 @@ public class NioEndpoint extends Abstrac cancelledKey(key); //we don't support any keys without attachments } else if ( ka.getError() ) { cancelledKey(key);//TODO this is not yet being used +} else if (ka.getCometNotify() ) { +ka.setCometNotify(false); +int ops = ka.interestOps() & ~OP_CALLBACK; +reg(key,ka,0);//avoid multiple calls, this gets re-registered after invocation +ka.interestOps(ops); +if (!processSocket(ka, SocketStatus.OPEN_READ, true)) processSocket(ka, SocketStatus.DISCONNECT, true); } else if ((ka.interestOps()&SelectionKey.OP_READ) == SelectionKey.OP_READ || (ka.interestOps()&SelectionKey.OP_WRITE) == SelectionKey.OP_WRITE) { //only timeout sockets that we are waiting for a read from @@ -1315,6 +1328,7 @@ public class NioEndpoint extends Abstrac public void reset(Poller poller, NioChannel channel, long soTimeout) { super.reset(channel, soTimeout); +cometNotify = false; interestOps = 0; this.poller = poller; sendfileData = null; @@ -1346,6 +1360,8 @@ public class NioEndpoint extends Abstrac public Poller getPoller() { return poller;} public void setPoller(Poller poller){this.poller = poller;} +public void setCometNotify(boolean notify) { this.cometNotify = notify; } +public boolean getCometNotify() { return cometNotify; } public int interestOps() { return interestOps;} public int interestOps(int ops) { this.interestOps = ops; return ops; } public CountDownLatch getReadLatch() { return readLatch; } @@ -1386,6 +1402,7 @@ public class NioEndpoint extends Abstrac private Poller poller = null; private int interestOps = 0; +private boolean cometNotify = false; private CountDownLatch readLatch = null; private CountDownLatch writeLatch = null; private SendfileData sendfileData = null; - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
svn commit: r1636751 - /tomcat/trunk/java/org/apache/tomcat/util/net/NioEndpoint.java
Author: markt Date: Tue Nov 4 22:00:50 2014 New Revision: 1636751 URL: http://svn.apache.org/r1636751 Log: s/cometNotify/callBackNotify/ since this is not Comet specific Modified: tomcat/trunk/java/org/apache/tomcat/util/net/NioEndpoint.java Modified: tomcat/trunk/java/org/apache/tomcat/util/net/NioEndpoint.java URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/tomcat/util/net/NioEndpoint.java?rev=1636751&r1=1636750&r2=1636751&view=diff == --- tomcat/trunk/java/org/apache/tomcat/util/net/NioEndpoint.java (original) +++ tomcat/trunk/java/org/apache/tomcat/util/net/NioEndpoint.java Tue Nov 4 22:00:50 2014 @@ -605,7 +605,7 @@ public class NioEndpoint extends Abstrac if (attachment == null) { return false; } -attachment.setCometNotify(false); //will get reset upon next reg +attachment.setCallBackNotify(false); //will get reset upon next reg SocketProcessor sc = processorCache.pop(); if ( sc == null ) sc = new SocketProcessor(attachment, status); else sc.reset(attachment, status); @@ -789,16 +789,16 @@ public class NioEndpoint extends Abstrac if ( att!=null ) { //handle callback flag if ((interestOps & OP_CALLBACK) == OP_CALLBACK ) { -att.setCometNotify(true); +att.setCallBackNotify(true); } else { -att.setCometNotify(false); +att.setCallBackNotify(false); } interestOps = (interestOps & (~OP_CALLBACK));//remove the callback flag att.access();//to prevent timeout //we are registering the key to start with, reset the fairness counter. int ops = key.interestOps() | interestOps; att.interestOps(ops); -if (att.getCometNotify()) key.interestOps(0); +if (att.getCallBackNotify()) key.interestOps(0); else key.interestOps(ops); } else { cancel = true; @@ -1263,8 +1263,8 @@ public class NioEndpoint extends Abstrac cancelledKey(key); //we don't support any keys without attachments } else if ( ka.getError() ) { cancelledKey(key);//TODO this is not yet being used -} else if (ka.getCometNotify() ) { -ka.setCometNotify(false); +} else if (ka.getCallBackNotify() ) { +ka.setCallBackNotify(false); int ops = ka.interestOps() & ~OP_CALLBACK; reg(key,ka,0);//avoid multiple calls, this gets re-registered after invocation ka.interestOps(ops); @@ -1328,7 +1328,7 @@ public class NioEndpoint extends Abstrac public void reset(Poller poller, NioChannel channel, long soTimeout) { super.reset(channel, soTimeout); -cometNotify = false; +callBackNotify = false; interestOps = 0; this.poller = poller; sendfileData = null; @@ -1360,8 +1360,8 @@ public class NioEndpoint extends Abstrac public Poller getPoller() { return poller;} public void setPoller(Poller poller){this.poller = poller;} -public void setCometNotify(boolean notify) { this.cometNotify = notify; } -public boolean getCometNotify() { return cometNotify; } +public void setCallBackNotify(boolean notify) { this.callBackNotify = notify; } +public boolean getCallBackNotify() { return callBackNotify; } public int interestOps() { return interestOps;} public int interestOps(int ops) { this.interestOps = ops; return ops; } public CountDownLatch getReadLatch() { return readLatch; } @@ -1402,7 +1402,7 @@ public class NioEndpoint extends Abstrac private Poller poller = null; private int interestOps = 0; -private boolean cometNotify = false; +private boolean callBackNotify = false; private CountDownLatch readLatch = null; private CountDownLatch writeLatch = null; private SendfileData sendfileData = null; - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
[Bug 57142] JSP 2.3 & EL 3.0 - %page import directive & EL ImportHandler
https://issues.apache.org/bugzilla/show_bug.cgi?id=57142 --- Comment #6 from Arthur Fiedler --- Thanks Mark. I'll add them tonight -- You are receiving this mail because: You are the assignee for the bug. - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
Re: [VOTE] Release Apache Tomcat 8.0.15
Mark, On 11/3/14 4:51 AM, Mark Thomas wrote: > The proposed Apache Tomcat 8.0.15 release is now available for voting. > > The main changes since 8.0.14 are: > - Add support for RFC6265 cookie parsing and generation. This is > currently disabled by default and may be enabled via the > CookieProcessor element of a Context. > - Add pluggable password derivation support to the Realms via the new > CredentialHandler interface. > - Add support for TLSv1.1 and TLSv1.2 for APR connector. Based upon a > patch by Marcel Šebek. This feature requires Tomcat Native library > 1.1.32 or later. > - Disable SSLv3 by default for all HTTPS connectors > > There is also a large than usual collection of bug fixes, new features > and performance improvements. For full details, see the changelog: > http://svn.us.apache.org/repos/asf/tomcat/trunk/webapps/docs/changelog.xml > > It can be obtained from: > https://dist.apache.org/repos/dist/dev/tomcat/tomcat-8/v8.0.15/ > The Maven staging repo is: > https://repository.apache.org/content/repositories/orgapachetomcat-1025/ > The svn tag is: > http://svn.apache.org/repos/asf/tomcat/tc8.0.x/tags/TOMCAT_8_0_15/ > > The proposed 8.0.15 release is: > [ ] Broken - do not release > [X] Stable - go ahead and release as 8.0.14 Details: Testing environment: Debian Linux kernel 2.6.32 x86_64 architecture, Oracle Java(TM) SE Runtime Environment (build 1.7.0_67-b01) Signatures are good Source and tarball contain the same things tcnative builds properly without warnings on GCC 4.7.2 Tomcat builds with minor warnings Unit tests build with minor warnings Unit tests pass with expected failures (clustering is known to be unsupported in my environment) Test web applications work in development environment SSL testing APR connector default (SSLProtocol="all") lacks support for SSLv3: cannot handshake APR connector respects choice of individual protocol (e.g. SSLv3, TLSv1.1, etc.) and always prefers the highest protocol choice available JSSE connectors (tested NIO in this case) default (sslProtocol="TLS") lacks support for SSLv3: cannot handshake JSSE connectors (tested NIO in this case) respect choice of individual protocol and always prefers the highest protocol choice available -chris signature.asc Description: OpenPGP digital signature
svn commit: r1636778 - /tomcat/trunk/test/org/apache/catalina/startup/TomcatBaseTest.java
Author: markt Date: Tue Nov 4 23:41:15 2014 New Revision: 1636778 URL: http://svn.apache.org/r1636778 Log: Reduce the default client timeout and make it easier to configure Modified: tomcat/trunk/test/org/apache/catalina/startup/TomcatBaseTest.java Modified: tomcat/trunk/test/org/apache/catalina/startup/TomcatBaseTest.java URL: http://svn.apache.org/viewvc/tomcat/trunk/test/org/apache/catalina/startup/TomcatBaseTest.java?rev=1636778&r1=1636777&r2=1636778&view=diff == --- tomcat/trunk/test/org/apache/catalina/startup/TomcatBaseTest.java (original) +++ tomcat/trunk/test/org/apache/catalina/startup/TomcatBaseTest.java Tue Nov 4 23:41:15 2014 @@ -61,6 +61,7 @@ import org.apache.tomcat.util.buf.ByteCh * don't have to keep writing the cleanup code. */ public abstract class TomcatBaseTest extends LoggingBaseTest { +private static final int DEFAULT_CLIENT_TIMEOUT_MS = 300_000; private Tomcat tomcat; private boolean accessLogEnabled = false; @@ -247,13 +248,13 @@ public abstract class TomcatBaseTest ext public static int headUrl(String path, ByteChunk out, Map> resHead) throws IOException { -return methodUrl(path, out, 100, null, resHead, "HEAD"); +return methodUrl(path, out, DEFAULT_CLIENT_TIMEOUT_MS, null, resHead, "HEAD"); } public static int getUrl(String path, ByteChunk out, Map> reqHead, Map> resHead) throws IOException { -return getUrl(path, out, 100, reqHead, resHead); +return getUrl(path, out, DEFAULT_CLIENT_TIMEOUT_MS, reqHead, resHead); } public static int getUrl(String path, ByteChunk out, int readTimeout, - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
svn commit: r1636779 - /tomcat/trunk/test/org/apache/tomcat/util/net/jsse/TesterBug50640SslImpl.java
Author: markt Date: Tue Nov 4 23:41:19 2014 New Revision: 1636779 URL: http://svn.apache.org/r1636779 Log: Switch to testing the NIO/NIO2 approach to using JSSEImplementation Modified: tomcat/trunk/test/org/apache/tomcat/util/net/jsse/TesterBug50640SslImpl.java Modified: tomcat/trunk/test/org/apache/tomcat/util/net/jsse/TesterBug50640SslImpl.java URL: http://svn.apache.org/viewvc/tomcat/trunk/test/org/apache/tomcat/util/net/jsse/TesterBug50640SslImpl.java?rev=1636779&r1=1636778&r2=1636779&view=diff == --- tomcat/trunk/test/org/apache/tomcat/util/net/jsse/TesterBug50640SslImpl.java (original) +++ tomcat/trunk/test/org/apache/tomcat/util/net/jsse/TesterBug50640SslImpl.java Tue Nov 4 23:41:19 2014 @@ -17,24 +17,21 @@ package org.apache.tomcat.util.net.jsse; import org.apache.tomcat.util.net.AbstractEndpoint; -import org.apache.tomcat.util.net.ServerSocketFactory; +import org.apache.tomcat.util.net.SSLUtil; public class TesterBug50640SslImpl extends JSSEImplementation { public static final String PROPERTY_NAME = "bug50640"; public static final String PROPERTY_VALUE = "pass"; -@Override -public ServerSocketFactory getServerSocketFactory( -AbstractEndpoint endpoint) { -// Check the custom attribute is visible & correcly set +@Override +public SSLUtil getSSLUtil(AbstractEndpoint endpoint) { String flag = endpoint.getProperty(PROPERTY_NAME); if (PROPERTY_VALUE.equals(flag)) { -return super.getServerSocketFactory(endpoint); +return super.getSSLUtil(endpoint); } else { return null; } } - } - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
svn commit: r1636781 - in /tomcat/trunk/java/org/apache/tomcat/util/net: DefaultServerSocketFactory.java SSLImplementation.java ServerSocketFactory.java jsse/JSSEImplementation.java jsse/JSSESocketFac
Author: markt Date: Tue Nov 4 23:41:30 2014 New Revision: 1636781 URL: http://svn.apache.org/r1636781 Log: Remove BIo specific JSSE code Removed: tomcat/trunk/java/org/apache/tomcat/util/net/DefaultServerSocketFactory.java tomcat/trunk/java/org/apache/tomcat/util/net/ServerSocketFactory.java Modified: tomcat/trunk/java/org/apache/tomcat/util/net/SSLImplementation.java tomcat/trunk/java/org/apache/tomcat/util/net/jsse/JSSEImplementation.java tomcat/trunk/java/org/apache/tomcat/util/net/jsse/JSSESocketFactory.java Modified: tomcat/trunk/java/org/apache/tomcat/util/net/SSLImplementation.java URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/tomcat/util/net/SSLImplementation.java?rev=1636781&r1=1636780&r2=1636781&view=diff == --- tomcat/trunk/java/org/apache/tomcat/util/net/SSLImplementation.java (original) +++ tomcat/trunk/java/org/apache/tomcat/util/net/SSLImplementation.java Tue Nov 4 23:41:30 2014 @@ -17,8 +17,6 @@ package org.apache.tomcat.util.net; -import java.net.Socket; - import javax.net.ssl.SSLSession; /* SSLImplementation: @@ -80,11 +78,6 @@ public abstract class SSLImplementation public abstract String getImplementationName(); -public abstract ServerSocketFactory getServerSocketFactory( -AbstractEndpoint endpoint); - -public abstract SSLSupport getSSLSupport(Socket sock); - public abstract SSLSupport getSSLSupport(SSLSession session); public abstract SSLUtil getSSLUtil(AbstractEndpoint ep); Modified: tomcat/trunk/java/org/apache/tomcat/util/net/jsse/JSSEImplementation.java URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/tomcat/util/net/jsse/JSSEImplementation.java?rev=1636781&r1=1636780&r2=1636781&view=diff == --- tomcat/trunk/java/org/apache/tomcat/util/net/jsse/JSSEImplementation.java (original) +++ tomcat/trunk/java/org/apache/tomcat/util/net/jsse/JSSEImplementation.java Tue Nov 4 23:41:30 2014 @@ -14,19 +14,14 @@ * See the License for the specific language governing permissions and * limitations under the License. */ - package org.apache.tomcat.util.net.jsse; -import java.net.Socket; - import javax.net.ssl.SSLSession; -import javax.net.ssl.SSLSocket; import org.apache.tomcat.util.net.AbstractEndpoint; import org.apache.tomcat.util.net.SSLImplementation; import org.apache.tomcat.util.net.SSLSupport; import org.apache.tomcat.util.net.SSLUtil; -import org.apache.tomcat.util.net.ServerSocketFactory; /* JSSEImplementation: @@ -43,16 +38,6 @@ public class JSSEImplementation extends } @Override -public ServerSocketFactory getServerSocketFactory(AbstractEndpoint endpoint) { -return new JSSESocketFactory(endpoint); -} - -@Override -public SSLSupport getSSLSupport(Socket s) { -return new JSSESupport((SSLSocket) s); -} - -@Override public SSLSupport getSSLSupport(SSLSession session) { return new JSSESupport(session); } Modified: tomcat/trunk/java/org/apache/tomcat/util/net/jsse/JSSESocketFactory.java URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/tomcat/util/net/jsse/JSSESocketFactory.java?rev=1636781&r1=1636780&r2=1636781&view=diff == --- tomcat/trunk/java/org/apache/tomcat/util/net/jsse/JSSESocketFactory.java (original) +++ tomcat/trunk/java/org/apache/tomcat/util/net/jsse/JSSESocketFactory.java Tue Nov 4 23:41:30 2014 @@ -22,10 +22,7 @@ import java.io.FileInputStream; import java.io.FileNotFoundException; import java.io.IOException; import java.io.InputStream; -import java.net.InetAddress; import java.net.ServerSocket; -import java.net.Socket; -import java.net.SocketException; import java.security.KeyManagementException; import java.security.KeyStore; import java.security.NoSuchAlgorithmException; @@ -54,9 +51,7 @@ import javax.net.ssl.SSLContext; import javax.net.ssl.SSLException; import javax.net.ssl.SSLServerSocket; import javax.net.ssl.SSLServerSocketFactory; -import javax.net.ssl.SSLSession; import javax.net.ssl.SSLSessionContext; -import javax.net.ssl.SSLSocket; import javax.net.ssl.TrustManager; import javax.net.ssl.TrustManagerFactory; import javax.net.ssl.X509KeyManager; @@ -64,7 +59,6 @@ import javax.net.ssl.X509KeyManager; import org.apache.tomcat.util.net.AbstractEndpoint; import org.apache.tomcat.util.net.Constants; import org.apache.tomcat.util.net.SSLUtil; -import org.apache.tomcat.util.net.ServerSocketFactory; import org.apache.tomcat.util.net.jsse.openssl.OpenSSLCipherConfigurationParser; import org.apache.tomcat.util.res.StringManager; @@ -80,7 +74,7 @@ import org.apache.tomcat.util.res.String * @author EKR -- renamed to JSSESocketFactory * @author Jan Luehe */ -public class JSSESocketFactory implements S
svn commit: r1636780 - in /tomcat/trunk/java/org/apache/coyote/http11: Http11AprProtocol.java Http11Nio2Protocol.java Http11NioProtocol.java
Author: markt Date: Tue Nov 4 23:41:24 2014 New Revision: 1636780 URL: http://svn.apache.org/r1636780 Log: Tweak connector names to make it clearer if SSL has been enabled. Modified: tomcat/trunk/java/org/apache/coyote/http11/Http11AprProtocol.java tomcat/trunk/java/org/apache/coyote/http11/Http11Nio2Protocol.java tomcat/trunk/java/org/apache/coyote/http11/Http11NioProtocol.java Modified: tomcat/trunk/java/org/apache/coyote/http11/Http11AprProtocol.java URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/coyote/http11/Http11AprProtocol.java?rev=1636780&r1=1636779&r2=1636780&view=diff == --- tomcat/trunk/java/org/apache/coyote/http11/Http11AprProtocol.java (original) +++ tomcat/trunk/java/org/apache/coyote/http11/Http11AprProtocol.java Tue Nov 4 23:41:24 2014 @@ -200,7 +200,11 @@ public class Http11AprProtocol extends A @Override protected String getNamePrefix() { -return ("http-apr"); +if (isSSLEnabled()) { +return ("https-apr"); +} else { +return ("http-apr"); +} } Modified: tomcat/trunk/java/org/apache/coyote/http11/Http11Nio2Protocol.java URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/coyote/http11/Http11Nio2Protocol.java?rev=1636780&r1=1636779&r2=1636780&view=diff == --- tomcat/trunk/java/org/apache/coyote/http11/Http11Nio2Protocol.java (original) +++ tomcat/trunk/java/org/apache/coyote/http11/Http11Nio2Protocol.java Tue Nov 4 23:41:24 2014 @@ -119,7 +119,11 @@ public class Http11Nio2Protocol extends @Override protected String getNamePrefix() { -return ("http-nio2"); +if (isSSLEnabled()) { +return ("https-nio2"); +} else { +return ("http-nio2"); +} } Modified: tomcat/trunk/java/org/apache/coyote/http11/Http11NioProtocol.java URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/coyote/http11/Http11NioProtocol.java?rev=1636780&r1=1636779&r2=1636780&view=diff == --- tomcat/trunk/java/org/apache/coyote/http11/Http11NioProtocol.java (original) +++ tomcat/trunk/java/org/apache/coyote/http11/Http11NioProtocol.java Tue Nov 4 23:41:24 2014 @@ -140,7 +140,11 @@ public class Http11NioProtocol extends A @Override protected String getNamePrefix() { -return ("http-nio"); +if (isSSLEnabled()) { +return ("https-nio"); +} else { +return ("http-nio"); +} } - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
[GUMP@vmgump]: Project tomcat-trunk-validate-eoln (in module tomcat-trunk) failed
To whom it may engage... This is an automated request, but not an unsolicited one. For more information please visit http://gump.apache.org/nagged.html, and/or contact the folk at gene...@gump.apache.org. Project tomcat-trunk-validate-eoln has an issue affecting its community integration. This issue affects 1 projects, and has been outstanding for 5 runs. The current state of this project is 'Failed', with reason 'Build Failed'. For reference only, the following projects are affected by this: - tomcat-trunk-validate-eoln : Tomcat 9.x, a web server implementing the Java Servlet 4.0, ... Full details are available at: http://vmgump.apache.org/gump/public/tomcat-trunk/tomcat-trunk-validate-eoln/index.html That said, some information snippets are provided here. The following annotations (debug/informational/warning/error messages) were provided: -INFO- Failed with reason build failed The following work was performed: http://vmgump.apache.org/gump/public/tomcat-trunk/tomcat-trunk-validate-eoln/gump_work/build_tomcat-trunk_tomcat-trunk-validate-eoln.html Work Name: build_tomcat-trunk_tomcat-trunk-validate-eoln (Type: Build) Work ended in a state of : Failed Elapsed: 1 sec Command Line: /usr/lib/jvm/java-7-oracle/bin/java -Djava.awt.headless=true -Dbuild.sysclasspath=only org.apache.tools.ant.Main -Dgump.merge=/srv/gump/public/gump/work/merge.xml validate-eoln [Working Directory: /srv/gump/public/workspace/tomcat-trunk] CLASSPATH: /usr/lib/jvm/java-7-oracle/lib/tools.jar:/srv/gump/public/workspace/tomcat-trunk/output/classes:/srv/gump/public/workspace/ant/dist/lib/ant.jar:/srv/gump/public/workspace/ant/dist/lib/ant-launcher.jar:/srv/gump/public/workspace/ant/dist/lib/ant-jmf.jar:/srv/gump/public/workspace/ant/dist/lib/ant-junit.jar:/srv/gump/public/workspace/ant/dist/lib/ant-junit4.jar:/srv/gump/public/workspace/ant/dist/lib/ant-swing.jar:/srv/gump/public/workspace/ant/dist/lib/ant-apache-resolver.jar:/srv/gump/public/workspace/ant/dist/lib/ant-apache-xalan2.jar:/srv/gump/public/workspace/xml-commons/java/build/resolver.jar - Buildfile: /srv/gump/public/workspace/tomcat-trunk/build.xml build-prepare: [mkdir] Created dir: /srv/gump/public/workspace/tomcat-trunk/output/classes [mkdir] Created dir: /srv/gump/public/workspace/tomcat-trunk/output/build [mkdir] Created dir: /srv/gump/public/workspace/tomcat-trunk/output/build/bin [mkdir] Created dir: /srv/gump/public/workspace/tomcat-trunk/output/build/conf [mkdir] Created dir: /srv/gump/public/workspace/tomcat-trunk/output/build/lib [mkdir] Created dir: /srv/gump/public/workspace/tomcat-trunk/output/build/logs [mkdir] Created dir: /srv/gump/public/workspace/tomcat-trunk/output/build/temp [mkdir] Created dir: /srv/gump/public/workspace/tomcat-trunk/output/build/webapps compile-prepare: [copy] Copying 1 file to /srv/gump/public/workspace/tomcat-trunk/java/org/apache/catalina/startup [copy] Copying 1 file to /srv/gump/public/workspace/tomcat-trunk/webapps/docs validate-eoln: [javac] Compiling 1 source file to /srv/gump/public/workspace/tomcat-trunk/output/classes [javac] javac: invalid target release: 1.8 [javac] Usage: javac [javac] use -help for a list of possible options BUILD FAILED /srv/gump/public/workspace/tomcat-trunk/build.xml:600: Compile failed; see the compiler error output for details. Total time: 1 second - To subscribe to this information via syndicated feeds: - RSS: http://vmgump.apache.org/gump/public/tomcat-trunk/tomcat-trunk-validate-eoln/rss.xml - Atom: http://vmgump.apache.org/gump/public/tomcat-trunk/tomcat-trunk-validate-eoln/atom.xml == Gump Tracking Only === Produced by Apache Gump(TM) version 2.3. Gump Run 2014110547, vmgump.apache.org:vmgump:2014110547 Gump E-mail Identifier (unique within run) #1. -- Apache Gump http://gump.apache.org/ [Instance: vmgump] - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
[GUMP@vmgump]: Project tomcat-trunk (in module tomcat-trunk) failed
To whom it may engage... This is an automated request, but not an unsolicited one. For more information please visit http://gump.apache.org/nagged.html, and/or contact the folk at gene...@gump.apache.org. Project tomcat-trunk has an issue affecting its community integration. This issue affects 5 projects, and has been outstanding for 5 runs. The current state of this project is 'Failed', with reason 'Build Failed'. For reference only, the following projects are affected by this: - tomcat-trunk : Tomcat 9.x, a web server implementing the Java Servlet 4.0, ... - tomcat-trunk-test-apr : Tomcat 9.x, a web server implementing the Java Servlet 4.0, ... - tomcat-trunk-test-bio : Tomcat 9.x, a web server implementing the Java Servlet 4.0, ... - tomcat-trunk-test-nio : Tomcat 9.x, a web server implementing the Java Servlet 4.0, ... - tomcat-trunk-test-nio2 : Tomcat 9.x, a web server implementing the Java Servlet 4.0, ... Full details are available at: http://vmgump.apache.org/gump/public/tomcat-trunk/tomcat-trunk/index.html That said, some information snippets are provided here. The following annotations (debug/informational/warning/error messages) were provided: -DEBUG- Dependency on commons-daemon exists, no need to add for property commons-daemon.native.src.tgz. -DEBUG- Dependency on commons-daemon exists, no need to add for property tomcat-native.tar.gz. -DEBUG- Dependency on junit exists, no need to add for property junit.jar. -INFO- Optional dependency tomcat-trunk-validate-eoln failed with reason build failed -INFO- Made directory [/srv/gump/public/workspace/tomcat-trunk/tomcat-deps] -INFO- Failed with reason build failed -DEBUG- Extracted fallback artifacts from Gump Repository The following work was performed: http://vmgump.apache.org/gump/public/tomcat-trunk/tomcat-trunk/gump_work/build_tomcat-trunk_tomcat-trunk.html Work Name: build_tomcat-trunk_tomcat-trunk (Type: Build) Work ended in a state of : Failed Elapsed: 3 secs Command Line: /usr/lib/jvm/java-7-oracle/bin/java -Djava.awt.headless=true -Dbuild.sysclasspath=only org.apache.tools.ant.Main -Dgump.merge=/srv/gump/public/gump/work/merge.xml -Djdt.jar=/srv/gump/packages/eclipse/plugins/P20140317-1600/ecj-P20140317-1600.jar -Dtomcat-native.tar.gz=/srv/gump/public/workspace/apache-commons/daemon/dist/bin/commons-daemon-20141105-native-src.tar.gz -Dcommons-daemon.native.src.tgz=/srv/gump/public/workspace/apache-commons/daemon/dist/bin/commons-daemon-20141105-native-src.tar.gz -Dcommons-daemon.jar=/srv/gump/public/workspace/apache-commons/daemon/dist/commons-daemon-20141105.jar -Djunit.jar=/srv/gump/public/workspace/junit/target/junit-4.12-SNAPSHOT.jar [Working Directory: /srv/gump/public/workspace/tomcat-trunk] CLASSPATH: /usr/lib/jvm/java-7-oracle/lib/tools.jar:/srv/gump/public/workspace/tomcat-trunk/output/classes:/srv/gump/public/workspace/ant/dist/lib/ant.jar:/srv/gump/public/workspace/ant/dist/lib/ant-launcher.jar:/srv/gump/public/workspace/ant/dist/lib/ant-jmf.jar:/srv/gump/public/workspace/ant/dist/lib/ant-junit.jar:/srv/gump/public/workspace/ant/dist/lib/ant-junit4.jar:/srv/gump/public/workspace/ant/dist/lib/ant-swing.jar:/srv/gump/public/workspace/ant/dist/lib/ant-apache-resolver.jar:/srv/gump/public/workspace/ant/dist/lib/ant-apache-xalan2.jar:/srv/gump/public/workspace/xml-commons/java/build/resolver.jar:/srv/gump/public/workspace/junit/target/junit-4.12-SNAPSHOT.jar:/srv/gump/packages/eclipse/plugins/P20140317-1600/ecj-P20140317-1600.jar:/srv/gump/public/workspace/apache-commons/daemon/dist/commons-daemon-20141105.jar - Buildfile: /srv/gump/public/workspace/tomcat-trunk/build.xml download-compile: testexist: [echo] Testing for /srv/gump/public/workspace/apache-commons/daemon/dist/bin/commons-daemon-20141105-native-src.tar.gz downloadfile-2: testexist: [echo] Testing for /srv/gump/public/workspace/apache-commons/daemon/dist/commons-daemon-20141105.jar downloadgz-2: testexist: [echo] Testing for /srv/gump/public/workspace/apache-commons/daemon/dist/bin/commons-daemon-20141105-native-src.tar.gz downloadfile-2: testexist: [echo] Testing for /srv/gump/packages/eclipse/plugins/P20140317-1600/ecj-P20140317-1600.jar downloadfile-2: build-prepare: [delete] Deleting directory /srv/gump/public/workspace/tomcat-trunk/output/build/temp [mkdir] Created dir: /srv/gump/public/workspace/tomcat-trunk/output/build/temp compile-prepare: download-validate: validate: compile: [javac] Compiling 1522 source files to /srv/gump/public/workspace/tomcat-trunk/output/classes [javac] javac: invalid target release: 1.8 [javac] Usage: javac [javac] use -help for a list of possible options BUILD FAILED /srv/gump/public/workspace/tomcat-trunk/build.xml:651: Compile failed; see the compiler error output for details. Total time: 3 seconds - To
[Bug 51698] ajp CPing/Forward-Request packet forgery, is a design decision? or a security vulnerability?
https://issues.apache.org/bugzilla/show_bug.cgi?id=51698 李智 <13813399...@139.com> changed: What|Removed |Added CC||13813399...@139.com -- You are receiving this mail because: You are the assignee for the bug. - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org