svn commit: r1533319 - in /tomcat/tc7.0.x/tags/TOMCAT_7_0_47: ./ NOTICE build.properties.default res/META-INF/default.notice res/META-INF/servlet-api.jar.notice webapps/docs/changelog.xml

2013-10-17 Thread violetagg
Author: violetagg
Date: Fri Oct 18 03:02:47 2013
New Revision: 1533319

URL: http://svn.apache.org/r1533319
Log:
Tag 7.0.47

Added:
tomcat/tc7.0.x/tags/TOMCAT_7_0_47/   (props changed)
  - copied from r1533082, tomcat/tc7.0.x/trunk/
Modified:
tomcat/tc7.0.x/tags/TOMCAT_7_0_47/NOTICE
tomcat/tc7.0.x/tags/TOMCAT_7_0_47/build.properties.default
tomcat/tc7.0.x/tags/TOMCAT_7_0_47/res/META-INF/default.notice
tomcat/tc7.0.x/tags/TOMCAT_7_0_47/res/META-INF/servlet-api.jar.notice
tomcat/tc7.0.x/tags/TOMCAT_7_0_47/webapps/docs/changelog.xml

Propchange: tomcat/tc7.0.x/tags/TOMCAT_7_0_47/
--
bugtraq:append = false

Propchange: tomcat/tc7.0.x/tags/TOMCAT_7_0_47/
--
bugtraq:label = Bugzilla ID (optional)

Propchange: tomcat/tc7.0.x/tags/TOMCAT_7_0_47/
--
--- bugtraq:message (added)
+++ bugtraq:message Fri Oct 18 03:02:47 2013
@@ -0,0 +1 @@
+Fix https://issues.apache.org/bugzilla/show_bug.cgi?id=%BUGID%

Propchange: tomcat/tc7.0.x/tags/TOMCAT_7_0_47/
--
bugtraq:number = true

Propchange: tomcat/tc7.0.x/tags/TOMCAT_7_0_47/
--
bugtraq:url = https://issues.apache.org/bugzilla/show_bug.cgi?id=%BUGID%

Propchange: tomcat/tc7.0.x/tags/TOMCAT_7_0_47/
--
bugtraq:warnifnoissue = false

Propchange: tomcat/tc7.0.x/tags/TOMCAT_7_0_47/
--
--- svn:ignore (added)
+++ svn:ignore Fri Oct 18 03:02:47 2013
@@ -0,0 +1,7 @@
+.*
+build.properties
+logs
+nbproject
+output
+work
+*.iml

Propchange: tomcat/tc7.0.x/tags/TOMCAT_7_0_47/
--
--- svn:mergeinfo (added)
+++ svn:mergeinfo Fri Oct 18 03:02:47 2013
@@ -0,0 +1 @@
+/tomcat/trunk:1156115-1157160,1157162-1157859,1157862-1157942,1157945-1160347,1160349-1163716,1163718-1166689,1166691-1174340,1174342-1175596,1175598-1175611,1175613-1175932,1175934-1177783,1177785-1177980,1178006-1180720,1180722-1183094,1183096-1187753,1187755,1187775,1187801,1187806,1187809,1187826-1188312,1188314-1188401,1188646-1188840,1188842-1190176,1190178-1195223,1195225-1195953,1195955,1195957-1201238,1201240-1203345,1203347-1206623,1206625-1208046,1208073,1208096,1208114,1208145,1208772,1209194-1212125,1212127-1220291,1220293,1220295-1221321,1221323-1222328,1222332-1222401,1222405-1222795,1222850-1222950,1222969-1225326,1225328-1225463,1225465,1225627,1225629-1226534,1226536-1228908,1228911-1228923,1228927-1229532,1229534-1230766,1230768-1231625,1231627-1233414,1233419-1235207,1235209-1237425,1237427,1237429-1237977,1237981,1237985,1237995,1238070,1238073,1239024-1239048,1239050-1239062,1239135,1239256,1239258-1239485,1239785-1240046,1240101,1240106,1240109,1240112,1240114
 
,1240116,1240118,1240121,1240329,1240474-1240850,1240857,1241087,1241160,1241408-1241822,1241908-1241909,1241912-1242110,1242371-1292130,1292134-1292458,1292464-1292670,1292672-1292776,1292780-1293392,1293397-1297017,1297019-1297963,1297965-1299820,1300108,1300111-1300460,1300520-1300948,1300997,1301006,1301280,1302332,1302348,1302608-1302610,1302649,1302837,1303138,1303163,1303338,1303521,1303587,1303698,1303803,1303852,1304011,1304035,1304037,1304135,1304249,1304253,1304260,1304271,1304275,1304468,1304895,1304930-1304932,1305194,1305943,1305965,1306556,1306579-1306580,1307084,1307310,1307511-1307512,1307579,1307591,1307597,1310636,1310639-1310640,1310642,1310701,1311212,1311995,1327617,1327670,1331766,1333161,1333173,1333827,1334787,1335026,1335257,1335547,1335692,1335711,1335731,1336515,1336813,1336864,1336868,1336884,1337419,1337426,1337546,1337572,1337591-1337595,1337643,1337707,1337719,1337734,1337741,1337745,1338151-1338154,1338178,1342027,1342029,1342315,1342320,1342476,1342
 
498,1342503,1342717,1342795,1342805,1343044-1343046,1343335,1343394,1343400,1343629,1343708,1343718,1343895,1344063,1344068,1344250,1344266,1344515,1344528,1344612,1344629,1344725,1344868,1344890,1344893,1344896,1344901,1345020,1345029,1345039,1345287-1345290,1345294,1345309,1345325,1345357,1345367,1345579-1345580,1345582,1345688,1345699,1345704,1345731-1345732,1345737,1345744,1345752,1345754,1345779,1345781,1345846,1346107,1346376,1346404,1346510,1346514,1346519,1346581,1346635,1346644,1346683,1346794,1346885,1346932,1347034,1347047,1347087,1347108-1347109,1347583,1347737,1348105,1348357,1348398,1348425,1348461-1348495,1348498,1348752,1348762,1348772,1348776,1348859,1348968,1348973,1348989,1349007,1349237,1349298,1349317,1349410,1349473,1349539,1349879,1349887,1349893,1349922,1349984,1350124,1350241,1350243,1350294-1350295,13

svn commit: r1533318 - /tomcat/tc7.0.x/tags/TOMCAT_7_0_47/

2013-10-17 Thread violetagg
Author: violetagg
Date: Fri Oct 18 02:56:45 2013
New Revision: 1533318

URL: http://svn.apache.org/r1533318
Log:
Remove tag TOMCAT_7_0_47 - r1533312 has to be added in the tag.

Removed:
tomcat/tc7.0.x/tags/TOMCAT_7_0_47/


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



svn commit: r1533316 - in /tomcat/tc7.0.x/trunk: ./ NOTICE res/META-INF/default.notice res/META-INF/servlet-api.jar.notice webapps/docs/changelog.xml

2013-10-17 Thread violetagg
Author: violetagg
Date: Fri Oct 18 02:51:08 2013
New Revision: 1533316

URL: http://svn.apache.org/r1533316
Log:
Fix https://issues.apache.org/bugzilla/show_bug.cgi?id=55663
Merged revision 1533312 from tomcat/trunk:
Notice files are corrected according to 
http://www.apache.org/legal/src-headers.html#notice

Modified:
tomcat/tc7.0.x/trunk/   (props changed)
tomcat/tc7.0.x/trunk/NOTICE
tomcat/tc7.0.x/trunk/res/META-INF/default.notice
tomcat/tc7.0.x/trunk/res/META-INF/servlet-api.jar.notice
tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml

Propchange: tomcat/tc7.0.x/trunk/
--
  Merged /tomcat/trunk:r1533312

Modified: tomcat/tc7.0.x/trunk/NOTICE
URL: 
http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/NOTICE?rev=1533316&r1=1533315&r2=1533316&view=diff
==
--- tomcat/tc7.0.x/trunk/NOTICE (original)
+++ tomcat/tc7.0.x/trunk/NOTICE Fri Oct 18 02:51:08 2013
@@ -1,7 +1,7 @@
 Apache Tomcat
 Copyright 1999-2013 The Apache Software Foundation
 
-This product includes software developed by
+This product includes software developed at
 The Apache Software Foundation (http://www.apache.org/).
 
 The Windows Installer is built with the Nullsoft

Modified: tomcat/tc7.0.x/trunk/res/META-INF/default.notice
URL: 
http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/res/META-INF/default.notice?rev=1533316&r1=1533315&r2=1533316&view=diff
==
--- tomcat/tc7.0.x/trunk/res/META-INF/default.notice (original)
+++ tomcat/tc7.0.x/trunk/res/META-INF/default.notice Fri Oct 18 02:51:08 2013
@@ -1,5 +1,5 @@
 Apache Tomcat
 Copyright 1999-@YEAR@ The Apache Software Foundation
 
-This product includes software developed by
+This product includes software developed at
 The Apache Software Foundation (http://www.apache.org/).

Modified: tomcat/tc7.0.x/trunk/res/META-INF/servlet-api.jar.notice
URL: 
http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/res/META-INF/servlet-api.jar.notice?rev=1533316&r1=1533315&r2=1533316&view=diff
==
--- tomcat/tc7.0.x/trunk/res/META-INF/servlet-api.jar.notice (original)
+++ tomcat/tc7.0.x/trunk/res/META-INF/servlet-api.jar.notice Fri Oct 18 
02:51:08 2013
@@ -1,7 +1,7 @@
 Apache Tomcat
 Copyright 1999-@YEAR@ The Apache Software Foundation
 
-This product includes software developed by
+This product includes software developed at
 The Apache Software Foundation (http://www.apache.org/).
 
 The original XML Schemas for Java EE Deployment Descriptors:

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=1533316&r1=1533315&r2=1533316&view=diff
==
--- tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml (original)
+++ tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml Fri Oct 18 02:51:08 2013
@@ -83,6 +83,15 @@
   
 
   
+  
+
+  
+55663: NOTICE files are corrected according to
+http://www.apache.org/legal/src-headers.html#notice";>NOTICE 
files requirements.
+(violetagg)
+  
+
+  
 
 
   



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



Re: [VOTE] Release Apache Tomcat 8.0.0-RC5

2013-10-17 Thread Rainer Jung
On 16.10.2013 20:21, Mark Thomas wrote:
> The proposed Apache Tomcat 8.0.0 release candidate 5 is now available
> for voting.
> 
> Given this is a release candidate I am working on the basis that it is
> equivalent to an alpha. The main changes since RC4 are:
> - Stability fixes in the APR/native connector
> - Stability fixes for non-blocking IO and WebSocket
> - Improvements to unit tests to reduce incidence of false reports
> - Add a drawing board example to the WebSocket examples
> - A handful of bug fixes
> - A small number of enhancements including direct gzip support in the
>   default Servlet
> - More HTML clean-up
> 
> It can be obtained from:
> https://dist.apache.org/repos/dist/dev/tomcat/tomcat-8/v8.0.0-RC5/
> The Maven staging repo is:
> https://repository.apache.org/content/repositories/orgapachetomcat-186/
> The svn tag is:
> http://svn.apache.org/repos/asf/tomcat/tags/TOMCAT_8_0_0_RC5/
> 
> The proposed 8.0.0-RC5 release is:
> [ ] Broken - do not release
> [X] Alpha - go ahead and release as 8.0.0-RC5 alpha

+1 as alpha.

Overview:

- MD5 OK
- signatures OK
- key in KEYS file
- gz and zip for src and bin consistent
- src consistent with svn tag
- builds fine but
  - Few warning about unsafe or unchecked operations.
Only 0 or 1 new one, some of the RC1 ones are fixed.
See full list at end of mail.
- build result looks consistent with binaries
- no checkstyle complaints
- no Javadoc warnings
- some tiny MBean data changes
- No unit test failures, great!

- Warnings, errors and exception counts during unit tests a bit
  higher than for RC 3

- JMX MBean-Comparison with RC 3 (all expected):
  - MBean example webapp new welcome file index.xhtml
  - MBean example webapp ignoreAnnotations changed from false to true
  - Runtime MBean common.loader system property all entries are now
quoted.

Build and tests were done using Java 1.7.0_40. OS was Solaris 10 Sparc,
tcnative was 1.1.29 based on APR 1.4.8 and OpenSSL 1.0.1e (plus a few
patches).


Unit test warnings: 95
  - 29 more than RC1, 13 less than RC3
  - most additional ones in tribes, especially from 27 (RC1) resp.
59 (RC3) to 46 (RC5):
org.apache.catalina.tribes.group.interceptors.NonBlockingCoordinator.sendElectionMsgToNextInline
Unable to send election message
to:org.apache.catalina.tribes.membership.MemberImpl[tcp://
  - 8 ones new in RC3, still in RC5:
  org.apache.tomcat.util.net.AbstractEndpoint.shutdownExecutor The
executor associated with thread pool [http-apr-127.0.0.1-auto-I] has not
fully shutdown. Some application threads may still be running.
  - up from 4 (RC3) to 6:
  IOException in replication worker, unable to drain channel.
Probable cause: Keep alive socket closed[null].


Unit test SEVERE messages: 420 total (-19 rel RC1, -37 rel RC3).

Here's the top 20 SEVERE messages:

Count  Message
  48 org.apache.catalina.startup.HostConfig.deployDescriptor Error
deploying configuration descriptor
/.../output/test-tmp/conf/Tomcat/localhost/myapp.xml
  48 org.apache.catalina.core.ContainerBase.addChildInternal
ContainerBase.addChild: start:
  36 org.apache.catalina.core.StandardWrapperValve.invoke
Servlet.service() for servlet [dispatch] in context with path [] threw
exception [Opps.] with root cause
  36 org.apache.catalina.core.ApplicationDispatcher.invoke
Servlet.service() for servlet error threw exception
  27 org.apache.tomcat.util.digester.Digester.startElement Begin event
threw exception
  15 org.apache.catalina.loader.WebappClassLoader.clearReferencesThreads
The web application [] appears to have started a thread named
[pool-N-thread-M] but has failed to stop it. This is very likely to
create a memory leak.
  15 org.apache.catalina.core.StandardWrapperValve.invoke
Servlet.service() for servlet [servlet] in context with path [] threw
exception
  12
org.apache.tomcat.util.descriptor.web.SecurityConstraint.findUncoveredHttpMethods
For security constraints with URL pattern [/] only the HTTP methods
[POST] are covered. All other methods are uncovered.
   9
org.apache.tomcat.util.descriptor.web.SecurityConstraint.findUncoveredHttpMethods
For security constraints with URL pattern [/test] only the HTTP methods
[POST] are covered. All other methods are uncovered.
   9 org.apache.catalina.startup.ContextConfig.beforeStart Exception
fixing docBase for context [/myapp]
   9 org.apache.catalina.core.StandardContext.startInternal Error
listenerStart
   6
org.apache.tomcat.util.descriptor.web.SecurityConstraint.findUncoveredHttpMethods
For security constraints with URL pattern [/] only the HTTP methods
[GET] are covered. All other methods are uncovered.
   6
org.apache.catalina.tribes.group.interceptors.NonBlockingCoordinator.messageReceived
Error processing coordination message. Could be fatal.
   6 org.apache.catalina.loader.WebappClassLoader.clearReferencesThreads
The web application [] is still processing a request that has yet to
finish. This is very likely to create a memory leak. You can control the
time allowed f

svn commit: r1533312 - in /tomcat/trunk: NOTICE res/META-INF/default.notice res/META-INF/servlet-api.jar.notice

2013-10-17 Thread violetagg
Author: violetagg
Date: Fri Oct 18 02:23:14 2013
New Revision: 1533312

URL: http://svn.apache.org/r1533312
Log:
Fix https://issues.apache.org/bugzilla/show_bug.cgi?id=55663
Notice files are corrected according to 
http://www.apache.org/legal/src-headers.html#notice

Modified:
tomcat/trunk/NOTICE
tomcat/trunk/res/META-INF/default.notice
tomcat/trunk/res/META-INF/servlet-api.jar.notice

Modified: tomcat/trunk/NOTICE
URL: 
http://svn.apache.org/viewvc/tomcat/trunk/NOTICE?rev=1533312&r1=1533311&r2=1533312&view=diff
==
--- tomcat/trunk/NOTICE (original)
+++ tomcat/trunk/NOTICE Fri Oct 18 02:23:14 2013
@@ -1,7 +1,7 @@
 Apache Tomcat
 Copyright 1999-2013 The Apache Software Foundation
 
-This product includes software developed by
+This product includes software developed at
 The Apache Software Foundation (http://www.apache.org/).
 
 The Windows Installer is built with the Nullsoft

Modified: tomcat/trunk/res/META-INF/default.notice
URL: 
http://svn.apache.org/viewvc/tomcat/trunk/res/META-INF/default.notice?rev=1533312&r1=1533311&r2=1533312&view=diff
==
--- tomcat/trunk/res/META-INF/default.notice (original)
+++ tomcat/trunk/res/META-INF/default.notice Fri Oct 18 02:23:14 2013
@@ -1,5 +1,5 @@
 Apache Tomcat
 Copyright 1999-@YEAR@ The Apache Software Foundation
 
-This product includes software developed by
+This product includes software developed at
 The Apache Software Foundation (http://www.apache.org/).

Modified: tomcat/trunk/res/META-INF/servlet-api.jar.notice
URL: 
http://svn.apache.org/viewvc/tomcat/trunk/res/META-INF/servlet-api.jar.notice?rev=1533312&r1=1533311&r2=1533312&view=diff
==
--- tomcat/trunk/res/META-INF/servlet-api.jar.notice (original)
+++ tomcat/trunk/res/META-INF/servlet-api.jar.notice Fri Oct 18 02:23:14 2013
@@ -1,7 +1,7 @@
 Apache Tomcat
 Copyright 1999-@YEAR@ The Apache Software Foundation
 
-This product includes software developed by
+This product includes software developed at
 The Apache Software Foundation (http://www.apache.org/).
 
 The original XML Schemas for Java EE Deployment Descriptors:



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



[Bug 55664] New: [websocket] NPE in Util$DecoderMatch during application start

2013-10-17 Thread bugzilla
https://issues.apache.org/bugzilla/show_bug.cgi?id=55664

Bug ID: 55664
   Summary: [websocket] NPE in Util$DecoderMatch during
application start
   Product: Tomcat 8
   Version: trunk
  Hardware: PC
Status: NEW
  Severity: normal
  Priority: P2
 Component: Catalina
  Assignee: dev@tomcat.apache.org
  Reporter: nick...@gmail.com

Created attachment 30934
  --> https://issues.apache.org/bugzilla/attachment.cgi?id=30934&action=edit
TestEncodingDecoding.patch

NPE is thrown when WS endpoint has associated encoder or decoder with type
using generics. Example: Decoder.Text>

Here I attach patch of org.apache.tomcat.websocket.pojo.TestEncodingDecoding
illustrating the case.

-- 
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: Tagging 7.0.47

2013-10-17 Thread Violeta Georgieva
2013/10/17 sebb 
>
> Please note https://issues.apache.org/bugzilla/show_bug.cgi?id=55663
>
> The text in the NOTICE file is wrong.
>

Thanks.
I'll fix the tag.

Violeta


Re: Tagging 7.0.47

2013-10-17 Thread sebb
Please note https://issues.apache.org/bugzilla/show_bug.cgi?id=55663

The text in the NOTICE file is wrong.

On 17 October 2013 13:15, Violeta Georgieva  wrote:
> Hi,
>
> I'm starting with Tomcat 7.0.47 tagging.
>
> Regards
> Violeta

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



[Bug 55663] New: Incorrect text in NOTICE file

2013-10-17 Thread bugzilla
https://issues.apache.org/bugzilla/show_bug.cgi?id=55663

Bug ID: 55663
   Summary: Incorrect text in NOTICE file
   Product: Tomcat 8
   Version: trunk
  Hardware: PC
OS: Windows XP
Status: NEW
  Severity: major
  Priority: P2
 Component: Catalina
  Assignee: dev@tomcat.apache.org
  Reporter: s...@apache.org

The NOTICE file in Tomcat trunk (and 7.x and 6.x) uses the wrong wording.

The 4th line should say [1][2]:

This product includes software developed at

however it actually says:

This product includes software developed by

which is not the same thing.

[Note that AL 1.0 and 1.1 did use the "developed by" wording; maybe that is the
origin of the problem.]

[1] http://www.apache.org/legal/src-headers.html#notice
[2] http://www.apache.org/dev/release.html#notice-require

-- 
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 55656] Server ClassLoader not used for Server creation

2013-10-17 Thread bugzilla
https://issues.apache.org/bugzilla/show_bug.cgi?id=55656

Mark Thomas  changed:

   What|Removed |Added

 Status|NEW |RESOLVED
 Resolution|--- |FIXED

--- Comment #3 from Mark Thomas  ---
Thanks for the patch.

The report makes sense and the patch looks good to me.

It has been applied to 8.0.x for 8.0.0-RC6 onwards and 7.0.x for 7.0.48
onwards.

Thanks again.

-- 
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: r1533119 - in /tomcat/tc7.0.x/trunk: ./ java/org/apache/catalina/startup/Catalina.java webapps/docs/changelog.xml

2013-10-17 Thread markt
Author: markt
Date: Thu Oct 17 15:28:24 2013
New Revision: 1533119

URL: http://svn.apache.org/r1533119
Log:
Fix https://issues.apache.org/bugzilla/show_bug.cgi?id=55656
Configure the Digester to use the server class loader when parsing server.xml 
rather than the class loader that loaded StandardServer.
Patch provided by Roberto Benedetti.

Modified:
tomcat/tc7.0.x/trunk/   (props changed)
tomcat/tc7.0.x/trunk/java/org/apache/catalina/startup/Catalina.java
tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml

Propchange: tomcat/tc7.0.x/trunk/
--
  Merged /tomcat/trunk:r1533117

Modified: tomcat/tc7.0.x/trunk/java/org/apache/catalina/startup/Catalina.java
URL: 
http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/java/org/apache/catalina/startup/Catalina.java?rev=1533119&r1=1533118&r2=1533119&view=diff
==
--- tomcat/tc7.0.x/trunk/java/org/apache/catalina/startup/Catalina.java 
(original)
+++ tomcat/tc7.0.x/trunk/java/org/apache/catalina/startup/Catalina.java Thu Oct 
17 15:28:24 2013
@@ -35,7 +35,6 @@ import org.apache.catalina.Globals;
 import org.apache.catalina.LifecycleException;
 import org.apache.catalina.LifecycleState;
 import org.apache.catalina.Server;
-import org.apache.catalina.core.StandardServer;
 import org.apache.catalina.security.SecurityConfig;
 import org.apache.juli.ClassLoaderLogManager;
 import org.apache.tomcat.util.ExceptionUtils;
@@ -310,7 +309,7 @@ public class Catalina {
 attrs.add("className");
 fakeAttributes.put(Object.class, attrs);
 digester.setFakeAttributes(fakeAttributes);
-digester.setClassLoader(StandardServer.class.getClassLoader());
+digester.setUseContextClassLoader(true);
 
 // Configure the actions we will be using
 digester.addObjectCreate("Server",
@@ -430,6 +429,7 @@ public class Catalina {
 
 // Initialize the digester
 Digester digester = new Digester();
+digester.setUseContextClassLoader(true);
 
 // Configure the rules we need for shutting down
 digester.addObjectCreate("Server",
@@ -459,7 +459,6 @@ public class Catalina {
 if( s == null ) {
 // Create and execute our Digester
 Digester digester = createStopDigester();
-
digester.setClassLoader(Thread.currentThread().getContextClassLoader());
 File file = configFile();
 FileInputStream fis = null;
 try {

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=1533119&r1=1533118&r2=1533119&view=diff
==
--- tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml (original)
+++ tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml Thu Oct 17 15:28:24 2013
@@ -55,6 +55,17 @@
   They eventually become mixed with the numbered issues. (I.e., numbered
   issues to not "pop up" wrt. others).
 -->
+
+  
+
+  
+55656: Configure the Digester to use the server class loader
+when parsing server.xml rather than the class loader that loaded
+StandardServer. Patch provided by Roberto Benedetti. (markt)
+  
+
+  
+
 
   
 



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



svn commit: r1533117 - /tomcat/trunk/java/org/apache/catalina/startup/Catalina.java

2013-10-17 Thread markt
Author: markt
Date: Thu Oct 17 15:26:13 2013
New Revision: 1533117

URL: http://svn.apache.org/r1533117
Log:
Fix https://issues.apache.org/bugzilla/show_bug.cgi?id=55656
Configure the Digester to use the server class loader when parsing server.xml 
rather than the class loader that loaded StandardServer.
Patch provided by Roberto Benedetti.

Modified:
tomcat/trunk/java/org/apache/catalina/startup/Catalina.java

Modified: tomcat/trunk/java/org/apache/catalina/startup/Catalina.java
URL: 
http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/catalina/startup/Catalina.java?rev=1533117&r1=1533116&r2=1533117&view=diff
==
--- tomcat/trunk/java/org/apache/catalina/startup/Catalina.java (original)
+++ tomcat/trunk/java/org/apache/catalina/startup/Catalina.java Thu Oct 17 
15:26:13 2013
@@ -34,7 +34,6 @@ import org.apache.catalina.Container;
 import org.apache.catalina.LifecycleException;
 import org.apache.catalina.LifecycleState;
 import org.apache.catalina.Server;
-import org.apache.catalina.core.StandardServer;
 import org.apache.catalina.security.SecurityConfig;
 import org.apache.juli.ClassLoaderLogManager;
 import org.apache.tomcat.util.ExceptionUtils;
@@ -275,7 +274,7 @@ public class Catalina {
 attrs.add("className");
 fakeAttributes.put(Object.class, attrs);
 digester.setFakeAttributes(fakeAttributes);
-digester.setClassLoader(StandardServer.class.getClassLoader());
+digester.setUseContextClassLoader(true);
 
 // Configure the actions we will be using
 digester.addObjectCreate("Server",
@@ -395,6 +394,7 @@ public class Catalina {
 
 // Initialize the digester
 Digester digester = new Digester();
+digester.setUseContextClassLoader(true);
 
 // Configure the rules we need for shutting down
 digester.addObjectCreate("Server",
@@ -424,7 +424,6 @@ public class Catalina {
 if( s == null ) {
 // Create and execute our Digester
 Digester digester = createStopDigester();
-
digester.setClassLoader(Thread.currentThread().getContextClassLoader());
 File file = configFile();
 FileInputStream fis = null;
 try {



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



Re: svn commit: r1533035 - /tomcat/tc7.0.x/trunk/webapps/examples/WEB-INF/classes/websocket/drawboard/Room.java

2013-10-17 Thread Christopher Schultz
Konstantin,

On 10/17/13 8:34 AM, Konstantin Preißer wrote:
> Mark,
> 
>> -Original Message-
>> From: Mark Thomas [mailto:ma...@apache.org]
>> Sent: Thursday, October 17, 2013 1:30 PM
>> To: Tomcat Developers List
>> Subject: Re: svn commit: r1533035 -
>> /tomcat/tc7.0.x/trunk/webapps/examples/WEB-
>> INF/classes/websocket/drawboard/Room.java
>>
>>
>> OK. I think I'm done.
>>
>> Mark
> 
> Thanks a lot. (I probably should have though of using lazy initializing also 
> when creating the room implementation, so e.g. the memory for the 
> BufferedImage is not created until the Drawboard is actually used :)

... or, you could always dispense with the server-side image altogether ;)

-chris



signature.asc
Description: OpenPGP digital signature


Re: [VOTE] Release Apache Tomcat 7.0.46

2013-10-17 Thread Christopher Schultz
Violetta,

On 10/16/13 3:33 PM, Violeta Georgieva wrote:
> The proposed Apache Tomcat 7.0.46 release is now available for voting.
> This release candidate contains JSR-356 Java WebSocket 1.0 implementation.
> Note that use of this functionality requires Java 7.
> 
> It can be obtained from:
> https://dist.apache.org/repos/dist/dev/tomcat/tomcat-7/v7.0.46/
> The Maven staging repo is:
> https://repository.apache.org/content/repositories/orgapachetomcat-189/
> The svn tag is:
> http://svn.apache.org/repos/asf/tomcat/tc7.0.x/tags/TOMCAT_7_0_46/
> 
> The proposed 7.0.46 release is:
> [ ] Broken - do not release
> [X] Stable - go ahead and release as 7.0.46 Stable

Debian Linux 2.6 x86-64
Oracle Java 1.6.0_26 64-bit JVM

MD5 sums match
GPG signatures match
ZIP and tarball are the same
tcnative builds fine
Checkstyle is happy
Java builds with a single warning:
compile-java6:
[javac] Compiling 1313 source files to
/home/cschultz/projects/apache-tomcat/tarball/apache-tomcat-7.0.45-src/output/classes
[javac]
/home/cschultz/projects/apache-tomcat/tarball/apache-tomcat-7.0.45-src/java/javax/el/ResourceBundleELResolver.java:109:
warning: getFeatureDescriptors(javax.el.ELContext,java.lang.Object) in
javax.el.ResourceBundleELResolver overrides
getFeatureDescriptors(javax.el.ELContext,java.lang.Object) in
javax.el.ELResolver; return type requires unchecked conversion
[javac] found   : java.util.Iterator
[javac] required: java.util.Iterator
[javac] public Iterator getFeatureDescriptors(
[javac] ^
BIO, NIO, and APR tests all pass (except for Tribes which are known to
fail in my environment)

A short smoke test in my development environment shows no problems.

Note that I'm not using Websocket or any of the new, fancy capabilities
of Tomcat.

-chris



signature.asc
Description: OpenPGP digital signature


svn commit: r1533084 - in /tomcat/tc7.0.x/tags/TOMCAT_7_0_47: ./ build.properties.default

2013-10-17 Thread violetagg
Author: violetagg
Date: Thu Oct 17 13:56:43 2013
New Revision: 1533084

URL: http://svn.apache.org/r1533084
Log:
Tag 7.0.47

Added:
tomcat/tc7.0.x/tags/TOMCAT_7_0_47/   (props changed)
  - copied from r1533082, tomcat/tc7.0.x/trunk/
Modified:
tomcat/tc7.0.x/tags/TOMCAT_7_0_47/build.properties.default

Propchange: tomcat/tc7.0.x/tags/TOMCAT_7_0_47/
--
bugtraq:append = false

Propchange: tomcat/tc7.0.x/tags/TOMCAT_7_0_47/
--
bugtraq:label = Bugzilla ID (optional)

Propchange: tomcat/tc7.0.x/tags/TOMCAT_7_0_47/
--
--- bugtraq:message (added)
+++ bugtraq:message Thu Oct 17 13:56:43 2013
@@ -0,0 +1 @@
+Fix https://issues.apache.org/bugzilla/show_bug.cgi?id=%BUGID%

Propchange: tomcat/tc7.0.x/tags/TOMCAT_7_0_47/
--
bugtraq:number = true

Propchange: tomcat/tc7.0.x/tags/TOMCAT_7_0_47/
--
bugtraq:url = https://issues.apache.org/bugzilla/show_bug.cgi?id=%BUGID%

Propchange: tomcat/tc7.0.x/tags/TOMCAT_7_0_47/
--
bugtraq:warnifnoissue = false

Propchange: tomcat/tc7.0.x/tags/TOMCAT_7_0_47/
--
--- svn:ignore (added)
+++ svn:ignore Thu Oct 17 13:56:43 2013
@@ -0,0 +1,7 @@
+.*
+build.properties
+logs
+nbproject
+output
+work
+*.iml

Propchange: tomcat/tc7.0.x/tags/TOMCAT_7_0_47/
--
--- svn:mergeinfo (added)
+++ svn:mergeinfo Thu Oct 17 13:56:43 2013
@@ -0,0 +1 @@
+/tomcat/trunk:1156115-1157160,1157162-1157859,1157862-1157942,1157945-1160347,1160349-1163716,1163718-1166689,1166691-1174340,1174342-1175596,1175598-1175611,1175613-1175932,1175934-1177783,1177785-1177980,1178006-1180720,1180722-1183094,1183096-1187753,1187755,1187775,1187801,1187806,1187809,1187826-1188312,1188314-1188401,1188646-1188840,1188842-1190176,1190178-1195223,1195225-1195953,1195955,1195957-1201238,1201240-1203345,1203347-1206623,1206625-1208046,1208073,1208096,1208114,1208145,1208772,1209194-1212125,1212127-1220291,1220293,1220295-1221321,1221323-1222328,1222332-1222401,1222405-1222795,1222850-1222950,1222969-1225326,1225328-1225463,1225465,1225627,1225629-1226534,1226536-1228908,1228911-1228923,1228927-1229532,1229534-1230766,1230768-1231625,1231627-1233414,1233419-1235207,1235209-1237425,1237427,1237429-1237977,1237981,1237985,1237995,1238070,1238073,1239024-1239048,1239050-1239062,1239135,1239256,1239258-1239485,1239785-1240046,1240101,1240106,1240109,1240112,1240114
 
,1240116,1240118,1240121,1240329,1240474-1240850,1240857,1241087,1241160,1241408-1241822,1241908-1241909,1241912-1242110,1242371-1292130,1292134-1292458,1292464-1292670,1292672-1292776,1292780-1293392,1293397-1297017,1297019-1297963,1297965-1299820,1300108,1300111-1300460,1300520-1300948,1300997,1301006,1301280,1302332,1302348,1302608-1302610,1302649,1302837,1303138,1303163,1303338,1303521,1303587,1303698,1303803,1303852,1304011,1304035,1304037,1304135,1304249,1304253,1304260,1304271,1304275,1304468,1304895,1304930-1304932,1305194,1305943,1305965,1306556,1306579-1306580,1307084,1307310,1307511-1307512,1307579,1307591,1307597,1310636,1310639-1310640,1310642,1310701,1311212,1311995,1327617,1327670,1331766,1333161,1333173,1333827,1334787,1335026,1335257,1335547,1335692,1335711,1335731,1336515,1336813,1336864,1336868,1336884,1337419,1337426,1337546,1337572,1337591-1337595,1337643,1337707,1337719,1337734,1337741,1337745,1338151-1338154,1338178,1342027,1342029,1342315,1342320,1342476,1342
 
498,1342503,1342717,1342795,1342805,1343044-1343046,1343335,1343394,1343400,1343629,1343708,1343718,1343895,1344063,1344068,1344250,1344266,1344515,1344528,1344612,1344629,1344725,1344868,1344890,1344893,1344896,1344901,1345020,1345029,1345039,1345287-1345290,1345294,1345309,1345325,1345357,1345367,1345579-1345580,1345582,1345688,1345699,1345704,1345731-1345732,1345737,1345744,1345752,1345754,1345779,1345781,1345846,1346107,1346376,1346404,1346510,1346514,1346519,1346581,1346635,1346644,1346683,1346794,1346885,1346932,1347034,1347047,1347087,1347108-1347109,1347583,1347737,1348105,1348357,1348398,1348425,1348461-1348495,1348498,1348752,1348762,1348772,1348776,1348859,1348968,1348973,1348989,1349007,1349237,1349298,1349317,1349410,1349473,1349539,1349879,1349887,1349893,1349922,1349984,1350124,1350241,1350243,1350294-1350295,1350299,1350864,1350900,1351010,1351054,1351056,1351068,1351134-1351135,1351148,1351259,1351604,1351636-1351640,1351991,1351993,1352011,1352056,1352059,1352661,1
 
352663,1352788,1352799,1353087,1353125,1353240,1353261,1353414,1353468,1353501,1353581,1

svn commit: r1533081 - /tomcat/tc7.0.x/tags/TOMCAT_7_0_47/

2013-10-17 Thread violetagg
Author: violetagg
Date: Thu Oct 17 13:47:52 2013
New Revision: 1533081

URL: http://svn.apache.org/r1533081
Log:
Remove tag TOMCAT_7_0_47 - r1533080 has to be added in the tag.

Removed:
tomcat/tc7.0.x/tags/TOMCAT_7_0_47/


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



svn commit: r1533080 - in /tomcat/tc7.0.x/trunk: build.properties.default res/maven/mvn.properties.default

2013-10-17 Thread violetagg
Author: violetagg
Date: Thu Oct 17 13:45:38 2013
New Revision: 1533080

URL: http://svn.apache.org/r1533080
Log:
Prep for 7.0.47 version

Modified:
tomcat/tc7.0.x/trunk/build.properties.default
tomcat/tc7.0.x/trunk/res/maven/mvn.properties.default

Modified: tomcat/tc7.0.x/trunk/build.properties.default
URL: 
http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/build.properties.default?rev=1533080&r1=1533079&r2=1533080&view=diff
==
--- tomcat/tc7.0.x/trunk/build.properties.default (original)
+++ tomcat/tc7.0.x/trunk/build.properties.default Thu Oct 17 13:45:38 2013
@@ -27,7 +27,7 @@
 # - Version Control Flags -
 version.major=7
 version.minor=0
-version.build=46
+version.build=47
 version.patch=0
 version.suffix=-dev
 

Modified: tomcat/tc7.0.x/trunk/res/maven/mvn.properties.default
URL: 
http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/res/maven/mvn.properties.default?rev=1533080&r1=1533079&r2=1533080&view=diff
==
--- tomcat/tc7.0.x/trunk/res/maven/mvn.properties.default (original)
+++ tomcat/tc7.0.x/trunk/res/maven/mvn.properties.default Thu Oct 17 13:45:38 
2013
@@ -35,7 +35,7 @@ maven.asf.release.repo.url=https://repos
 maven.asf.release.repo.repositoryId=apache.releases
 
 # Release version info
-maven.asf.release.deploy.version=7.0.46
+maven.asf.release.deploy.version=7.0.47
 
 #Where do we load the libraries from
 tomcat.lib.path=../../output/build/lib



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



svn commit: r1533078 - in /tomcat/tc7.0.x/tags/TOMCAT_7_0_47: ./ build.properties.default

2013-10-17 Thread violetagg
Author: violetagg
Date: Thu Oct 17 13:39:31 2013
New Revision: 1533078

URL: http://svn.apache.org/r1533078
Log:
Tag 7.0.47

Added:
tomcat/tc7.0.x/tags/TOMCAT_7_0_47/   (props changed)
  - copied from r1533075, tomcat/tc7.0.x/trunk/
Modified:
tomcat/tc7.0.x/tags/TOMCAT_7_0_47/build.properties.default

Propchange: tomcat/tc7.0.x/tags/TOMCAT_7_0_47/
--
bugtraq:append = false

Propchange: tomcat/tc7.0.x/tags/TOMCAT_7_0_47/
--
bugtraq:label = Bugzilla ID (optional)

Propchange: tomcat/tc7.0.x/tags/TOMCAT_7_0_47/
--
--- bugtraq:message (added)
+++ bugtraq:message Thu Oct 17 13:39:31 2013
@@ -0,0 +1 @@
+Fix https://issues.apache.org/bugzilla/show_bug.cgi?id=%BUGID%

Propchange: tomcat/tc7.0.x/tags/TOMCAT_7_0_47/
--
bugtraq:number = true

Propchange: tomcat/tc7.0.x/tags/TOMCAT_7_0_47/
--
bugtraq:url = https://issues.apache.org/bugzilla/show_bug.cgi?id=%BUGID%

Propchange: tomcat/tc7.0.x/tags/TOMCAT_7_0_47/
--
bugtraq:warnifnoissue = false

Propchange: tomcat/tc7.0.x/tags/TOMCAT_7_0_47/
--
--- svn:ignore (added)
+++ svn:ignore Thu Oct 17 13:39:31 2013
@@ -0,0 +1,7 @@
+.*
+build.properties
+logs
+nbproject
+output
+work
+*.iml

Propchange: tomcat/tc7.0.x/tags/TOMCAT_7_0_47/
--
--- svn:mergeinfo (added)
+++ svn:mergeinfo Thu Oct 17 13:39:31 2013
@@ -0,0 +1 @@
+/tomcat/trunk:1156115-1157160,1157162-1157859,1157862-1157942,1157945-1160347,1160349-1163716,1163718-1166689,1166691-1174340,1174342-1175596,1175598-1175611,1175613-1175932,1175934-1177783,1177785-1177980,1178006-1180720,1180722-1183094,1183096-1187753,1187755,1187775,1187801,1187806,1187809,1187826-1188312,1188314-1188401,1188646-1188840,1188842-1190176,1190178-1195223,1195225-1195953,1195955,1195957-1201238,1201240-1203345,1203347-1206623,1206625-1208046,1208073,1208096,1208114,1208145,1208772,1209194-1212125,1212127-1220291,1220293,1220295-1221321,1221323-1222328,1222332-1222401,1222405-1222795,1222850-1222950,1222969-1225326,1225328-1225463,1225465,1225627,1225629-1226534,1226536-1228908,1228911-1228923,1228927-1229532,1229534-1230766,1230768-1231625,1231627-1233414,1233419-1235207,1235209-1237425,1237427,1237429-1237977,1237981,1237985,1237995,1238070,1238073,1239024-1239048,1239050-1239062,1239135,1239256,1239258-1239485,1239785-1240046,1240101,1240106,1240109,1240112,1240114
 
,1240116,1240118,1240121,1240329,1240474-1240850,1240857,1241087,1241160,1241408-1241822,1241908-1241909,1241912-1242110,1242371-1292130,1292134-1292458,1292464-1292670,1292672-1292776,1292780-1293392,1293397-1297017,1297019-1297963,1297965-1299820,1300108,1300111-1300460,1300520-1300948,1300997,1301006,1301280,1302332,1302348,1302608-1302610,1302649,1302837,1303138,1303163,1303338,1303521,1303587,1303698,1303803,1303852,1304011,1304035,1304037,1304135,1304249,1304253,1304260,1304271,1304275,1304468,1304895,1304930-1304932,1305194,1305943,1305965,1306556,1306579-1306580,1307084,1307310,1307511-1307512,1307579,1307591,1307597,1310636,1310639-1310640,1310642,1310701,1311212,1311995,1327617,1327670,1331766,1333161,1333173,1333827,1334787,1335026,1335257,1335547,1335692,1335711,1335731,1336515,1336813,1336864,1336868,1336884,1337419,1337426,1337546,1337572,1337591-1337595,1337643,1337707,1337719,1337734,1337741,1337745,1338151-1338154,1338178,1342027,1342029,1342315,1342320,1342476,1342
 
498,1342503,1342717,1342795,1342805,1343044-1343046,1343335,1343394,1343400,1343629,1343708,1343718,1343895,1344063,1344068,1344250,1344266,1344515,1344528,1344612,1344629,1344725,1344868,1344890,1344893,1344896,1344901,1345020,1345029,1345039,1345287-1345290,1345294,1345309,1345325,1345357,1345367,1345579-1345580,1345582,1345688,1345699,1345704,1345731-1345732,1345737,1345744,1345752,1345754,1345779,1345781,1345846,1346107,1346376,1346404,1346510,1346514,1346519,1346581,1346635,1346644,1346683,1346794,1346885,1346932,1347034,1347047,1347087,1347108-1347109,1347583,1347737,1348105,1348357,1348398,1348425,1348461-1348495,1348498,1348752,1348762,1348772,1348776,1348859,1348968,1348973,1348989,1349007,1349237,1349298,1349317,1349410,1349473,1349539,1349879,1349887,1349893,1349922,1349984,1350124,1350241,1350243,1350294-1350295,1350299,1350864,1350900,1351010,1351054,1351056,1351068,1351134-1351135,1351148,1351259,1351604,1351636-1351640,1351991,1351993,1352011,1352056,1352059,1352661,1
 
352663,1352788,1352799,1353087,1353125,1353240,1353261,1353414,1353468,1353501,1353581,1

[Bug 55662] New: Add a way to set an instance of java.sql.Driver directly on org.apache.tomcat.jdbc.pool.DataSource

2013-10-17 Thread bugzilla
https://issues.apache.org/bugzilla/show_bug.cgi?id=55662

Bug ID: 55662
   Summary: Add a way to set an instance of java.sql.Driver
directly on org.apache.tomcat.jdbc.pool.DataSource
   Product: Tomcat 7
   Version: 7.0.42
  Hardware: Macintosh
Status: NEW
  Severity: enhancement
  Priority: P2
 Component: Integration
  Assignee: dev@tomcat.apache.org
  Reporter: nebh...@nebhale.com

Currently when org.apache.tomcat.jdbc.pool.DataSource is directly instantiated
(e.g. in an IoC environment), the only way to set the type of java.sql.Driver
that is should use is by passing in a String classname which is then passed to
DriverManager.  The downside to this is that it requires the DataSource and the
Driver to be in the same classloader.  In practice many times the Driver is in
the application classloader while the DataSource is in the container
classloader meaning that other than packaging a Tomcat JAR in your application
you cannot use the DataSource directly.

It'd be great to have a way to pass the actual instance of Driver to the
DataSource and have it use that instead of going to DriverManager to find it. 
This would enable standard classloader inheritance to work properly and allow
the non-adjacent packaging of the Driver and DataSource.

An example of this style of configuration can be found in Spring's
SimpleDriverDataSource[1].

[1]:
http://docs.spring.io/spring/docs/3.2.x/javadoc-api/org/springframework/jdbc/datasource/SimpleDriverDataSource.html#setDriver(java.sql.Driver)

-- 
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: svn commit: r1533035 - /tomcat/tc7.0.x/trunk/webapps/examples/WEB-INF/classes/websocket/drawboard/Room.java

2013-10-17 Thread Konstantin Preißer
Mark,

> -Original Message-
> From: Mark Thomas [mailto:ma...@apache.org]
> Sent: Thursday, October 17, 2013 1:30 PM
> To: Tomcat Developers List
> Subject: Re: svn commit: r1533035 -
> /tomcat/tc7.0.x/trunk/webapps/examples/WEB-
> INF/classes/websocket/drawboard/Room.java
> 
> 
> OK. I think I'm done.
> 
> Mark

Thanks a lot. (I probably should have though of using lazy initializing also 
when creating the room implementation, so e.g. the memory for the BufferedImage 
is not created until the Drawboard is actually used :)


Regards,
Konstantin Preißer


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



Tagging 7.0.47

2013-10-17 Thread Violeta Georgieva
Hi,

I'm starting with Tomcat 7.0.47 tagging.

Regards
Violeta


svn commit: r3287 - /dev/tomcat/tomcat-7/v7.0.46/

2013-10-17 Thread violetagg
Author: violetagg
Date: Thu Oct 17 12:06:14 2013
New Revision: 3287

Log:
7.0.46 RC did not pass the vote - dropping.

Removed:
dev/tomcat/tomcat-7/v7.0.46/


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



Re: [VOTE] Release Apache Tomcat 7.0.46

2013-10-17 Thread Violeta Georgieva
2013/10/16 Violeta Georgieva 
>
> The proposed Apache Tomcat 7.0.46 release is now available for voting.
> This release candidate contains JSR-356 Java WebSocket 1.0
implementation. Note that use of this functionality requires Java 7.
>
> It can be obtained from:
> https://dist.apache.org/repos/dist/dev/tomcat/tomcat-7/v7.0.46/
> The Maven staging repo is:
> https://repository.apache.org/content/repositories/orgapachetomcat-189/
> The svn tag is:
> http://svn.apache.org/repos/asf/tomcat/tc7.0.x/tags/TOMCAT_7_0_46/
>
> The proposed 7.0.46 release is:
> [X] Broken - do not release
> [ ] Stable - go ahead and release as 7.0.46 Stable


Based on the issues reported here I'm cancelling the voting.

Regards
Violeta


svn commit: r1533050 - in /tomcat/tc7.0.x/trunk: ./ webapps/docs/changelog.xml webapps/examples/WEB-INF/classes/websocket/drawboard/DrawboardContextListener.java webapps/examples/WEB-INF/classes/webso

2013-10-17 Thread markt
Author: markt
Date: Thu Oct 17 11:28:57 2013
New Revision: 1533050

URL: http://svn.apache.org/r1533050
Log:
Use lazy init for the room in the WebSocket drawing board example.
This is primarily to avoid an issue with a hang on Java 6 in Tomcat 7 (the 
JSR-356 examples require Java 6) but may also help with adding multiple room 
support.

Modified:
tomcat/tc7.0.x/trunk/   (props changed)
tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml

tomcat/tc7.0.x/trunk/webapps/examples/WEB-INF/classes/websocket/drawboard/DrawboardContextListener.java

tomcat/tc7.0.x/trunk/webapps/examples/WEB-INF/classes/websocket/drawboard/DrawboardEndpoint.java

Propchange: tomcat/tc7.0.x/trunk/
--
  Merged /tomcat/trunk:r1533048-1533049

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=1533050&r1=1533049&r2=1533050&view=diff
==
--- tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml (original)
+++ tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml Thu Oct 17 11:28:57 2013
@@ -64,6 +64,14 @@
   
 
   
+  
+
+  
+Avoid hang observed with Java 6 on Windows when stopping the Tomcat
+process via CTRL-C. (markt) 
+  
+
+  
 
 
   
@@ -93,12 +101,6 @@
 thread-safe manner. (markt)
   
   
-Ensure that unused input is not swallowed when keep-alive is disabled
-and the connection enters an error state. This allows the connection to
-be closed immediately rather than having to wait for the client to 
first
-send any remaining data that is only going to be ignored. (markt)
-  
-  
 Update the APR/native connector to version 1.1.29. (violetagg)
   
 

Modified: 
tomcat/tc7.0.x/trunk/webapps/examples/WEB-INF/classes/websocket/drawboard/DrawboardContextListener.java
URL: 
http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/webapps/examples/WEB-INF/classes/websocket/drawboard/DrawboardContextListener.java?rev=1533050&r1=1533049&r2=1533050&view=diff
==
--- 
tomcat/tc7.0.x/trunk/webapps/examples/WEB-INF/classes/websocket/drawboard/DrawboardContextListener.java
 (original)
+++ 
tomcat/tc7.0.x/trunk/webapps/examples/WEB-INF/classes/websocket/drawboard/DrawboardContextListener.java
 Thu Oct 17 11:28:57 2013
@@ -29,6 +29,9 @@ public final class DrawboardContextListe
 @Override
 public void contextDestroyed(ServletContextEvent sce) {
 // Shutdown our room.
-DrawboardEndpoint.getRoom().shutdown();
+Room room = DrawboardEndpoint.getRoom(false);
+if (room != null) {
+room.shutdown();
+}
 }
 }

Modified: 
tomcat/tc7.0.x/trunk/webapps/examples/WEB-INF/classes/websocket/drawboard/DrawboardEndpoint.java
URL: 
http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/webapps/examples/WEB-INF/classes/websocket/drawboard/DrawboardEndpoint.java?rev=1533050&r1=1533049&r2=1533050&view=diff
==
--- 
tomcat/tc7.0.x/trunk/webapps/examples/WEB-INF/classes/websocket/drawboard/DrawboardEndpoint.java
 (original)
+++ 
tomcat/tc7.0.x/trunk/webapps/examples/WEB-INF/classes/websocket/drawboard/DrawboardEndpoint.java
 Thu Oct 17 11:28:57 2013
@@ -40,10 +40,22 @@ public final class DrawboardEndpoint ext
 /**
  * Our room where players can join.
  */
-private static final Room room = new Room();
+private static volatile Room room = null;
+private static final Object roomLock = new Object();
 
-public static Room getRoom() {
-return room;
+public static Room getRoom(boolean create) {
+if (create) {
+if (room == null) {
+synchronized (roomLock) {
+if (room == null) {
+room = new Room();
+}
+}
+}
+return room;
+} else {
+return room;
+}
 }
 
 /**
@@ -72,6 +84,7 @@ public final class DrawboardEndpoint ext
 session.addMessageHandler(stringHandler);
 final Client client = new Client(session);
 
+final Room room = getRoom(true);
 room.invokeAndWait(new Runnable() {
 @Override
 public void run() {
@@ -100,23 +113,23 @@ public final class DrawboardEndpoint ext
 
 @Override
 public void onClose(Session session, CloseReason closeReason) {
-room.invokeAndWait(new Runnable() {
-@Override
-public void run() {
-try {
-
-// Player can be null if it couldn't enter the room
-if (player != null) {
-// Remove this player from the room.
-  

Re: svn commit: r1533035 - /tomcat/tc7.0.x/trunk/webapps/examples/WEB-INF/classes/websocket/drawboard/Room.java

2013-10-17 Thread Mark Thomas
On 17/10/2013 12:21, Konstantin Preißer wrote:
> 
> 
>> -Original Message-
>> From: Konstantin Preißer [mailto:kpreis...@apache.org]
>> Sent: Thursday, October 17, 2013 1:18 PM
>> To: 'Tomcat Developers List'
>> Subject: RE: svn commit: r1533035 -
>> /tomcat/tc7.0.x/trunk/webapps/examples/WEB-
>> INF/classes/websocket/drawboard/Room.java
>>
>> Hi Mark,
>>
>>> -Original Message-
>>> From: Mark Thomas [mailto:ma...@apache.org]
>>> Sent: Thursday, October 17, 2013 1:10 PM
>>> To: Tomcat Developers List
>>> Subject: Re: svn commit: r1533035 -
>>> /tomcat/tc7.0.x/trunk/webapps/examples/WEB-
>>> INF/classes/websocket/drawboard/Room.java
>>>
>>> On 17/10/2013 11:53, Mark Thomas wrote:
 On 17/10/2013 11:50, Konstantin Preißer wrote:
> Hi Mark,
>
>> -Original Message-
>> From: Mark Thomas [mailto:ma...@apache.org]
>> Sent: Thursday, October 17, 2013 12:49 PM
>> To: Tomcat Developers List
>> Subject: Re: svn commit: r1533035 -
>> /tomcat/tc7.0.x/trunk/webapps/examples/WEB-
>> INF/classes/websocket/drawboard/Room.java
>>
>> On 17/10/2013 11:39, Konstantin Kolinko wrote:
>>> 2013/10/17  :
 Author: markt
 Date: Thu Oct 17 10:32:21 2013
 New Revision: 1533035

 URL: http://svn.apache.org/r1533035
 Log:
 Avoid hangs on shutdown

 Modified:
 tomcat/tc7.0.x/trunk/webapps/examples/WEB-
>> INF/classes/websocket/drawboard/Room.java

>>>
>>> I expect this to
>>> a) fail when running with a security manager
>>> b) cause a memory leak when examples app is reloaded, as you will
>> get
>>> a new instance of ShutdownDetection class in webapp's classloader
>>> and
>>> new instance of shutdown hook.
>>
>> I'm open to better suggestions. Another option I considered was just
>> removing the call to roomGraphics.dispose(); and letting GC take care
>> of
>> things.
>>
>> Alternatively, we could provide some form of global flag.
>>
>> I think I prefer the global flag that indicates that a shutdown is in
>> process. I can think of several other places where such a flag would
>> have been useful and we can expose it through a custom servlet
>> context
>> attribute such as
>>> "org.apache.tomcat.JVM_SHUTDOWN_IN_PROGRESS".
>>
>> I'll start looking at the global flag option. Meanwhile, any suggestions
>> on how to improve the fix or an alternative fix welcome.
>
> Can you give me some insight of why Grahpics2D.dispose() may cause a
>>> hang on shutdown? I have never seen .dispose() causing a hang, at least
>> not
>>> on Windows.
> If it hangs, might this be a result of different threads using the 
> Grahpics
>>> object?

 Clean 7.0.x build
 catalina.bat start
 CTRL-C in the Tomcat Window

 The result is an exception written to stderr (I assume err rather than
 out) and Tomcat fails to stop. The exception is triggered by AWT trying
 to register a shutdown hook after the shutdown process has started.
>>>
>>> Ah. More info. It only occurs with Java 6.
>>>
>>> We could just classify this as a JVM bug and more on. That said, I think
>>> some changes to the init code could probably avoid this in Java 6 as
>>> well. I'll take a quick look.
>>
>> OK, thanks.
>> However, I can reproduce the hang now with Tomcat 7 on Java 7. Although I
>> do not get a exception, I get a short hang and a warning: "The executor
>> associated with thread pool [http-bio-8080] has not fully shutdown. Some
>> application threads may still be running." After that, Tomcat closed.
>> I do not get this with Tomcat 8.
>>
>> My reaction also would have been to just remove the dispose() in the
>> Tomcat 7 example since it is unlikely that the examples application is
>> reloaded many times on a Tomcat run and creates too much Graphics2D
>> objects that the GC does not dispose. But of course, I have nothing against a
>> better solution if you find one. :)
> 
> OK, that was not the full story:
> 
> I can reproduce the short hang (and the warning) on Tomcat 8 with BIO 
> connector, but not with NIO or APR...

OK. I think I'm done.

Mark


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



svn commit: r1533049 - /tomcat/trunk/webapps/examples/WEB-INF/classes/websocket/drawboard/DrawboardEndpoint.java

2013-10-17 Thread markt
Author: markt
Date: Thu Oct 17 11:26:15 2013
New Revision: 1533049

URL: http://svn.apache.org/r1533049
Log:
Whitespace police

Modified:

tomcat/trunk/webapps/examples/WEB-INF/classes/websocket/drawboard/DrawboardEndpoint.java

Modified: 
tomcat/trunk/webapps/examples/WEB-INF/classes/websocket/drawboard/DrawboardEndpoint.java
URL: 
http://svn.apache.org/viewvc/tomcat/trunk/webapps/examples/WEB-INF/classes/websocket/drawboard/DrawboardEndpoint.java?rev=1533049&r1=1533048&r2=1533049&view=diff
==
--- 
tomcat/trunk/webapps/examples/WEB-INF/classes/websocket/drawboard/DrawboardEndpoint.java
 (original)
+++ 
tomcat/trunk/webapps/examples/WEB-INF/classes/websocket/drawboard/DrawboardEndpoint.java
 Thu Oct 17 11:26:15 2013
@@ -119,13 +119,11 @@ public final class DrawboardEndpoint ext
 @Override
 public void run() {
 try {
-
 // Player can be null if it couldn't enter the room
 if (player != null) {
 // Remove this player from the room.
 player.removeFromRoom();
 }
-
 } catch (RuntimeException ex) {
 log.error("Unexpected exception: " + ex.toString(), 
ex);
 }



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



svn commit: r1533048 - in /tomcat/trunk/webapps/examples/WEB-INF/classes/websocket/drawboard: DrawboardContextListener.java DrawboardEndpoint.java

2013-10-17 Thread markt
Author: markt
Date: Thu Oct 17 11:25:23 2013
New Revision: 1533048

URL: http://svn.apache.org/r1533048
Log:
Use lazy init for the room in the WebSocket drawing board example.
This is primarily to avoid an issue with a hang on Java 6 in Tomcat 7 (the 
JSR-356 examples require Java 6) but may also help with adding multiple room 
support.

Modified:

tomcat/trunk/webapps/examples/WEB-INF/classes/websocket/drawboard/DrawboardContextListener.java

tomcat/trunk/webapps/examples/WEB-INF/classes/websocket/drawboard/DrawboardEndpoint.java

Modified: 
tomcat/trunk/webapps/examples/WEB-INF/classes/websocket/drawboard/DrawboardContextListener.java
URL: 
http://svn.apache.org/viewvc/tomcat/trunk/webapps/examples/WEB-INF/classes/websocket/drawboard/DrawboardContextListener.java?rev=1533048&r1=1533047&r2=1533048&view=diff
==
--- 
tomcat/trunk/webapps/examples/WEB-INF/classes/websocket/drawboard/DrawboardContextListener.java
 (original)
+++ 
tomcat/trunk/webapps/examples/WEB-INF/classes/websocket/drawboard/DrawboardContextListener.java
 Thu Oct 17 11:25:23 2013
@@ -29,6 +29,9 @@ public final class DrawboardContextListe
 @Override
 public void contextDestroyed(ServletContextEvent sce) {
 // Shutdown our room.
-DrawboardEndpoint.getRoom().shutdown();
+Room room = DrawboardEndpoint.getRoom(false);
+if (room != null) {
+room.shutdown();
+}
 }
 }

Modified: 
tomcat/trunk/webapps/examples/WEB-INF/classes/websocket/drawboard/DrawboardEndpoint.java
URL: 
http://svn.apache.org/viewvc/tomcat/trunk/webapps/examples/WEB-INF/classes/websocket/drawboard/DrawboardEndpoint.java?rev=1533048&r1=1533047&r2=1533048&view=diff
==
--- 
tomcat/trunk/webapps/examples/WEB-INF/classes/websocket/drawboard/DrawboardEndpoint.java
 (original)
+++ 
tomcat/trunk/webapps/examples/WEB-INF/classes/websocket/drawboard/DrawboardEndpoint.java
 Thu Oct 17 11:25:23 2013
@@ -40,10 +40,22 @@ public final class DrawboardEndpoint ext
 /**
  * Our room where players can join.
  */
-private static final Room room = new Room();
+private static volatile Room room = null;
+private static final Object roomLock = new Object();
 
-public static Room getRoom() {
-return room;
+public static Room getRoom(boolean create) {
+if (create) {
+if (room == null) {
+synchronized (roomLock) {
+if (room == null) {
+room = new Room();
+}
+}
+}
+return room;
+} else {
+return room;
+}
 }
 
 /**
@@ -72,6 +84,7 @@ public final class DrawboardEndpoint ext
 session.addMessageHandler(stringHandler);
 final Client client = new Client(session);
 
+final Room room = getRoom(true);
 room.invokeAndWait(new Runnable() {
 @Override
 public void run() {
@@ -100,23 +113,25 @@ public final class DrawboardEndpoint ext
 
 @Override
 public void onClose(Session session, CloseReason closeReason) {
-room.invokeAndWait(new Runnable() {
-@Override
-public void run() {
-try {
-
-// Player can be null if it couldn't enter the room
-if (player != null) {
-// Remove this player from the room.
-player.removeFromRoom();
+Room room = getRoom(false);
+if (room != null) {
+room.invokeAndWait(new Runnable() {
+@Override
+public void run() {
+try {
+
+// Player can be null if it couldn't enter the room
+if (player != null) {
+// Remove this player from the room.
+player.removeFromRoom();
+}
+
+} catch (RuntimeException ex) {
+log.error("Unexpected exception: " + ex.toString(), 
ex);
 }
-
-} catch (RuntimeException ex) {
-log.error("Unexpected exception: " + ex.toString(), ex);
 }
-}
-});
-
+});
+}
 }
 
 



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



RE: svn commit: r1533035 - /tomcat/tc7.0.x/trunk/webapps/examples/WEB-INF/classes/websocket/drawboard/Room.java

2013-10-17 Thread Konstantin Preißer


> -Original Message-
> From: Konstantin Preißer [mailto:kpreis...@apache.org]
> Sent: Thursday, October 17, 2013 1:18 PM
> To: 'Tomcat Developers List'
> Subject: RE: svn commit: r1533035 -
> /tomcat/tc7.0.x/trunk/webapps/examples/WEB-
> INF/classes/websocket/drawboard/Room.java
> 
> Hi Mark,
> 
> > -Original Message-
> > From: Mark Thomas [mailto:ma...@apache.org]
> > Sent: Thursday, October 17, 2013 1:10 PM
> > To: Tomcat Developers List
> > Subject: Re: svn commit: r1533035 -
> > /tomcat/tc7.0.x/trunk/webapps/examples/WEB-
> > INF/classes/websocket/drawboard/Room.java
> >
> > On 17/10/2013 11:53, Mark Thomas wrote:
> > > On 17/10/2013 11:50, Konstantin Preißer wrote:
> > >> Hi Mark,
> > >>
> > >>> -Original Message-
> > >>> From: Mark Thomas [mailto:ma...@apache.org]
> > >>> Sent: Thursday, October 17, 2013 12:49 PM
> > >>> To: Tomcat Developers List
> > >>> Subject: Re: svn commit: r1533035 -
> > >>> /tomcat/tc7.0.x/trunk/webapps/examples/WEB-
> > >>> INF/classes/websocket/drawboard/Room.java
> > >>>
> > >>> On 17/10/2013 11:39, Konstantin Kolinko wrote:
> >  2013/10/17  :
> > > Author: markt
> > > Date: Thu Oct 17 10:32:21 2013
> > > New Revision: 1533035
> > >
> > > URL: http://svn.apache.org/r1533035
> > > Log:
> > > Avoid hangs on shutdown
> > >
> > > Modified:
> > > tomcat/tc7.0.x/trunk/webapps/examples/WEB-
> > >>> INF/classes/websocket/drawboard/Room.java
> > >
> > 
> >  I expect this to
> >  a) fail when running with a security manager
> >  b) cause a memory leak when examples app is reloaded, as you will
> get
> >  a new instance of ShutdownDetection class in webapp's classloader
> > and
> >  new instance of shutdown hook.
> > >>>
> > >>> I'm open to better suggestions. Another option I considered was just
> > >>> removing the call to roomGraphics.dispose(); and letting GC take care
> of
> > >>> things.
> > >>>
> > >>> Alternatively, we could provide some form of global flag.
> > >>>
> > >>> I think I prefer the global flag that indicates that a shutdown is in
> > >>> process. I can think of several other places where such a flag would
> > >>> have been useful and we can expose it through a custom servlet
> context
> > >>> attribute such as
> > "org.apache.tomcat.JVM_SHUTDOWN_IN_PROGRESS".
> > >>>
> > >>> I'll start looking at the global flag option. Meanwhile, any suggestions
> > >>> on how to improve the fix or an alternative fix welcome.
> > >>
> > >> Can you give me some insight of why Grahpics2D.dispose() may cause a
> > hang on shutdown? I have never seen .dispose() causing a hang, at least
> not
> > on Windows.
> > >> If it hangs, might this be a result of different threads using the 
> > >> Grahpics
> > object?
> > >
> > > Clean 7.0.x build
> > > catalina.bat start
> > > CTRL-C in the Tomcat Window
> > >
> > > The result is an exception written to stderr (I assume err rather than
> > > out) and Tomcat fails to stop. The exception is triggered by AWT trying
> > > to register a shutdown hook after the shutdown process has started.
> >
> > Ah. More info. It only occurs with Java 6.
> >
> > We could just classify this as a JVM bug and more on. That said, I think
> > some changes to the init code could probably avoid this in Java 6 as
> > well. I'll take a quick look.
> 
> OK, thanks.
> However, I can reproduce the hang now with Tomcat 7 on Java 7. Although I
> do not get a exception, I get a short hang and a warning: "The executor
> associated with thread pool [http-bio-8080] has not fully shutdown. Some
> application threads may still be running." After that, Tomcat closed.
> I do not get this with Tomcat 8.
> 
> My reaction also would have been to just remove the dispose() in the
> Tomcat 7 example since it is unlikely that the examples application is
> reloaded many times on a Tomcat run and creates too much Graphics2D
> objects that the GC does not dispose. But of course, I have nothing against a
> better solution if you find one. :)

OK, that was not the full story:

I can reproduce the short hang (and the warning) on Tomcat 8 with BIO 
connector, but not with NIO or APR...


Regards,
Konstantin Preißer


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



RE: svn commit: r1533035 - /tomcat/tc7.0.x/trunk/webapps/examples/WEB-INF/classes/websocket/drawboard/Room.java

2013-10-17 Thread Konstantin Preißer
Hi Mark,

> -Original Message-
> From: Mark Thomas [mailto:ma...@apache.org]
> Sent: Thursday, October 17, 2013 1:10 PM
> To: Tomcat Developers List
> Subject: Re: svn commit: r1533035 -
> /tomcat/tc7.0.x/trunk/webapps/examples/WEB-
> INF/classes/websocket/drawboard/Room.java
> 
> On 17/10/2013 11:53, Mark Thomas wrote:
> > On 17/10/2013 11:50, Konstantin Preißer wrote:
> >> Hi Mark,
> >>
> >>> -Original Message-
> >>> From: Mark Thomas [mailto:ma...@apache.org]
> >>> Sent: Thursday, October 17, 2013 12:49 PM
> >>> To: Tomcat Developers List
> >>> Subject: Re: svn commit: r1533035 -
> >>> /tomcat/tc7.0.x/trunk/webapps/examples/WEB-
> >>> INF/classes/websocket/drawboard/Room.java
> >>>
> >>> On 17/10/2013 11:39, Konstantin Kolinko wrote:
>  2013/10/17  :
> > Author: markt
> > Date: Thu Oct 17 10:32:21 2013
> > New Revision: 1533035
> >
> > URL: http://svn.apache.org/r1533035
> > Log:
> > Avoid hangs on shutdown
> >
> > Modified:
> > tomcat/tc7.0.x/trunk/webapps/examples/WEB-
> >>> INF/classes/websocket/drawboard/Room.java
> >
> 
>  I expect this to
>  a) fail when running with a security manager
>  b) cause a memory leak when examples app is reloaded, as you will get
>  a new instance of ShutdownDetection class in webapp's classloader
> and
>  new instance of shutdown hook.
> >>>
> >>> I'm open to better suggestions. Another option I considered was just
> >>> removing the call to roomGraphics.dispose(); and letting GC take care of
> >>> things.
> >>>
> >>> Alternatively, we could provide some form of global flag.
> >>>
> >>> I think I prefer the global flag that indicates that a shutdown is in
> >>> process. I can think of several other places where such a flag would
> >>> have been useful and we can expose it through a custom servlet context
> >>> attribute such as
> "org.apache.tomcat.JVM_SHUTDOWN_IN_PROGRESS".
> >>>
> >>> I'll start looking at the global flag option. Meanwhile, any suggestions
> >>> on how to improve the fix or an alternative fix welcome.
> >>
> >> Can you give me some insight of why Grahpics2D.dispose() may cause a
> hang on shutdown? I have never seen .dispose() causing a hang, at least not
> on Windows.
> >> If it hangs, might this be a result of different threads using the Grahpics
> object?
> >
> > Clean 7.0.x build
> > catalina.bat start
> > CTRL-C in the Tomcat Window
> >
> > The result is an exception written to stderr (I assume err rather than
> > out) and Tomcat fails to stop. The exception is triggered by AWT trying
> > to register a shutdown hook after the shutdown process has started.
> 
> Ah. More info. It only occurs with Java 6.
> 
> We could just classify this as a JVM bug and more on. That said, I think
> some changes to the init code could probably avoid this in Java 6 as
> well. I'll take a quick look.

OK, thanks.
However, I can reproduce the hang now with Tomcat 7 on Java 7. Although I do 
not get a exception, I get a short hang and a warning: "The executor associated 
with thread pool [http-bio-8080] has not fully shutdown. Some application 
threads may still be running." After that, Tomcat closed.
I do not get this with Tomcat 8.

My reaction also would have been to just remove the dispose() in the Tomcat 7 
example since it is unlikely that the examples application is reloaded many 
times on a Tomcat run and creates too much Graphics2D objects that the GC does 
not dispose. But of course, I have nothing against a better solution if you 
find one. :)


Regards,
Konstantin Preißer




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



Re: svn commit: r1533035 - /tomcat/tc7.0.x/trunk/webapps/examples/WEB-INF/classes/websocket/drawboard/Room.java

2013-10-17 Thread Mark Thomas
On 17/10/2013 11:53, Mark Thomas wrote:
> On 17/10/2013 11:50, Konstantin Preißer wrote:
>> Hi Mark,
>>
>>> -Original Message-
>>> From: Mark Thomas [mailto:ma...@apache.org]
>>> Sent: Thursday, October 17, 2013 12:49 PM
>>> To: Tomcat Developers List
>>> Subject: Re: svn commit: r1533035 -
>>> /tomcat/tc7.0.x/trunk/webapps/examples/WEB-
>>> INF/classes/websocket/drawboard/Room.java
>>>
>>> On 17/10/2013 11:39, Konstantin Kolinko wrote:
 2013/10/17  :
> Author: markt
> Date: Thu Oct 17 10:32:21 2013
> New Revision: 1533035
>
> URL: http://svn.apache.org/r1533035
> Log:
> Avoid hangs on shutdown
>
> Modified:
> tomcat/tc7.0.x/trunk/webapps/examples/WEB-
>>> INF/classes/websocket/drawboard/Room.java
>

 I expect this to
 a) fail when running with a security manager
 b) cause a memory leak when examples app is reloaded, as you will get
 a new instance of ShutdownDetection class in webapp's classloader and
 new instance of shutdown hook.
>>>
>>> I'm open to better suggestions. Another option I considered was just
>>> removing the call to roomGraphics.dispose(); and letting GC take care of
>>> things.
>>>
>>> Alternatively, we could provide some form of global flag.
>>>
>>> I think I prefer the global flag that indicates that a shutdown is in
>>> process. I can think of several other places where such a flag would
>>> have been useful and we can expose it through a custom servlet context
>>> attribute such as "org.apache.tomcat.JVM_SHUTDOWN_IN_PROGRESS".
>>>
>>> I'll start looking at the global flag option. Meanwhile, any suggestions
>>> on how to improve the fix or an alternative fix welcome.
>>
>> Can you give me some insight of why Grahpics2D.dispose() may cause a hang on 
>> shutdown? I have never seen .dispose() causing a hang, at least not on 
>> Windows.
>> If it hangs, might this be a result of different threads using the Grahpics 
>> object?
> 
> Clean 7.0.x build
> catalina.bat start
> CTRL-C in the Tomcat Window
> 
> The result is an exception written to stderr (I assume err rather than
> out) and Tomcat fails to stop. The exception is triggered by AWT trying
> to register a shutdown hook after the shutdown process has started.

Ah. More info. It only occurs with Java 6.

We could just classify this as a JVM bug and more on. That said, I think
some changes to the init code could probably avoid this in Java 6 as
well. I'll take a quick look.

Mark


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



svn commit: r1533046 - /tomcat/tc7.0.x/trunk/webapps/examples/WEB-INF/classes/websocket/drawboard/Room.java

2013-10-17 Thread markt
Author: markt
Date: Thu Oct 17 11:04:08 2013
New Revision: 1533046

URL: http://svn.apache.org/r1533046
Log:
Revert r1533035. A better solution is required.

Modified:

tomcat/tc7.0.x/trunk/webapps/examples/WEB-INF/classes/websocket/drawboard/Room.java

Modified: 
tomcat/tc7.0.x/trunk/webapps/examples/WEB-INF/classes/websocket/drawboard/Room.java
URL: 
http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/webapps/examples/WEB-INF/classes/websocket/drawboard/Room.java?rev=1533046&r1=1533045&r2=1533046&view=diff
==
--- 
tomcat/tc7.0.x/trunk/webapps/examples/WEB-INF/classes/websocket/drawboard/Room.java
 (original)
+++ 
tomcat/tc7.0.x/trunk/webapps/examples/WEB-INF/classes/websocket/drawboard/Room.java
 Thu Oct 17 11:04:08 2013
@@ -316,9 +316,7 @@ public final class Room {
 public void run() {
 closed = true;
 drawmessageBroadcastTimer.cancel();
-if (!ShutdownDetection.hasShutdownStarted()) {
-roomGraphics.dispose();
-}
+roomGraphics.dispose();
 }
 });
 }
@@ -414,23 +412,4 @@ public final class Room {
 client.sendMessage(new StringWebsocketMessage(completeMsg));
 }
 }
-
-
-static {
-Runtime.getRuntime().addShutdownHook(new ShutdownDetection());
-}
-
-
-private static class ShutdownDetection extends Thread {
-private static volatile boolean shutdownStarted = false;
-
-private static boolean hasShutdownStarted() {
-return shutdownStarted;
-}
-
-@Override
-public void run() {
-shutdownStarted = true;
-}
-}
 }



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



Re: svn commit: r1533035 - /tomcat/tc7.0.x/trunk/webapps/examples/WEB-INF/classes/websocket/drawboard/Room.java

2013-10-17 Thread Mark Thomas
On 17/10/2013 11:50, Konstantin Preißer wrote:
> Hi Mark,
> 
>> -Original Message-
>> From: Mark Thomas [mailto:ma...@apache.org]
>> Sent: Thursday, October 17, 2013 12:49 PM
>> To: Tomcat Developers List
>> Subject: Re: svn commit: r1533035 -
>> /tomcat/tc7.0.x/trunk/webapps/examples/WEB-
>> INF/classes/websocket/drawboard/Room.java
>>
>> On 17/10/2013 11:39, Konstantin Kolinko wrote:
>>> 2013/10/17  :
 Author: markt
 Date: Thu Oct 17 10:32:21 2013
 New Revision: 1533035

 URL: http://svn.apache.org/r1533035
 Log:
 Avoid hangs on shutdown

 Modified:
 tomcat/tc7.0.x/trunk/webapps/examples/WEB-
>> INF/classes/websocket/drawboard/Room.java

>>>
>>> I expect this to
>>> a) fail when running with a security manager
>>> b) cause a memory leak when examples app is reloaded, as you will get
>>> a new instance of ShutdownDetection class in webapp's classloader and
>>> new instance of shutdown hook.
>>
>> I'm open to better suggestions. Another option I considered was just
>> removing the call to roomGraphics.dispose(); and letting GC take care of
>> things.
>>
>> Alternatively, we could provide some form of global flag.
>>
>> I think I prefer the global flag that indicates that a shutdown is in
>> process. I can think of several other places where such a flag would
>> have been useful and we can expose it through a custom servlet context
>> attribute such as "org.apache.tomcat.JVM_SHUTDOWN_IN_PROGRESS".
>>
>> I'll start looking at the global flag option. Meanwhile, any suggestions
>> on how to improve the fix or an alternative fix welcome.
> 
> Can you give me some insight of why Grahpics2D.dispose() may cause a hang on 
> shutdown? I have never seen .dispose() causing a hang, at least not on 
> Windows.
> If it hangs, might this be a result of different threads using the Grahpics 
> object?

Clean 7.0.x build
catalina.bat start
CTRL-C in the Tomcat Window

The result is an exception written to stderr (I assume err rather than
out) and Tomcat fails to stop. The exception is triggered by AWT trying
to register a shutdown hook after the shutdown process has started.

Mark


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



RE: svn commit: r1533035 - /tomcat/tc7.0.x/trunk/webapps/examples/WEB-INF/classes/websocket/drawboard/Room.java

2013-10-17 Thread Konstantin Preißer
Hi Mark,

> -Original Message-
> From: Mark Thomas [mailto:ma...@apache.org]
> Sent: Thursday, October 17, 2013 12:49 PM
> To: Tomcat Developers List
> Subject: Re: svn commit: r1533035 -
> /tomcat/tc7.0.x/trunk/webapps/examples/WEB-
> INF/classes/websocket/drawboard/Room.java
> 
> On 17/10/2013 11:39, Konstantin Kolinko wrote:
> > 2013/10/17  :
> >> Author: markt
> >> Date: Thu Oct 17 10:32:21 2013
> >> New Revision: 1533035
> >>
> >> URL: http://svn.apache.org/r1533035
> >> Log:
> >> Avoid hangs on shutdown
> >>
> >> Modified:
> >> tomcat/tc7.0.x/trunk/webapps/examples/WEB-
> INF/classes/websocket/drawboard/Room.java
> >>
> >
> > I expect this to
> > a) fail when running with a security manager
> > b) cause a memory leak when examples app is reloaded, as you will get
> > a new instance of ShutdownDetection class in webapp's classloader and
> > new instance of shutdown hook.
> 
> I'm open to better suggestions. Another option I considered was just
> removing the call to roomGraphics.dispose(); and letting GC take care of
> things.
> 
> Alternatively, we could provide some form of global flag.
> 
> I think I prefer the global flag that indicates that a shutdown is in
> process. I can think of several other places where such a flag would
> have been useful and we can expose it through a custom servlet context
> attribute such as "org.apache.tomcat.JVM_SHUTDOWN_IN_PROGRESS".
> 
> I'll start looking at the global flag option. Meanwhile, any suggestions
> on how to improve the fix or an alternative fix welcome.

Can you give me some insight of why Grahpics2D.dispose() may cause a hang on 
shutdown? I have never seen .dispose() causing a hang, at least not on Windows.
If it hangs, might this be a result of different threads using the Grahpics 
object?


Regards,
Konstantin Preißer


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



Re: svn commit: r1533035 - /tomcat/tc7.0.x/trunk/webapps/examples/WEB-INF/classes/websocket/drawboard/Room.java

2013-10-17 Thread Mark Thomas
On 17/10/2013 11:39, Konstantin Kolinko wrote:
> 2013/10/17  :
>> Author: markt
>> Date: Thu Oct 17 10:32:21 2013
>> New Revision: 1533035
>>
>> URL: http://svn.apache.org/r1533035
>> Log:
>> Avoid hangs on shutdown
>>
>> Modified:
>> 
>> tomcat/tc7.0.x/trunk/webapps/examples/WEB-INF/classes/websocket/drawboard/Room.java
>>
> 
> I expect this to
> a) fail when running with a security manager
> b) cause a memory leak when examples app is reloaded, as you will get
> a new instance of ShutdownDetection class in webapp's classloader and
> new instance of shutdown hook.

I'm open to better suggestions. Another option I considered was just
removing the call to roomGraphics.dispose(); and letting GC take care of
things.

Alternatively, we could provide some form of global flag.

I think I prefer the global flag that indicates that a shutdown is in
process. I can think of several other places where such a flag would
have been useful and we can expose it through a custom servlet context
attribute such as "org.apache.tomcat.JVM_SHUTDOWN_IN_PROGRESS".

I'll start looking at the global flag option. Meanwhile, any suggestions
on how to improve the fix or an alternative fix welcome.

Mark


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



svn commit: r1533036 - /tomcat/tc7.0.x/trunk/java/org/apache/catalina/core/AprLifecycleListener.java

2013-10-17 Thread markt
Author: markt
Date: Thu Oct 17 10:41:35 2013
New Revision: 1533036

URL: http://svn.apache.org/r1533036
Log:
Require 1.1.29 as a minimum

Modified:
tomcat/tc7.0.x/trunk/java/org/apache/catalina/core/AprLifecycleListener.java

Modified: 
tomcat/tc7.0.x/trunk/java/org/apache/catalina/core/AprLifecycleListener.java
URL: 
http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/java/org/apache/catalina/core/AprLifecycleListener.java?rev=1533036&r1=1533035&r2=1533036&view=diff
==
--- 
tomcat/tc7.0.x/trunk/java/org/apache/catalina/core/AprLifecycleListener.java 
(original)
+++ 
tomcat/tc7.0.x/trunk/java/org/apache/catalina/core/AprLifecycleListener.java 
Thu Oct 17 10:41:35 2013
@@ -60,9 +60,9 @@ public class AprLifecycleListener
 
 protected static final int TCN_REQUIRED_MAJOR = 1;
 protected static final int TCN_REQUIRED_MINOR = 1;
-protected static final int TCN_REQUIRED_PATCH = 28;
+protected static final int TCN_REQUIRED_PATCH = 29;
 protected static final int TCN_RECOMMENDED_MINOR = 1;
-protected static final int TCN_RECOMMENDED_PV = 28;
+protected static final int TCN_RECOMMENDED_PV = 29;
 
 
 // -- Properties



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



Re: svn commit: r1533035 - /tomcat/tc7.0.x/trunk/webapps/examples/WEB-INF/classes/websocket/drawboard/Room.java

2013-10-17 Thread Konstantin Kolinko
2013/10/17  :
> Author: markt
> Date: Thu Oct 17 10:32:21 2013
> New Revision: 1533035
>
> URL: http://svn.apache.org/r1533035
> Log:
> Avoid hangs on shutdown
>
> Modified:
> 
> tomcat/tc7.0.x/trunk/webapps/examples/WEB-INF/classes/websocket/drawboard/Room.java
>

I expect this to
a) fail when running with a security manager
b) cause a memory leak when examples app is reloaded, as you will get
a new instance of ShutdownDetection class in webapp's classloader and
new instance of shutdown hook.


> Modified: 
> tomcat/tc7.0.x/trunk/webapps/examples/WEB-INF/classes/websocket/drawboard/Room.java
> URL: 
> http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/webapps/examples/WEB-INF/classes/websocket/drawboard/Room.java?rev=1533035&r1=1533034&r2=1533035&view=diff
> ==
> --- 
> tomcat/tc7.0.x/trunk/webapps/examples/WEB-INF/classes/websocket/drawboard/Room.java
>  (original)
> +++ 
> tomcat/tc7.0.x/trunk/webapps/examples/WEB-INF/classes/websocket/drawboard/Room.java
>  Thu Oct 17 10:32:21 2013
> @@ -316,7 +316,9 @@ public final class Room {
>  public void run() {
>  closed = true;
>  drawmessageBroadcastTimer.cancel();
> -roomGraphics.dispose();
> +if (!ShutdownDetection.hasShutdownStarted()) {
> +roomGraphics.dispose();
> +}
>  }
>  });
>  }
> @@ -412,4 +414,23 @@ public final class Room {
>  client.sendMessage(new StringWebsocketMessage(completeMsg));
>  }
>  }
> +
> +
> +static {
> +Runtime.getRuntime().addShutdownHook(new ShutdownDetection());
> +}
> +
> +
> +private static class ShutdownDetection extends Thread {
> +private static volatile boolean shutdownStarted = false;
> +
> +private static boolean hasShutdownStarted() {
> +return shutdownStarted;
> +}
> +
> +@Override
> +public void run() {
> +shutdownStarted = true;
> +}
> +}
>  }
>
>
>
> -
> 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: [VOTE] Release Apache Tomcat 7.0.46

2013-10-17 Thread Mark Thomas
On 17/10/2013 11:35, Konstantin Kolinko wrote:
> 2013/10/17 Violeta Georgieva :
>> 2013/10/17 Mark Thomas 
>>>
>>> On 17/10/2013 10:52, Violeta Georgieva wrote:
 Hi Mark,


 2013/10/17 Mark Thomas 
>
> On 16/10/2013 23:47, Konstantin Preißer wrote:
>
>> Hmm, unfortunately it seems the Websocket implementation using the
>> deprecated proprietary API does not work correctly when using the
>> HTTP APR and NIO connector on Windows...
>
> 
>
>> With the BIO connector, everything works fine.
>>
>> The new JSR 356 examples work fine with BIO, NIO and APR connectors.
>>
>> I have done some digging and I found that with r1516410, the old
>> Websocket implementation works fine with NIO and APR, but with
>> r1516411, it does not work anymore.
>
> I think the safest thing to do is to revert that change. I think I see
> see a better solution but I don't want to risk yet more regressions.


 I see this as a cancellation of this vote but I would like to hear your
 opinion also.
>>>
>>> As much as it pains me to say it, I think we need a new tag :(
>>>
>>
>> Ok
>> I can see you already committed the revert.
>> Can I start right now?
>>
> 
> o.a.catalina.core.AprLifecycleListener says
> protected static final int TCN_RECOMMENDED_PV = 28;

29 needs to be required. I'll fix that now.

> Should that be changed to be "29" to match the recently released native 
> 1.1.29?
> 
> For Tomcat 8 I would even change TCN_REQUIRED_PATCH to be 29, as it
> relies on the poller fix that went in 1.1.29.

8.0.x has already had that change made.

Mark


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



Re: [VOTE] Release Apache Tomcat 7.0.46

2013-10-17 Thread Mark Thomas
On 17/10/2013 11:33, Mark Thomas wrote:
> On 17/10/2013 10:55, Violeta Georgieva wrote:
>> 2013/10/17 Mark Thomas 
>>>
>>> On 17/10/2013 10:52, Violeta Georgieva wrote:
 Hi Mark,


 2013/10/17 Mark Thomas 
>
> On 16/10/2013 23:47, Konstantin Preißer wrote:
>
>> Hmm, unfortunately it seems the Websocket implementation using the
>> deprecated proprietary API does not work correctly when using the
>> HTTP APR and NIO connector on Windows...
>
> 
>
>> With the BIO connector, everything works fine.
>>
>> The new JSR 356 examples work fine with BIO, NIO and APR connectors.
>>
>> I have done some digging and I found that with r1516410, the old
>> Websocket implementation works fine with NIO and APR, but with
>> r1516411, it does not work anymore.
>
> I think the safest thing to do is to revert that change. I think I see
> see a better solution but I don't want to risk yet more regressions.


 I see this as a cancellation of this vote but I would like to hear your
 opinion also.
>>>
>>> As much as it pains me to say it, I think we need a new tag :(
>>>
>>
>> Ok
>> I can see you already committed the revert.
>> Can I start right now?
> 
> Hmm. The drawing board WebSocket example is currently broken for me.
> Need to figure out why.

My bad. I was running on Java 6 not 7.

Mark


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



Re: [VOTE] Release Apache Tomcat 7.0.46

2013-10-17 Thread Konstantin Kolinko
2013/10/17 Violeta Georgieva :
> 2013/10/17 Mark Thomas 
>>
>> On 17/10/2013 10:52, Violeta Georgieva wrote:
>> > Hi Mark,
>> >
>> >
>> > 2013/10/17 Mark Thomas 
>> >>
>> >> On 16/10/2013 23:47, Konstantin Preißer wrote:
>> >>
>> >>> Hmm, unfortunately it seems the Websocket implementation using the
>> >>> deprecated proprietary API does not work correctly when using the
>> >>> HTTP APR and NIO connector on Windows...
>> >>
>> >> 
>> >>
>> >>> With the BIO connector, everything works fine.
>> >>>
>> >>> The new JSR 356 examples work fine with BIO, NIO and APR connectors.
>> >>>
>> >>> I have done some digging and I found that with r1516410, the old
>> >>> Websocket implementation works fine with NIO and APR, but with
>> >>> r1516411, it does not work anymore.
>> >>
>> >> I think the safest thing to do is to revert that change. I think I see
>> >> see a better solution but I don't want to risk yet more regressions.
>> >
>> >
>> > I see this as a cancellation of this vote but I would like to hear your
>> > opinion also.
>>
>> As much as it pains me to say it, I think we need a new tag :(
>>
>
> Ok
> I can see you already committed the revert.
> Can I start right now?
>

o.a.catalina.core.AprLifecycleListener says
protected static final int TCN_RECOMMENDED_PV = 28;

Should that be changed to be "29" to match the recently released native 1.1.29?

For Tomcat 8 I would even change TCN_REQUIRED_PATCH to be 29, as it
relies on the poller fix that went in 1.1.29.

Best regards,
Konstantin Kolinko

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



Re: [VOTE] Release Apache Tomcat 7.0.46

2013-10-17 Thread Mark Thomas
On 17/10/2013 10:55, Violeta Georgieva wrote:
> 2013/10/17 Mark Thomas 
>>
>> On 17/10/2013 10:52, Violeta Georgieva wrote:
>>> Hi Mark,
>>>
>>>
>>> 2013/10/17 Mark Thomas 

 On 16/10/2013 23:47, Konstantin Preißer wrote:

> Hmm, unfortunately it seems the Websocket implementation using the
> deprecated proprietary API does not work correctly when using the
> HTTP APR and NIO connector on Windows...

 

> With the BIO connector, everything works fine.
>
> The new JSR 356 examples work fine with BIO, NIO and APR connectors.
>
> I have done some digging and I found that with r1516410, the old
> Websocket implementation works fine with NIO and APR, but with
> r1516411, it does not work anymore.

 I think the safest thing to do is to revert that change. I think I see
 see a better solution but I don't want to risk yet more regressions.
>>>
>>>
>>> I see this as a cancellation of this vote but I would like to hear your
>>> opinion also.
>>
>> As much as it pains me to say it, I think we need a new tag :(
>>
> 
> Ok
> I can see you already committed the revert.
> Can I start right now?

Hmm. The drawing board WebSocket example is currently broken for me.
Need to figure out why.

Mark

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



svn commit: r1533035 - /tomcat/tc7.0.x/trunk/webapps/examples/WEB-INF/classes/websocket/drawboard/Room.java

2013-10-17 Thread markt
Author: markt
Date: Thu Oct 17 10:32:21 2013
New Revision: 1533035

URL: http://svn.apache.org/r1533035
Log:
Avoid hangs on shutdown

Modified:

tomcat/tc7.0.x/trunk/webapps/examples/WEB-INF/classes/websocket/drawboard/Room.java

Modified: 
tomcat/tc7.0.x/trunk/webapps/examples/WEB-INF/classes/websocket/drawboard/Room.java
URL: 
http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/webapps/examples/WEB-INF/classes/websocket/drawboard/Room.java?rev=1533035&r1=1533034&r2=1533035&view=diff
==
--- 
tomcat/tc7.0.x/trunk/webapps/examples/WEB-INF/classes/websocket/drawboard/Room.java
 (original)
+++ 
tomcat/tc7.0.x/trunk/webapps/examples/WEB-INF/classes/websocket/drawboard/Room.java
 Thu Oct 17 10:32:21 2013
@@ -316,7 +316,9 @@ public final class Room {
 public void run() {
 closed = true;
 drawmessageBroadcastTimer.cancel();
-roomGraphics.dispose();
+if (!ShutdownDetection.hasShutdownStarted()) {
+roomGraphics.dispose();
+}
 }
 });
 }
@@ -412,4 +414,23 @@ public final class Room {
 client.sendMessage(new StringWebsocketMessage(completeMsg));
 }
 }
+
+
+static {
+Runtime.getRuntime().addShutdownHook(new ShutdownDetection());
+}
+
+
+private static class ShutdownDetection extends Thread {
+private static volatile boolean shutdownStarted = false;
+
+private static boolean hasShutdownStarted() {
+return shutdownStarted;
+}
+
+@Override
+public void run() {
+shutdownStarted = true;
+}
+}
 }



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



svn commit: r1533034 - /tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml

2013-10-17 Thread kkolinko
Author: kkolinko
Date: Thu Oct 17 10:28:46 2013
New Revision: 1533034

URL: http://svn.apache.org/r1533034
Log:
Changelog for r1533016

Modified:
tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml

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=1533034&r1=1533033&r2=1533034&view=diff
==
--- tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml (original)
+++ tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml Thu Oct 17 10:28:46 2013
@@ -55,7 +55,17 @@
   They eventually become mixed with the numbered issues. (I.e., numbered
   issues to not "pop up" wrt. others).
 -->
-
+
+  
+
+  
+Fix regression with legacy WebSocket implementation in NIO and APR
+connectors. (markt)
+  
+
+  
+
+
   
 
   



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



Re: [VOTE] Release Apache Tomcat 7.0.46

2013-10-17 Thread Violeta Georgieva
2013/10/17 Mark Thomas 
>
> On 17/10/2013 10:52, Violeta Georgieva wrote:
> > Hi Mark,
> >
> >
> > 2013/10/17 Mark Thomas 
> >>
> >> On 16/10/2013 23:47, Konstantin Preißer wrote:
> >>
> >>> Hmm, unfortunately it seems the Websocket implementation using the
> >>> deprecated proprietary API does not work correctly when using the
> >>> HTTP APR and NIO connector on Windows...
> >>
> >> 
> >>
> >>> With the BIO connector, everything works fine.
> >>>
> >>> The new JSR 356 examples work fine with BIO, NIO and APR connectors.
> >>>
> >>> I have done some digging and I found that with r1516410, the old
> >>> Websocket implementation works fine with NIO and APR, but with
> >>> r1516411, it does not work anymore.
> >>
> >> I think the safest thing to do is to revert that change. I think I see
> >> see a better solution but I don't want to risk yet more regressions.
> >
> >
> > I see this as a cancellation of this vote but I would like to hear your
> > opinion also.
>
> As much as it pains me to say it, I think we need a new tag :(
>

Ok
I can see you already committed the revert.
Can I start right now?

Thanks


Re: [VOTE] Release Apache Tomcat 7.0.46

2013-10-17 Thread Mark Thomas
On 17/10/2013 10:52, Violeta Georgieva wrote:
> Hi Mark,
> 
> 
> 2013/10/17 Mark Thomas 
>>
>> On 16/10/2013 23:47, Konstantin Preißer wrote:
>>
>>> Hmm, unfortunately it seems the Websocket implementation using the
>>> deprecated proprietary API does not work correctly when using the
>>> HTTP APR and NIO connector on Windows...
>>
>> 
>>
>>> With the BIO connector, everything works fine.
>>>
>>> The new JSR 356 examples work fine with BIO, NIO and APR connectors.
>>>
>>> I have done some digging and I found that with r1516410, the old
>>> Websocket implementation works fine with NIO and APR, but with
>>> r1516411, it does not work anymore.
>>
>> I think the safest thing to do is to revert that change. I think I see
>> see a better solution but I don't want to risk yet more regressions.
> 
> 
> I see this as a cancellation of this vote but I would like to hear your
> opinion also.

As much as it pains me to say it, I think we need a new tag :(

Mark


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



Re: [VOTE] Release Apache Tomcat 7.0.46

2013-10-17 Thread Violeta Georgieva
Hi Mark,


2013/10/17 Mark Thomas 
>
> On 16/10/2013 23:47, Konstantin Preißer wrote:
>
> > Hmm, unfortunately it seems the Websocket implementation using the
> > deprecated proprietary API does not work correctly when using the
> > HTTP APR and NIO connector on Windows...
>
> 
>
> > With the BIO connector, everything works fine.
> >
> > The new JSR 356 examples work fine with BIO, NIO and APR connectors.
> >
> > I have done some digging and I found that with r1516410, the old
> > Websocket implementation works fine with NIO and APR, but with
> > r1516411, it does not work anymore.
>
> I think the safest thing to do is to revert that change. I think I see
> see a better solution but I don't want to risk yet more regressions.


I see this as a cancellation of this vote but I would like to hear your
opinion also.

Thanks
Vily


svn commit: r1533016 - in /tomcat/tc7.0.x/trunk: ./ java/org/apache/coyote/AbstractProtocol.java

2013-10-17 Thread markt
Author: markt
Date: Thu Oct 17 09:12:02 2013
New Revision: 1533016

URL: http://svn.apache.org/r1533016
Log:
Revert r1516411 which was soem code clean-up that broke the old WebSocket 
implementation for NIO and APR

Modified:
tomcat/tc7.0.x/trunk/   (props changed)
tomcat/tc7.0.x/trunk/java/org/apache/coyote/AbstractProtocol.java

Propchange: tomcat/tc7.0.x/trunk/
--
  Reverse-merged /tomcat/trunk:r1498896

Modified: tomcat/tc7.0.x/trunk/java/org/apache/coyote/AbstractProtocol.java
URL: 
http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/java/org/apache/coyote/AbstractProtocol.java?rev=1533016&r1=1533015&r2=1533016&view=diff
==
--- tomcat/tc7.0.x/trunk/java/org/apache/coyote/AbstractProtocol.java (original)
+++ tomcat/tc7.0.x/trunk/java/org/apache/coyote/AbstractProtocol.java Thu Oct 
17 09:12:02 2013
@@ -664,6 +664,8 @@ public abstract class AbstractProtocol i
 connections.remove(socket);
 release(wrapper, processor, false, false);
 } else if (state == SocketState.UPGRADED) {
+// Need to keep the connection associated with the 
processor
+connections.put(socket, processor);
 // Don't add sockets back to the poller if this was a
 // non-blocking write otherwise the poller may trigger
 // multiple read events which may lead to thread starvation



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



Re: [VOTE] Release Apache Tomcat 7.0.46

2013-10-17 Thread Mark Thomas
On 16/10/2013 23:47, Konstantin Preißer wrote:

> Hmm, unfortunately it seems the Websocket implementation using the
> deprecated proprietary API does not work correctly when using the
> HTTP APR and NIO connector on Windows...



> With the BIO connector, everything works fine.
> 
> The new JSR 356 examples work fine with BIO, NIO and APR connectors.
> 
> I have done some digging and I found that with r1516410, the old
> Websocket implementation works fine with NIO and APR, but with
> r1516411, it does not work anymore.

I think the safest thing to do is to revert that change. I think I see
see a better solution but I don't want to risk yet more regressions.

Mark

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