svn commit: r1622173 - in /tomcat/tc7.0.x/trunk: ./ res/checkstyle/checkstyle.xml test/org/apache/catalina/core/TestStandardContext.java
Author: violetagg Date: Wed Sep 3 07:19:00 2014 New Revision: 1622173 URL: http://svn.apache.org/r1622173 Log: Merged revision 1621929 from tomcat/trunk: Fix unit test for BZ 56903 Modified: tomcat/tc7.0.x/trunk/ (props changed) tomcat/tc7.0.x/trunk/res/checkstyle/checkstyle.xml tomcat/tc7.0.x/trunk/test/org/apache/catalina/core/TestStandardContext.java Propchange: tomcat/tc7.0.x/trunk/ -- Merged /tomcat/trunk:r1621929 Modified: tomcat/tc7.0.x/trunk/res/checkstyle/checkstyle.xml URL: http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/res/checkstyle/checkstyle.xml?rev=1622173&r1=1622172&r2=1622173&view=diff == --- tomcat/tc7.0.x/trunk/res/checkstyle/checkstyle.xml (original) +++ tomcat/tc7.0.x/trunk/res/checkstyle/checkstyle.xml Wed Sep 3 07:19:00 2014 @@ -57,7 +57,7 @@ - + Modified: tomcat/tc7.0.x/trunk/test/org/apache/catalina/core/TestStandardContext.java URL: http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/test/org/apache/catalina/core/TestStandardContext.java?rev=1622173&r1=1622172&r2=1622173&view=diff == --- tomcat/tc7.0.x/trunk/test/org/apache/catalina/core/TestStandardContext.java (original) +++ tomcat/tc7.0.x/trunk/test/org/apache/catalina/core/TestStandardContext.java Wed Sep 3 07:19:00 2014 @@ -20,6 +20,7 @@ package org.apache.catalina.core; import java.io.File; import java.io.IOException; import java.io.PrintWriter; +import java.util.Arrays; import java.util.Set; import javax.servlet.Filter; @@ -41,6 +42,8 @@ import javax.servlet.http.HttpServlet; import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletResponse; +import org.hamcrest.CoreMatchers; + import static org.junit.Assert.assertEquals; import static org.junit.Assert.assertFalse; import static org.junit.Assert.assertNotSame; @@ -865,8 +868,8 @@ public class TestStandardContext extends public void testBug56903() { Context context = new StandardContext(); -String list = "a,b,c"; -context.setResourceOnlyServlets(list); -Assert.assertEquals(list, context.getResourceOnlyServlets()); +context.setResourceOnlyServlets("a,b,c"); + Assert.assertThat(Arrays.asList(context.getResourceOnlyServlets().split(",")), +CoreMatchers.hasItems("a", "b", "c")); } } - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
Re: svn commit: r1622166 - in /tomcat/tc7.0.x/trunk: ./ java/org/apache/catalina/core/StandardContext.java test/org/apache/catalina/core/TestStandardContext.java webapps/docs/changelog.xml
2014-09-03 9:16 GMT+03:00 Felix Schumacher < felix.schumac...@internetallee.de>: > > > > On 3. September 2014 08:05:59 MESZ, violet...@apache.org wrote: > >Author: violetagg > >Date: Wed Sep 3 06:05:58 2014 > >New Revision: 1622166 > > > >URL: http://svn.apache.org/r1622166 > >Log: > >Merged revision 1621731 from tomcat/trunk: > >Correct the return value for StandardContext.getResourceOnlyServlets() > >so that multiple names are separated by commas. Identified by Coverity > >Scan and fixed based on a patch by Felix Schumacher. > > > >Modified: > >tomcat/tc7.0.x/trunk/ (props changed) > >tomcat/tc7.0.x/trunk/java/org/apache/catalina/core/StandardContext.java > >tomcat/tc7.0.x/trunk/test/org/apache/catalina/core/TestStandardContext.java > >tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml > > > >Propchange: tomcat/tc7.0.x/trunk/ > >-- > > Merged /tomcat/trunk:r1621731 > > > >Modified: > >tomcat/tc7.0.x/trunk/java/org/apache/catalina/core/StandardContext.java > >URL: > > http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/java/org/apache/catalina/core/StandardContext.java?rev=1622166&r1=1622165&r2=1622166&view=diff > >== > >--- > >tomcat/tc7.0.x/trunk/java/org/apache/catalina/core/StandardContext.java > >(original) > >+++ > >tomcat/tc7.0.x/trunk/java/org/apache/catalina/core/StandardContext.java > >Wed Sep 3 06:05:58 2014 > >@@ -984,7 +984,9 @@ public class StandardContext extends Con > > StringBuilder result = new StringBuilder(); > > boolean first = true; > > for (String servletName : resourceOnlyServlets) { > >-if (!first) { > >+if (first) { > >+first = false; > >+} else { > > result.append(','); > > } > > result.append(servletName); > > > >Modified: > >tomcat/tc7.0.x/trunk/test/org/apache/catalina/core/TestStandardContext.java > >URL: > > http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/test/org/apache/catalina/core/TestStandardContext.java?rev=1622166&r1=1622165&r2=1622166&view=diff > >== > >--- > >tomcat/tc7.0.x/trunk/test/org/apache/catalina/core/TestStandardContext.java > >(original) > >+++ > >tomcat/tc7.0.x/trunk/test/org/apache/catalina/core/TestStandardContext.java > >Wed Sep 3 06:05:58 2014 > >@@ -68,6 +68,7 @@ import org.apache.catalina.startup.Tomca > > import org.apache.catalina.startup.TomcatBaseTest; > > import org.apache.tomcat.util.buf.ByteChunk; > > > >+ > > public class TestStandardContext extends TomcatBaseTest { > > > > private static final String REQUEST = > >@@ -859,4 +860,13 @@ public class TestStandardContext extends > > } > > > > } > >+ > >+@Test > >+public void testBug56903() { > >+Context context = new StandardContext(); > >+ > >+String list = "a,b,c"; > >+context.setResourceOnlyServlets(list); > >+Assert.assertEquals(list, context.getResourceOnlyServlets()); > >+} > This will probably not work. At least in trunk the string is generated of a set and thus will not always be sorted. So you either have to sort it or just check wether a, b and c are in the result. I merged the additional commit made by Mark. Regards, Violeta > Regards > Felix > > } > > > >Modified: tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml > >URL: > > http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml?rev=1622166&r1=1622165&r2=1622166&view=diff > >== > >--- tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml (original) > >+++ tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml Wed Sep 3 06:05:58 > >2014 > >@@ -103,6 +103,12 @@ > > when Context have been reloaded. (kkolinko) > > > > > >+56903: Correct the return value for > >+StandardContext.getResourceOnlyServlets() so that > >multiple > >+names are separated by commas. Identified by Coverity Scan and > >fixed > >+based on a patch by Felix Schumacher. (markt) > >+ > >+ > > Fixed the multipart elements merge operation performed during web > > application deployment. Identified by Coverity Scan. (violetagg) > > > > > > > > > >- > >To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org > >For additional commands, e-mail: dev-h...@tomcat.apache.org > > > - > To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org > For additional commands, e-mail: dev-h...@tomcat.apache.org >
Re: git (yet again)
On 02/09/2014 20:28, Konstantin Kolinko wrote: > In July I successfully configured Git to operate on the same set of > files as Subversion, on Windows. Neat. I use completely separate git and svn checkouts and swap between them as the mood suits me. As I get more familiar with git then I am using git more. Generally the only time when I have issues is when I try and take a short cut and do git development directly on trunk and then realise the issue is more complex and I really should be using a branch. > Impressions etc. > > 1. Such workflow works. It is great for building up experience with the tool. > > It also allows us to discuss Mark's "a) decide how we want to organise > development in git" point, without actually moving to Git. > > I think I can document it on a Wiki page, if others are interested. My impression is that it is more complex to set up than [1] and might make folks think git is more difficult to work with than it really is. > 2. An annoying fact is that the Git repository at git.apache.org lags > for up to one hour behind the Subversion one. > > The symptoms are as if the "git svn pull" is performed via some cron > job, instead of a postcommit hook or svn-pub-sub. I wonder whether > the Infra team can make it work better. The sync from svn to the git.a.o is based on svn-pub-sub and is meant to be close to real time. The replication it github is less frequent. Obviously this would cease to be an issue if we moved to git (note there is no git -> svn process to keep the old svn repo up to date). > 3. I would like to commit my ".git/info/attributes" file as > ".gitattributes" into Subversion. Can you put that file somewhere where others can take a look at it first? > 4. My impression is that Git works slower. My impression has been the opposite. git-svn is a little slower than just svn but that is expected since there is an extra layer. When I use git at work (with github) things seem very quick. > My points from the previous thread on this topic: > http://markmail.org/message/m7ig5a7wunyewdy6 > > Areas where we depend on Subversion and need to implement a fix before the > move: > 1). There is svn externals reference from Tomcat Native to Tomcat Trunk. > > (Does it mean that we have to migrate TC Native to Git at the same time? > Can we remove this svn externals reference?) We'd move Tomcat Native at the same time. There are equivalent features we can use to continue to use something svn external like. [2] > 2). svn revision numbers are used by the config difference form in the > Migration guide. > http://tomcat.apache.org/migration-8.html#Upgrading_8.0.x > > (Is it possible to replace it with links to similar Git tools, e.g. to > "compare" pages on GitHub? Does HTML GUI at git.apache.org have > similar history and compare pages?) I'm sure we could come up with something. > 3). The plan to create a Maven build (BZ 56397) relies on svn externals. > (I think it is time to abandon the idea.) I'm happy to leave this open for now. We could do this using one of the ideas in [2]. > 6. Maybe move away modules/bayeux and modules/tomcat-lite ? My expectation was that these would be left behind in svn. [1] http://wiki.apache.org/general/GitAtApache [2] http://stackoverflow.com/questions/571232/svnexternals-equivalent-in-git - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
Encoding request URI
Hi I have a problem sending UTF-8 encoded request URI to tomcat. I am always getting Bad request from tomcat. Charset is set to UTF-8 in the request. My connectors in server.xml have URIEncoding="UTF-8" set. I am using tomcat 8.0.11 on windows x64. I would appreciate any help. BRLulseged
svn commit: r1622187 - in /tomcat/trunk: java/org/apache/catalina/valves/ExtendedAccessLogValve.java webapps/docs/changelog.xml
Author: violetagg Date: Wed Sep 3 09:03:54 2014 New Revision: 1622187 URL: http://svn.apache.org/r1622187 Log: Correct the information written by ExtendedAccessLogValve when a format token x-O(XXX) is used so that multiple values for a header XXX are separated by commas. Identified by Coverity Scan. Modified: tomcat/trunk/java/org/apache/catalina/valves/ExtendedAccessLogValve.java tomcat/trunk/webapps/docs/changelog.xml Modified: tomcat/trunk/java/org/apache/catalina/valves/ExtendedAccessLogValve.java URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/catalina/valves/ExtendedAccessLogValve.java?rev=1622187&r1=1622186&r2=1622187&view=diff == --- tomcat/trunk/java/org/apache/catalina/valves/ExtendedAccessLogValve.java (original) +++ tomcat/trunk/java/org/apache/catalina/valves/ExtendedAccessLogValve.java Wed Sep 3 09:03:54 2014 @@ -339,7 +339,9 @@ public class ExtendedAccessLogValve exte StringBuilder buffer = new StringBuilder(); boolean first = true; while (iter.hasNext()) { -if (!first) { +if (first) { +first = false; +} else { buffer.append(","); } buffer.append(iter.next()); Modified: tomcat/trunk/webapps/docs/changelog.xml URL: http://svn.apache.org/viewvc/tomcat/trunk/webapps/docs/changelog.xml?rev=1622187&r1=1622186&r2=1622187&view=diff == --- tomcat/trunk/webapps/docs/changelog.xml (original) +++ tomcat/trunk/webapps/docs/changelog.xml Wed Sep 3 09:03:54 2014 @@ -88,6 +88,12 @@ Fixed the multipart elements merge operation performed during web application deployment. Identified by Coverity Scan. (violetagg) + +Correct the information written by +ExtendedAccessLogValve when a format token x-O(XXX) is +used so that multiple values for a header XXX are separated by commas. +Identified by Coverity Scan. (violetagg) + - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
svn commit: r1622189 - in /tomcat/tc7.0.x/trunk: ./ java/org/apache/catalina/valves/ExtendedAccessLogValve.java webapps/docs/changelog.xml
Author: violetagg Date: Wed Sep 3 09:06:07 2014 New Revision: 1622189 URL: http://svn.apache.org/r1622189 Log: Merged revision 1622187 from tomcat/trunk: Correct the information written by ExtendedAccessLogValve when a format token x-O(XXX) is used so that multiple values for a header XXX are separated by commas. Identified by Coverity Scan. Modified: tomcat/tc7.0.x/trunk/ (props changed) tomcat/tc7.0.x/trunk/java/org/apache/catalina/valves/ExtendedAccessLogValve.java tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml Propchange: tomcat/tc7.0.x/trunk/ -- Merged /tomcat/trunk:r1622187 Modified: tomcat/tc7.0.x/trunk/java/org/apache/catalina/valves/ExtendedAccessLogValve.java URL: http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/java/org/apache/catalina/valves/ExtendedAccessLogValve.java?rev=1622189&r1=1622188&r2=1622189&view=diff == --- tomcat/tc7.0.x/trunk/java/org/apache/catalina/valves/ExtendedAccessLogValve.java (original) +++ tomcat/tc7.0.x/trunk/java/org/apache/catalina/valves/ExtendedAccessLogValve.java Wed Sep 3 09:06:07 2014 @@ -358,7 +358,9 @@ public class ExtendedAccessLogValve exte StringBuilder buffer = new StringBuilder(); boolean first = true; while (iter.hasNext()) { -if (!first) { +if (first) { +first = false; +} else { buffer.append(","); } buffer.append(iter.next()); Modified: tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml URL: http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml?rev=1622189&r1=1622188&r2=1622189&view=diff == --- tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml (original) +++ tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml Wed Sep 3 09:06:07 2014 @@ -112,6 +112,12 @@ Fixed the multipart elements merge operation performed during web application deployment. Identified by Coverity Scan. (violetagg) + +Correct the information written by +ExtendedAccessLogValve when a format token x-O(XXX) is +used so that multiple values for a header XXX are separated by commas. +Identified by Coverity Scan. (violetagg) + - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
Re: Encoding request URI
On 03/09/2014 10:03, Lulseged Zerfu wrote: > Hi > I have a problem sending UTF-8 encoded request URI to tomcat. I am always > getting Bad request from tomcat. > Charset is set to UTF-8 in the request. My connectors in server.xml have > URIEncoding="UTF-8" set. > I am using tomcat 8.0.11 on windows x64. > I would appreciate any help. Read this: http://www.catb.org/esr/faqs/smart-questions.html Then post to the users mailing list. Mark - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
[VOTE][RESULT] Release Apache Tomcat 8.0.12
Binding: +1: kkolinko, violetagg, remm, jfarcand, markt No other votes were cast. The vote therefore passes. I'll release the bits shortly and announce once the mirrors have caught up (probably tomorrow). Mark - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
svn commit: r6361 - /dev/tomcat/tomcat-8/v8.0.12/ /release/tomcat/tomcat-8/v8.0.12/
Author: markt Date: Wed Sep 3 09:36:36 2014 New Revision: 6361 Log: Release Apache Tomcat 8.0.12 Added: release/tomcat/tomcat-8/v8.0.12/ - copied from r6312, dev/tomcat/tomcat-8/v8.0.12/ Removed: dev/tomcat/tomcat-8/v8.0.12/ - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
Re: git (yet again)
Am 02.09.2014 um 18:41 schrieb Mark Thomas: I've been looking at this again (anything to get a break from writing parsers for cookies) and chatting with some of the infra folks that look after the ASF's git repos. There are a couple of things we need to do: a) decide how we want to organise development in git b) decide if we want to move to git Now the decision we make for a) might influence some folks to make a different decision for b). On the other hand, there is no point debating a) if we are never going to move. So, how do folks want to approach this? A: Vote to move to git and then figure out how best to use it? or B: Agree our git workflows and then have a vote on moving to git with those workflows? I'm leaning towards A myself. It looks like the discussion in january and the answers on this thread show a majority for a move to git (not necessarily a consensus). I'd prefer if we knew more about the details before finally voting on it, so "B", and I expect the time and work needed for that will not be wasted. I agree with others about items for a). Things that come into my mind: - one repos or multiple: Actually I dont't care about that question per se, but more about the implications that will have (which I'm not sure about). For instance, does it matter in git, that we would only have one master (trunk), and the heads of the versions only as branches? - backport workflow I find "trunk first, then version branches" slightly better, but it might depend on details unknown to me. Concerning "cherry-pick" this seems to break the link between the original (e.g. master) commit and the commit on the branch. Not a good thing IMHO. - use of temporary feature or backport branches: delete after merge? - handling pull requests (tracking patch authors) - move tomcat-connectors as well, same repos? No preference here. - move old branches to simplify code archeology? I'd prefer so. - sources for the web site remain in svn? - is there (in principle) a way back from git to svn, or is this a one way street? No details needed, but if the project finds out the move was a bad thing, are we confident, that we can get back? - Konstantin provided some reasons against git during the last three discussions. Some of the might be mitigated by now (e.g. svn externals vs. git submodules? Version diffs), some of them might not (Buildbot and Jenkins integration, missing EU mirror). I guess experienced git users (like Martin Grigorov) could answer most questions easily, but I don't have the experience with git allowing me to understand implications of decisions. Regards, Rainer - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
buildbot exception in ASF Buildbot on tomcat-trunk
The Buildbot has detected a build exception on builder tomcat-trunk while building ASF Buildbot. Full details are available at: http://ci.apache.org/builders/tomcat-trunk/builds/390 Buildbot URL: http://ci.apache.org/ Buildslave for this Build: bb-vm_ubuntu Build Reason: scheduler Build Source Stamp: [branch tomcat/trunk] 1620326 Blamelist: BUILD FAILED: exception upload_2 sincerely, -The Buildbot - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
buildbot failure in ASF Buildbot on tomcat-trunk
The Buildbot has detected a new failure on builder tomcat-trunk while building ASF Buildbot. Full details are available at: http://ci.apache.org/builders/tomcat-trunk/builds/391 Buildbot URL: http://ci.apache.org/ Buildslave for this Build: bb-vm_ubuntu Build Reason: scheduler Build Source Stamp: [branch tomcat/trunk] 1620428 Blamelist: BUILD FAILED: failed compile sincerely, -The Buildbot - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
buildbot exception in ASF Buildbot on tomcat-trunk
The Buildbot has detected a build exception on builder tomcat-trunk while building ASF Buildbot. Full details are available at: http://ci.apache.org/builders/tomcat-trunk/builds/392 Buildbot URL: http://ci.apache.org/ Buildslave for this Build: bb-vm_ubuntu Build Reason: scheduler Build Source Stamp: [branch tomcat/trunk] 1620435 Blamelist: BUILD FAILED: exception upload_2 sincerely, -The Buildbot - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
Re: git (yet again)
On 3 September 2014 10:41, Rainer Jung wrote: > > Am 02.09.2014 um 18:41 schrieb Mark Thomas: > >> I've been looking at this again (anything to get a break from writing >> parsers for cookies) and chatting with some of the infra folks that look >> after the ASF's git repos. >> >> There are a couple of things we need to do: >> a) decide how we want to organise development in git >> b) decide if we want to move to git >> >> Now the decision we make for a) might influence some folks to make a >> different decision for b). On the other hand, there is no point debating >> a) if we are never going to move. >> >> So, how do folks want to approach this? > > >> A: Vote to move to git and then figure out how best to use it? or >> B: Agree our git workflows and then have a vote on moving to git with >> those workflows? >> There's one aspect of Git that does not seem to have been covered here: the commit messages don't seem to include what was actually changed. So in order to review a commit, it is necessary to click the link. In turn, this makes it harder to comment on a change. This is something that happens quite frequently with the SVN commit messages. Maybe it's possible to configure the commit messages so that diffs are shown; if not, then perhaps there needs to be a convention for how to comment on commits. - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
buildbot failure in ASF Buildbot on tomcat-trunk
The Buildbot has detected a new failure on builder tomcat-trunk while building ASF Buildbot. Full details are available at: http://ci.apache.org/builders/tomcat-trunk/builds/393 Buildbot URL: http://ci.apache.org/ Buildslave for this Build: bb-vm_ubuntu Build Reason: scheduler Build Source Stamp: [branch tomcat/trunk] 1620462 Blamelist: BUILD FAILED: failed compile sincerely, -The Buildbot - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
Re: git (yet again)
Le 03/09/2014 12:17, sebb a écrit : > Maybe it's possible to configure the commit messages so that diffs are > shown; if not, then perhaps there needs to be a convention for how to > comment on commits. I confirm this is possible, here is for example a commit message for a change on the tomcat8 package in Debian: http://lists.alioth.debian.org/pipermail/pkg-java-commits/2014-July/032758.html The commits are also threaded and grouped by push, see: http://lists.alioth.debian.org/pipermail/pkg-java-commits/2014-July/thread.html Emmanuel Bourg - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
buildbot exception in ASF Buildbot on tomcat-trunk
The Buildbot has detected a build exception on builder tomcat-trunk while building ASF Buildbot. Full details are available at: http://ci.apache.org/builders/tomcat-trunk/builds/395 Buildbot URL: http://ci.apache.org/ Buildslave for this Build: bb-vm_ubuntu Build Reason: scheduler Build Source Stamp: [branch tomcat/trunk] 1620546 Blamelist: BUILD FAILED: exception upload_2 sincerely, -The Buildbot - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
Time for 7.0.56
Hi, I plan to start with 7.0.56 release preparation in the next days. Regards, Violeta
Re: buildbot exception in ASF Buildbot on tomcat-trunk
On 03/09/2014 11:01, build...@apache.org wrote: > The Buildbot has detected a build exception on builder tomcat-trunk while > building ASF Buildbot. > Full details are available at: > http://ci.apache.org/builders/tomcat-trunk/builds/390 I've kicked our buildslave back into life. I'm expecting a bunch of errors as it works through the backlog of builds for us and a couple of other projects. I'll keep an eye on it in case there is anything fundamental that needs fixing. Mark - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
Re: git (yet again)
Hi all, On Sep 3, 2014 12:42 PM, "Rainer Jung" wrote: > > > Am 02.09.2014 um 18:41 schrieb Mark Thomas: > >> I've been looking at this again (anything to get a break from writing >> parsers for cookies) and chatting with some of the infra folks that look >> after the ASF's git repos. >> >> There are a couple of things we need to do: >> a) decide how we want to organise development in git >> b) decide if we want to move to git >> >> Now the decision we make for a) might influence some folks to make a >> different decision for b). On the other hand, there is no point debating >> a) if we are never going to move. >> >> So, how do folks want to approach this? > > >> A: Vote to move to git and then figure out how best to use it? or >> B: Agree our git workflows and then have a vote on moving to git with >> those workflows? >> >> I'm leaning towards A myself. > > > It looks like the discussion in january and the answers on this thread show a majority for a move to git (not necessarily a consensus). I'd prefer if we knew more about the details before finally voting on it, so "B", and I expect the time and work needed for that will not be wasted. > > I agree with others about items for a). Things that come into my mind: > > - one repos or multiple: Actually I dont't care about that question per se, but more about the implications that will have (which I'm not sure about). For instance, does it matter in git, that we would only have one master (trunk), and the heads of the versions only as branches? I am not sure how merging/cherry-pucking would work in separate repos. As I said before I use git-new-workdir to have different local working folders for branches of the same repo. This way I can have several branches opened simultaneously in the IDE. Konstantin noted that this doesn't work on Windows at the moment. > > - backport workflow > I find "trunk first, then version branches" slightly better, but it might depend on details unknown to me. Concerning "cherry-pick" this seems to break the link between the original (e.g. master) commit and the commit on the branch. Not a good thing IMHO. Each cherry picked commit has the sha id of the original in its message automatically. Additionally with "git cherry" you can check the branches a commit has been picked. > > - use of temporary feature or backport branches: delete after merge? Branching in Git is cheap. You can keep them if you want. Feature branches are usually deleted after merge. > > - handling pull requests (tracking patch authors) Apache committers don't have write access to GitHub mirrors. I have a Shell script to merge Pull Requests and preserve the authorship. The PR is automatically closed once the code is sync-ed as Mark already said. Commenting on code in a feature branch at GitHub UI doesn't notify the author nor the team. Not ideal! > > - move tomcat-connectors as well, same repos? No preference here. > > - move old branches to simplify code archeology? I'd prefer so. Most svn2git scripts support this. > > - sources for the web site remain in svn? This is the case for Apache Wicket. I'd like to change it to Git too. > > - is there (in principle) a way back from git to svn, or is this a one way street? No details needed, but if the project finds out the move was a bad thing, are we confident, that we can get back? > > - Konstantin provided some reasons against git during the last three discussions. Some of the might be mitigated by now (e.g. svn externals vs. git submodules? Version diffs), some of them might not (Buildbot and Jenkins integration, missing EU mirror). We use BuildBot without problems. For me US Git is much faster than EU SVN. I live in Bulgaria. > > I guess experienced git users (like Martin Grigorov) could answer most questions easily, but I don't have the experience with git allowing me to understand implications of decisions. > > Regards, > > Rainer > > > - > To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org > For additional commands, e-mail: dev-h...@tomcat.apache.org >
buildbot failure in ASF Buildbot on tomcat-trunk
The Buildbot has detected a new failure on builder tomcat-trunk while building ASF Buildbot. Full details are available at: http://ci.apache.org/builders/tomcat-trunk/builds/396 Buildbot URL: http://ci.apache.org/ Buildslave for this Build: bb-vm_ubuntu Build Reason: scheduler Build Source Stamp: [branch tomcat/trunk] 1620551 Blamelist: BUILD FAILED: failed compile sincerely, -The Buildbot - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
svn commit: r1622215 - in /tomcat/tc7.0.x/trunk: ./ java/org/apache/catalina/core/ApplicationContextFacade.java webapps/docs/changelog.xml
Author: violetagg Date: Wed Sep 3 10:43:48 2014 New Revision: 1622215 URL: http://svn.apache.org/r1622215 Log: Fix https://issues.apache.org/bugzilla/show_bug.cgi?id=56857 Merged revision 1618169 from tomcat/trunk: Fix thread safety issue when calling ServletContext methods while running under a security manager. Modified: tomcat/tc7.0.x/trunk/ (props changed) tomcat/tc7.0.x/trunk/java/org/apache/catalina/core/ApplicationContextFacade.java tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml Propchange: tomcat/tc7.0.x/trunk/ -- Merged /tomcat/trunk:r1618169 Modified: tomcat/tc7.0.x/trunk/java/org/apache/catalina/core/ApplicationContextFacade.java URL: http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/java/org/apache/catalina/core/ApplicationContextFacade.java?rev=1622215&r1=1622214&r2=1622215&view=diff == --- tomcat/tc7.0.x/trunk/java/org/apache/catalina/core/ApplicationContextFacade.java (original) +++ tomcat/tc7.0.x/trunk/java/org/apache/catalina/core/ApplicationContextFacade.java Wed Sep 3 10:43:48 2014 @@ -32,6 +32,7 @@ import java.util.EventListener; import java.util.HashMap; import java.util.Map; import java.util.Set; +import java.util.concurrent.ConcurrentHashMap; import javax.servlet.Filter; import javax.servlet.FilterRegistration; @@ -62,15 +63,15 @@ public class ApplicationContextFacade im /** * Cache Class object used for reflection. */ -private HashMap[]> classCache; - - +private final Map[]> classCache; + + /** * Cache method object. */ -private HashMap objectCache; - - +private final Map objectCache; + + // --- Constructors @@ -83,9 +84,9 @@ public class ApplicationContextFacade im public ApplicationContextFacade(ApplicationContext context) { super(); this.context = context; - + classCache = new HashMap[]>(); -objectCache = new HashMap(); +objectCache = new ConcurrentHashMap(); initClassCache(); } Modified: tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml URL: http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml?rev=1622215&r1=1622214&r2=1622215&view=diff == --- tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml (original) +++ tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml Wed Sep 3 10:43:48 2014 @@ -98,6 +98,10 @@ 56825: Enable pre-emptive authentication to work with the SSL authenticator. Based on a patch by jlmonteiro. (markt) + +56857: Fix thread safety issue when calling ServletContext +methods while running under a security manager. (markt) + 56882: Add testcase for processing of forwards and includes when Context have been reloaded. (kkolinko) - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
[Bug 56857] Thread safety issue in ApplicationContextFacade.invokeMethod
https://issues.apache.org/bugzilla/show_bug.cgi?id=56857 Violeta Georgieva changed: What|Removed |Added Status|NEW |RESOLVED Resolution|--- |FIXED --- Comment #4 from Violeta Georgieva --- The fix is downported in 7.0.x for 7.0.56 onwards. -- 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
[Bug 56857] Thread safety issue in ApplicationContextFacade.invokeMethod
https://issues.apache.org/bugzilla/show_bug.cgi?id=56857 --- Comment #5 from Volker Kleinschmidt --- Great news, thank you. -- 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: r1622234 - /tomcat/trunk/java/org/apache/catalina/util/ExtensionValidator.java
Author: markt Date: Wed Sep 3 12:17:18 2014 New Revision: 1622234 URL: http://svn.apache.org/r1622234 Log: Whitespace police Modified: tomcat/trunk/java/org/apache/catalina/util/ExtensionValidator.java Modified: tomcat/trunk/java/org/apache/catalina/util/ExtensionValidator.java URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/catalina/util/ExtensionValidator.java?rev=1622234&r1=1622233&r2=1622234&view=diff == --- tomcat/trunk/java/org/apache/catalina/util/ExtensionValidator.java (original) +++ tomcat/trunk/java/org/apache/catalina/util/ExtensionValidator.java Wed Sep 3 12:17:18 2014 @@ -176,7 +176,7 @@ public final class ExtensionValidator { ManifestResource.SYSTEM); containerManifestResources.add(mre); } -} +} } - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
svn commit: r1622263 - in /tomcat/trunk: bin/catalina.bat webapps/docs/changelog.xml
Author: markt Date: Wed Sep 3 14:09:00 2014 New Revision: 1622263 URL: http://svn.apache.org/r1622263 Log: Fix https://issues.apache.org/bugzilla/show_bug.cgi?id=56895 Correctly compose JAVA_OPTS in catalina.bat so that escape sequences are preserved. Patch by Lucas Theisen. Modified: tomcat/trunk/bin/catalina.bat tomcat/trunk/webapps/docs/changelog.xml Modified: tomcat/trunk/bin/catalina.bat URL: http://svn.apache.org/viewvc/tomcat/trunk/bin/catalina.bat?rev=1622263&r1=1622262&r2=1622263&view=diff == --- tomcat/trunk/bin/catalina.bat (original) +++ tomcat/trunk/bin/catalina.bat Wed Sep 3 14:09:00 2014 @@ -193,12 +193,12 @@ set LOGGING_CONFIG=-Dnop if not exist "%CATALINA_BASE%\conf\logging.properties" goto noJuliConfig set LOGGING_CONFIG=-Djava.util.logging.config.file="%CATALINA_BASE%\conf\logging.properties" :noJuliConfig -set JAVA_OPTS=%JAVA_OPTS% %LOGGING_CONFIG% +set "JAVA_OPTS=%JAVA_OPTS% %LOGGING_CONFIG%" if not "%LOGGING_MANAGER%" == "" goto noJuliManager set LOGGING_MANAGER=-Djava.util.logging.manager=org.apache.juli.ClassLoaderLogManager :noJuliManager -set JAVA_OPTS=%JAVA_OPTS% %LOGGING_MANAGER% +set "JAVA_OPTS=%JAVA_OPTS% %LOGGING_MANAGER%" rem - Execute The Requested Command --- Modified: tomcat/trunk/webapps/docs/changelog.xml URL: http://svn.apache.org/viewvc/tomcat/trunk/webapps/docs/changelog.xml?rev=1622263&r1=1622262&r2=1622263&view=diff == --- tomcat/trunk/webapps/docs/changelog.xml (original) +++ tomcat/trunk/webapps/docs/changelog.xml Wed Sep 3 14:09:00 2014 @@ -124,6 +124,15 @@ + + + +56895: Correctly compose JAVA_OPTS in +catalina.bat so that escape sequences are preserved. Patch +by Lucas Theisen. (markt) + + + - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
buildbot exception in ASF Buildbot on tomcat-trunk
The Buildbot has detected a build exception on builder tomcat-trunk while building ASF Buildbot. Full details are available at: http://ci.apache.org/builders/tomcat-trunk/builds/413 Buildbot URL: http://ci.apache.org/ Buildslave for this Build: bb-vm_ubuntu Build Reason: scheduler Build Source Stamp: [branch tomcat/trunk] 1621698 Blamelist: BUILD FAILED: exception upload_2 sincerely, -The Buildbot - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
buildbot failure in ASF Buildbot on tomcat-trunk
The Buildbot has detected a new failure on builder tomcat-trunk while building ASF Buildbot. Full details are available at: http://ci.apache.org/builders/tomcat-trunk/builds/418 Buildbot URL: http://ci.apache.org/ Buildslave for this Build: bb-vm_ubuntu Build Reason: scheduler Build Source Stamp: [branch tomcat/trunk] 1621868 Blamelist: BUILD FAILED: failed compile sincerely, -The Buildbot - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
svn commit: r1622264 - in /tomcat/tc7.0.x/trunk: ./ bin/catalina.bat webapps/docs/changelog.xml
Author: markt Date: Wed Sep 3 14:10:49 2014 New Revision: 1622264 URL: http://svn.apache.org/r1622264 Log: Fix https://issues.apache.org/bugzilla/show_bug.cgi?id=56895 Correctly compose JAVA_OPTS in catalina.bat so that escape sequences are preserved. Patch by Lucas Theisen. Modified: tomcat/tc7.0.x/trunk/ (props changed) tomcat/tc7.0.x/trunk/bin/catalina.bat tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml Propchange: tomcat/tc7.0.x/trunk/ -- Merged /tomcat/trunk:r1622263 Modified: tomcat/tc7.0.x/trunk/bin/catalina.bat URL: http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/bin/catalina.bat?rev=1622264&r1=1622263&r2=1622264&view=diff == --- tomcat/tc7.0.x/trunk/bin/catalina.bat (original) +++ tomcat/tc7.0.x/trunk/bin/catalina.bat Wed Sep 3 14:10:49 2014 @@ -176,12 +176,12 @@ set LOGGING_CONFIG=-Dnop if not exist "%CATALINA_BASE%\conf\logging.properties" goto noJuliConfig set LOGGING_CONFIG=-Djava.util.logging.config.file="%CATALINA_BASE%\conf\logging.properties" :noJuliConfig -set JAVA_OPTS=%JAVA_OPTS% %LOGGING_CONFIG% +set "JAVA_OPTS=%JAVA_OPTS% %LOGGING_CONFIG%" if not "%LOGGING_MANAGER%" == "" goto noJuliManager set LOGGING_MANAGER=-Djava.util.logging.manager=org.apache.juli.ClassLoaderLogManager :noJuliManager -set JAVA_OPTS=%JAVA_OPTS% %LOGGING_MANAGER% +set "JAVA_OPTS=%JAVA_OPTS% %LOGGING_MANAGER%" rem - Execute The Requested Command --- Modified: tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml URL: http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml?rev=1622264&r1=1622263&r2=1622264&view=diff == --- tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml (original) +++ tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml Wed Sep 3 14:10:49 2014 @@ -200,6 +200,11 @@ variables. Be more strict with executable filename on Windows (s/java/java.exe/). Based on a patch by Neeme Praks. (markt/kkolinko) + +56895: Correctly compose JAVA_OPTS in +catalina.bat so that escape sequences are preserved. Patch +by Lucas Theisen. (markt) + - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
svn commit: r1622233 - in /tomcat/trunk: java/org/apache/tomcat/websocket/WsWebSocketContainer.java webapps/docs/changelog.xml
Author: markt Date: Wed Sep 3 12:16:41 2014 New Revision: 1622233 URL: http://svn.apache.org/r1622233 Log: Fix https://issues.apache.org/bugzilla/show_bug.cgi?id=56907 Ensure that client IO threads are stopped if a secure WebSocket client connection fails. Modified: tomcat/trunk/java/org/apache/tomcat/websocket/WsWebSocketContainer.java tomcat/trunk/webapps/docs/changelog.xml Modified: tomcat/trunk/java/org/apache/tomcat/websocket/WsWebSocketContainer.java URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/tomcat/websocket/WsWebSocketContainer.java?rev=1622233&r1=1622232&r2=1622233&view=diff == --- tomcat/trunk/java/org/apache/tomcat/websocket/WsWebSocketContainer.java (original) +++ tomcat/trunk/java/org/apache/tomcat/websocket/WsWebSocketContainer.java Wed Sep 3 12:16:41 2014 @@ -273,6 +273,7 @@ public class WsWebSocketContainer ByteBuffer response; String subProtocol; +boolean success = false; try { fConnect.get(timeout, TimeUnit.MILLISECONDS); @@ -310,10 +311,15 @@ public class WsWebSocketContainer throw new DeploymentException( sm.getString("Sec-WebSocket-Protocol")); } +success = true; } catch (ExecutionException | InterruptedException | SSLException | EOFException | TimeoutException e) { throw new DeploymentException( sm.getString("wsWebSocketContainer.httpRequestFailed"), e); +} finally { +if (!success) { +channel.close(); +} } // Switch to WebSocket Modified: tomcat/trunk/webapps/docs/changelog.xml URL: http://svn.apache.org/viewvc/tomcat/trunk/webapps/docs/changelog.xml?rev=1622233&r1=1622232&r2=1622233&view=diff == --- tomcat/trunk/webapps/docs/changelog.xml (original) +++ tomcat/trunk/webapps/docs/changelog.xml Wed Sep 3 12:16:41 2014 @@ -112,6 +112,14 @@ + + + +56907: Ensure that client IO threads are stopped if a secure +WebSocket client connection fails. (markt) + + + - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
svn commit: r1622228 - in /tomcat/trunk: java/org/apache/catalina/util/ExtensionValidator.java webapps/docs/changelog.xml
Author: violetagg Date: Wed Sep 3 11:49:56 2014 New Revision: 168 URL: http://svn.apache.org/r168 Log: Fix a potential resource leak when reading MANIFEST.MF file for extension dependencies reported by Coverity Scan. Modified: tomcat/trunk/java/org/apache/catalina/util/ExtensionValidator.java tomcat/trunk/webapps/docs/changelog.xml Modified: tomcat/trunk/java/org/apache/catalina/util/ExtensionValidator.java URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/catalina/util/ExtensionValidator.java?rev=168&r1=167&r2=168&view=diff == --- tomcat/trunk/java/org/apache/catalina/util/ExtensionValidator.java (original) +++ tomcat/trunk/java/org/apache/catalina/util/ExtensionValidator.java Wed Sep 3 11:49:56 2014 @@ -169,14 +169,14 @@ public final class ExtensionValidator { * @param jarFile The system JAR whose manifest to add */ public static void addSystemResource(File jarFile) throws IOException { -Manifest manifest = getManifest(new FileInputStream(jarFile)); -if (manifest != null) { -ManifestResource mre -= new ManifestResource(jarFile.getAbsolutePath(), - manifest, - ManifestResource.SYSTEM); -containerManifestResources.add(mre); -} +try (InputStream is = new FileInputStream(jarFile)) { +Manifest manifest = getManifest(is); +if (manifest != null) { +ManifestResource mre = new ManifestResource(jarFile.getAbsolutePath(), manifest, +ManifestResource.SYSTEM); +containerManifestResources.add(mre); +} +} } Modified: tomcat/trunk/webapps/docs/changelog.xml URL: http://svn.apache.org/viewvc/tomcat/trunk/webapps/docs/changelog.xml?rev=168&r1=167&r2=168&view=diff == --- tomcat/trunk/webapps/docs/changelog.xml (original) +++ tomcat/trunk/webapps/docs/changelog.xml Wed Sep 3 11:49:56 2014 @@ -94,6 +94,10 @@ used so that multiple values for a header XXX are separated by commas. Identified by Coverity Scan. (violetagg) + +Fix a potential resource leak when reading MANIFEST.MF file for +extension dependencies reported by Coverity Scan. (violetagg) + - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
buildbot failure in ASF Buildbot on tomcat-trunk
The Buildbot has detected a new failure on builder tomcat-trunk while building ASF Buildbot. Full details are available at: http://ci.apache.org/builders/tomcat-trunk/builds/411 Buildbot URL: http://ci.apache.org/ Buildslave for this Build: bb-vm_ubuntu Build Reason: scheduler Build Source Stamp: [branch tomcat/trunk] 1621087 Blamelist: BUILD FAILED: failed compile sincerely, -The Buildbot - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
svn commit: r1622237 - /tomcat/trunk/webapps/docs/changelog.xml
Author: markt Date: Wed Sep 3 12:23:32 2014 New Revision: 1622237 URL: http://svn.apache.org/r1622237 Log: Add release date Modified: tomcat/trunk/webapps/docs/changelog.xml Modified: tomcat/trunk/webapps/docs/changelog.xml URL: http://svn.apache.org/viewvc/tomcat/trunk/webapps/docs/changelog.xml?rev=1622237&r1=1622236&r2=1622237&view=diff == --- tomcat/trunk/webapps/docs/changelog.xml (original) +++ tomcat/trunk/webapps/docs/changelog.xml Wed Sep 3 12:23:32 2014 @@ -121,7 +121,7 @@ - + - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
[Bug 56895] catalina.bat does not properly compose JAVA_OPTS
https://issues.apache.org/bugzilla/show_bug.cgi?id=56895 Mark Thomas changed: What|Removed |Added Status|NEW |RESOLVED Resolution|--- |FIXED OS||All --- Comment #1 from Mark Thomas --- Fixed in 8.0.x for 8.0.12 onwards and in 7.0.x for 7.0.56 onwards. -- 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: r1622240 - in /tomcat/tc7.0.x/trunk: ./ java/org/apache/catalina/util/ExtensionValidator.java webapps/docs/changelog.xml
Author: violetagg Date: Wed Sep 3 12:45:58 2014 New Revision: 1622240 URL: http://svn.apache.org/r1622240 Log: Merged revision 168 from tomcat/trunk: Fix a potential resource leak when reading MANIFEST.MF file for extension dependencies reported by Coverity Scan. Modified: tomcat/tc7.0.x/trunk/ (props changed) tomcat/tc7.0.x/trunk/java/org/apache/catalina/util/ExtensionValidator.java tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml Propchange: tomcat/tc7.0.x/trunk/ -- Merged /tomcat/trunk:r168 Modified: tomcat/tc7.0.x/trunk/java/org/apache/catalina/util/ExtensionValidator.java URL: http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/java/org/apache/catalina/util/ExtensionValidator.java?rev=1622240&r1=1622239&r2=1622240&view=diff == --- tomcat/tc7.0.x/trunk/java/org/apache/catalina/util/ExtensionValidator.java (original) +++ tomcat/tc7.0.x/trunk/java/org/apache/catalina/util/ExtensionValidator.java Wed Sep 3 12:45:58 2014 @@ -224,13 +224,22 @@ public final class ExtensionValidator { * @param jarFile The system JAR whose manifest to add */ public static void addSystemResource(File jarFile) throws IOException { -Manifest manifest = getManifest(new FileInputStream(jarFile)); -if (manifest != null) { -ManifestResource mre -= new ManifestResource(jarFile.getAbsolutePath(), - manifest, - ManifestResource.SYSTEM); -containerManifestResources.add(mre); +InputStream is = null; +try { +is = new FileInputStream(jarFile); +Manifest manifest = getManifest(is); +if (manifest != null) { +ManifestResource mre = new ManifestResource(jarFile.getAbsolutePath(), manifest, +ManifestResource.SYSTEM); +containerManifestResources.add(mre); +} +} finally { +if (is != null) { +try { +is.close(); +} catch (IOException e) { +} +} } } Modified: tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml URL: http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml?rev=1622240&r1=1622239&r2=1622240&view=diff == --- tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml (original) +++ tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml Wed Sep 3 12:45:58 2014 @@ -122,6 +122,10 @@ used so that multiple values for a header XXX are separated by commas. Identified by Coverity Scan. (violetagg) + +Fix a potential resource leak when reading MANIFEST.MF file for +extension dependencies reported by Coverity Scan. (violetagg) + - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
svn commit: r1622236 - in /tomcat/tc7.0.x/trunk: ./ java/org/apache/tomcat/websocket/WsWebSocketContainer.java webapps/docs/changelog.xml
Author: markt Date: Wed Sep 3 12:22:08 2014 New Revision: 1622236 URL: http://svn.apache.org/r1622236 Log: Fix https://issues.apache.org/bugzilla/show_bug.cgi?id=56907 Ensure that client IO threads are stopped if a secure WebSocket client connection fails. Modified: tomcat/tc7.0.x/trunk/ (props changed) tomcat/tc7.0.x/trunk/java/org/apache/tomcat/websocket/WsWebSocketContainer.java tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml Propchange: tomcat/tc7.0.x/trunk/ -- Merged /tomcat/trunk:r1622233 Modified: tomcat/tc7.0.x/trunk/java/org/apache/tomcat/websocket/WsWebSocketContainer.java URL: http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/java/org/apache/tomcat/websocket/WsWebSocketContainer.java?rev=1622236&r1=1622235&r2=1622236&view=diff == --- tomcat/tc7.0.x/trunk/java/org/apache/tomcat/websocket/WsWebSocketContainer.java (original) +++ tomcat/tc7.0.x/trunk/java/org/apache/tomcat/websocket/WsWebSocketContainer.java Wed Sep 3 12:22:08 2014 @@ -284,6 +284,7 @@ public class WsWebSocketContainer ByteBuffer response; String subProtocol; +boolean success = false; try { fConnect.get(timeout, TimeUnit.MILLISECONDS); @@ -321,6 +322,7 @@ public class WsWebSocketContainer throw new DeploymentException( sm.getString("Sec-WebSocket-Protocol")); } +success = true; } catch (ExecutionException e) { throw new DeploymentException( sm.getString("wsWebSocketContainer.httpRequestFailed"), e); @@ -336,6 +338,10 @@ public class WsWebSocketContainer } catch (TimeoutException e) { throw new DeploymentException( sm.getString("wsWebSocketContainer.httpRequestFailed"), e); +} finally { +if (!success) { +channel.close(); +} } // Switch to WebSocket Modified: tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml URL: http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml?rev=1622236&r1=1622235&r2=1622236&view=diff == --- tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml (original) +++ tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml Wed Sep 3 12:22:08 2014 @@ -164,6 +164,10 @@ amongst other things, the JNDI resources associated with the web application. (markt) + +56907: Ensure that client IO threads are stopped if a secure +WebSocket client connection fails. (markt) + - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
svn commit: r1622259 - /tomcat/trunk/java/org/apache/tomcat/websocket/PerMessageDeflate.java
Author: markt Date: Wed Sep 3 14:01:29 2014 New Revision: 1622259 URL: http://svn.apache.org/r1622259 Log: No need for volatile. Can be final. Reported by FindBugs. Modified: tomcat/trunk/java/org/apache/tomcat/websocket/PerMessageDeflate.java Modified: tomcat/trunk/java/org/apache/tomcat/websocket/PerMessageDeflate.java URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/tomcat/websocket/PerMessageDeflate.java?rev=1622259&r1=1622258&r2=1622259&view=diff == --- tomcat/trunk/java/org/apache/tomcat/websocket/PerMessageDeflate.java (original) +++ tomcat/trunk/java/org/apache/tomcat/websocket/PerMessageDeflate.java Wed Sep 3 14:01:29 2014 @@ -51,12 +51,12 @@ public class PerMessageDeflate implement private final Inflater inflater = new Inflater(true); private final ByteBuffer readBuffer = ByteBuffer.allocate(Constants.DEFAULT_BUFFER_SIZE); private final Deflater deflater = new Deflater(Deflater.DEFAULT_COMPRESSION, true); +private final byte[] EOM_BUFFER = new byte[EOM_BYTES.length + 1]; private volatile Transformation next; private volatile boolean skipDecompression = false; private volatile ByteBuffer writeBuffer = ByteBuffer.allocate(Constants.DEFAULT_BUFFER_SIZE); private volatile boolean firstCompressedFrameWritten = false; -private volatile byte[] EOM_BUFFER = new byte[EOM_BYTES.length + 1]; static PerMessageDeflate negotiate(List> preferences) { // Accept the first preference that the server is able to support - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
buildbot exception in ASF Buildbot on tomcat-trunk
The Buildbot has detected a build exception on builder tomcat-trunk while building ASF Buildbot. Full details are available at: http://ci.apache.org/builders/tomcat-trunk/builds/409 Buildbot URL: http://ci.apache.org/ Buildslave for this Build: bb-vm_ubuntu Build Reason: scheduler Build Source Stamp: [branch tomcat/trunk] 1620923 Blamelist: BUILD FAILED: exception upload_2 sincerely, -The Buildbot - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
svn commit: r1622253 - in /tomcat/tc7.0.x/trunk: ./ java/org/apache/tomcat/websocket/server/LocalStrings.properties java/org/apache/tomcat/websocket/server/WsServerContainer.java webapps/docs/changelo
Author: markt Date: Wed Sep 3 13:41:05 2014 New Revision: 1622253 URL: http://svn.apache.org/r1622253 Log: Fix https://issues.apache.org/bugzilla/show_bug.cgi?id=56905 Make destruction on web application stop of thread group used for WebSocket connections more robust. Patch by kkolinko with minor tweaks Modified: tomcat/tc7.0.x/trunk/ (props changed) tomcat/tc7.0.x/trunk/java/org/apache/tomcat/websocket/server/LocalStrings.properties tomcat/tc7.0.x/trunk/java/org/apache/tomcat/websocket/server/WsServerContainer.java tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml Propchange: tomcat/tc7.0.x/trunk/ -- Merged /tomcat/trunk:r1622251 Modified: tomcat/tc7.0.x/trunk/java/org/apache/tomcat/websocket/server/LocalStrings.properties URL: http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/java/org/apache/tomcat/websocket/server/LocalStrings.properties?rev=1622253&r1=1622252&r2=1622253&view=diff == --- tomcat/tc7.0.x/trunk/java/org/apache/tomcat/websocket/server/LocalStrings.properties (original) +++ tomcat/tc7.0.x/trunk/java/org/apache/tomcat/websocket/server/LocalStrings.properties Wed Sep 3 13:41:05 2014 @@ -24,7 +24,7 @@ serverContainer.missingEndpoint=An Endpo serverContainer.pojoDeploy=POJO class [{0}] deploying to path [{1}] in ServletContext [{2}] serverContainer.servletContextMismatch=Attempted to register a POJO annotated for WebSocket at path [{0}] in the ServletContext with context path [{1}] when the WebSocket ServerContainer is allocated to the ServletContext with context path [{2}] serverContainer.servletContextMissing=No ServletContext was specified -serverContainer.threadGroupNotDestroyed=Unable to destroy WebSocket thread group [{0}] as some threads were still running when the web application was stopped +serverContainer.threadGroupNotDestroyed=Unable to destroy WebSocket thread group [{0}] as [{1}] threads were still running when the web application was stopped. The thread group will be destroyed once the threads terminate. uriTemplate.duplicateParameter=The parameter [{0}] appears more than once in the path which is not permitted uriTemplate.emptySegment=The path [{0}] contains one or more empty segments which are is not permitted Modified: tomcat/tc7.0.x/trunk/java/org/apache/tomcat/websocket/server/WsServerContainer.java URL: http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/java/org/apache/tomcat/websocket/server/WsServerContainer.java?rev=1622253&r1=1622252&r2=1622253&view=diff == --- tomcat/tc7.0.x/trunk/java/org/apache/tomcat/websocket/server/WsServerContainer.java (original) +++ tomcat/tc7.0.x/trunk/java/org/apache/tomcat/websocket/server/WsServerContainer.java Wed Sep 3 13:41:05 2014 @@ -276,14 +276,42 @@ public class WsServerContainer extends W public void destroy() { shutdownExecutor(); super.destroy(); +// If the executor hasn't fully shutdown it won't be possible to +// destroy this thread group as there will still be threads running. +// Mark the thread group as daemon one, so that it destroys itself +// when thread count reaches zero. +// Synchronization on threadGroup is needed, as there is a race between +// destroy() call from termination of the last thread in thread group +// marked as daemon versus the explicit destroy() call. +int threadCount = threadGroup.activeCount(); +boolean success = false; try { -threadGroup.destroy(); -} catch (IllegalThreadStateException itse) { -// If the executor hasn't fully shutdown it won't be possible to -// destroy this thread group as there will still be threads running -log.warn(sm.getString("serverContainer.threadGroupNotDestroyed", -threadGroup.getName())); +while (true) { +int oldThreadCount = threadCount; +synchronized (threadGroup) { +if (threadCount > 0) { +Thread.yield(); +threadCount = threadGroup.activeCount(); +} +if (threadCount > 0 && threadCount != oldThreadCount) { +// Value not stabilized. Retry. +continue; +} +if (threadCount > 0) { +threadGroup.setDaemon(true); +} else { +threadGroup.destroy(); +success = true; +} +break; +} +} +} catch (IllegalThreadStateException exception) { +// Fall-through } +if (!success) { +log.warn(sm.getS
Re: Coverity static analysis scanning
Hi guys, Tomcat had also been analyzed for a couple of months on the SonarQube instance of the ASF [1], but the last analysis is very old. The analysis must be failing for some reasons, so I copy Olivier who's managing the SQ instance @ASF. He can certainly give you more information on how to get the analysis back to normal - and probably also how to get a login there. IMO, it's best to advertise and use this instance instead of Nemo - which we use @SonarSource mainly as a demo instance. [1] https://analysis.apache.org/dashboard/index/77101?did=1 - Fabrice belling...@apache.org fabrice.belling...@sonarsource.com From: Henri Gomez > Date: Wed, Aug 27, 2014 at 12:00 PM > Subject: Re: Coverity static analysis scanning > To: Tomcat Developers List , Fabrice Bellingard < > fabrice.belling...@sonarsource.com> > > > Fabrice Belingard, ASFer is working for Sonar. > I add him in loop so he could give us more informations > > 2014-08-27 11:45 GMT+02:00 Mark Thomas : > > On 26/08/2014 22:52, Henri Gomez wrote: > >> Hi all > >> > >> Are you aware SonarQube is analysing Tomcat in Nemo for years ? > >> > >> > >> http://nemo.sonarqube.org/dashboard/index/50544 > >> > >> 310 Blocker issues, 121 Critical issues. > > > > I took a quick look. The first 60 or so blocker issues I looked at were > > all false positives triggered by us catching Throwable for good reasons. > > Can we get a login to this system to make them as false positives? > > > > Mark > > > > > >> > >> Wondering if Coverity will provides more informations than SonarQube ? > >> > >> BTW, SonarQube is analysing major ASF projects for a long time now :) > >> > >> > >> 2014-08-26 11:20 GMT+02:00 Mark Thomas : > >>> All, > >>> > >>> I have been pinged off-list by Coverity to say that they have set up > >>> Tomcat with a free account with their static code analysis service. > >>> > >>> I think I have the ability to send invitations so if anyone wants to > >>> take a look at the results, just reply here. > >>> > >>> I have taken a quick look and they do appear to have found some valid > >>> threading issues. There are ~350 issues in total and I don't yet have a > >>> feel for the false positive rate. > >>> > >>> Mark > >>> > >>> - > >>> To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org > >>> For additional commands, e-mail: dev-h...@tomcat.apache.org > >>> > >> > >> - > >> To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org > >> For additional commands, e-mail: dev-h...@tomcat.apache.org > >> > > > > > > - > > To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org > > For additional commands, e-mail: dev-h...@tomcat.apache.org > > > >
[Bug 56907] Threads leak
https://issues.apache.org/bugzilla/show_bug.cgi?id=56907 Mark Thomas changed: What|Removed |Added Status|NEW |RESOLVED Resolution|--- |FIXED OS||All --- Comment #1 from Mark Thomas --- Thanks for the report. This has been fixed in 8.0.x for 8.0.13 onwards and in 7.0.x for 7.0.56 onwards. -- 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
buildbot exception in ASF Buildbot on tomcat-trunk
The Buildbot has detected a build exception on builder tomcat-trunk while building ASF Buildbot. Full details are available at: http://ci.apache.org/builders/tomcat-trunk/builds/420 Buildbot URL: http://ci.apache.org/ Buildslave for this Build: bb-vm_ubuntu Build Reason: scheduler Build Source Stamp: [branch tomcat/trunk] 1622263 Blamelist: markt BUILD FAILED: exception upload_2 sincerely, -The Buildbot - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
buildbot failure in ASF Buildbot on tomcat-trunk
The Buildbot has detected a new failure on builder tomcat-trunk while building ASF Buildbot. Full details are available at: http://ci.apache.org/builders/tomcat-trunk/builds/402 Buildbot URL: http://ci.apache.org/ Buildslave for this Build: bb-vm_ubuntu Build Reason: scheduler Build Source Stamp: [branch tomcat/trunk] 1620743 Blamelist: BUILD FAILED: failed compile sincerely, -The Buildbot - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
[Bug 56905] "Unable to destroy WebSocket thread group" warning when reloading examples webapp
https://issues.apache.org/bugzilla/show_bug.cgi?id=56905 Mark Thomas changed: What|Removed |Added Status|NEW |RESOLVED Resolution|--- |FIXED OS||All --- Comment #2 from Mark Thomas --- Patch looks sensible to me. Applied to 8.0.x for 8.0.13 onwards and to 7.0.x got 7.0.56 onwards. -- 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: git (yet again)
On 2014-09-03, sebb wrote: > Maybe it's possible to configure the commit messages so that diffs are > shown; if not, then perhaps there needs to be a convention for how to > comment on commits. Might be something that can be configured per project, we do get diffs for commits in Ant-land: for example http://mail-archives.apache.org/mod_mbox/ant-notifications/201408.mbox/%3C20bedaba96cd4b7582e31104e4d27d4a%40git.apache.org%3E Stefan - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
buildbot exception in ASF Buildbot on tomcat-trunk
The Buildbot has detected a build exception on builder tomcat-trunk while building ASF Buildbot. Full details are available at: http://ci.apache.org/builders/tomcat-trunk/builds/401 Buildbot URL: http://ci.apache.org/ Buildslave for this Build: bb-vm_ubuntu Build Reason: scheduler Build Source Stamp: [branch tomcat/trunk] 1620693 Blamelist: BUILD FAILED: exception compile upload_2 sincerely, -The Buildbot - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
svn commit: r1622251 - in /tomcat/trunk: java/org/apache/tomcat/websocket/server/LocalStrings.properties java/org/apache/tomcat/websocket/server/WsServerContainer.java webapps/docs/changelog.xml
Author: markt Date: Wed Sep 3 13:36:43 2014 New Revision: 1622251 URL: http://svn.apache.org/r1622251 Log: Fix https://issues.apache.org/bugzilla/show_bug.cgi?id=56905 Make destruction on web application stop of thread group used for WebSocket connections more robust. Patch by kkolinko with minor tweaks Modified: tomcat/trunk/java/org/apache/tomcat/websocket/server/LocalStrings.properties tomcat/trunk/java/org/apache/tomcat/websocket/server/WsServerContainer.java tomcat/trunk/webapps/docs/changelog.xml Modified: tomcat/trunk/java/org/apache/tomcat/websocket/server/LocalStrings.properties URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/tomcat/websocket/server/LocalStrings.properties?rev=1622251&r1=1622250&r2=1622251&view=diff == --- tomcat/trunk/java/org/apache/tomcat/websocket/server/LocalStrings.properties (original) +++ tomcat/trunk/java/org/apache/tomcat/websocket/server/LocalStrings.properties Wed Sep 3 13:36:43 2014 @@ -22,7 +22,7 @@ serverContainer.missingEndpoint=An Endpo serverContainer.pojoDeploy=POJO class [{0}] deploying to path [{1}] in ServletContext [{2}] serverContainer.servletContextMismatch=Attempted to register a POJO annotated for WebSocket at path [{0}] in the ServletContext with context path [{1}] when the WebSocket ServerContainer is allocated to the ServletContext with context path [{2}] serverContainer.servletContextMissing=No ServletContext was specified -serverContainer.threadGroupNotDestroyed=Unable to destroy WebSocket thread group [{0}] as some threads were still running when the web application was stopped +serverContainer.threadGroupNotDestroyed=Unable to destroy WebSocket thread group [{0}] as [{1}] threads were still running when the web application was stopped. The thread group will be destroyed once the threads terminate. uriTemplate.duplicateParameter=The parameter [{0}] appears more than once in the path which is not permitted uriTemplate.emptySegment=The path [{0}] contains one or more empty segments which are is not permitted Modified: tomcat/trunk/java/org/apache/tomcat/websocket/server/WsServerContainer.java URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/tomcat/websocket/server/WsServerContainer.java?rev=1622251&r1=1622250&r2=1622251&view=diff == --- tomcat/trunk/java/org/apache/tomcat/websocket/server/WsServerContainer.java (original) +++ tomcat/trunk/java/org/apache/tomcat/websocket/server/WsServerContainer.java Wed Sep 3 13:36:43 2014 @@ -273,14 +273,42 @@ public class WsServerContainer extends W public void destroy() { shutdownExecutor(); super.destroy(); +// If the executor hasn't fully shutdown it won't be possible to +// destroy this thread group as there will still be threads running. +// Mark the thread group as daemon one, so that it destroys itself +// when thread count reaches zero. +// Synchronization on threadGroup is needed, as there is a race between +// destroy() call from termination of the last thread in thread group +// marked as daemon versus the explicit destroy() call. +int threadCount = threadGroup.activeCount(); +boolean success = false; try { -threadGroup.destroy(); -} catch (IllegalThreadStateException itse) { -// If the executor hasn't fully shutdown it won't be possible to -// destroy this thread group as there will still be threads running -log.warn(sm.getString("serverContainer.threadGroupNotDestroyed", -threadGroup.getName())); +while (true) { +int oldThreadCount = threadCount; +synchronized (threadGroup) { +if (threadCount > 0) { +Thread.yield(); +threadCount = threadGroup.activeCount(); +} +if (threadCount > 0 && threadCount != oldThreadCount) { +// Value not stabilized. Retry. +continue; +} +if (threadCount > 0) { +threadGroup.setDaemon(true); +} else { +threadGroup.destroy(); +success = true; +} +break; +} +} +} catch (IllegalThreadStateException exception) { +// Fall-through } +if (!success) { +log.warn(sm.getString("serverContainer.threadGroupNotDestroyed", +threadGroup.getName(), Integer.valueOf(threadCount))); } } Modified: tomcat/trunk/webapps/docs/changelog.xml URL: http://svn.apache.org/viewvc/tomcat/trunk/webapps/docs/changelog.xml?rev=162225
svn commit: r1622270 - in /tomcat/tc7.0.x/trunk: ./ java/org/apache/catalina/servlets/DefaultServlet.java webapps/docs/changelog.xml
Author: violetagg Date: Wed Sep 3 14:27:20 2014 New Revision: 1622270 URL: http://svn.apache.org/r1622270 Log: Fix https://issues.apache.org/bugzilla/show_bug.cgi?id=56902 Merged revision 1621729 from tomcat/trunk: Potential resource leak in Default Servlet Based on a patch by Felix Schumacher Modified: tomcat/tc7.0.x/trunk/ (props changed) tomcat/tc7.0.x/trunk/java/org/apache/catalina/servlets/DefaultServlet.java tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml Propchange: tomcat/tc7.0.x/trunk/ -- Merged /tomcat/trunk:r1621729 Modified: tomcat/tc7.0.x/trunk/java/org/apache/catalina/servlets/DefaultServlet.java URL: http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/java/org/apache/catalina/servlets/DefaultServlet.java?rev=1622270&r1=1622269&r2=1622270&view=diff == --- tomcat/tc7.0.x/trunk/java/org/apache/catalina/servlets/DefaultServlet.java (original) +++ tomcat/tc7.0.x/trunk/java/org/apache/catalina/servlets/DefaultServlet.java Wed Sep 3 14:27:20 2014 @@ -2128,27 +2128,32 @@ public class DefaultServlet while ( (exception == null) && (ranges.hasNext()) ) { InputStream resourceInputStream = cacheEntry.resource.streamContent(); -InputStream istream = -new BufferedInputStream(resourceInputStream, input); - -Range currentRange = ranges.next(); - -// Writing MIME header. -ostream.println(); -ostream.println("--" + mimeSeparation); -if (contentType != null) -ostream.println("Content-Type: " + contentType); -ostream.println("Content-Range: bytes " + currentRange.start - + "-" + currentRange.end + "/" - + currentRange.length); -ostream.println(); - -// Printing content -exception = copyRange(istream, ostream, currentRange.start, - currentRange.end); - -istream.close(); +InputStream istream = null; +try { +istream = new BufferedInputStream(resourceInputStream, input); +Range currentRange = ranges.next(); +// Writing MIME header. +ostream.println(); +ostream.println("--" + mimeSeparation); +if (contentType != null) +ostream.println("Content-Type: " + contentType); +ostream.println("Content-Range: bytes " + currentRange.start + + "-" + currentRange.end + "/" + + currentRange.length); +ostream.println(); + +// Printing content +exception = copyRange(istream, ostream, currentRange.start, + currentRange.end); +} finally { +if (istream != null) { +try { +istream.close(); +} catch (IOException e) { +} +} +} } ostream.println(); Modified: tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml URL: http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml?rev=1622270&r1=1622269&r2=1622270&view=diff == --- tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml (original) +++ tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml Wed Sep 3 14:27:20 2014 @@ -107,6 +107,11 @@ when Context have been reloaded. (kkolinko) +56902: Fix a potential resource leak in the Default Servlet +reported by Coverity Scan. Based on a patch provided by Felix +Schumacher. (markt) + + 56903: Correct the return value for StandardContext.getResourceOnlyServlets() so that multiple names are separated by commas. Identified by Coverity Scan and fixed - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
svn commit: r1622277 - in /tomcat/tc7.0.x/trunk: ./ java/org/apache/catalina/core/DefaultInstanceManager.java java/org/apache/catalina/startup/ContextConfig.java webapps/docs/changelog.xml
Author: violetagg Date: Wed Sep 3 15:00:43 2014 New Revision: 1622277 URL: http://svn.apache.org/r1622277 Log: Merged revisions 1621725, 1621726, 1621727 from tomcat/trunk: Partial fix for https://issues.apache.org/bugzilla/show_bug.cgi?id=56900 Fix resource leaks reading property files Based on a patch by Felix Schumacher Modified: tomcat/tc7.0.x/trunk/ (props changed) tomcat/tc7.0.x/trunk/java/org/apache/catalina/core/DefaultInstanceManager.java tomcat/tc7.0.x/trunk/java/org/apache/catalina/startup/ContextConfig.java tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml Propchange: tomcat/tc7.0.x/trunk/ -- Merged /tomcat/trunk:r1621725-1621727 Modified: tomcat/tc7.0.x/trunk/java/org/apache/catalina/core/DefaultInstanceManager.java URL: http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/java/org/apache/catalina/core/DefaultInstanceManager.java?rev=1622277&r1=1622276&r2=1622277&view=diff == --- tomcat/tc7.0.x/trunk/java/org/apache/catalina/core/DefaultInstanceManager.java (original) +++ tomcat/tc7.0.x/trunk/java/org/apache/catalina/core/DefaultInstanceManager.java Wed Sep 3 15:00:43 2014 @@ -50,6 +50,7 @@ import org.apache.catalina.ContainerServ import org.apache.catalina.Globals; import org.apache.catalina.security.SecurityUtil; import org.apache.catalina.util.Introspection; +import org.apache.juli.logging.Log; import org.apache.tomcat.InstanceManager; import org.apache.tomcat.util.ExceptionUtils; import org.apache.tomcat.util.res.StringManager; @@ -72,9 +73,9 @@ public class DefaultInstanceManager impl protected final ClassLoader containerClassLoader; protected boolean privileged; protected boolean ignoreAnnotations; -private final Properties restrictedFilters = new Properties(); -private final Properties restrictedListeners = new Properties(); -private final Properties restrictedServlets = new Properties(); +private final Properties restrictedFilters; +private final Properties restrictedListeners; +private final Properties restrictedServlets; private final Map, AnnotationCacheEntry[]> annotationCache = new WeakHashMap, AnnotationCacheEntry[]>(); private final Map postConstructMethods; @@ -86,43 +87,18 @@ public class DefaultInstanceManager impl this.containerClassLoader = containerClassLoader; ignoreAnnotations = catalinaContext.getIgnoreAnnotations(); StringManager sm = StringManager.getManager(Constants.Package); -try { -InputStream is = -this.getClass().getClassLoader().getResourceAsStream -("org/apache/catalina/core/RestrictedServlets.properties"); -if (is != null) { -restrictedServlets.load(is); -} else { - catalinaContext.getLogger().error(sm.getString("defaultInstanceManager.restrictedServletsResource")); -} -} catch (IOException e) { - catalinaContext.getLogger().error(sm.getString("defaultInstanceManager.restrictedServletsResource"), e); -} - -try { -InputStream is = -this.getClass().getClassLoader().getResourceAsStream - ("org/apache/catalina/core/RestrictedListeners.properties"); -if (is != null) { -restrictedListeners.load(is); -} else { - catalinaContext.getLogger().error(sm.getString("defaultInstanceManager.restrictedListenersResources")); -} -} catch (IOException e) { - catalinaContext.getLogger().error(sm.getString("defaultInstanceManager.restrictedListenersResources"), e); -} -try { -InputStream is = -this.getClass().getClassLoader().getResourceAsStream - ("org/apache/catalina/core/RestrictedFilters.properties"); -if (is != null) { -restrictedFilters.load(is); -} else { - catalinaContext.getLogger().error(sm.getString("defaultInstanceManager.restrictedFiltersResource")); -} -} catch (IOException e) { - catalinaContext.getLogger().error(sm.getString("defaultInstanceManager.restrictedServletsResources"), e); -} +restrictedServlets = loadProperties( +"org/apache/catalina/core/RestrictedServlets.properties", + sm.getString("defaultInstanceManager.restrictedServletsResource"), +catalinaContext.getLogger()); +restrictedListeners = loadProperties( +"org/apache/catalina/core/RestrictedListeners.properties", +"defaultInstanceManager.restrictedListenersResources", +catalinaContext.getLogger()); +restrictedFilters = loadProperties( +
Re: git (yet again)
On Wed, Sep 3, 2014 at 2:54 PM, Stefan Bodewig wrote: > On 2014-09-03, sebb wrote: > > > Maybe it's possible to configure the commit messages so that diffs are > > shown; if not, then perhaps there needs to be a convention for how to > > comment on commits. > > Might be something that can be configured per project, we do get diffs > for commits in Ant-land: for example > > http://mail-archives.apache.org/mod_mbox/ant-notifications/201408.mbox/%3C20bedaba96cd4b7582e31104e4d27d4a%40git.apache.org%3E Diffs in mail notifications come for free in the ASF Git setup. Commenting on diffs in the email is not the important thing. Having an email means that another committer (i.e. someone with more knowledge) did something. The new thing is being able to comment on "the patch" (the Pull Request) provided by a contributor *before* it gets in the repo. Usually the contributors don't have the whole picture. > > > Stefan > > - > To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org > For additional commands, e-mail: dev-h...@tomcat.apache.org > >
[Bug 56903] Missing comma-Separator in StandardContexts getRessourceOnlyServlets - CID-45051
https://issues.apache.org/bugzilla/show_bug.cgi?id=56903 --- Comment #3 from Violeta Georgieva --- Fix is committed to 7.0.x and will be available in 7.0.56 onwards. -- 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
[Bug 56900] Resource Leaks found by CID 45266 and 45249
https://issues.apache.org/bugzilla/show_bug.cgi?id=56900 --- Comment #3 from Violeta Georgieva --- Fix is committed to 7.0.x and will be available in 7.0.56 onwards. -- 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
[Bug 56902] DefaultServlet could leak resource in method copy - CID-45243
https://issues.apache.org/bugzilla/show_bug.cgi?id=56902 --- Comment #2 from Violeta Georgieva --- Fix is committed to 7.0.x and will be available in 7.0.56 onwards. -- 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: r1622297 - in /tomcat/trunk: java/org/apache/catalina/util/ServerInfo.java webapps/docs/changelog.xml
Author: violetagg Date: Wed Sep 3 16:42:46 2014 New Revision: 1622297 URL: http://svn.apache.org/r1622297 Log: Fix some potential resource leaks when reading property files. Reported by Coverity Scan. Modified: tomcat/trunk/java/org/apache/catalina/util/ServerInfo.java tomcat/trunk/webapps/docs/changelog.xml Modified: tomcat/trunk/java/org/apache/catalina/util/ServerInfo.java URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/catalina/util/ServerInfo.java?rev=1622297&r1=1622296&r2=1622297&view=diff == --- tomcat/trunk/java/org/apache/catalina/util/ServerInfo.java (original) +++ tomcat/trunk/java/org/apache/catalina/util/ServerInfo.java Wed Sep 3 16:42:46 2014 @@ -58,12 +58,10 @@ public class ServerInfo { String built = null; String number = null; -try { -InputStream is = ServerInfo.class.getResourceAsStream -("/org/apache/catalina/util/ServerInfo.properties"); -Properties props = new Properties(); +Properties props = new Properties(); +try (InputStream is = ServerInfo.class.getResourceAsStream +("/org/apache/catalina/util/ServerInfo.properties")) { props.load(is); -is.close(); info = props.getProperty("server.info"); built = props.getProperty("server.built"); number = props.getProperty("server.number"); Modified: tomcat/trunk/webapps/docs/changelog.xml URL: http://svn.apache.org/viewvc/tomcat/trunk/webapps/docs/changelog.xml?rev=1622297&r1=1622296&r2=1622297&view=diff == --- tomcat/trunk/webapps/docs/changelog.xml (original) +++ tomcat/trunk/webapps/docs/changelog.xml Wed Sep 3 16:42:46 2014 @@ -98,6 +98,10 @@ Fix a potential resource leak when reading MANIFEST.MF file for extension dependencies reported by Coverity Scan. (violetagg) + +Fix some potential resource leaks when reading property files. Reported +by Coverity Scan. (violetagg) + - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
svn commit: r1622302 - in /tomcat/tc7.0.x/trunk: ./ java/org/apache/catalina/connector/Request.java test/org/apache/catalina/connector/TestRequest.java test/org/apache/catalina/connector/TesterRequest
Author: markt Date: Wed Sep 3 17:37:51 2014 New Revision: 1622302 URL: http://svn.apache.org/r1622302 Log: Correctly handle multiple accept-language headers rather than just using the first header to determine the user's preferred Locale. Modified: tomcat/tc7.0.x/trunk/ (props changed) tomcat/tc7.0.x/trunk/java/org/apache/catalina/connector/Request.java tomcat/tc7.0.x/trunk/test/org/apache/catalina/connector/TestRequest.java tomcat/tc7.0.x/trunk/test/org/apache/catalina/connector/TesterRequest.java tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml Propchange: tomcat/tc7.0.x/trunk/ -- Merged /tomcat/trunk:r1618112 Modified: tomcat/tc7.0.x/trunk/java/org/apache/catalina/connector/Request.java URL: http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/java/org/apache/catalina/connector/Request.java?rev=1622302&r1=1622301&r2=1622302&view=diff == --- tomcat/tc7.0.x/trunk/java/org/apache/catalina/connector/Request.java (original) +++ tomcat/tc7.0.x/trunk/java/org/apache/catalina/connector/Request.java Wed Sep 3 17:37:51 2014 @@ -3226,26 +3226,33 @@ public class Request localesParsed = true; +// Store the accumulated languages that have been requested in +// a local collection, sorted by the quality value (so we can +// add Locales in descending order). The values will be ArrayLists +// containing the corresponding Locales to be added +TreeMap> locales = new TreeMap>(); + Enumeration values = getHeaders("accept-language"); while (values.hasMoreElements()) { String value = values.nextElement(); -parseLocalesHeader(value); +parseLocalesHeader(value, locales); } +// Process the quality values in highest->lowest order (due to +// negating the Double value when creating the key) +for (ArrayList list : locales.values()) { +for (Locale locale : list) { +addLocale(locale); +} +} } /** * Parse accept-language header value. */ -protected void parseLocalesHeader(String value) { - -// Store the accumulated languages that have been requested in -// a local collection, sorted by the quality value (so we can -// add Locales in descending order). The values will be ArrayLists -// containing the corresponding Locales to be added -TreeMap> locales = new TreeMap>(); +protected void parseLocalesHeader(String value, TreeMap> locales) { // Preprocess the value to remove all whitespace int white = value.indexOf(' '); @@ -3340,17 +3347,7 @@ public class Request locales.put(key, values); } values.add(locale); - -} - -// Process the quality values in highest->lowest order (due to -// negating the Double value when creating the key) -for (ArrayList list : locales.values()) { -for (Locale locale : list) { -addLocale(locale); -} } - } Modified: tomcat/tc7.0.x/trunk/test/org/apache/catalina/connector/TestRequest.java URL: http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/test/org/apache/catalina/connector/TestRequest.java?rev=1622302&r1=1622301&r2=1622302&view=diff == --- tomcat/tc7.0.x/trunk/test/org/apache/catalina/connector/TestRequest.java (original) +++ tomcat/tc7.0.x/trunk/test/org/apache/catalina/connector/TestRequest.java Wed Sep 3 17:37:51 2014 @@ -28,6 +28,7 @@ import java.net.URL; import java.util.ArrayList; import java.util.Enumeration; import java.util.List; +import java.util.Locale; import java.util.TreeMap; import javax.servlet.ServletException; @@ -40,6 +41,7 @@ import static org.junit.Assert.assertNot import static org.junit.Assert.assertTrue; import static org.junit.Assert.fail; +import org.junit.Assert; import org.junit.Test; import org.apache.catalina.Context; @@ -660,7 +662,7 @@ public class TestRequest extends TomcatB writer.append("Content-Disposition: form-data; name=\"part\"\r\n"); writer.append("Content-Type: text/plain; charset=UTF-8\r\n"); writer.append("\r\n"); -writer.append("äö").append("\r\n"); +writer.append("��").append("\r\n"); writer.flush(); writer.append("\r\n"); @@ -687,7 +689,7 @@ public class TestRequest extends TomcatB while ((line = reader.readLine()) != null) { response.add(line); } -assertTrue(response.contains("Part äö")); +assertTrue(response.contains("Part ��")); } finally { if (reader != null) {
buildbot exception in ASF Buildbot on tomcat-7-trunk
The Buildbot has detected a build exception on builder tomcat-7-trunk while building ASF Buildbot. Full details are available at: http://ci.apache.org/builders/tomcat-7-trunk/builds/231 Buildbot URL: http://ci.apache.org/ Buildslave for this Build: bb-vm_ubuntu Build Reason: scheduler Build Source Stamp: [branch tomcat/tc7.0.x/trunk] 1622302 Blamelist: markt BUILD FAILED: exception svn upload_2 sincerely, -The Buildbot - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
svn commit: r1622303 - in /tomcat/tc7.0.x/trunk: ./ java/org/apache/catalina/connector/ java/org/apache/tomcat/util/http/parser/ test/org/apache/catalina/connector/ test/org/apache/tomcat/util/http/pa
Author: markt Date: Wed Sep 3 17:47:42 2014 New Revision: 1622303 URL: http://svn.apache.org/r1622303 Log: Fix https://issues.apache.org/bugzilla/show_bug.cgi?id=56848 Improve handling of accept-language headers Added: tomcat/tc7.0.x/trunk/java/org/apache/tomcat/util/http/parser/AcceptLanguage.java - copied, changed from r1618166, tomcat/trunk/java/org/apache/tomcat/util/http/parser/AcceptLanguage.java tomcat/tc7.0.x/trunk/test/org/apache/tomcat/util/http/parser/TestAcceptLanguage.java - copied unchanged from r1618166, tomcat/trunk/test/org/apache/tomcat/util/http/parser/TestAcceptLanguage.java Modified: tomcat/tc7.0.x/trunk/ (props changed) tomcat/tc7.0.x/trunk/java/org/apache/catalina/connector/Request.java tomcat/tc7.0.x/trunk/java/org/apache/tomcat/util/http/parser/HttpParser.java tomcat/tc7.0.x/trunk/java/org/apache/tomcat/util/http/parser/MediaType.java tomcat/tc7.0.x/trunk/test/org/apache/catalina/connector/TestRequest.java tomcat/tc7.0.x/trunk/test/org/apache/catalina/connector/TesterRequest.java tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml Propchange: tomcat/tc7.0.x/trunk/ -- Merged /tomcat/trunk:r1618166 Modified: tomcat/tc7.0.x/trunk/java/org/apache/catalina/connector/Request.java URL: http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/java/org/apache/catalina/connector/Request.java?rev=1622303&r1=1622302&r2=1622303&view=diff == --- tomcat/tc7.0.x/trunk/java/org/apache/catalina/connector/Request.java (original) +++ tomcat/tc7.0.x/trunk/java/org/apache/catalina/connector/Request.java Wed Sep 3 17:47:42 2014 @@ -21,6 +21,7 @@ import java.io.BufferedReader; import java.io.File; import java.io.IOException; import java.io.InputStream; +import java.io.StringReader; import java.io.UnsupportedEncodingException; import java.lang.reflect.InvocationTargetException; import java.nio.charset.Charset; @@ -74,7 +75,6 @@ import org.apache.catalina.core.Applicat import org.apache.catalina.core.AsyncContextImpl; import org.apache.catalina.realm.GenericPrincipal; import org.apache.catalina.util.ParameterMap; -import org.apache.catalina.util.StringParser; import org.apache.coyote.ActionCode; import org.apache.coyote.http11.upgrade.servlet31.HttpUpgradeHandler; import org.apache.juli.logging.Log; @@ -95,6 +95,7 @@ import org.apache.tomcat.util.http.fileu import org.apache.tomcat.util.http.fileupload.servlet.ServletFileUpload; import org.apache.tomcat.util.http.fileupload.servlet.ServletRequestContext; import org.apache.tomcat.util.http.mapper.MappingData; +import org.apache.tomcat.util.http.parser.AcceptLanguage; import org.apache.tomcat.util.res.StringManager; import org.ietf.jgss.GSSCredential; import org.ietf.jgss.GSSException; @@ -375,12 +376,6 @@ public class Request /** - * The string parser we will use for parsing request lines. - */ -private final StringParser parser = new StringParser(); - - -/** * Local port */ protected int localPort = -1; @@ -3254,99 +3249,24 @@ public class Request */ protected void parseLocalesHeader(String value, TreeMap> locales) { -// Preprocess the value to remove all whitespace -int white = value.indexOf(' '); -if (white < 0) { -white = value.indexOf('\t'); -} -if (white >= 0) { -StringBuilder sb = new StringBuilder(); -int len = value.length(); -for (int i = 0; i < len; i++) { -char ch = value.charAt(i); -if ((ch != ' ') && (ch != '\t')) { -sb.append(ch); -} -} -parser.setString(sb.toString()); -} else { -parser.setString(value); +List acceptLanguages; +try { +acceptLanguages = AcceptLanguage.parse(new StringReader(value)); +} catch (IOException e) { +// Mal-formed headers are ignore. Do the same in the unlikely event +// of an IOException. +return; } -// Process each comma-delimited language specification -int length = parser.getLength(); -while (true) { - -// Extract the next comma-delimited entry -int start = parser.getIndex(); -if (start >= length) { -break; -} -int end = parser.findChar(','); -String entry = parser.extract(start, end).trim(); -parser.advance(); // For the following entry - -// Extract the quality factor for this entry -double quality = 1.0; -int semi = entry.indexOf(";q="); -if (semi >= 0) { -try { -String strQuality = entry.substring(semi + 3); -if (strQuality.length()
svn commit: r1622304 - in /tomcat/tc7.0.x/trunk: ./ java/org/apache/tomcat/util/http/parser/HttpParser.java
Author: markt Date: Wed Sep 3 17:48:29 2014 New Revision: 1622304 URL: http://svn.apache.org/r1622304 Log: Fix parsing bug when quality ends in invalid character(s) Modified: tomcat/tc7.0.x/trunk/ (props changed) tomcat/tc7.0.x/trunk/java/org/apache/tomcat/util/http/parser/HttpParser.java Propchange: tomcat/tc7.0.x/trunk/ -- Merged /tomcat/trunk:r1618259 Modified: tomcat/tc7.0.x/trunk/java/org/apache/tomcat/util/http/parser/HttpParser.java URL: http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/java/org/apache/tomcat/util/http/parser/HttpParser.java?rev=1622304&r1=1622303&r2=1622304&view=diff == --- tomcat/tc7.0.x/trunk/java/org/apache/tomcat/util/http/parser/HttpParser.java (original) +++ tomcat/tc7.0.x/trunk/java/org/apache/tomcat/util/http/parser/HttpParser.java Wed Sep 3 17:48:29 2014 @@ -534,8 +534,9 @@ public class HttpParser { } else if (c == delimiter || c == 9 || c == 32 || c == -1) { break; } else { -// Go back so character is available for next read -input.skip(-1); +// Malformed. Use quality of zero so it is dropped and skip until +// EOF or the next delimiter +skipUntil(input, c, delimiter); return 0; } } - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
[Bug 56848] Tomcat accept-language parsing doesn't properly handle IETF BCP47 language tags
https://issues.apache.org/bugzilla/show_bug.cgi?id=56848 Mark Thomas changed: What|Removed |Added Status|NEW |RESOLVED Resolution|--- |FIXED --- Comment #2 from Mark Thomas --- This has also been fixed in 7.0.x for 7.0.56 onwards. -- 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: r1622306 - in /tomcat/tc7.0.x/trunk: ./ java/org/apache/catalina/util/ServerInfo.java webapps/docs/changelog.xml
Author: violetagg Date: Wed Sep 3 17:51:34 2014 New Revision: 1622306 URL: http://svn.apache.org/r1622306 Log: Merged revision 1622297 from tomcat/trunk: Fix some potential resource leaks when reading property files. Reported by Coverity Scan. Modified: tomcat/tc7.0.x/trunk/ (props changed) tomcat/tc7.0.x/trunk/java/org/apache/catalina/util/ServerInfo.java tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml Propchange: tomcat/tc7.0.x/trunk/ -- Merged /tomcat/trunk:r1622297 Modified: tomcat/tc7.0.x/trunk/java/org/apache/catalina/util/ServerInfo.java URL: http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/java/org/apache/catalina/util/ServerInfo.java?rev=1622306&r1=1622305&r2=1622306&view=diff == --- tomcat/tc7.0.x/trunk/java/org/apache/catalina/util/ServerInfo.java (original) +++ tomcat/tc7.0.x/trunk/java/org/apache/catalina/util/ServerInfo.java Wed Sep 3 17:51:34 2014 @@ -19,6 +19,7 @@ package org.apache.catalina.util; +import java.io.IOException; import java.io.InputStream; import java.util.Properties; @@ -54,17 +55,24 @@ public class ServerInfo { static { +Properties props = new Properties(); +InputStream is = null; try { -InputStream is = ServerInfo.class.getResourceAsStream -("/org/apache/catalina/util/ServerInfo.properties"); -Properties props = new Properties(); +is = ServerInfo.class.getResourceAsStream +("/org/apache/catalina/util/ServerInfo.properties"); props.load(is); -is.close(); serverInfo = props.getProperty("server.info"); serverBuilt = props.getProperty("server.built"); serverNumber = props.getProperty("server.number"); } catch (Throwable t) { ExceptionUtils.handleThrowable(t); +} finally { +if (is != null) { +try { +is.close(); +} catch (IOException e) { +} +} } if (serverInfo == null) serverInfo = "Apache Tomcat 7.0.x-dev"; Modified: tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml URL: http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml?rev=1622306&r1=1622305&r2=1622306&view=diff == --- tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml (original) +++ tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml Wed Sep 3 17:51:34 2014 @@ -145,6 +145,10 @@ 56848: Improve handling of accept-language headers. (markt) + +Fix some potential resource leaks when reading property files. Reported +by Coverity Scan. (violetagg) + - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
buildbot failure in ASF Buildbot on tomcat-7-trunk
The Buildbot has detected a new failure on builder tomcat-7-trunk while building ASF Buildbot. Full details are available at: http://ci.apache.org/builders/tomcat-7-trunk/builds/232 Buildbot URL: http://ci.apache.org/ Buildslave for this Build: bb-vm_ubuntu Build Reason: scheduler Build Source Stamp: [branch tomcat/tc7.0.x/trunk] 1622306 Blamelist: markt,violetagg BUILD FAILED: failed compile sincerely, -The Buildbot - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
Re: buildbot failure in ASF Buildbot on tomcat-7-trunk
On 03/09/2014 18:58, build...@apache.org wrote: > The Buildbot has detected a new failure on builder tomcat-7-trunk while > building ASF Buildbot. > Full details are available at: > http://ci.apache.org/builders/tomcat-7-trunk/builds/232 > > Buildbot URL: http://ci.apache.org/ > > Buildslave for this Build: bb-vm_ubuntu > > Build Reason: scheduler > Build Source Stamp: [branch tomcat/tc7.0.x/trunk] 1622306 > Blamelist: markt,violetagg > > BUILD FAILED: failed compile Bah. Locale.forLanguageTag isn't available with Java 6. I didn't notice as I use Java 7 in the IDE because of WebSocket. I'll see if I can find an alternative. Mark - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
svn commit: r1622312 - in /tomcat/trunk: java/org/apache/catalina/util/CharsetMapper.java java/org/apache/tomcat/util/descriptor/web/FragmentJarScannerCallback.java webapps/docs/changelog.xml
Author: violetagg Date: Wed Sep 3 18:22:14 2014 New Revision: 1622312 URL: http://svn.apache.org/r1622312 Log: Fix some potential resource leaks when reading files and other resources. Reported by Coverity Scan. Modified: tomcat/trunk/java/org/apache/catalina/util/CharsetMapper.java tomcat/trunk/java/org/apache/tomcat/util/descriptor/web/FragmentJarScannerCallback.java tomcat/trunk/webapps/docs/changelog.xml Modified: tomcat/trunk/java/org/apache/catalina/util/CharsetMapper.java URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/catalina/util/CharsetMapper.java?rev=1622312&r1=1622311&r2=1622312&view=diff == --- tomcat/trunk/java/org/apache/catalina/util/CharsetMapper.java (original) +++ tomcat/trunk/java/org/apache/catalina/util/CharsetMapper.java Wed Sep 3 18:22:14 2014 @@ -69,11 +69,8 @@ public class CharsetMapper { * resource could not be loaded for any reason. */ public CharsetMapper(String name) { -try { -InputStream stream = - this.getClass().getResourceAsStream(name); +try (InputStream stream = this.getClass().getResourceAsStream(name)) { map.load(stream); -stream.close(); } catch (Throwable t) { ExceptionUtils.handleThrowable(t); throw new IllegalArgumentException(t.toString()); Modified: tomcat/trunk/java/org/apache/tomcat/util/descriptor/web/FragmentJarScannerCallback.java URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/tomcat/util/descriptor/web/FragmentJarScannerCallback.java?rev=1622312&r1=1622311&r2=1622312&view=diff == --- tomcat/trunk/java/org/apache/tomcat/util/descriptor/web/FragmentJarScannerCallback.java (original) +++ tomcat/trunk/java/org/apache/tomcat/util/descriptor/web/FragmentJarScannerCallback.java Wed Sep 3 18:22:14 2014 @@ -111,15 +111,13 @@ public class FragmentJarScannerCallback @Override public void scan(File file, String webappPath, boolean isWebapp) throws IOException { -InputStream stream = null; WebXml fragment = new WebXml(); fragment.setWebappJar(isWebapp); fragment.setDelegate(delegate); -try { -File fragmentFile = new File(file, FRAGMENT_LOCATION); +File fragmentFile = new File(file, FRAGMENT_LOCATION); +try (InputStream stream = new FileInputStream(fragmentFile)) { if (fragmentFile.isFile()) { -stream = new FileInputStream(fragmentFile); InputSource source = new InputSource(fragmentFile.toURI().toURL().toString()); source.setByteStream(stream); Modified: tomcat/trunk/webapps/docs/changelog.xml URL: http://svn.apache.org/viewvc/tomcat/trunk/webapps/docs/changelog.xml?rev=1622312&r1=1622311&r2=1622312&view=diff == --- tomcat/trunk/webapps/docs/changelog.xml (original) +++ tomcat/trunk/webapps/docs/changelog.xml Wed Sep 3 18:22:14 2014 @@ -99,8 +99,8 @@ extension dependencies reported by Coverity Scan. (violetagg) -Fix some potential resource leaks when reading property files. Reported -by Coverity Scan. (violetagg) +Fix some potential resource leaks when reading properties, files and +other resources. Reported by Coverity Scan. (violetagg) - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
buildbot failure in ASF Buildbot on tomcat-trunk
The Buildbot has detected a new failure on builder tomcat-trunk while building ASF Buildbot. Full details are available at: http://ci.apache.org/builders/tomcat-trunk/builds/422 Buildbot URL: http://ci.apache.org/ Buildslave for this Build: bb-vm_ubuntu Build Reason: scheduler Build Source Stamp: [branch tomcat/trunk] 1622312 Blamelist: violetagg BUILD FAILED: failed compile sincerely, -The Buildbot - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
svn commit: r1622313 - in /tomcat/tc7.0.x/trunk: ./ java/org/apache/tomcat/util/http/parser/HttpParser.java
Author: markt Date: Wed Sep 3 18:52:46 2014 New Revision: 1622313 URL: http://svn.apache.org/r1622313 Log: Revert r1622304. It depends on a Java 7 API. Modified: tomcat/tc7.0.x/trunk/ (props changed) tomcat/tc7.0.x/trunk/java/org/apache/tomcat/util/http/parser/HttpParser.java Propchange: tomcat/tc7.0.x/trunk/ -- Reverse-merged /tomcat/trunk:r1618259 Modified: tomcat/tc7.0.x/trunk/java/org/apache/tomcat/util/http/parser/HttpParser.java URL: http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/java/org/apache/tomcat/util/http/parser/HttpParser.java?rev=1622313&r1=1622312&r2=1622313&view=diff == --- tomcat/tc7.0.x/trunk/java/org/apache/tomcat/util/http/parser/HttpParser.java (original) +++ tomcat/tc7.0.x/trunk/java/org/apache/tomcat/util/http/parser/HttpParser.java Wed Sep 3 18:52:46 2014 @@ -534,9 +534,8 @@ public class HttpParser { } else if (c == delimiter || c == 9 || c == 32 || c == -1) { break; } else { -// Malformed. Use quality of zero so it is dropped and skip until -// EOF or the next delimiter -skipUntil(input, c, delimiter); +// Go back so character is available for next read +input.skip(-1); return 0; } } - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
svn commit: r1622314 - in /tomcat/tc7.0.x/trunk: ./ java/org/apache/catalina/connector/ java/org/apache/tomcat/util/http/parser/ test/org/apache/catalina/connector/ test/org/apache/tomcat/util/http/pa
Author: markt Date: Wed Sep 3 18:53:56 2014 New Revision: 1622314 URL: http://svn.apache.org/r1622314 Log: Fix https://issues.apache.org/bugzilla/show_bug.cgi?id=56848 Revert r1622303. It depends on a Java 7 API. Removed: tomcat/tc7.0.x/trunk/java/org/apache/tomcat/util/http/parser/AcceptLanguage.java tomcat/tc7.0.x/trunk/test/org/apache/tomcat/util/http/parser/TestAcceptLanguage.java Modified: tomcat/tc7.0.x/trunk/ (props changed) tomcat/tc7.0.x/trunk/java/org/apache/catalina/connector/Request.java tomcat/tc7.0.x/trunk/java/org/apache/tomcat/util/http/parser/HttpParser.java tomcat/tc7.0.x/trunk/java/org/apache/tomcat/util/http/parser/MediaType.java tomcat/tc7.0.x/trunk/test/org/apache/catalina/connector/TestRequest.java tomcat/tc7.0.x/trunk/test/org/apache/catalina/connector/TesterRequest.java tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml Propchange: tomcat/tc7.0.x/trunk/ -- Reverse-merged /tomcat/trunk:r1618166 Modified: tomcat/tc7.0.x/trunk/java/org/apache/catalina/connector/Request.java URL: http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/java/org/apache/catalina/connector/Request.java?rev=1622314&r1=1622313&r2=1622314&view=diff == --- tomcat/tc7.0.x/trunk/java/org/apache/catalina/connector/Request.java (original) +++ tomcat/tc7.0.x/trunk/java/org/apache/catalina/connector/Request.java Wed Sep 3 18:53:56 2014 @@ -21,7 +21,6 @@ import java.io.BufferedReader; import java.io.File; import java.io.IOException; import java.io.InputStream; -import java.io.StringReader; import java.io.UnsupportedEncodingException; import java.lang.reflect.InvocationTargetException; import java.nio.charset.Charset; @@ -75,6 +74,7 @@ import org.apache.catalina.core.Applicat import org.apache.catalina.core.AsyncContextImpl; import org.apache.catalina.realm.GenericPrincipal; import org.apache.catalina.util.ParameterMap; +import org.apache.catalina.util.StringParser; import org.apache.coyote.ActionCode; import org.apache.coyote.http11.upgrade.servlet31.HttpUpgradeHandler; import org.apache.juli.logging.Log; @@ -95,7 +95,6 @@ import org.apache.tomcat.util.http.fileu import org.apache.tomcat.util.http.fileupload.servlet.ServletFileUpload; import org.apache.tomcat.util.http.fileupload.servlet.ServletRequestContext; import org.apache.tomcat.util.http.mapper.MappingData; -import org.apache.tomcat.util.http.parser.AcceptLanguage; import org.apache.tomcat.util.res.StringManager; import org.ietf.jgss.GSSCredential; import org.ietf.jgss.GSSException; @@ -376,6 +375,12 @@ public class Request /** + * The string parser we will use for parsing request lines. + */ +private final StringParser parser = new StringParser(); + + +/** * Local port */ protected int localPort = -1; @@ -3249,24 +3254,99 @@ public class Request */ protected void parseLocalesHeader(String value, TreeMap> locales) { -List acceptLanguages; -try { -acceptLanguages = AcceptLanguage.parse(new StringReader(value)); -} catch (IOException e) { -// Mal-formed headers are ignore. Do the same in the unlikely event -// of an IOException. -return; +// Preprocess the value to remove all whitespace +int white = value.indexOf(' '); +if (white < 0) { +white = value.indexOf('\t'); +} +if (white >= 0) { +StringBuilder sb = new StringBuilder(); +int len = value.length(); +for (int i = 0; i < len; i++) { +char ch = value.charAt(i); +if ((ch != ' ') && (ch != '\t')) { +sb.append(ch); +} +} +parser.setString(sb.toString()); +} else { +parser.setString(value); } -for (AcceptLanguage acceptLanguage : acceptLanguages) { +// Process each comma-delimited language specification +int length = parser.getLength(); +while (true) { + +// Extract the next comma-delimited entry +int start = parser.getIndex(); +if (start >= length) { +break; +} +int end = parser.findChar(','); +String entry = parser.extract(start, end).trim(); +parser.advance(); // For the following entry + +// Extract the quality factor for this entry +double quality = 1.0; +int semi = entry.indexOf(";q="); +if (semi >= 0) { +try { +String strQuality = entry.substring(semi + 3); +if (strQuality.length() <= 5) { +quality = Double.parseDouble(strQuality); +} else { +quality = 0.0; +
[Bug 56848] Tomcat accept-language parsing doesn't properly handle IETF BCP47 language tags
https://issues.apache.org/bugzilla/show_bug.cgi?id=56848 Mark Thomas changed: What|Removed |Added Status|RESOLVED|REOPENED Resolution|FIXED |--- --- Comment #3 from Mark Thomas --- The fix is Java 7 specific. Tomcat 7 has to run on Java 6 and there simply isn't the support for BCP47 in the Java 7 API. I'm leaning towards resolving this as WONTFIX. -- 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: r1622324 - /tomcat/tc7.0.x/trunk/test/org/apache/catalina/connector/TestRequest.java
Author: markt Date: Wed Sep 3 19:26:38 2014 New Revision: 1622324 URL: http://svn.apache.org/r1622324 Log: Don't use Java 7 API in unit tests Modified: tomcat/tc7.0.x/trunk/test/org/apache/catalina/connector/TestRequest.java Modified: tomcat/tc7.0.x/trunk/test/org/apache/catalina/connector/TestRequest.java URL: http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/test/org/apache/catalina/connector/TestRequest.java?rev=1622324&r1=1622323&r2=1622324&view=diff == --- tomcat/tc7.0.x/trunk/test/org/apache/catalina/connector/TestRequest.java (original) +++ tomcat/tc7.0.x/trunk/test/org/apache/catalina/connector/TestRequest.java Wed Sep 3 19:26:38 2014 @@ -818,7 +818,7 @@ public class TestRequest extends TomcatB req.addHeader("accept-language", "en-gb"); Locale actual = req.getLocale(); -Locale expected = Locale.forLanguageTag("en-gb"); +Locale expected = new Locale("en", "gb"); Assert.assertEquals(expected, actual); } @@ -835,7 +835,7 @@ public class TestRequest extends TomcatB req.addHeader("accept-language", "en;q=0.5"); Locale actual = req.getLocale(); -Locale expected = Locale.forLanguageTag("en-gb"); +Locale expected = new Locale("en", "gb"); Assert.assertEquals(expected, actual); } - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
svn commit: r1622328 - in /tomcat/tc7.0.x/trunk: ./ java/org/apache/catalina/authenticator/ java/org/apache/coyote/http11/ test/org/apache/tomcat/util/net/
Author: markt Date: Wed Sep 3 19:30:15 2014 New Revision: 1622328 URL: http://svn.apache.org/r1622328 Log: Don't trigger re-authentication for webapps that don't need it. Modified: tomcat/tc7.0.x/trunk/ (props changed) tomcat/tc7.0.x/trunk/java/org/apache/catalina/authenticator/AuthenticatorBase.java tomcat/tc7.0.x/trunk/java/org/apache/catalina/authenticator/SSLAuthenticator.java tomcat/tc7.0.x/trunk/java/org/apache/coyote/http11/Http11AprProcessor.java tomcat/tc7.0.x/trunk/java/org/apache/coyote/http11/Http11NioProcessor.java tomcat/tc7.0.x/trunk/java/org/apache/coyote/http11/Http11Processor.java tomcat/tc7.0.x/trunk/test/org/apache/tomcat/util/net/TestClientCert.java Propchange: tomcat/tc7.0.x/trunk/ -- Merged /tomcat/trunk:r1617461 Modified: tomcat/tc7.0.x/trunk/java/org/apache/catalina/authenticator/AuthenticatorBase.java URL: http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/java/org/apache/catalina/authenticator/AuthenticatorBase.java?rev=1622328&r1=1622327&r2=1622328&view=diff == --- tomcat/tc7.0.x/trunk/java/org/apache/catalina/authenticator/AuthenticatorBase.java (original) +++ tomcat/tc7.0.x/trunk/java/org/apache/catalina/authenticator/AuthenticatorBase.java Wed Sep 3 19:30:15 2014 @@ -562,7 +562,7 @@ public abstract class AuthenticatorBase } if (!authRequired && context.getPreemptiveAuthentication()) { -X509Certificate[] certs = getRequestCertificates(request); +X509Certificate[] certs = getRequestCertificates(request, false); authRequired = certs != null && certs.length > 0; } @@ -620,11 +620,13 @@ public abstract class AuthenticatorBase * extracting the certificate chain from the Coyote request. * * @param request Request to be processed + * @param force Should a renegotiation be forced to request certificates + * from the user agent if none have been provided * * @return The X509 certificate chain if found, null * otherwise. */ -protected X509Certificate[] getRequestCertificates(final Request request) +protected X509Certificate[] getRequestCertificates(final Request request, boolean force) throws IllegalStateException { X509Certificate certs[] = @@ -632,7 +634,7 @@ public abstract class AuthenticatorBase if ((certs == null) || (certs.length < 1)) { try { -request.getCoyoteRequest().action (ActionCode.REQ_SSL_CERTIFICATE, null); + request.getCoyoteRequest().action(ActionCode.REQ_SSL_CERTIFICATE, Boolean.valueOf(force)); certs = (X509Certificate[]) request.getAttribute(Globals.CERTIFICATES_ATTR); } catch (IllegalStateException ise) { // Request body was too large for save buffer Modified: tomcat/tc7.0.x/trunk/java/org/apache/catalina/authenticator/SSLAuthenticator.java URL: http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/java/org/apache/catalina/authenticator/SSLAuthenticator.java?rev=1622328&r1=1622327&r2=1622328&view=diff == --- tomcat/tc7.0.x/trunk/java/org/apache/catalina/authenticator/SSLAuthenticator.java (original) +++ tomcat/tc7.0.x/trunk/java/org/apache/catalina/authenticator/SSLAuthenticator.java Wed Sep 3 19:30:15 2014 @@ -127,7 +127,7 @@ public class SSLAuthenticator if (containerLog.isDebugEnabled()) containerLog.debug(" Looking up certificates"); -X509Certificate certs[] = getRequestCertificates(request); +X509Certificate certs[] = getRequestCertificates(request, true); if ((certs == null) || (certs.length < 1)) { if (containerLog.isDebugEnabled()) Modified: tomcat/tc7.0.x/trunk/java/org/apache/coyote/http11/Http11AprProcessor.java URL: http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/java/org/apache/coyote/http11/Http11AprProcessor.java?rev=1622328&r1=1622327&r2=1622328&view=diff == --- tomcat/tc7.0.x/trunk/java/org/apache/coyote/http11/Http11AprProcessor.java (original) +++ tomcat/tc7.0.x/trunk/java/org/apache/coyote/http11/Http11AprProcessor.java Wed Sep 3 19:30:15 2014 @@ -402,18 +402,26 @@ public class Http11AprProcessor extends } case REQ_SSL_CERTIFICATE: { if (endpoint.isSSLEnabled() && (socketRef != 0)) { -// Consume and buffer the request body, so that it does not -// interfere with the client's handshake messages -InputFilter[] inputFilters = inputBuffer.getFilters(); -((BufferedInputFilter) inputFilters[Constants.BUFFERED_FILTER]).setLimit(maxSave
[Bug 56825] AuthenticatorBase not looking for Coyote Request certificate
https://issues.apache.org/bugzilla/show_bug.cgi?id=56825 Mark Thomas changed: What|Removed |Added Status|REOPENED|RESOLVED Resolution|--- |FIXED --- Comment #7 from Mark Thomas --- Re-authentication patch back-ported from truk for 7.0.56 onwards. -- 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
[Bug 56908] New: Resource Leaks found by CID 45133
https://issues.apache.org/bugzilla/show_bug.cgi?id=56908 Bug ID: 56908 Summary: Resource Leaks found by CID 45133 Product: Tomcat 8 Version: trunk Hardware: All OS: All Status: NEW Severity: minor Priority: P2 Component: Jasper Assignee: dev@tomcat.apache.org Reporter: felix.schumac...@internetallee.de Created attachment 31961 --> https://issues.apache.org/bugzilla/attachment.cgi?id=31961&action=edit Add try-with block to prevent leakage of jar-resource Prevent resource leak identified by Coverity Scan ID 45133 by adding a try-with block. -- 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: r1622342 - in /tomcat/trunk: java/org/apache/jasper/compiler/Compiler.java webapps/docs/changelog.xml
Author: violetagg Date: Wed Sep 3 19:59:59 2014 New Revision: 1622342 URL: http://svn.apache.org/r1622342 Log: Fix https://issues.apache.org/bugzilla/show_bug.cgi?id=56908 Fix some potential resource leaks when reading jar files. Reported by Coverity Scan. Patch provided by Felix Schumacher. Modified: tomcat/trunk/java/org/apache/jasper/compiler/Compiler.java tomcat/trunk/webapps/docs/changelog.xml Modified: tomcat/trunk/java/org/apache/jasper/compiler/Compiler.java URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/jasper/compiler/Compiler.java?rev=1622342&r1=1622341&r2=1622342&view=diff == --- tomcat/trunk/java/org/apache/jasper/compiler/Compiler.java (original) +++ tomcat/trunk/java/org/apache/jasper/compiler/Compiler.java Wed Sep 3 19:59:59 2014 @@ -484,8 +484,9 @@ public abstract class Compiler { // Assume we constructed this correctly int entryStart = key.lastIndexOf("!/"); String entry = key.substring(entryStart + 2); -Jar jar = JarFactory.newInstance(new URL(key.substring(4, entryStart))); -includeLastModified = jar.getLastModified(entry); +try (Jar jar = JarFactory.newInstance(new URL(key.substring(4, entryStart { +includeLastModified = jar.getLastModified(entry); +} } else { if (key.startsWith("jar:") || key.startsWith("file:")) { includeUrl = new URL(key); Modified: tomcat/trunk/webapps/docs/changelog.xml URL: http://svn.apache.org/viewvc/tomcat/trunk/webapps/docs/changelog.xml?rev=1622342&r1=1622341&r2=1622342&view=diff == --- tomcat/trunk/webapps/docs/changelog.xml (original) +++ tomcat/trunk/webapps/docs/changelog.xml Wed Sep 3 19:59:59 2014 @@ -114,6 +114,11 @@ will throw IOException when an I/O error occur during the operation. (violetagg) + +56908: Fix some potential resource leaks when reading +jar files. Reported by Coverity Scan. Patch provided by Felix +Schumacher. (violetagg) + - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
svn commit: r1622344 - in /tomcat/tc7.0.x/trunk: ./ java/org/apache/catalina/startup/ContextConfig.java java/org/apache/catalina/util/CharsetMapper.java webapps/docs/changelog.xml
Author: violetagg Date: Wed Sep 3 20:11:53 2014 New Revision: 1622344 URL: http://svn.apache.org/r1622344 Log: Merged revision 1622312 from tomcat/trunk: Fix some potential resource leaks when reading files and other resources. Reported by Coverity Scan. Modified: tomcat/tc7.0.x/trunk/ (props changed) tomcat/tc7.0.x/trunk/java/org/apache/catalina/startup/ContextConfig.java tomcat/tc7.0.x/trunk/java/org/apache/catalina/util/CharsetMapper.java tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml Propchange: tomcat/tc7.0.x/trunk/ -- Merged /tomcat/trunk:r1622312 Modified: tomcat/tc7.0.x/trunk/java/org/apache/catalina/startup/ContextConfig.java URL: http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/java/org/apache/catalina/startup/ContextConfig.java?rev=1622344&r1=1622343&r2=1622344&view=diff == --- tomcat/tc7.0.x/trunk/java/org/apache/catalina/startup/ContextConfig.java (original) +++ tomcat/tc7.0.x/trunk/java/org/apache/catalina/startup/ContextConfig.java Wed Sep 3 20:11:53 2014 @@ -2677,6 +2677,12 @@ public class ContextConfig implements Li fragment.setDistributable(true); } } finally { +if (stream != null) { +try { +stream.close(); +} catch (IOException e) { +} +} fragment.setURL(file.toURI().toURL()); if (fragment.getName() == null) { fragment.setName(fragment.getURL().toString()); Modified: tomcat/tc7.0.x/trunk/java/org/apache/catalina/util/CharsetMapper.java URL: http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/java/org/apache/catalina/util/CharsetMapper.java?rev=1622344&r1=1622343&r2=1622344&view=diff == --- tomcat/tc7.0.x/trunk/java/org/apache/catalina/util/CharsetMapper.java (original) +++ tomcat/tc7.0.x/trunk/java/org/apache/catalina/util/CharsetMapper.java Wed Sep 3 20:11:53 2014 @@ -18,6 +18,7 @@ package org.apache.catalina.util; +import java.io.IOException; import java.io.InputStream; import java.util.Locale; import java.util.Properties; @@ -69,14 +70,20 @@ public class CharsetMapper { * resource could not be loaded for any reason. */ public CharsetMapper(String name) { +InputStream stream = null; try { -InputStream stream = - this.getClass().getResourceAsStream(name); +stream = this.getClass().getResourceAsStream(name); map.load(stream); -stream.close(); } catch (Throwable t) { ExceptionUtils.handleThrowable(t); throw new IllegalArgumentException(t.toString()); +} finally { +if (stream != null) { +try { +stream.close(); +} catch (IOException e) { +} +} } } Modified: tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml URL: http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml?rev=1622344&r1=1622343&r2=1622344&view=diff == --- tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml (original) +++ tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml Wed Sep 3 20:11:53 2014 @@ -142,8 +142,8 @@ Locale. (markt) -Fix some potential resource leaks when reading property files. Reported -by Coverity Scan. (violetagg) +Fix some potential resource leaks when reading properties, files and +other resources. Reported by Coverity Scan. (violetagg) - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
svn commit: r1622350 - in /tomcat/tc7.0.x/trunk: ./ java/org/apache/jasper/compiler/Compiler.java webapps/docs/changelog.xml
Author: violetagg Date: Wed Sep 3 20:35:49 2014 New Revision: 1622350 URL: http://svn.apache.org/r1622350 Log: Fix https://issues.apache.org/bugzilla/show_bug.cgi?id=56908 Merged revision 1622342 from tomcat/trunk: Fix some potential resource leaks when reading jar files. Reported by Coverity Scan. Based on patch provided by Felix Schumacher. Modified: tomcat/tc7.0.x/trunk/ (props changed) tomcat/tc7.0.x/trunk/java/org/apache/jasper/compiler/Compiler.java tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml Propchange: tomcat/tc7.0.x/trunk/ -- Merged /tomcat/trunk:r1622342 Modified: tomcat/tc7.0.x/trunk/java/org/apache/jasper/compiler/Compiler.java URL: http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/java/org/apache/jasper/compiler/Compiler.java?rev=1622350&r1=1622349&r2=1622350&view=diff == --- tomcat/tc7.0.x/trunk/java/org/apache/jasper/compiler/Compiler.java (original) +++ tomcat/tc7.0.x/trunk/java/org/apache/jasper/compiler/Compiler.java Wed Sep 3 20:35:49 2014 @@ -20,6 +20,7 @@ package org.apache.jasper.compiler; import java.io.File; import java.io.FileNotFoundException; import java.io.FileOutputStream; +import java.io.IOException; import java.io.OutputStreamWriter; import java.io.PrintWriter; import java.io.UnsupportedEncodingException; @@ -493,6 +494,7 @@ public abstract class Compiler { Iterator> it = depends.entrySet().iterator(); while (it.hasNext()) { Entry include = it.next(); +URLConnection iuc = null; try { String key = include.getKey(); URL includeUrl; @@ -505,7 +507,7 @@ public abstract class Compiler { return true; } -URLConnection iuc = includeUrl.openConnection(); +iuc = includeUrl.openConnection(); long includeLastModified = 0; if (iuc instanceof JarURLConnection) { includeLastModified = @@ -513,7 +515,6 @@ public abstract class Compiler { } else { includeLastModified = iuc.getLastModified(); } -iuc.getInputStream().close(); if (includeLastModified != include.getValue().longValue()) { return true; @@ -523,6 +524,13 @@ public abstract class Compiler { log.debug("Problem accessing resource. Treat as outdated.", e); return true; +} finally { +if (iuc != null) { +try { +iuc.getInputStream().close(); +} catch (IOException e) { +} +} } } Modified: tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml URL: http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml?rev=1622350&r1=1622349&r2=1622350&view=diff == --- tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml (original) +++ tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml Wed Sep 3 20:35:49 2014 @@ -175,6 +175,11 @@ will throw IOException when an I/O error occur during the operation. (violetagg) + +56908: Fix some potential resource leaks when reading jar +files. Reported by Coverity Scan. Based on patch provided by Felix +Schumacher. (violetagg) + - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
[Bug 56908] Resource Leaks found by CID 45133
https://issues.apache.org/bugzilla/show_bug.cgi?id=56908 Violeta Georgieva changed: What|Removed |Added Status|NEW |RESOLVED Resolution|--- |FIXED --- Comment #1 from Violeta Georgieva --- Thanks for the patch. This has been fixed in trunk for 8.0.13 and in 7.0.x for 7.0.56 onwards. -- 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: r1622360 - in /tomcat/site/trunk: docs/security-6.html docs/security-7.html docs/security-8.html xdocs/security-6.xml xdocs/security-7.xml xdocs/security-8.xml
Author: kkolinko Date: Wed Sep 3 21:30:46 2014 New Revision: 1622360 URL: http://svn.apache.org/r1622360 Log: Use abbreviated month names instead of ISO date format for release dates on Security pages, for consistency with earlier releases on these pages. Modified: tomcat/site/trunk/docs/security-6.html tomcat/site/trunk/docs/security-7.html tomcat/site/trunk/docs/security-8.html tomcat/site/trunk/xdocs/security-6.xml tomcat/site/trunk/xdocs/security-7.xml tomcat/site/trunk/xdocs/security-8.xml Modified: tomcat/site/trunk/docs/security-6.html URL: http://svn.apache.org/viewvc/tomcat/site/trunk/docs/security-6.html?rev=1622360&r1=1622359&r2=1622360&view=diff == --- tomcat/site/trunk/docs/security-6.html (original) +++ tomcat/site/trunk/docs/security-6.html Wed Sep 3 21:30:46 2014 @@ -304,7 +304,7 @@ -released 2014-05-23 Fixed in Apache Tomcat 6.0.41 +released 23 May 2014 Fixed in Apache Tomcat 6.0.41 @@ -417,7 +417,7 @@ -released 31 January 2014 Fixed in Apache Tomcat 6.0.39 +released 31 Jan 2014 Fixed in Apache Tomcat 6.0.39 Modified: tomcat/site/trunk/docs/security-7.html URL: http://svn.apache.org/viewvc/tomcat/site/trunk/docs/security-7.html?rev=1622360&r1=1622359&r2=1622360&view=diff == --- tomcat/site/trunk/docs/security-7.html (original) +++ tomcat/site/trunk/docs/security-7.html Wed Sep 3 21:30:46 2014 @@ -321,7 +321,7 @@ -released 2014-05-22 Fixed in Apache Tomcat 7.0.54 +released 22 May 2014 Fixed in Apache Tomcat 7.0.54 @@ -355,7 +355,7 @@ -released 2014-03-30 Fixed in Apache Tomcat 7.0.53 +released 30 Mar 2014 Fixed in Apache Tomcat 7.0.53 @@ -477,7 +477,7 @@ -2014-01-08 Fixed in Apache Tomcat 7.0.50 +released 08 Jan 2014 Fixed in Apache Tomcat 7.0.50 @@ -546,7 +546,7 @@ -2013-10-24 Fixed in Apache Tomcat 7.0.47 +released 24 Oct 2013 Fixed in Apache Tomcat 7.0.47 Modified: tomcat/site/trunk/docs/security-8.html URL: http://svn.apache.org/viewvc/tomcat/site/trunk/docs/security-8.html?rev=1622360&r1=1622359&r2=1622360&view=diff == --- tomcat/site/trunk/docs/security-8.html (original) +++ tomcat/site/trunk/docs/security-8.html Wed Sep 3 21:30:46 2014 @@ -267,7 +267,7 @@ -beta, 2014-05-21 Fixed in Apache Tomcat 8.0.8 +beta, 21 May 2014 Fixed in Apache Tomcat 8.0.8 @@ -313,7 +313,7 @@ -beta, 2014-03-27 Fixed in Apache Tomcat 8.0.5 +beta, 27 Mar 2014 Fixed in Apache Tomcat 8.0.5 @@ -424,7 +424,7 @@ -beta, 2014-02-11 Fixed in Apache Tomcat 8.0.3 +beta, 11 Feb 2014 Fixed in Apache Tomcat 8.0.3 @@ -468,7 +468,7 @@ -alpha, 2013-12-26 Fixed in Apache Tomcat 8.0.0-RC10 +alpha, 26 Dec 2013 Fixed in Apache Tomcat 8.0.0-RC10 @@ -537,7 +537,7 @@ -alpha, 2013-09-23 Fixed in Apache Tomcat 8.0.0-RC3 +alpha, 23 Sep 2013 Fixed in Apache Tomcat 8.0.0-RC3 Modified: tomcat/site/trunk/xdocs/security-6.xml URL: http://svn.apache.org/viewvc/tomcat/site/trunk/xdocs/security-6.xml?rev=1622360&r1=1622359&r2=1622360&view=diff == --- tomcat/site/trunk/xdocs/security-6.xml (original) +++ tomcat/site/trunk/xdocs/security-6.xml Wed Sep 3 21:30:46 2014 @@ -48,7 +48,7 @@ - + Note: The issues below were fixed in Apache Tomcat 6.0.40 but the release vote for the 6.0.40 release candidate did not pass. @@ -128,7 +128,7 @@ - + Note: The issues below were fixed in Apache Tomcat 6.0.38 but the release vote for 6.0.38 did not pass. Modified: tomcat/site/trunk/xdocs/security-7.xml URL: http://svn.apache.org/viewvc/tomcat/site/trunk/xdocs/security-7.xml?rev=1622360&r1=1622359&r2=1622360&view=diff == --- tomcat/site/trunk/xdocs/security-7.xml (original) +++ tomcat/site/trunk/xdocs/security-7.xml Wed Sep 3 21:30:46 2014 @@ -50,7 +50,7 @@ - + Low: Information Disclosure CVE-2014-0119 @@ -75,7 +75,7 @@ - + Important: Denial of Service CVE-2014-0075 @@ -161,7 +161,7 @@ - + Note: The issues below were fixed in Apache Tomcat 7.0.48 but the release votes for 7.0.48 to 7.0.49 did not pass. @@ -207,7 +207,7 @@ - + Note: The issue below was fixed in Apache Tomcat 7.0.43 but the release votes for 7.0.43 to 7.0.46 did not pass. Modified: tomcat/site/trunk/xdocs/security-8.xml URL: http://svn.apache.org/viewvc/tomcat/site/trunk/xdocs/security-8.xml?rev=1622360&r1=1622359&r2=1622360&view=diff == --- tomcat/si
Re: git (yet again)
On 3 September 2014 16:10, Martin Grigorov wrote: > On Wed, Sep 3, 2014 at 2:54 PM, Stefan Bodewig wrote: > >> On 2014-09-03, sebb wrote: >> >> > Maybe it's possible to configure the commit messages so that diffs are >> > shown; if not, then perhaps there needs to be a convention for how to >> > comment on commits. >> >> Might be something that can be configured per project, we do get diffs >> for commits in Ant-land: for example >> >> http://mail-archives.apache.org/mod_mbox/ant-notifications/201408.mbox/%3C20bedaba96cd4b7582e31104e4d27d4a%40git.apache.org%3E > > > Diffs in mail notifications come for free in the ASF Git setup. OK, good. I was going by the infra puppet diffs on infrastructure-cvs which only have a compare URL. But it seems these are github commits. > Commenting on diffs in the email is not the important thing. Having an > email means that another committer (i.e. someone with more knowledge) did > something. > The new thing is being able to comment on "the patch" (the Pull Request) > provided by a contributor *before* it gets in the repo. Usually the > contributors don't have the whole picture. Yes, this would be useful. However, it is fairly common for Tomcat committers to comment on each other's commits, either as part of CTR or sometimes to provide feedback. etc. A quick scan of some recent commits shows 5-10% with comments. > >> >> >> Stefan >> >> - >> To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org >> For additional commands, e-mail: dev-h...@tomcat.apache.org >> >> - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
[Bug 56825] AuthenticatorBase not looking for Coyote Request certificate
https://issues.apache.org/bugzilla/show_bug.cgi?id=56825 Konstantin Kolinko changed: What|Removed |Added Status|RESOLVED|REOPENED Resolution|FIXED |--- --- Comment #8 from Konstantin Kolinko --- Re-reviewing the changes in Tomcat 7 (revisions r1617447 r1620827 and r1622328 ) I have a question. There exists ActionCode.REQ_SSL_ATTRIBUTE. The method org.apache.catalina.connector.Request.getAttribute() does "if (isSSLAttribute(name)) coyoteRequest.action(ActionCode.REQ_SSL_ATTRIBUTE, ...)" This action populates the "javax.servlet.request.X509Certificate" attribute (aka Globals.CERTIFICATES_ATTR). I mean that it is effectively equivalent to the new API of using ActionCode.REQ_SSL_CERTIFICATE with parameter Boolean.FALSE. > When using Tomcat SSL coyote connector, the request does not by default > contain > the certificate chain under the key javax.servlet.request.X509Certificate > > The following coyote action must be invoked in order to extract the > certificate > chain and enrich the request under the right key. Is the above really true? Why was the old code not working properly? Was all this fix really needed? Was the new API really needed? I did the following at tc7.0.x\trunk: I reverted to the state before those fixes and updated the tests to their current versions: svn up -r 1617446 cd test/org/apache/tomcat/util/net svn up TestClientCert.java svn up TesterSupport.java Then I run test.entry=org.apache.tomcat.util.net.TestClientCert test with BIO, NIO, APR (java.7.home=JDK 7u67). Results are: 1) With APR the tests were skipped, "SKIPPED: SSL renegotiation has to be supported for this test" 2) With BIO and NIO the tests passed. So it looks like there was no issue. -- 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
[Bug 56848] Tomcat accept-language parsing doesn't properly handle IETF BCP47 language tags
https://issues.apache.org/bugzilla/show_bug.cgi?id=56848 --- Comment #4 from Andy Wang --- Would it make sense to try to use reflection and only support BCP47 if Java 7+ is used? -- 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
[Bug 56909] New: Failed to create poller with specified size of -1
https://issues.apache.org/bugzilla/show_bug.cgi?id=56909 Bug ID: 56909 Summary: Failed to create poller with specified size of -1 Product: Tomcat 7 Version: 7.0.26 Hardware: All OS: All Status: NEW Severity: normal Priority: P2 Component: Connectors Assignee: dev@tomcat.apache.org Reporter: sunqi...@163.com set maxConnections="-1" with the APR connector. tomcat start fail,the error msg is: "org.apache.tomcat.util.net.AprEndpoint allocatePoller Failed to create poller with specified size of -1" // Single poller by default int defaultPollerSize = getMaxConnections(); if ((OS.IS_WIN32 || OS.IS_WIN64) && (defaultPollerSize > 1024)) { // The maximum per poller to get reasonable performance is 1024 // Adjust poller size so that it won't reach the limit. This is // a limitation of XP / Server 2003 that has been fixed in // Vista / Server 2008 onwards. actualPollerSize = 1024; } else { actualPollerSize = defaultPollerSize; } -- 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
[Bug 56910] New: when maxConnections="-1" AprEndpoint init error
https://issues.apache.org/bugzilla/show_bug.cgi?id=56910 Bug ID: 56910 Summary: when maxConnections="-1" AprEndpoint init error Product: Tomcat 7 Version: 7.0.55 Hardware: All OS: All Status: NEW Severity: normal Priority: P2 Component: Connectors Assignee: dev@tomcat.apache.org Reporter: w.hongji...@gmail.com use apr connector set maxConnections="-1" in server.xml when start tomcat, exceptions occur: java.lang.NegativeArraySizeException at org.apache.tomcat.util.net.AprEndpoint$SocketTimeouts.(AprEndpoint.java:1145) at org.apache.tomcat.util.net.AprEndpoint$Poller.init(AprEndpoint.java:1382) at org.apache.tomcat.util.net.AprEndpoint.startInternal(AprEndpoint.java:602) at org.apache.tomcat.util.net.AbstractEndpoint.start(AbstractEndpoint.java:650) at org.apache.coyote.AbstractProtocol.start(AbstractProtocol.java:449) at org.apache.catalina.connector.Connector.startInternal(Connector.java:1007) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150) at org.apache.catalina.core.StandardService.startInternal(StandardService.java:459) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150) at org.apache.catalina.core.StandardServer.startInternal(StandardServer.java:731) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150) at org.apache.catalina.startup.Catalina.start(Catalina.java:689) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:606) at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:321) at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:455) In AprEndpoint.init() method: protected void init() { pool = Pool.create(serverSockPool); // Single poller by default int defaultPollerSize = getMaxConnections(); if ((OS.IS_WIN32 || OS.IS_WIN64) && (defaultPollerSize > 1024)) { // The maximum per poller to get reasonable performance is 1024 // Adjust poller size so that it won't reach the limit. This is // a limitation of XP / Server 2003 that has been fixed in // Vista / Server 2008 onwards. actualPollerSize = 1024; } else { actualPollerSize = defaultPollerSize; } timeouts = new SocketTimeouts(defaultPollerSize); //here !!! did not check getMaxConnections() maybe return -1. -- 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
[Bug 56909] Failed to create poller with specified size of -1
https://issues.apache.org/bugzilla/show_bug.cgi?id=56909 sunqi changed: What|Removed |Added Version|7.0.26 |trunk -- 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
[Bug 56909] Failed to create poller with specified size of -1
https://issues.apache.org/bugzilla/show_bug.cgi?id=56909 sunqi changed: What|Removed |Added CC||sunqi...@163.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
RE: Encoding request URI
Hi Hope it will format this time. I am not using any web browser to execute requests. I do use latest http client component from apache. My request URI contains characters that are not allowed in a URI. Some examples are[]"space .etc Therefore I send UTF-8 encoded request URI and it fails. But if I ONLY encode not allowed characters, it works fine. Then I have to decode when processing the request inside a servlet. The problem with this approach is that I only encode some characters. This will not work one day I get another unallowed character that's not on my list. My request looks like: /mtasxdms/simservs.ngn.etsi.org/users/sip:a...@vodafon.com/simservs.xml/~~/simservs/communication-diversion/NoReplyTimer/simservs/communication-diversion/cp:ruleset/cp:rule[@id="cfnrc"]/cp:conditions/mmt-serv:valid-periods/mmt-serv:valid-days/mmt-serv:day?xmlns(cp=urn:ietf:params:xml:ns:common-policy) xmlns(mmt-serv=http://schemas.vodafon.com/mmtel/services) BRLulseged > Date: Wed, 3 Sep 2014 10:09:48 +0100 > From: ma...@apache.org > To: dev@tomcat.apache.org > Subject: Re: Encoding request URI > > On 03/09/2014 10:03, Lulseged Zerfu wrote: > > Hi > > I have a problem sending UTF-8 encoded request URI to tomcat. I am always > > getting Bad request from tomcat. > > Charset is set to UTF-8 in the request. My connectors in server.xml have > > URIEncoding="UTF-8" set. > > I am using tomcat 8.0.11 on windows x64. > > I would appreciate any help. > > Read this: > http://www.catb.org/esr/faqs/smart-questions.html > > Then post to the users mailing list. > > Mark > > > - > To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org > For additional commands, e-mail: dev-h...@tomcat.apache.org >
Re: git (yet again)
On Thu, Sep 4, 2014 at 12:46 AM, sebb wrote: > On 3 September 2014 16:10, Martin Grigorov wrote: > > On Wed, Sep 3, 2014 at 2:54 PM, Stefan Bodewig > wrote: > > > >> On 2014-09-03, sebb wrote: > >> > >> > Maybe it's possible to configure the commit messages so that diffs are > >> > shown; if not, then perhaps there needs to be a convention for how to > >> > comment on commits. > >> > >> Might be something that can be configured per project, we do get diffs > >> for commits in Ant-land: for example > >> > >> > http://mail-archives.apache.org/mod_mbox/ant-notifications/201408.mbox/%3C20bedaba96cd4b7582e31104e4d27d4a%40git.apache.org%3E > > > > > > Diffs in mail notifications come for free in the ASF Git setup. > > OK, good. > > I was going by the infra puppet diffs on infrastructure-cvs which > only have a compare URL. > > But it seems these are github commits. > I also noticed those commits. I'll ask Tony (tonypc) how this works for them. I know Joe (joes) was strongly against using non-ASF services for Apache needs. Apparently this changed! I see Apache Spark also makes a heavy use of GitHub but I don't know the details again. Joe (and the whole Infra team) was against using Atlassian Stash ( https://www.atlassian.com/software/stash) on ASF hardware. ASF already uses several other Atlassian product like JIRA, Confluence, HipChat, FishEye. Stash is the application behind bitbucket.org. I find it even better than GitHub user experience. > > > Commenting on diffs in the email is not the important thing. Having an > > email means that another committer (i.e. someone with more knowledge) did > > something. > > The new thing is being able to comment on "the patch" (the Pull Request) > > provided by a contributor *before* it gets in the repo. Usually the > > contributors don't have the whole picture. > > Yes, this would be useful. > > However, it is fairly common for Tomcat committers to comment on each > other's commits, either as part of CTR or sometimes to provide > feedback. etc. > A quick scan of some recent commits shows 5-10% with comments. > > > > >> > >> > >> Stefan > >> > >> - > >> To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org > >> For additional commands, e-mail: dev-h...@tomcat.apache.org > >> > >> > > - > To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org > For additional commands, e-mail: dev-h...@tomcat.apache.org > >