[GUMP@vmgump]: Project tomcat-tc8.0.x-test-nio (in module tomcat-8.0.x) 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-tc8.0.x-test-nio has an issue affecting its community integration. This issue affects 1 projects, and has been outstanding for 3 runs. The current state of this project is 'Failed', with reason 'Build Failed'. For reference only, the following projects are affected by this: - tomcat-tc8.0.x-test-nio : Tomcat 8.x, a web server implementing the Java Servlet 3.1, ... Full details are available at: http://vmgump.apache.org/gump/public/tomcat-8.0.x/tomcat-tc8.0.x-test-nio/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. -INFO- Failed with reason build failed -INFO- Project Reports in: /srv/gump/public/workspace/tomcat-8.0.x/output/logs-NIO -INFO- Project Reports in: /srv/gump/public/workspace/tomcat-8.0.x/output/test-tmp-NIO/logs The following work was performed: http://vmgump.apache.org/gump/public/tomcat-8.0.x/tomcat-tc8.0.x-test-nio/gump_work/build_tomcat-8.0.x_tomcat-tc8.0.x-test-nio.html Work Name: build_tomcat-8.0.x_tomcat-tc8.0.x-test-nio (Type: Build) Work ended in a state of : Failed Elapsed: 46 mins 13 secs Command Line: /usr/lib/jvm/java-8-oracle/bin/java -Djava.awt.headless=true -Dbuild.sysclasspath=only org.apache.tools.ant.Main -Dgump.merge=/srv/gump/public/gump/work/merge.xml -Djunit.jar=/srv/gump/public/workspace/junit/target/junit-4.13-SNAPSHOT.jar -Dobjenesis.jar=/srv/gump/public/workspace/objenesis/main/target/objenesis-2.2-SNAPSHOT.jar -Dtest.reports=output/logs-NIO -Dtomcat-native.tar.gz=/srv/gump/public/workspace/apache-commons/daemon/dist/bin/commons-daemon-20150603-native-src.tar.gz -Dexamples.sources.skip=true -Djdt.jar=/srv/gump/packages/eclipse/plugins/R-4.4-201406061215/ecj-4.4.jar -Dcommons-daemon.jar=/srv/gump/public/workspace/apache-commons/daemon/dist/commons-daemon-20150603.jar -Dcommons-daemon.native.src.tgz=/srv/gump/public/workspace/apache-commons/daemon/dist/bin/commons-daemon-20150603-native-src.tar.gz -Dtest.temp=output/test-tmp-NIO -Dtest.accesslog=true -Dexecute.test.nio=true -Dtest.openssl.path=/srv/gump/public/workspace/openssl-1.0.2/dest-20150603/bin/op enssl -Dexecute.test.bio=false -Dexecute.test.apr=false -Dtest.excludePerformance=true -Dexecute.test.nio2=false -Deasymock.jar=/srv/gump/public/workspace/easymock/easymock/target/easymock-3.4-SNAPSHOT.jar -Dhamcrest.jar=/srv/gump/packages/hamcrest/hamcrest-core-1.3.jar -Dcglib.jar=/srv/gump/packages/cglib/cglib-nodep-2.2.jar test [Working Directory: /srv/gump/public/workspace/tomcat-8.0.x] CLASSPATH: /usr/lib/jvm/java-8-oracle/lib/tools.jar:/srv/gump/public/workspace/tomcat-8.0.x/output/build/webapps/examples/WEB-INF/classes:/srv/gump/public/workspace/tomcat-8.0.x/output/testclasses:/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/tomcat-8.0.x/output/build/bin/bootstrap.jar:/srv/gump/public/workspace/tomcat-8.0.x/output/build/bin/tomcat-juli.jar:/srv/gump/public/workspace/tomcat-8.0.x/output/build/lib/annotations-api.jar:/srv/gump/public/workspace/tomcat-8.0.x/output/build/lib/servlet-api.ja r:/srv/gump/public/workspace/tomcat-8.0.x/output/build/lib/jsp-api.jar:/srv/gump/public/workspace/tomcat-8.0.x/output/build/lib/el-api.jar:/srv/gump/public/workspace/tomcat-8.0.x/output/build/lib/websocket-api.jar:/srv/gump/public/workspace/tomcat-8.0.x/output/build/lib/catalina.jar:/srv/gump/public/workspace/tomcat-8.0.x/output/build/lib/catalina-ant.jar:/srv/gump/public/workspace/tomcat-8.0.x/output/build/lib/catalina-storeconfig.jar:/srv/gump/public/workspace/tomcat-8.0.x/output/build/lib/tomcat-coyote.jar:/srv/gump/public/workspace/tomcat-8.0.x/output/build/lib/jasper.jar:/srv/gump/public/workspace/tomcat-8.0.x/output/build/lib/jasper-el.jar:/srv/gump/public/workspace/tomcat-8.0.x/output/build/lib/catalina-tribes.jar:/srv/gump/public/workspace/tomcat-8.0.x/output/build/lib/catalina-ha.jar:/srv/gump/public/workspace/tomcat-8.0.x/output/build/lib/tomcat-api.jar:/srv/gump/public/workspace/tomcat-8.0.x/output/build/lib/tomcat-jni.jar:/srv/gump/public/wo
[GUMP@vmgump]: Project tomcat-trunk-test-nio2 (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-test-nio2 has an issue affecting its community integration. This issue affects 1 projects, and has been outstanding for 21 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-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-test-nio2/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. -INFO- Failed with reason build failed -INFO- Project Reports in: /srv/gump/public/workspace/tomcat-trunk/output/logs-NIO2 -INFO- Project Reports in: /srv/gump/public/workspace/tomcat-trunk/output/test-tmp-NIO2/logs The following work was performed: http://vmgump.apache.org/gump/public/tomcat-trunk/tomcat-trunk-test-nio2/gump_work/build_tomcat-trunk_tomcat-trunk-test-nio2.html Work Name: build_tomcat-trunk_tomcat-trunk-test-nio2 (Type: Build) Work ended in a state of : Failed Elapsed: 44 mins 9 secs Command Line: /usr/lib/jvm/java-8-oracle/bin/java -Djava.awt.headless=true -Dbuild.sysclasspath=only org.apache.tools.ant.Main -Dgump.merge=/srv/gump/public/gump/work/merge.xml -Djunit.jar=/srv/gump/public/workspace/junit/target/junit-4.13-SNAPSHOT.jar -Dobjenesis.jar=/srv/gump/public/workspace/objenesis/main/target/objenesis-2.2-SNAPSHOT.jar -Dtest.reports=output/logs-NIO2 -Dtomcat-native.tar.gz=/srv/gump/public/workspace/apache-commons/daemon/dist/bin/commons-daemon-20150603-native-src.tar.gz -Dexamples.sources.skip=true -Djdt.jar=/srv/gump/packages/eclipse/plugins/R-4.4-201406061215/ecj-4.4.jar -Dcommons-daemon.jar=/srv/gump/public/workspace/apache-commons/daemon/dist/commons-daemon-20150603.jar -Dcommons-daemon.native.src.tgz=/srv/gump/public/workspace/apache-commons/daemon/dist/bin/commons-daemon-20150603-native-src.tar.gz -Dtest.temp=output/test-tmp-NIO2 -Dtest.accesslog=true -Dexecute.test.nio=false -Dtest.openssl.path=/srv/gump/public/workspace/openssl-master/dest-20150603/bi n/openssl -Dexecute.test.apr=false -Dtest.excludePerformance=true -Dexecute.test.nio2=true -Deasymock.jar=/srv/gump/public/workspace/easymock/easymock/target/easymock-3.4-SNAPSHOT.jar -Dhamcrest.jar=/srv/gump/packages/hamcrest/hamcrest-core-1.3.jar -Dcglib.jar=/srv/gump/packages/cglib/cglib-nodep-2.2.jar test [Working Directory: /srv/gump/public/workspace/tomcat-trunk] CLASSPATH: /usr/lib/jvm/java-8-oracle/lib/tools.jar:/srv/gump/public/workspace/tomcat-trunk/output/build/webapps/examples/WEB-INF/classes:/srv/gump/public/workspace/tomcat-trunk/output/testclasses:/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/tomcat-trunk/output/build/bin/bootstrap.jar:/srv/gump/public/workspace/tomcat-trunk/output/build/bin/tomcat-juli.jar:/srv/gump/public/workspace/tomcat-trunk/output/build/lib/annotations-api.jar:/srv/gump/public/workspace/tomcat-trunk/output/build/lib/servlet-api.ja r:/srv/gump/public/workspace/tomcat-trunk/output/build/lib/jsp-api.jar:/srv/gump/public/workspace/tomcat-trunk/output/build/lib/el-api.jar:/srv/gump/public/workspace/tomcat-trunk/output/build/lib/websocket-api.jar:/srv/gump/public/workspace/tomcat-trunk/output/build/lib/catalina.jar:/srv/gump/public/workspace/tomcat-trunk/output/build/lib/catalina-ant.jar:/srv/gump/public/workspace/tomcat-trunk/output/build/lib/catalina-storeconfig.jar:/srv/gump/public/workspace/tomcat-trunk/output/build/lib/tomcat-coyote.jar:/srv/gump/public/workspace/tomcat-trunk/output/build/lib/jasper.jar:/srv/gump/public/workspace/tomcat-trunk/output/build/lib/jasper-el.jar:/srv/gump/public/workspace/tomcat-trunk/output/build/lib/catalina-tribes.jar:/srv/gump/public/workspace/tomcat-trunk/output/build/lib/catalina-ha.jar:/srv/gump/public/workspace/tomcat-trunk/output/build/lib/tomcat-api.jar:/srv/gump/public/workspace/tomcat-trunk/output/build/lib/tomcat-jni.jar:/srv/gump/public/workspace/tomcat-trunk/output
[GUMP@vmgump]: Project tomcat-trunk-test-apr (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-test-apr has an issue affecting its community integration. This issue affects 1 projects, and has been outstanding for 21 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-test-apr : 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-test-apr/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. -INFO- Failed with reason build failed -INFO- Project Reports in: /srv/gump/public/workspace/tomcat-trunk/output/logs-APR -INFO- Project Reports in: /srv/gump/public/workspace/tomcat-trunk/output/test-tmp-APR/logs The following work was performed: http://vmgump.apache.org/gump/public/tomcat-trunk/tomcat-trunk-test-apr/gump_work/build_tomcat-trunk_tomcat-trunk-test-apr.html Work Name: build_tomcat-trunk_tomcat-trunk-test-apr (Type: Build) Work ended in a state of : Failed Elapsed: 32 mins 47 secs Command Line: /usr/lib/jvm/java-8-oracle/bin/java -Djava.awt.headless=true -Dbuild.sysclasspath=only org.apache.tools.ant.Main -Dgump.merge=/srv/gump/public/gump/work/merge.xml -Djunit.jar=/srv/gump/public/workspace/junit/target/junit-4.13-SNAPSHOT.jar -Dobjenesis.jar=/srv/gump/public/workspace/objenesis/main/target/objenesis-2.2-SNAPSHOT.jar -Dtest.reports=output/logs-APR -Dtomcat-native.tar.gz=/srv/gump/public/workspace/apache-commons/daemon/dist/bin/commons-daemon-20150603-native-src.tar.gz -Dexamples.sources.skip=true -Djdt.jar=/srv/gump/packages/eclipse/plugins/R-4.4-201406061215/ecj-4.4.jar -Dtest.apr.loc=/srv/gump/public/workspace/tomcat-native-trunk/dest-20150603/lib -Dcommons-daemon.jar=/srv/gump/public/workspace/apache-commons/daemon/dist/commons-daemon-20150603.jar -Dcommons-daemon.native.src.tgz=/srv/gump/public/workspace/apache-commons/daemon/dist/bin/commons-daemon-20150603-native-src.tar.gz -Dtest.temp=output/test-tmp-APR -Dtest.accesslog=true -Dexecute.test.nio=false -Dtest.openssl.path=/srv/gump/public/workspace/openssl-master/dest-20150603/bin/openssl -Dexecute.test.apr=true -Dtest.excludePerformance=true -Dexecute.test.nio2=false -Deasymock.jar=/srv/gump/public/workspace/easymock/easymock/target/easymock-3.4-SNAPSHOT.jar -Dhamcrest.jar=/srv/gump/packages/hamcrest/hamcrest-core-1.3.jar -Dcglib.jar=/srv/gump/packages/cglib/cglib-nodep-2.2.jar test [Working Directory: /srv/gump/public/workspace/tomcat-trunk] CLASSPATH: /usr/lib/jvm/java-8-oracle/lib/tools.jar:/srv/gump/public/workspace/tomcat-trunk/output/build/webapps/examples/WEB-INF/classes:/srv/gump/public/workspace/tomcat-trunk/output/testclasses:/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/tomcat-trunk/output/build/bin/bootstrap.jar:/srv/gump/public/workspace/tomcat-trunk/output/build/bin/tomcat-juli.jar:/srv/gump/public/workspace/tomcat-trunk/output/build/lib/annotations-api.jar:/srv/gump/public/workspace/tomcat-trunk/output/build/lib/servlet-api.ja r:/srv/gump/public/workspace/tomcat-trunk/output/build/lib/jsp-api.jar:/srv/gump/public/workspace/tomcat-trunk/output/build/lib/el-api.jar:/srv/gump/public/workspace/tomcat-trunk/output/build/lib/websocket-api.jar:/srv/gump/public/workspace/tomcat-trunk/output/build/lib/catalina.jar:/srv/gump/public/workspace/tomcat-trunk/output/build/lib/catalina-ant.jar:/srv/gump/public/workspace/tomcat-trunk/output/build/lib/catalina-storeconfig.jar:/srv/gump/public/workspace/tomcat-trunk/output/build/lib/tomcat-coyote.jar:/srv/gump/public/workspace/tomcat-trunk/output/build/lib/jasper.jar:/srv/gump/public/workspace/tomcat-trunk/output/build/lib/jasper-el.jar:/srv/gump/public/workspace/tomcat-trunk/output/build/lib/catalina-tribes.jar:/srv/gump/public/workspace/tomcat-trunk/output/build/lib/catalina-ha.jar:/srv/gump/public/workspace/tomcat-trunk/output/build/lib/tomcat-api.jar:/srv/gump/public/workspace/tomcat-trunk/out
svn commit: r1683260 - /tomcat/trunk/java/org/apache/tomcat/util/net/jsse/JSSESupport.java
Author: remm Date: Wed Jun 3 09:39:06 2015 New Revision: 1683260 URL: http://svn.apache.org/r1683260 Log: The JSSE support class contains only generic code that uses a standard SSL session, so it is normally possible to reuse it. Make constructor public. Modified: tomcat/trunk/java/org/apache/tomcat/util/net/jsse/JSSESupport.java Modified: tomcat/trunk/java/org/apache/tomcat/util/net/jsse/JSSESupport.java URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/tomcat/util/net/jsse/JSSESupport.java?rev=1683260&r1=1683259&r2=1683260&view=diff == --- tomcat/trunk/java/org/apache/tomcat/util/net/jsse/JSSESupport.java (original) +++ tomcat/trunk/java/org/apache/tomcat/util/net/jsse/JSSESupport.java Wed Jun 3 09:39:06 2015 @@ -74,7 +74,7 @@ public class JSSESupport implements SSLS private SSLSession session; -JSSESupport(SSLSession session) { +public JSSESupport(SSLSession session) { this.session = session; } - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
[ANN] End of life for Apache Tomcat 6.0.x
The Apache Tomcat team announces that support for Apache Tomcat 6.0.x will end on 31 December 2016. This means that after 31 December 2016: - releases from the 6.0.x branch are highly unlikely - bugs affecting only the 6.0.x branch will not be addressed - security vulnerability reports will not be checked against the 6.0.x branch Three months later (i.e. after 30 March 2017) - the 6.0.x download pages will be removed - the latest 6.0.x release will be removed from the mirror system - the 6.0.x branch in svn will move from /tomcat/tc6.0.x to /tomcat/archive/tc6.0.x - the links to the 6.0.x documentation will be removed from tomcat.apache.org - The bugzilla project for 6.0.x will be made read-only Note that all 6.0.x releases will always be available from the archive. It is anticipated that the final 6.0.x release will be made shortly before 31 December 2016. - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
[PROPOSAL] Remove tomcat-jdbc from Tomcat 9 onwards
A connection pooling question on the users list prompted me to write a short history [1] of Tomcat's connection pooling with respect to DBCP 1, DBCP 2 and tomcat-jdbc. That got me thinking. Given the current situation: - DBCP 2 is stable - The Commons community is supporting DBCP 2 - tomcat-jdbc is stable - support for tomcat-jdbc is sporadic at best - DBCP 2 performance is very close to that of tomcat-jdbc (to be clear, tomcat-jdbc still has better performance) I'd like to propose that we do not ship tomcat-jdbc with Tomcat 9 onwards (i.e. remove it from trunk/modules). There are some features in tomcat-jdbc that are not available in Commons DBCP 2. This proposal includes porting those features to DBCP 2 if there is user demand for them. Thoughts? Mark - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
Re: [PROPOSAL] Remove tomcat-jdbc from Tomcat 9 onwards
2015-06-03 12:08 GMT+02:00 Mark Thomas : > A connection pooling question on the users list prompted me to write a > short history [1] of Tomcat's connection pooling with respect to DBCP 1, > DBCP 2 and tomcat-jdbc. That got me thinking. > > Given the current situation: > - DBCP 2 is stable > - The Commons community is supporting DBCP 2 > - tomcat-jdbc is stable > - support for tomcat-jdbc is sporadic at best > - DBCP 2 performance is very close to that of tomcat-jdbc (to > be clear, tomcat-jdbc still has better performance) > > I'd like to propose that we do not ship tomcat-jdbc with Tomcat 9 > onwards (i.e. remove it from trunk/modules). > > There are some features in tomcat-jdbc that are not available in Commons > DBCP 2. This proposal includes porting those features to DBCP 2 if there > is user demand for them. > > Thoughts? > > Good plan. Rémy
svn commit: r1683321 - /tomcat/trunk/java/org/apache/coyote/http2/Stream.java
Author: markt Date: Wed Jun 3 13:17:54 2015 New Revision: 1683321 URL: http://svn.apache.org/r1683321 Log: Increase default buffer size to match minimum frame size. Use lazy init for buffers to reduce memory footprint Modified: tomcat/trunk/java/org/apache/coyote/http2/Stream.java Modified: tomcat/trunk/java/org/apache/coyote/http2/Stream.java URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/coyote/http2/Stream.java?rev=1683321&r1=1683320&r2=1683321&view=diff == --- tomcat/trunk/java/org/apache/coyote/http2/Stream.java (original) +++ tomcat/trunk/java/org/apache/coyote/http2/Stream.java Wed Jun 3 13:17:54 2015 @@ -358,19 +358,24 @@ public class Stream extends AbstractStre * corruption by careful use of the buffer it would still require the * same copies as using two buffers and the behaviour would be less * clear. + * + * The buffers are created lazily because 32K per stream quickly adds + * up to a lot of memory and most requests do not have bodies. */ // This buffer is used to populate the ByteChunk passed in to the read // method -private final byte[] outBuffer = new byte[8 * 1024]; +private byte[] outBuffer; // This buffer is the destination for incoming data. It is normally is // 'write mode'. -private final ByteBuffer inBuffer = ByteBuffer.allocate(8 * 1024); +private ByteBuffer inBuffer; private boolean endOfStream = false; @Override public int doRead(ByteChunk chunk) throws IOException { +ensureBuffersExist(); + int written = 0; // Ensure that only one thread accesses inBuffer at a time @@ -405,7 +410,21 @@ public class Stream extends AbstractStre public ByteBuffer getInBuffer() { +ensureBuffersExist(); return inBuffer; } + + +private void ensureBuffersExist() { +if (inBuffer != null) { +return; +} +synchronized (this) { +if (inBuffer == null) { +inBuffer = ByteBuffer.allocate(16 * 1024); +outBuffer = new byte[16 * 1024]; +} +} +} } } - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
svn commit: r1683322 - /tomcat/trunk/java/org/apache/coyote/http2/Stream.java
Author: markt Date: Wed Jun 3 13:18:32 2015 New Revision: 1683322 URL: http://svn.apache.org/r1683322 Log: inBuffer needs to be volatile for double checked locking to work. Modified: tomcat/trunk/java/org/apache/coyote/http2/Stream.java Modified: tomcat/trunk/java/org/apache/coyote/http2/Stream.java URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/coyote/http2/Stream.java?rev=1683322&r1=1683321&r2=1683322&view=diff == --- tomcat/trunk/java/org/apache/coyote/http2/Stream.java (original) +++ tomcat/trunk/java/org/apache/coyote/http2/Stream.java Wed Jun 3 13:18:32 2015 @@ -367,7 +367,7 @@ public class Stream extends AbstractStre private byte[] outBuffer; // This buffer is the destination for incoming data. It is normally is // 'write mode'. -private ByteBuffer inBuffer; +private volatile ByteBuffer inBuffer; private boolean endOfStream = false; - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
[jira] [Commented] (MTOMCAT-266) The attribute crashes Tomcat on startup
[ https://issues.apache.org/jira/browse/MTOMCAT-266?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14570844#comment-14570844 ] Constantino Cronemberger commented on MTOMCAT-266: -- It looks like this is similar to MTOMCAT-83. I understand fork is used for integration tests, so it will not really cover what I really need and maybe what the reporter wants as well. In my case I would like to run tomcat with this Java argument: -Djava.util.logging.manager=org.apache.logging.log4j.jul.LogManager I tried to add it in the systemProperties element but it did not work because Maven also uses JUL so it gets initialized before this system property is set. The option I have now is to pass this argument to Maven, but then I would need to also add to Maven classpath all Lo4j2 jars which is not a good idea. Then I searched for some options to let Tomcat be started in a separate JVM and I found this fork configuration, but now I know it will not work for me. So maybe we will need another option to control whether we want to let the forked process running or not. > The attribute crashes Tomcat on startup > -- > > Key: MTOMCAT-266 > URL: https://issues.apache.org/jira/browse/MTOMCAT-266 > Project: Apache Tomcat Maven Plugin > Issue Type: Bug > Components: tomcat7 >Affects Versions: 2.2 > Environment: Windows 8.1, Java 1.7.0_51 and Maven 3.2.1 >Reporter: M. R. >Assignee: Olivier Lamy (*$^¨%`£) >Priority: Minor > Attachments: tomcat-plugin-crash.txt > > > The plugin works perfectly running Tomcat with my project web application. > I do "mvn tomcat7:run" and the server is started, the webapp is deployed and > I can browse to it. > If I add the attribute, though, the server crashes. > Here's (a portion of) my pom: > > org.apache.tomcat.maven > tomcat7-maven-plugin > 2.2 > > localhost > 8080 > / > UTF-8 > > > (I'll add the stacktrace later) -- This message was sent by Atlassian JIRA (v6.3.4#6332) - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
[jira] [Comment Edited] (MTOMCAT-83) Support specifying arguments using a real forked JVM
[ https://issues.apache.org/jira/browse/MTOMCAT-83?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14570852#comment-14570852 ] Constantino Cronemberger edited comment on MTOMCAT-83 at 6/3/15 1:55 PM: - Isn't this issue very similar to this one MTOMCAT-266? I have added some comment on that issue. was (Author: ccronemberger): Isn't this issue very similar to this one MTOMCAT-266? > Support specifying arguments using a real forked JVM > > > Key: MTOMCAT-83 > URL: https://issues.apache.org/jira/browse/MTOMCAT-83 > Project: Apache Tomcat Maven Plugin > Issue Type: New Feature >Affects Versions: 1.1 >Reporter: Stevo Slavic > Fix For: backlog > > > [tomcat-maven-plugin's run > goal|http://mojo.codehaus.org/tomcat-maven-plugin/run-mojo.html] seems to > support forking, but not specifying arguments for forked JVM. Something like > that IMO would be useful for specifying memory options different from Maven > build and javaagent like jacoco for coverage. -- This message was sent by Atlassian JIRA (v6.3.4#6332) - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
[jira] [Commented] (MTOMCAT-83) Support specifying arguments using a real forked JVM
[ https://issues.apache.org/jira/browse/MTOMCAT-83?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14570852#comment-14570852 ] Constantino Cronemberger commented on MTOMCAT-83: - Isn't this issue very similar to this one MTOMCAT-266? > Support specifying arguments using a real forked JVM > > > Key: MTOMCAT-83 > URL: https://issues.apache.org/jira/browse/MTOMCAT-83 > Project: Apache Tomcat Maven Plugin > Issue Type: New Feature >Affects Versions: 1.1 >Reporter: Stevo Slavic > Fix For: backlog > > > [tomcat-maven-plugin's run > goal|http://mojo.codehaus.org/tomcat-maven-plugin/run-mojo.html] seems to > support forking, but not specifying arguments for forked JVM. Something like > that IMO would be useful for specifying memory options different from Maven > build and javaagent like jacoco for coverage. -- This message was sent by Atlassian JIRA (v6.3.4#6332) - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
svn commit: r1683337 - in /tomcat/trunk: java/org/apache/coyote/http2/ConnectionSettings.java test/org/apache/coyote/http2/Http2TestBase.java test/org/apache/coyote/http2/TestHttp2Section_4_1.java
Author: markt Date: Wed Jun 3 13:56:45 2015 New Revision: 1683337 URL: http://svn.apache.org/r1683337 Log: Add a test for ignoring unknown frame types Added: tomcat/trunk/test/org/apache/coyote/http2/TestHttp2Section_4_1.java (with props) Modified: tomcat/trunk/java/org/apache/coyote/http2/ConnectionSettings.java tomcat/trunk/test/org/apache/coyote/http2/Http2TestBase.java Modified: tomcat/trunk/java/org/apache/coyote/http2/ConnectionSettings.java URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/coyote/http2/ConnectionSettings.java?rev=1683337&r1=1683336&r2=1683337&view=diff == --- tomcat/trunk/java/org/apache/coyote/http2/ConnectionSettings.java (original) +++ tomcat/trunk/java/org/apache/coyote/http2/ConnectionSettings.java Wed Jun 3 13:56:45 2015 @@ -35,7 +35,9 @@ public class ConnectionSettings { private static final int MAX_MAX_FRAME_SIZE = (1 << 24) - 1; static final int DEFAULT_MAX_FRAME_SIZE = MIN_MAX_FRAME_SIZE; -private volatile int headerTableSize = 4096; +static final int DEFAULT_HEADER_TABLE_SIZE = 4096; +private volatile int headerTableSize = DEFAULT_HEADER_TABLE_SIZE; + private volatile boolean enablePush = true; private volatile long maxConcurrentStreams = UNLIMITED; private volatile int initialWindowSize = DEFAULT_WINDOW_SIZE; Modified: tomcat/trunk/test/org/apache/coyote/http2/Http2TestBase.java URL: http://svn.apache.org/viewvc/tomcat/trunk/test/org/apache/coyote/http2/Http2TestBase.java?rev=1683337&r1=1683336&r2=1683337&view=diff == --- tomcat/trunk/test/org/apache/coyote/http2/Http2TestBase.java (original) +++ tomcat/trunk/test/org/apache/coyote/http2/Http2TestBase.java Wed Jun 3 13:56:45 2015 @@ -41,6 +41,7 @@ import org.apache.coyote.http2.HpackDeco import org.apache.coyote.http2.Http2Parser.Input; import org.apache.coyote.http2.Http2Parser.Output; import org.apache.tomcat.util.codec.binary.Base64; +import org.apache.tomcat.util.http.MimeHeaders; /** @@ -64,6 +65,7 @@ public abstract class Http2TestBase exte } private Socket s; +protected HpackEncoder hpackEncoder; protected Input input; protected TestOutput output; protected Http2Parser parser; @@ -83,6 +85,7 @@ public abstract class Http2TestBase exte validateHttp2InitialResponse(); } + protected void validateHttp2InitialResponse() throws Exception { // - 101 response acts as acknowledgement of the HTTP2-Settings header // Need to read 4 frames @@ -97,15 +100,61 @@ public abstract class Http2TestBase exte Assert.assertEquals("0-Settings-End\n" + "0-Settings-Ack\n" + -"1-HeadersStart\n" + -"1-Header-[:status]-[200]\n" + -"1-HeadersEnd\n" + -"1-Body-8192\n" + -"1-EndOfStream", output.getTrace()); +getSimpleResponseTrace(1) +, output.getTrace()); output.clearTrace(); } +protected void sendSimpleRequest(int streamId) throws IOException { +MimeHeaders headers = new MimeHeaders(); +headers.addValue(":method").setString("GET"); +headers.addValue(":path").setString("/any"); +headers.addValue(":authority").setString("localhost:" + getPort()); +ByteBuffer buf = ByteBuffer.allocate(128); +hpackEncoder.encode(headers, buf); + +buf.flip(); +byte[] frameHeader = new byte[9]; + +ByteUtil.setThreeBytes(frameHeader, 0, buf.limit()); +// Header frame is type 0x01 +frameHeader[3] = 0x01; +// Flags. end of headers (0x04). end of stream (0x01) +frameHeader[4] = 0x05; +// Stream id +ByteUtil.set31Bits(frameHeader, 5, streamId); +os.write(frameHeader); +os.write(buf.array(), buf.arrayOffset(), buf.limit()); +os.flush(); +} + + +protected void readSimpleResponse() throws IOException { +// Headers +parser.readFrame(true); +// Body +parser.readFrame(true); +} + + +protected String getSimpleResponseTrace(int streamId) { +StringBuilder result = new StringBuilder(); +result.append(streamId); +result.append("-HeadersStart\n"); +result.append(streamId); +result.append("-Header-[:status]-[200]\n"); +result.append(streamId); +result.append("-HeadersEnd\n"); +result.append(streamId); +result.append("-Body-8192\n"); +result.append(streamId); +result.append("-EndOfStream\n"); + +return result.toString(); +} + + protected void enableHttp2() { Connector connector = getTomcatInstance().getConnector(); Http2Protocol http2Protocol = new Http2Protocol(); @@ -291,7 +340,7 @@ public abstract class Http2T
svn commit: r1683339 - in /tomcat/trunk/test/org/apache/coyote/http2: Http2TestBase.java TestHttp2Section_4_1.java
Author: markt Date: Wed Jun 3 14:08:53 2015 New Revision: 1683339 URL: http://svn.apache.org/r1683339 Log: Add test to confirm that the server ignores the reserved bit if set Modified: tomcat/trunk/test/org/apache/coyote/http2/Http2TestBase.java tomcat/trunk/test/org/apache/coyote/http2/TestHttp2Section_4_1.java Modified: tomcat/trunk/test/org/apache/coyote/http2/Http2TestBase.java URL: http://svn.apache.org/viewvc/tomcat/trunk/test/org/apache/coyote/http2/Http2TestBase.java?rev=1683339&r1=1683338&r2=1683339&view=diff == --- tomcat/trunk/test/org/apache/coyote/http2/Http2TestBase.java (original) +++ tomcat/trunk/test/org/apache/coyote/http2/Http2TestBase.java Wed Jun 3 14:08:53 2015 @@ -107,25 +107,37 @@ public abstract class Http2TestBase exte protected void sendSimpleRequest(int streamId) throws IOException { +byte[] frameHeader = new byte[9]; +ByteBuffer headersPayload = ByteBuffer.allocate(128); + +buildSimpleRequest(frameHeader, headersPayload, streamId); +writeSimpleRequest(frameHeader, headersPayload); +} + + +protected void buildSimpleRequest(byte[] frameHeader, ByteBuffer headersPayload, int streamId) { MimeHeaders headers = new MimeHeaders(); headers.addValue(":method").setString("GET"); headers.addValue(":path").setString("/any"); headers.addValue(":authority").setString("localhost:" + getPort()); -ByteBuffer buf = ByteBuffer.allocate(128); -hpackEncoder.encode(headers, buf); +hpackEncoder.encode(headers, headersPayload); -buf.flip(); -byte[] frameHeader = new byte[9]; +headersPayload.flip(); -ByteUtil.setThreeBytes(frameHeader, 0, buf.limit()); +ByteUtil.setThreeBytes(frameHeader, 0, headersPayload.limit()); // Header frame is type 0x01 frameHeader[3] = 0x01; // Flags. end of headers (0x04). end of stream (0x01) frameHeader[4] = 0x05; // Stream id ByteUtil.set31Bits(frameHeader, 5, streamId); +} + + +protected void writeSimpleRequest(byte[] frameHeader, ByteBuffer headersPayload) +throws IOException { os.write(frameHeader); -os.write(buf.array(), buf.arrayOffset(), buf.limit()); +os.write(headersPayload.array(), headersPayload.arrayOffset(), headersPayload.limit()); os.flush(); } Modified: tomcat/trunk/test/org/apache/coyote/http2/TestHttp2Section_4_1.java URL: http://svn.apache.org/viewvc/tomcat/trunk/test/org/apache/coyote/http2/TestHttp2Section_4_1.java?rev=1683339&r1=1683338&r2=1683339&view=diff == --- tomcat/trunk/test/org/apache/coyote/http2/TestHttp2Section_4_1.java (original) +++ tomcat/trunk/test/org/apache/coyote/http2/TestHttp2Section_4_1.java Wed Jun 3 14:08:53 2015 @@ -16,6 +16,8 @@ */ package org.apache.coyote.http2; +import java.nio.ByteBuffer; + import org.junit.Assert; import org.junit.Test; @@ -33,6 +35,7 @@ public class TestHttp2Section_4_1 extend // TODO: Tests for over-sized frames. Better located in tests for section 6? + @Test public void testUnknownFrameType() throws Exception { hpackEncoder = new HpackEncoder(ConnectionSettings.DEFAULT_HEADER_TABLE_SIZE); @@ -45,7 +48,29 @@ public class TestHttp2Section_4_1 extend Assert.assertEquals(getSimpleResponseTrace(3), output.getTrace()); } + // TODO: Tests for unexpected flags. Better located in tests for section 6? -// TODO: Test that set reserved bit is ignored. + +@Test +public void testReservedBitIgnored() throws Exception { +hpackEncoder = new HpackEncoder(ConnectionSettings.DEFAULT_HEADER_TABLE_SIZE); + +// HTTP2 upgrade +http2Connect(); + +// Build the simple request +byte[] frameHeader = new byte[9]; +ByteBuffer headersPayload = ByteBuffer.allocate(128); +buildSimpleRequest(frameHeader, headersPayload, 3); + +// Tweak the header to set the reserved bit +frameHeader[5] = (byte) (frameHeader[5] | 0x80); + +// Process the request +writeSimpleRequest(frameHeader, headersPayload); + +readSimpleResponse(); +Assert.assertEquals(getSimpleResponseTrace(3), output.getTrace()); +} } - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
svn commit: r1683350 - /tomcat/trunk/test/org/apache/coyote/http2/TestHttp2Section_4_3.java
Author: markt Date: Wed Jun 3 14:52:44 2015 New Revision: 1683350 URL: http://svn.apache.org/r1683350 Log: Add an initial test case for RFC7540, section 4.3 Added: tomcat/trunk/test/org/apache/coyote/http2/TestHttp2Section_4_3.java (with props) Added: tomcat/trunk/test/org/apache/coyote/http2/TestHttp2Section_4_3.java URL: http://svn.apache.org/viewvc/tomcat/trunk/test/org/apache/coyote/http2/TestHttp2Section_4_3.java?rev=1683350&view=auto == --- tomcat/trunk/test/org/apache/coyote/http2/TestHttp2Section_4_3.java (added) +++ tomcat/trunk/test/org/apache/coyote/http2/TestHttp2Section_4_3.java Wed Jun 3 14:52:44 2015 @@ -0,0 +1,60 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package org.apache.coyote.http2; + +import java.nio.ByteBuffer; + +import org.junit.Assert; +import org.junit.Ignore; +import org.junit.Test; + +/** + * Unit tests for Section 4.3 of + * https://tools.ietf.org/html/rfc7540";>RFC 7540. + * + * The order of tests in this class is aligned with the order of the + * requirements in the RFC. + */ +public class TestHttp2Section_4_3 extends Http2TestBase { + +@Ignore // Appears to trigger various problems +@Test +public void testHeaderDecodingError() throws Exception { +hpackEncoder = new HpackEncoder(ConnectionSettings.DEFAULT_HEADER_TABLE_SIZE); + +// HTTP2 upgrade +http2Connect(); + +// Build the simple request +byte[] frameHeader = new byte[9]; +ByteBuffer headersPayload = ByteBuffer.allocate(128); +buildSimpleRequest(frameHeader, headersPayload, 3); + +// Try and corrupt the headerPayload +headersPayload.put(0, (byte) (headersPayload.get(0) + 128)); + +// Process the request +writeSimpleRequest(frameHeader, headersPayload); + +readSimpleResponse(); +Assert.assertEquals(getSimpleResponseTrace(3), output.getTrace()); + +} + + +// TODO: Header frames must be a contiguous sequence +} Propchange: tomcat/trunk/test/org/apache/coyote/http2/TestHttp2Section_4_3.java -- svn:eol-style = native - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
svn commit: r1683392 - /tomcat/trunk/java/org/apache/coyote/http2/Http2UpgradeHandler.java
Author: markt Date: Wed Jun 3 17:36:40 2015 New Revision: 1683392 URL: http://svn.apache.org/r1683392 Log: Lower log level for connection errors to debug since they are easily triggered by clients. Modified: tomcat/trunk/java/org/apache/coyote/http2/Http2UpgradeHandler.java Modified: tomcat/trunk/java/org/apache/coyote/http2/Http2UpgradeHandler.java URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/coyote/http2/Http2UpgradeHandler.java?rev=1683392&r1=1683391&r2=1683392&view=diff == --- tomcat/trunk/java/org/apache/coyote/http2/Http2UpgradeHandler.java (original) +++ tomcat/trunk/java/org/apache/coyote/http2/Http2UpgradeHandler.java Wed Jun 3 17:36:40 2015 @@ -244,8 +244,9 @@ public class Http2UpgradeHandler extends } } catch (Http2Exception h2e) { if (h2e.getStreamId() == 0) { -// Connection error -log.warn(sm.getString("upgradeHandler.connectionError"), h2e); +if (log.isDebugEnabled()) { + log.debug(sm.getString("upgradeHandler.connectionError"), h2e); +} close(h2e); break; } else { - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
svn commit: r1683395 - /tomcat/trunk/java/org/apache/coyote/http2/Http2UpgradeHandler.java
Author: markt Date: Wed Jun 3 17:52:22 2015 New Revision: 1683395 URL: http://svn.apache.org/r1683395 Log: Add missing flags field from GOAWAY constant Modified: tomcat/trunk/java/org/apache/coyote/http2/Http2UpgradeHandler.java Modified: tomcat/trunk/java/org/apache/coyote/http2/Http2UpgradeHandler.java URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/coyote/http2/Http2UpgradeHandler.java?rev=1683395&r1=1683394&r2=1683395&view=diff == --- tomcat/trunk/java/org/apache/coyote/http2/Http2UpgradeHandler.java (original) +++ tomcat/trunk/java/org/apache/coyote/http2/Http2UpgradeHandler.java Wed Jun 3 17:52:22 2015 @@ -93,7 +93,7 @@ public class Http2UpgradeHandler extends private static final byte[] SETTINGS_EMPTY = { 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00 }; private static final byte[] SETTINGS_ACK = { 0x00, 0x00, 0x00, 0x04, 0x01, 0x00, 0x00, 0x00, 0x00 }; -private static final byte[] GOAWAY = { 0x07, 0x00, 0x00, 0x00, 0x00 }; +private static final byte[] GOAWAY = { 0x07, 0x00, 0x00, 0x00, 0x00, 0x00 }; private static final String HTTP2_SETTINGS_HEADER = "HTTP2-Settings"; private static final byte[] HTTP2_UPGRADE_ACK = ("HTTP/1.1 101 Switching Protocols\r\n" + - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
svn commit: r1683411 - /tomcat/trunk/java/org/apache/coyote/http2/ByteUtil.java
Author: markt Date: Wed Jun 3 18:44:15 2015 New Revision: 1683411 URL: http://svn.apache.org/r1683411 Log: Add new method to set four bytes Modified: tomcat/trunk/java/org/apache/coyote/http2/ByteUtil.java Modified: tomcat/trunk/java/org/apache/coyote/http2/ByteUtil.java URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/coyote/http2/ByteUtil.java?rev=1683411&r1=1683410&r2=1683411&view=diff == --- tomcat/trunk/java/org/apache/coyote/http2/ByteUtil.java (original) +++ tomcat/trunk/java/org/apache/coyote/http2/ByteUtil.java Wed Jun 3 18:44:15 2015 @@ -72,4 +72,12 @@ public class ByteUtil { return ((long)(input[firstByte] & 0xFF) << 24) + ((input[firstByte + 1] & 0xFF) << 16) + ((input[firstByte + 2] & 0xFF) << 8) + (input[firstByte + 3] & 0xFF); } + + +public static void setFourBytes(byte[] output, int firstByte, long value) { +output[firstByte] = (byte) ((value & 0xFF00) >> 24); +output[firstByte + 1] = (byte) ((value & 0xFF) >> 16); +output[firstByte + 2] = (byte) ((value & 0xFF00) >> 8); +output[firstByte + 3] = (byte) (value & 0xFF); +} } - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
svn commit: r1683410 - /tomcat/trunk/java/org/apache/coyote/http2/ErrorCode.java
Author: markt Date: Wed Jun 3 18:43:33 2015 New Revision: 1683410 URL: http://svn.apache.org/r1683410 Log: Extract error codes to new Enum Added: tomcat/trunk/java/org/apache/coyote/http2/ErrorCode.java (with props) Added: tomcat/trunk/java/org/apache/coyote/http2/ErrorCode.java URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/coyote/http2/ErrorCode.java?rev=1683410&view=auto == --- tomcat/trunk/java/org/apache/coyote/http2/ErrorCode.java (added) +++ tomcat/trunk/java/org/apache/coyote/http2/ErrorCode.java Wed Jun 3 18:43:33 2015 @@ -0,0 +1,53 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package org.apache.coyote.http2; + +public enum ErrorCode { + +NO_ERROR(0x00), +PROTOCOL_ERROR (0x01), +INTERNAL_ERROR (0x02), +FLOW_CONTROL_ERROR (0x03), +SETTINGS_TIMEOUT(0x04), +STREAM_CLOSED (0x05), +FRAME_SIZE_ERROR(0x06), +REFUSED_STREAM (0x07), +CANCEL (0x08), +COMPRESSION_ERROR (0x09), +CONNECT_ERROR (0x0a), +ENHANCE_YOUR_CALM (0x0b), +INADEQUATE_SECURITY (0x0c), +HTTP_1_1_REQUIRED (0x0d); + +private final long errorCode; + +private ErrorCode(long errorCode) { +this.errorCode = errorCode; +} + + +public long getErrorCode() { +return errorCode; +} + + +public byte[] getErrorCodeBytes() { +byte[] errorCodeByte = new byte[4]; +ByteUtil.setFourBytes(errorCodeByte, 0, errorCode); +return errorCodeByte; +} +} Propchange: tomcat/trunk/java/org/apache/coyote/http2/ErrorCode.java -- svn:eol-style = native - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
svn commit: r1683412 - in /tomcat/trunk: java/org/apache/coyote/http2/ test/org/apache/coyote/http2/
Author: markt Date: Wed Jun 3 18:45:52 2015 New Revision: 1683412 URL: http://svn.apache.org/r1683412 Log: Swtich to new Enum for error code Add parsing for the Goaway frame (some TODOs in this code) Enable test for header decoding issues that now passes Modified: tomcat/trunk/java/org/apache/coyote/http2/ConnectionSettings.java tomcat/trunk/java/org/apache/coyote/http2/Http2Exception.java tomcat/trunk/java/org/apache/coyote/http2/Http2Parser.java tomcat/trunk/java/org/apache/coyote/http2/Http2UpgradeHandler.java tomcat/trunk/java/org/apache/coyote/http2/LocalStrings.properties tomcat/trunk/test/org/apache/coyote/http2/Http2TestBase.java tomcat/trunk/test/org/apache/coyote/http2/TestHttp2Section_4_3.java Modified: tomcat/trunk/java/org/apache/coyote/http2/ConnectionSettings.java URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/coyote/http2/ConnectionSettings.java?rev=1683412&r1=1683411&r2=1683412&view=diff == --- tomcat/trunk/java/org/apache/coyote/http2/ConnectionSettings.java (original) +++ tomcat/trunk/java/org/apache/coyote/http2/ConnectionSettings.java Wed Jun 3 18:45:52 2015 @@ -84,7 +84,7 @@ public class ConnectionSettings { // Need to put a sensible limit on this. Start with 16k (default is 4k) if (headerTableSize > (16 * 1024)) { throw new Http2Exception(sm.getString("connectionSettings.headerTableSizeLimit", -Long.toString(headerTableSize)), 0, Http2Exception.PROTOCOL_ERROR); +Long.toString(headerTableSize)), 0, ErrorCode.PROTOCOL_ERROR); } this.headerTableSize = (int) headerTableSize; } @@ -98,7 +98,7 @@ public class ConnectionSettings { // will never be negative if (enablePush > 1) { throw new Http2Exception(sm.getString("connectionSettings.enablePushInvalid", -Long.toString(enablePush)), 0, Http2Exception.PROTOCOL_ERROR); +Long.toString(enablePush)), 0, ErrorCode.PROTOCOL_ERROR); } this.enablePush = (enablePush == 1); } @@ -119,7 +119,7 @@ public class ConnectionSettings { if (initialWindowSize > MAX_WINDOW_SIZE) { throw new Http2Exception(sm.getString("connectionSettings.windowSizeTooBig", Long.toString(initialWindowSize), Long.toString(MAX_WINDOW_SIZE)), -0, Http2Exception.PROTOCOL_ERROR); +0, ErrorCode.PROTOCOL_ERROR); } this.initialWindowSize = (int) initialWindowSize; } @@ -132,7 +132,7 @@ public class ConnectionSettings { if (maxFrameSize < MIN_MAX_FRAME_SIZE || maxFrameSize > MAX_MAX_FRAME_SIZE) { throw new Http2Exception(sm.getString("connectionSettings.maxFrameSizeInvalid", Long.toString(maxFrameSize), Integer.toString(MIN_MAX_FRAME_SIZE), -Integer.toString(MAX_MAX_FRAME_SIZE)), 0, Http2Exception.PROTOCOL_ERROR); +Integer.toString(MAX_MAX_FRAME_SIZE)), 0, ErrorCode.PROTOCOL_ERROR); } this.maxFrameSize = (int) maxFrameSize; } Modified: tomcat/trunk/java/org/apache/coyote/http2/Http2Exception.java URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/coyote/http2/Http2Exception.java?rev=1683412&r1=1683411&r2=1683412&view=diff == --- tomcat/trunk/java/org/apache/coyote/http2/Http2Exception.java (original) +++ tomcat/trunk/java/org/apache/coyote/http2/Http2Exception.java Wed Jun 3 18:45:52 2015 @@ -22,27 +22,11 @@ public class Http2Exception extends IOEx private static final long serialVersionUID = 1L; -public static final byte[] NO_ERROR = { 0x00, 0x00, 0x00, 0x00 }; -public static final byte[] PROTOCOL_ERROR = { 0x00, 0x00, 0x00, 0x01 }; -public static final byte[] INTERNAL_ERROR = { 0x00, 0x00, 0x00, 0x02 }; -public static final byte[] FLOW_CONTROL_ERROR = { 0x00, 0x00, 0x00, 0x03 }; -public static final byte[] SETTINGS_TIMEOUT = { 0x00, 0x00, 0x00, 0x04 }; -public static final byte[] STREAM_CLOSED = { 0x00, 0x00, 0x00, 0x05 }; -public static final byte[] FRAME_SIZE_ERROR = { 0x00, 0x00, 0x00, 0x06}; -public static final byte[] REFUSED_STREAM = { 0x00, 0x00, 0x00, 0x07}; -public static final byte[] CANCEL = { 0x00, 0x00, 0x00, 0x08}; -public static final byte[] COMPRESSION_ERROR= { 0x00, 0x00, 0x00, 0x09}; -public static final byte[] CONNECT_ERROR = { 0x00, 0x00, 0x00, 0x0a}; -public static final byte[] ENHANCE_YOUR_CALM = { 0x00, 0x00, 0x00, 0x0b}; -public static final byte[] INADEQUATE_SECURITY = { 0x00, 0x00, 0x00, 0x0c}; -public static final byte[] HTTP_1_1_REQUIRED = { 0x00, 0x00, 0x00, 0x0d}; - - private final int streamId; -private final byte[] errorCode; +private final ErrorCode errorC
svn commit: r1683413 - in /tomcat/trunk: java/org/apache/coyote/http2/Http2Parser.java test/org/apache/coyote/http2/TestHttp2Section_4_3.java
Author: markt Date: Wed Jun 3 18:48:40 2015 New Revision: 1683413 URL: http://svn.apache.org/r1683413 Log: Correct error code for decoding issues Modified: tomcat/trunk/java/org/apache/coyote/http2/Http2Parser.java tomcat/trunk/test/org/apache/coyote/http2/TestHttp2Section_4_3.java Modified: tomcat/trunk/java/org/apache/coyote/http2/Http2Parser.java URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/coyote/http2/Http2Parser.java?rev=1683413&r1=1683412&r2=1683413&view=diff == --- tomcat/trunk/java/org/apache/coyote/http2/Http2Parser.java (original) +++ tomcat/trunk/java/org/apache/coyote/http2/Http2Parser.java Wed Jun 3 18:48:40 2015 @@ -234,7 +234,7 @@ class Http2Parser { } catch (HpackException hpe) { throw new Http2Exception( sm.getString("http2Parser.processFrameHeaders.decodingFailed"), -0, ErrorCode.PROTOCOL_ERROR); +0, ErrorCode.COMPRESSION_ERROR); } // switches to write mode headerReadBuffer.compact(); @@ -244,7 +244,7 @@ class Http2Parser { if (headerReadBuffer.position() > 0) { throw new Http2Exception( sm.getString("http2Parser.processFrameHeaders.decodingDataLeft"), -0, ErrorCode.PROTOCOL_ERROR); +0, ErrorCode.COMPRESSION_ERROR); } swallow(padLength); Modified: tomcat/trunk/test/org/apache/coyote/http2/TestHttp2Section_4_3.java URL: http://svn.apache.org/viewvc/tomcat/trunk/test/org/apache/coyote/http2/TestHttp2Section_4_3.java?rev=1683413&r1=1683412&r2=1683413&view=diff == --- tomcat/trunk/test/org/apache/coyote/http2/TestHttp2Section_4_3.java (original) +++ tomcat/trunk/test/org/apache/coyote/http2/TestHttp2Section_4_3.java Wed Jun 3 18:48:40 2015 @@ -52,7 +52,8 @@ public class TestHttp2Section_4_3 extend parser.readFrame(true); Assert.assertTrue(output.getTrace(), -output.getTrace().startsWith("0-Goaway-[2147483647]-[1]-[")); +output.getTrace().startsWith("0-Goaway-[2147483647]-[" + +ErrorCode.COMPRESSION_ERROR.getErrorCode() + "]-[")); } - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
Re: [PROPOSAL] Remove tomcat-jdbc from Tomcat 9 onwards
Mark, On 6/3/15 6:08 AM, Mark Thomas wrote: > A connection pooling question on the users list prompted me to write a > short history [1] of Tomcat's connection pooling with respect to DBCP 1, > DBCP 2 and tomcat-jdbc. That got me thinking. > > Given the current situation: > - DBCP 2 is stable > - The Commons community is supporting DBCP 2 > - tomcat-jdbc is stable > - support for tomcat-jdbc is sporadic at best > - DBCP 2 performance is very close to that of tomcat-jdbc (to > be clear, tomcat-jdbc still has better performance) > > I'd like to propose that we do not ship tomcat-jdbc with Tomcat 9 > onwards (i.e. remove it from trunk/modules). > > There are some features in tomcat-jdbc that are not available in Commons > DBCP 2. This proposal includes porting those features to DBCP 2 if there > is user demand for them. +1 If there is enough community interest in tomcat-jdbc, it can be released as a separate project. If there is not enough community interest... well, then, by definition it doesn't really fit The Apache Way. -chris signature.asc Description: OpenPGP digital signature
[GUMP@vmgump]: Project tomcat-tc8.0.x-test-apr (in module tomcat-8.0.x) 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-tc8.0.x-test-apr has an issue affecting its community integration. This issue affects 1 projects, and has been outstanding for 7 runs. The current state of this project is 'Failed', with reason 'Build Failed'. For reference only, the following projects are affected by this: - tomcat-tc8.0.x-test-apr : Tomcat 8.x, a web server implementing the Java Servlet 3.1, ... Full details are available at: http://vmgump.apache.org/gump/public/tomcat-8.0.x/tomcat-tc8.0.x-test-apr/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. -INFO- Failed with reason build failed -INFO- Project Reports in: /srv/gump/public/workspace/tomcat-8.0.x/output/logs-APR -INFO- Project Reports in: /srv/gump/public/workspace/tomcat-8.0.x/output/test-tmp-APR/logs The following work was performed: http://vmgump.apache.org/gump/public/tomcat-8.0.x/tomcat-tc8.0.x-test-apr/gump_work/build_tomcat-8.0.x_tomcat-tc8.0.x-test-apr.html Work Name: build_tomcat-8.0.x_tomcat-tc8.0.x-test-apr (Type: Build) Work ended in a state of : Failed Elapsed: 32 mins 20 secs Command Line: /usr/lib/jvm/java-8-oracle/bin/java -Djava.awt.headless=true -Dbuild.sysclasspath=only org.apache.tools.ant.Main -Dgump.merge=/srv/gump/public/gump/work/merge.xml -Djunit.jar=/srv/gump/public/workspace/junit/target/junit-4.13-SNAPSHOT.jar -Dobjenesis.jar=/srv/gump/public/workspace/objenesis/main/target/objenesis-2.2-SNAPSHOT.jar -Dtest.reports=output/logs-APR -Dtomcat-native.tar.gz=/srv/gump/public/workspace/apache-commons/daemon/dist/bin/commons-daemon-20150604-native-src.tar.gz -Dexamples.sources.skip=true -Djdt.jar=/srv/gump/packages/eclipse/plugins/R-4.4-201406061215/ecj-4.4.jar -Dtest.apr.loc=/srv/gump/public/workspace/tomcat-native/dest-20150604/lib -Dcommons-daemon.jar=/srv/gump/public/workspace/apache-commons/daemon/dist/commons-daemon-20150604.jar -Dcommons-daemon.native.src.tgz=/srv/gump/public/workspace/apache-commons/daemon/dist/bin/commons-daemon-20150604-native-src.tar.gz -Dtest.temp=output/test-tmp-APR -Dtest.accesslog=true -Dexecute.test.nio=false -Dtest .openssl.path=/srv/gump/public/workspace/openssl-1.0.2/dest-20150604/bin/openssl -Dexecute.test.bio=false -Dexecute.test.apr=true -Dtest.excludePerformance=true -Dexecute.test.nio2=false -Deasymock.jar=/srv/gump/public/workspace/easymock/easymock/target/easymock-3.4-SNAPSHOT.jar -Dhamcrest.jar=/srv/gump/packages/hamcrest/hamcrest-core-1.3.jar -Dcglib.jar=/srv/gump/packages/cglib/cglib-nodep-2.2.jar test [Working Directory: /srv/gump/public/workspace/tomcat-8.0.x] CLASSPATH: /usr/lib/jvm/java-8-oracle/lib/tools.jar:/srv/gump/public/workspace/tomcat-8.0.x/output/build/webapps/examples/WEB-INF/classes:/srv/gump/public/workspace/tomcat-8.0.x/output/testclasses:/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/tomcat-8.0.x/output/build/bin/bootstrap.jar:/srv/gump/public/workspace/tomcat-8.0.x/output/build/bin/tomcat-juli.jar:/srv/gump/public/workspace/tomcat-8.0.x/output/build/lib/annotations-api.jar:/srv/gump/public/workspace/tomcat-8.0.x/output/build/lib/servlet-api.ja r:/srv/gump/public/workspace/tomcat-8.0.x/output/build/lib/jsp-api.jar:/srv/gump/public/workspace/tomcat-8.0.x/output/build/lib/el-api.jar:/srv/gump/public/workspace/tomcat-8.0.x/output/build/lib/websocket-api.jar:/srv/gump/public/workspace/tomcat-8.0.x/output/build/lib/catalina.jar:/srv/gump/public/workspace/tomcat-8.0.x/output/build/lib/catalina-ant.jar:/srv/gump/public/workspace/tomcat-8.0.x/output/build/lib/catalina-storeconfig.jar:/srv/gump/public/workspace/tomcat-8.0.x/output/build/lib/tomcat-coyote.jar:/srv/gump/public/workspace/tomcat-8.0.x/output/build/lib/jasper.jar:/srv/gump/public/workspace/tomcat-8.0.x/output/build/lib/jasper-el.jar:/srv/gump/public/workspace/tomcat-8.0.x/output/build/lib/catalina-tribes.jar:/srv/gump/public/workspace/tomcat-8.0.x/output/build/lib/catalina-ha.jar:/srv/gump/public/workspace/tomcat-8.0.x/output/build/lib/tomcat-api.jar:/srv/gump/public/workspace/tomcat-8.0.x
[Bug 57980] After submitting a multipart form-data, if the Http request object is not parsed and return from server without parsing, causes browser crashed ('program cannot display the webpage' messag
https://bz.apache.org/bugzilla/show_bug.cgi?id=57980 --- Comment #9 from pgarnaik.wo...@gmail.com --- Thanks a lot, Chuck's hint 'maxSwallowSize' resolves the issue. I was not aware of this attribute. -- 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
[GUMP@vmgump]: Project tomcat-trunk-test-nio (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-test-nio has an issue affecting its community integration. This issue affects 1 projects, and has been outstanding for 23 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-test-nio : 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-test-nio/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. -INFO- Failed with reason build failed -INFO- Project Reports in: /srv/gump/public/workspace/tomcat-trunk/output/logs-NIO -INFO- Project Reports in: /srv/gump/public/workspace/tomcat-trunk/output/test-tmp-NIO/logs The following work was performed: http://vmgump.apache.org/gump/public/tomcat-trunk/tomcat-trunk-test-nio/gump_work/build_tomcat-trunk_tomcat-trunk-test-nio.html Work Name: build_tomcat-trunk_tomcat-trunk-test-nio (Type: Build) Work ended in a state of : Failed Elapsed: 33 mins 49 secs Command Line: /usr/lib/jvm/java-8-oracle/bin/java -Djava.awt.headless=true -Dbuild.sysclasspath=only org.apache.tools.ant.Main -Dgump.merge=/srv/gump/public/gump/work/merge.xml -Djunit.jar=/srv/gump/public/workspace/junit/target/junit-4.13-SNAPSHOT.jar -Dobjenesis.jar=/srv/gump/public/workspace/objenesis/main/target/objenesis-2.2-SNAPSHOT.jar -Dtest.reports=output/logs-NIO -Dtomcat-native.tar.gz=/srv/gump/public/workspace/apache-commons/daemon/dist/bin/commons-daemon-20150604-native-src.tar.gz -Dexamples.sources.skip=true -Djdt.jar=/srv/gump/packages/eclipse/plugins/R-4.4-201406061215/ecj-4.4.jar -Dcommons-daemon.jar=/srv/gump/public/workspace/apache-commons/daemon/dist/commons-daemon-20150604.jar -Dcommons-daemon.native.src.tgz=/srv/gump/public/workspace/apache-commons/daemon/dist/bin/commons-daemon-20150604-native-src.tar.gz -Dtest.temp=output/test-tmp-NIO -Dtest.accesslog=true -Dexecute.test.nio=true -Dtest.openssl.path=/srv/gump/public/workspace/openssl-master/dest-20150604/bin/o penssl -Dexecute.test.apr=false -Dtest.excludePerformance=true -Dexecute.test.nio2=false -Deasymock.jar=/srv/gump/public/workspace/easymock/easymock/target/easymock-3.4-SNAPSHOT.jar -Dhamcrest.jar=/srv/gump/packages/hamcrest/hamcrest-core-1.3.jar -Dcglib.jar=/srv/gump/packages/cglib/cglib-nodep-2.2.jar test [Working Directory: /srv/gump/public/workspace/tomcat-trunk] CLASSPATH: /usr/lib/jvm/java-8-oracle/lib/tools.jar:/srv/gump/public/workspace/tomcat-trunk/output/build/webapps/examples/WEB-INF/classes:/srv/gump/public/workspace/tomcat-trunk/output/testclasses:/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/tomcat-trunk/output/build/bin/bootstrap.jar:/srv/gump/public/workspace/tomcat-trunk/output/build/bin/tomcat-juli.jar:/srv/gump/public/workspace/tomcat-trunk/output/build/lib/annotations-api.jar:/srv/gump/public/workspace/tomcat-trunk/output/build/lib/servlet-api.ja r:/srv/gump/public/workspace/tomcat-trunk/output/build/lib/jsp-api.jar:/srv/gump/public/workspace/tomcat-trunk/output/build/lib/el-api.jar:/srv/gump/public/workspace/tomcat-trunk/output/build/lib/websocket-api.jar:/srv/gump/public/workspace/tomcat-trunk/output/build/lib/catalina.jar:/srv/gump/public/workspace/tomcat-trunk/output/build/lib/catalina-ant.jar:/srv/gump/public/workspace/tomcat-trunk/output/build/lib/catalina-storeconfig.jar:/srv/gump/public/workspace/tomcat-trunk/output/build/lib/tomcat-coyote.jar:/srv/gump/public/workspace/tomcat-trunk/output/build/lib/jasper.jar:/srv/gump/public/workspace/tomcat-trunk/output/build/lib/jasper-el.jar:/srv/gump/public/workspace/tomcat-trunk/output/build/lib/catalina-tribes.jar:/srv/gump/public/workspace/tomcat-trunk/output/build/lib/catalina-ha.jar:/srv/gump/public/workspace/tomcat-trunk/output/build/lib/tomcat-api.jar:/srv/gump/public/workspace/tomcat-trunk/output/build/lib/tomcat-jni.jar:/srv/gump/public/workspace/tomcat-trunk/output/bu ild/lib/tomcat-util.jar:/srv