[Tomcat Wiki] Update of "Example Application Exposing Internals Using JMX" by NevenCvetkovic
Dear Wiki user, You have subscribed to a wiki page or wiki category on "Tomcat Wiki" for change notification. The "Example Application Exposing Internals Using JMX" page has been changed by NevenCvetkovic: https://wiki.apache.org/tomcat/Example%20Application%20Exposing%20Internals%20Using%20JMX?action=diff&rev1=1&rev2=2 - This is a placeholder for a simple web application that exposes internals using JMX. + Here's a simple application that illustrates exposing internals using JMX. + == Description == + Application contains: + * Web deployment descriptor (e.g. WEB-INF/web.xml) that describes the application (optional) + * JSP views: home.jsp and WEB-INF/views/view.jsp + * A counter (e.g. example.jmx.web.MyCounter) that can increment, get current count, reset counter and reset to a specific value. + * A servlet (e.g. example.jmx.web.CounterServlet) that calls counter and forwards to a view (e.g. WEB-INF/views/view.jsp) + * A servlet listener (e.g. example.jmx.web.RegisterMBeansListener), that registers the MBean to JMX MBeanServer + * An MBean interface (e.g. example.jmx.mbean.CounterMBean) that defines JMX attributes and operations, e.g. name, resetCounter, getCurrentCount, getCurrentTime + * An MBean implementation (e.g. example.jmx.mbean.Counter) that implements MBean interface + + == Code Examples == + + === example.jmx.web.MyCounter === + {{{ + package example.jmx.web; + + import java.util.concurrent.atomic.AtomicInteger; + + public class MyCounter { + + private static AtomicInteger counter = new AtomicInteger(0); + + public static int incrementAndGet() { + return counter.incrementAndGet(); + } + + public static int getCurrentCount() { + return counter.get(); + } + + public static void resetCounter() { + resetCounter(0); + } + + public static void resetCounter(int start) { + counter = new AtomicInteger(start); + } + + } + }}} + + === example.jmx.web.CounterServlet servlet === + {{{ + package example.jmx.web; + + import java.io.IOException; + + import javax.servlet.ServletException; + import javax.servlet.annotation.WebServlet; + import javax.servlet.http.HttpServlet; + import javax.servlet.http.HttpServletRequest; + import javax.servlet.http.HttpServletResponse; + + @WebServlet("/count") + public class CounterServlet extends HttpServlet { + + private static final long serialVersionUID = 886395215542306826L; + + @Override + protected void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException { + + request.setAttribute("COUNT", MyCounter.incrementAndGet()); + request.getRequestDispatcher("/WEB-INF/views/view.jsp").forward(request, response); + } + + } + }}} + + === example.jmx.web.RegisterMBeansListener web listener === + {{{ + package example.jmx.web; + + import java.lang.management.ManagementFactory; + + import javax.management.InstanceAlreadyExistsException; + import javax.management.InstanceNotFoundException; + import javax.management.MBeanRegistrationException; + import javax.management.MBeanServer; + import javax.management.MalformedObjectNameException; + import javax.management.NotCompliantMBeanException; + import javax.management.ObjectName; + import javax.servlet.ServletContextEvent; + import javax.servlet.ServletContextListener; + import javax.servlet.annotation.WebListener; + + import example.jmx.mbean.CounterMBean; + import example.jmx.mbean.Counter; + + @WebListener + public class RegisterMBeansListener implements ServletContextListener { + + private ObjectName objectName; + + public RegisterMBeansListener() { + } + + @Override + public void contextInitialized(ServletContextEvent sce) { + System.out.println("Registering MBean..."); + final MBeanServer server = ManagementFactory.getPlatformMBeanServer(); + try { + objectName = new ObjectName("JmxExampleApp:type=Counter"); + final CounterMBean mbean = new Counter(); + server.registerMBean(mbean, objectName); + System.out.println("MBean registered: " + objectName); + } catch (MalformedObjectNameException mone) { + mone.printStackTrace(); + } catch (InstanceAlreadyExistsException iaee) { + iaee.printStackTrace(); + } catch (MBeanRegistrationException mbre) { + mbre.printStackTrace(); + } catch (NotCompliantMBeanException ncmbe) { + ncmbe.printStackTrace(); + } + } + + @Override + public void contextDestroyed(ServletContextEvent sce) { + System.out.println("Unregistering MBean..."); + final MBeanServer server = ManagementFactory.getPlatformMBeanServer(); + try { + objectName = new ObjectName("JmxExampleApp:type=Counter"); + server.unregisterMBean(objectName); + System.out.println("MB
svn commit: r1595775 - in /tomcat/tc6.0.x/trunk: ./ STATUS.txt
Author: markt Date: Mon May 19 08:03:22 2014 New Revision: 1595775 URL: http://svn.apache.org/r1595775 Log: Vote Modified: tomcat/tc6.0.x/trunk/ (props changed) tomcat/tc6.0.x/trunk/STATUS.txt Propchange: tomcat/tc6.0.x/trunk/ -- Merged /tomcat/trunk:r1595171 Merged /tomcat/tc7.0.x/trunk:r1595174 Modified: tomcat/tc6.0.x/trunk/STATUS.txt URL: http://svn.apache.org/viewvc/tomcat/tc6.0.x/trunk/STATUS.txt?rev=1595775&r1=1595774&r2=1595775&view=diff == --- tomcat/tc6.0.x/trunk/STATUS.txt (original) +++ tomcat/tc6.0.x/trunk/STATUS.txt Mon May 19 08:03:22 2014 @@ -38,7 +38,7 @@ PATCHES PROPOSED TO BACKPORT: Additional patch: http://svn.apache.org/viewvc?view=revision&revision=1595366 - +1: kkolinko + +1: kkolinko, markt -1: - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
Re: [VOTE] Release Apache Tomcat 6.0.40
On 18/05/2014 15:19, Rémy Maucherat wrote: > 2014-05-15 16:14 GMT+02:00 Mark Thomas : > >> The proposed 6.0.40 release is: >> [ ] Broken - do not release >> [X] Stable - go ahead and release as 6.0.40 Stable >> > Great job on clearing up all the issues. Thanks. Pity I created a regression (BZ 56529) that means I am going to have to re-roll the release. I'll wait until Konstantin's additional fix has one more vote and that start on a 6.0.41 RC. Mark - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
buildbot failure in ASF Buildbot on tomcat-6-trunk
The Buildbot has detected a new failure on builder tomcat-6-trunk while building ASF Buildbot. Full details are available at: http://ci.apache.org/builders/tomcat-6-trunk/builds/19 Buildbot URL: http://ci.apache.org/ Buildslave for this Build: bb-vm_ubuntu Build Reason: scheduler Build Source Stamp: [branch tomcat/tc6.0.x/trunk] 1595775 Blamelist: fhanik,kkolinko,markt,remm BUILD FAILED: failed sincerely, -The Buildbot - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
svn commit: r1595808 - /tomcat/tc6.0.x/trunk/STATUS.txt
Author: violetagg Date: Mon May 19 09:51:07 2014 New Revision: 1595808 URL: http://svn.apache.org/r1595808 Log: vote Modified: tomcat/tc6.0.x/trunk/STATUS.txt Modified: tomcat/tc6.0.x/trunk/STATUS.txt URL: http://svn.apache.org/viewvc/tomcat/tc6.0.x/trunk/STATUS.txt?rev=1595808&r1=1595807&r2=1595808&view=diff == --- tomcat/tc6.0.x/trunk/STATUS.txt (original) +++ tomcat/tc6.0.x/trunk/STATUS.txt Mon May 19 09:51:07 2014 @@ -38,7 +38,7 @@ PATCHES PROPOSED TO BACKPORT: Additional patch: http://svn.apache.org/viewvc?view=revision&revision=1595366 - +1: kkolinko, markt + +1: kkolinko, markt, violetagg -1: - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
[Bug 56283] Add support for Java 8 to Jasper
https://issues.apache.org/bugzilla/show_bug.cgi?id=56283 Robbie Gibson changed: What|Removed |Added Status|RESOLVED|REOPENED Resolution|FIXED |--- --- Comment #6 from Robbie Gibson --- Verified fixed when replacing ecj-P20140317-1600.jar with ecj-4.4M7.jar from http://www.eclipse.org/downloads/download.php?file=/eclipse/downloads/drops4/S-4.4M7-201405010200/ecj-4.4M7.jar -- 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 56283] Add support for Java 8 to Jasper
https://issues.apache.org/bugzilla/show_bug.cgi?id=56283 Mark Thomas changed: What|Removed |Added Status|REOPENED|RESOLVED Resolution|--- |FIXED --- Comment #7 from Mark Thomas --- (In reply to Robbie Gibson from comment #6) > Verified fixed when replacing ecj-P20140317-1600.jar with ecj-4.4M7.jar from > http://www.eclipse.org/downloads/download.php?file=/eclipse/downloads/drops4/ > S-4.4M7-201405010200/ecj-4.4M7.jar This is a separate issue and should be in a separate bugzilla entry. -- 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
7.0.54 status
Hi guys, found the mail saying 7.0.54 will be tagged then some discussion about fix to include inside then nothing (not sure it is linked to my box, apache mail issue or something else). Can you please give a status on 7.0.54. We (tomee community) are really interested in https://issues.apache.org/bugzilla/show_bug.cgi?id=56425 Romain Manni-Bucau Twitter: @rmannibucau Blog: http://rmannibucau.wordpress.com/ LinkedIn: http://fr.linkedin.com/in/rmannibucau Github: https://github.com/rmannibucau
Re: 7.0.54 status
Hi 2014-05-19 13:09 GMT+03:00 Romain Manni-Bucau : > > Hi guys, > > found the mail saying 7.0.54 will be tagged then some discussion about fix > to include inside then nothing (not sure it is linked to my box, apache > mail issue or something else). > > Can you please give a status on 7.0.54. There is one more bug that needs a fix and I'll prepare a release candidate. Regards Violeta > > We (tomee community) are really interested in > https://issues.apache.org/bugzilla/show_bug.cgi?id=56425 > > > Romain Manni-Bucau > Twitter: @rmannibucau > Blog: http://rmannibucau.wordpress.com/ > LinkedIn: http://fr.linkedin.com/in/rmannibucau > Github: https://github.com/rmannibucau
Re: 7.0.54 status
On 19/05/2014 11:13, Violeta Georgieva wrote: > Hi > > > 2014-05-19 13:09 GMT+03:00 Romain Manni-Bucau : >> >> Hi guys, >> >> found the mail saying 7.0.54 will be tagged then some discussion about fix >> to include inside then nothing (not sure it is linked to my box, apache >> mail issue or something else). >> >> Can you please give a status on 7.0.54. > > There is one more bug that needs a fix and I'll prepare a release candidate. Which one? Mark - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
svn commit: r1595816 - in /tomcat/tc6.0.x/trunk: ./ STATUS.txt java/org/apache/jasper/compiler/Validator.java webapps/docs/changelog.xml
Author: markt Date: Mon May 19 10:18:29 2014 New Revision: 1595816 URL: http://svn.apache.org/r1595816 Log: Fix https://issues.apache.org/bugzilla/show_bug.cgi?id=56529 Fix NoSuchElementException while handling attributes with empty string value in custom tags. Based on a patch provided by Hariprasad Manchi. (violetagg/kkolinko) Modified: tomcat/tc6.0.x/trunk/ (props changed) tomcat/tc6.0.x/trunk/STATUS.txt tomcat/tc6.0.x/trunk/java/org/apache/jasper/compiler/Validator.java tomcat/tc6.0.x/trunk/webapps/docs/changelog.xml Propchange: tomcat/tc6.0.x/trunk/ -- Merged /tomcat/trunk:r1595289 Merged /tomcat/tc7.0.x/trunk:r1595366 Modified: tomcat/tc6.0.x/trunk/STATUS.txt URL: http://svn.apache.org/viewvc/tomcat/tc6.0.x/trunk/STATUS.txt?rev=1595816&r1=1595815&r2=1595816&view=diff == --- tomcat/tc6.0.x/trunk/STATUS.txt (original) +++ tomcat/tc6.0.x/trunk/STATUS.txt Mon May 19 10:18:29 2014 @@ -28,19 +28,6 @@ None PATCHES PROPOSED TO BACKPORT: [ New proposals should be added at the end of the list ] -* Fix https://issues.apache.org/bugzilla/show_bug.cgi?id=56529 - Fix NoSuchElementException while handling attributes with empty string value - in custom tags. Patch provided by Hariprasad Manchi. - http://svn.apache.org/viewvc?view=revision&revision=1595174 - +1: markt, fhanik, remm - +1: kkolinko (additional patch below) - -1: - - Additional patch: - http://svn.apache.org/viewvc?view=revision&revision=1595366 - +1: kkolinko, markt, violetagg - -1: - PATCHES/ISSUES THAT ARE STALLED: Modified: tomcat/tc6.0.x/trunk/java/org/apache/jasper/compiler/Validator.java URL: http://svn.apache.org/viewvc/tomcat/tc6.0.x/trunk/java/org/apache/jasper/compiler/Validator.java?rev=1595816&r1=1595815&r2=1595816&view=diff == --- tomcat/tc6.0.x/trunk/java/org/apache/jasper/compiler/Validator.java (original) +++ tomcat/tc6.0.x/trunk/java/org/apache/jasper/compiler/Validator.java Mon May 19 10:18:29 2014 @@ -1086,11 +1086,16 @@ class Validator { String textAttributeValue; if (!elExpression && el != null) { // Should be a single Text node -textAttributeValue = ((ELNode.Text) el.iterator().next()).getText(); +Iterator it = el.iterator(); +if (it.hasNext()) { +textAttributeValue = ((ELNode.Text) it.next()) +.getText(); +} else { +textAttributeValue = ""; +} } else { textAttributeValue = xmlAttributeValue; } - for (int j = 0; tldAttrs != null && j < tldAttrs.length; j++) { if (attrs.getLocalName(i).equals(tldAttrs[j].getName()) && (attrs.getURI(i) == null Modified: tomcat/tc6.0.x/trunk/webapps/docs/changelog.xml URL: http://svn.apache.org/viewvc/tomcat/tc6.0.x/trunk/webapps/docs/changelog.xml?rev=1595816&r1=1595815&r2=1595816&view=diff == --- tomcat/tc6.0.x/trunk/webapps/docs/changelog.xml (original) +++ tomcat/tc6.0.x/trunk/webapps/docs/changelog.xml Mon May 19 10:18:29 2014 @@ -43,7 +43,18 @@ - + + + + +56529: Avoid NoSuchElementException while handling +attributes with empty string value in custom tags. Based on a patch +provided by Hariprasad Manchi. (violetagg/kkolinko) + + + + + - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
Re: 7.0.54 status
2014-05-19 13:19 GMT+03:00 Mark Thomas : > > On 19/05/2014 11:13, Violeta Georgieva wrote: > > Hi > > > > > > 2014-05-19 13:09 GMT+03:00 Romain Manni-Bucau : > >> > >> Hi guys, > >> > >> found the mail saying 7.0.54 will be tagged then some discussion about fix > >> to include inside then nothing (not sure it is linked to my box, apache > >> mail issue or something else). > >> > >> Can you please give a status on 7.0.54. > > > > There is one more bug that needs a fix and I'll prepare a release candidate. > > Which one? https://issues.apache.org/bugzilla/show_bug.cgi?id=56518 > > Mark > > > - > To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org > For additional commands, e-mail: dev-h...@tomcat.apache.org >
[Bug 56543] New: Jasper fails to compile JSP pages when running with JDK 1.8
https://issues.apache.org/bugzilla/show_bug.cgi?id=56543 Bug ID: 56543 Summary: Jasper fails to compile JSP pages when running with JDK 1.8 Product: Tomcat 7 Version: 7.0.53 Hardware: PC Status: NEW Severity: normal Priority: P2 Component: Jasper Assignee: dev@tomcat.apache.org Reporter: robbie_use...@yahoo.co.uk Created attachment 31636 --> https://issues.apache.org/bugzilla/attachment.cgi?id=31636&action=edit Failing minimal webapp Taking an existing Tomcat/webapp installation and running with JDK 1.8 leads to compile errors with Jasper. It seems due to Eclipse defect 390889 https://bugs.eclipse.org/bugs/show_bug.cgi?id=390889 Attached is a reduced webapp which works fine when run with JDK 1.6 or 1.7 but fails with 1.8. (First reported at https://issues.apache.org/bugzilla/show_bug.cgi?id=56283) -- 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 56543] Jasper fails to compile JSP pages when running with JDK 1.8
https://issues.apache.org/bugzilla/show_bug.cgi?id=56543 Robbie Gibson changed: What|Removed |Added OS||All --- Comment #1 from Robbie Gibson --- Replacing ecj-P20140317-1600.jar with ecj-4.4M7.jar from http://www.eclipse.org/downloads/download.php?file=/eclipse/downloads/drops4/S-4.4M7-201405010200/ecj-4.4M7.jar seems to fix the problem. -- 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 56283] Add support for Java 8 to Jasper
https://issues.apache.org/bugzilla/show_bug.cgi?id=56283 --- Comment #8 from Robbie Gibson --- Done, sorry for the confusion. -- 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 56283] Add support for Java 8 to Jasper
https://issues.apache.org/bugzilla/show_bug.cgi?id=56283 --- Comment #9 from Violeta Georgieva --- for reference bug 56543 -- 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
[VOTE][CANCELLED] Release Apache Tomcat 6.0.40
On 19/05/2014 09:04, Mark Thomas wrote: > On 18/05/2014 15:19, Rémy Maucherat wrote: >> 2014-05-15 16:14 GMT+02:00 Mark Thomas : >> >>> The proposed 6.0.40 release is: >>> [ ] Broken - do not release >>> [X] Stable - go ahead and release as 6.0.40 Stable >>> >> Great job on clearing up all the issues. > > Thanks. Pity I created a regression (BZ 56529) that means I am going to > have to re-roll the release. I'll wait until Konstantin's additional fix > has one more vote and that start on a 6.0.41 RC. The above has been done so I'll start on 6.0.41 shortly. Mark - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
Re: 7.0.54 status
On 19/05/2014 11:25, Violeta Georgieva wrote: > 2014-05-19 13:19 GMT+03:00 Mark Thomas : >> >> On 19/05/2014 11:13, Violeta Georgieva wrote: >>> Hi >>> >>> >>> 2014-05-19 13:09 GMT+03:00 Romain Manni-Bucau : Hi guys, found the mail saying 7.0.54 will be tagged then some discussion about > fix to include inside then nothing (not sure it is linked to my box, apache mail issue or something else). Can you please give a status on 7.0.54. >>> >>> There is one more bug that needs a fix and I'll prepare a release > candidate. >> >> Which one? > > https://issues.apache.org/bugzilla/show_bug.cgi?id=56518 That might take a while. I couldn't see an obvious fix. Given the available work-arounds (use a different connector, disable the connection limit) I'd lean towards tagging what we have now. Mark - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
svn commit: r5380 - /dev/tomcat/tomcat-6/v6.0.40/
Author: markt Date: Mon May 19 10:45:24 2014 New Revision: 5380 Log: Drop 6.0.40 RC to make way for 6.0.41 Removed: dev/tomcat/tomcat-6/v6.0.40/ - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
svn commit: r1595825 - in /tomcat/tc6.0.x/tags/TOMCAT_6_0_41: ./ build.properties.default
Author: markt Date: Mon May 19 10:47:33 2014 New Revision: 1595825 URL: http://svn.apache.org/r1595825 Log: Tag 6.0.41 Added: tomcat/tc6.0.x/tags/TOMCAT_6_0_41/ (props changed) - copied from r1595824, tomcat/tc6.0.x/trunk/ Modified: tomcat/tc6.0.x/tags/TOMCAT_6_0_41/build.properties.default Propchange: tomcat/tc6.0.x/tags/TOMCAT_6_0_41/ -- --- svn:ignore (added) +++ svn:ignore Mon May 19 10:47:33 2014 @@ -0,0 +1,7 @@ +.classpath +.project +.settings +output +build.properties +work +logs Propchange: tomcat/tc6.0.x/tags/TOMCAT_6_0_41/ -- --- svn:mergeinfo (added) +++ svn:mergeinfo Mon May 19 10:47:33 2014 @@ -0,0 +1,2 @@ +/tomcat/tc7.0.x/trunk:1224802,1243045,1298635,1304471,1311997,1312007,1331772,1333164,1333176,1354866,1371298,1371302,1371620,1402110,1413553,1413557,1413563,1430083,1438415,1447013,1484919,1486877,1500065,1503852,1505844,1513151,1521040,1526470,1536524,1539176-1539177,1544469,1544473,1552805,1558894,1558917,1561368,1561382,1561386,1561552,1561561,1561636,1561641,1561643,1561737,1562748,1564317,1568922,1570163,1577328,1577464-1577465,1578814,1586659,1586897,1586960,1588199,1588997,1589740,1589851,1589997,1590019,1590028,1590337,1590492,1590651,1590838,1590845,1590848,1590912,1593262,1593288,1593371,1593835,1594230,1595174,1595366 +/tomcat/trunk:601180,606992,612607,630314,640888,652744,653247,656018,666232,673796,673820,677910,683969,683982,684001,684081,684234,684269-684270,685177,687503,687645,689402,690781,691392,691805,692748,693378,694992,695053,695311,696780,696782,698012,698227,698236,698613,699427,699634,701355,709294,709811,709816,710063,710066,710125,710205,711126,711600,712461,712467,713953,714002,718360,719119,719124,719602,719626,719628,720046,720069,721040,721286,721708,721886,723404,723738,726052,727303,728032,728768,728947,729057,729567,729569,729571,729681,729809,729815,729934,730250,730590,731651,732859,732863,734734,740675,740684,742677,742697,742714,744160,744238,746321,746384,746425,747834,747863,748344,750258,750291,750921,751286-751287,751289,751295,752323,753039,757335,757774,758249,758365,758596,758616,758664,759074,761601,762868,762929,762936-762937,763166,763183,763193,763228,763262,763298,763302,763325,763599,763611,763654,763681,763706,764985,764997,765662,768335,769979,770716,770 809,770876,772872,776921,776924,776935,776945,777464,777466,777576,777625,778379,778523-778524,781528,781779,782145,782791,783316,783696,783724,783756,783762,783766,783863,783934,784453,784602,784614,785381,785688,785768,785859,786468,786487,786490,786496,786667,787627,787770,787985,789389,790405,791041,791184,791194,791224,791243,791326,791328,791789,792740,793372,793757,793882,793981,794082,794673,794822,795043,795152,795210,795457,795466,797168,797425,797596,797607,802727,802940,804462,804544,804734,805153,809131,809603,810916,810977,812125,812137,812432,813001,813013,813866,814180,814708,814876,815972,816252,817442,817822,819339,819361,820110,820132,820874,820954,821397,828196,828201,828210,828225,828759,830378-830379,830999,831106,831774,831785,831828,831850,831860,832214,832218,833121,833545,834047,835036,835336,836405,881396,881412,883130,883134,883146,883165,883177,883362,883565,884341,885038,885231,885241,885260,885901,885991,886019,888072,889363,889606,889716,890139,890265 ,890349-890350,890417,891185-891187,891583,892198,892341,892415,892464,892555,892812,892814,892817,892843,892887,893321,893493,894580,894586,894805,894831,895013,895045,895057,895191,895392,895703,896370,896384,897380-897381,897776,898126,898256,898468,898527,898555,898558,898718,898836,898906,899284,899348,899420,899653,899769-899770,899783,899788,899792,899916,899918-899919,899935,899949,903916,905020,905151,905722,905728,905735,907311,907513,907538,907652,907819,907825,907864,908002,908721,908754,908759,909097,909206,909212,909525,909636,909869,909875,909887,910266,910370,910442,910471,910485,910974,915226,915737,915861,916097,916141,916157,916170,917598,917633,918093,918489,918594,918684,918787,918792,918799,918803,918885,919851,919914,920025,920055,920298,920449,920596,920824,920840,921444,922010,926716,927062,927621,928482,928695,928732,928798,931709,932357,932967,935105,935983,939491,939551,940064,941356,941463,943112,944409,944416,945231,945808,945835,945841,946686,948057,95 0164,950596,950614,950851,950905,951615,953434,954435,955648,955655,956832,957130,957830,958192,960701,961948,962865,962872,962881,962900,963106,963865,963868,964614,966177-966178,966292,966692,966863,981815,988448,991837,993042,1001955,1002185,1002263,1002274,1002349,1002359,1002362,1002481,1002514,1003461,1003481,1003488,1003556,1003572,1003581,1003861,1004393,1004409,1004415,1004868-1004869,1004912,1005452,1005467,1005647,1005802,1022120,1022134,1022323,1022415,1022606,1022623,1024224,1024251,1026042,1026784,1026912,1026920,1029767,1033415,1033448,103
Re: [VOTE][CANCELLED] Release Apache Tomcat 6.0.40
2014-05-19 13:42 GMT+03:00 Mark Thomas : > > On 19/05/2014 09:04, Mark Thomas wrote: > > On 18/05/2014 15:19, Rémy Maucherat wrote: > >> 2014-05-15 16:14 GMT+02:00 Mark Thomas : > >> > >>> The proposed 6.0.40 release is: > >>> [ ] Broken - do not release > >>> [X] Stable - go ahead and release as 6.0.40 Stable > >>> > >> Great job on clearing up all the issues. > > > > Thanks. Pity I created a regression (BZ 56529) that means I am going to > > have to re-roll the release. I'll wait until Konstantin's additional fix > > has one more vote and that start on a 6.0.41 RC. > > The above has been done so I'll start on 6.0.41 shortly. Should we include a fix for jdt also? (bug 56543) the current available version is 4.4RC1 > > Mark > > > - > To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org > For additional commands, e-mail: dev-h...@tomcat.apache.org >
Re: [VOTE][CANCELLED] Release Apache Tomcat 6.0.40
On 19/05/2014 11:48, Violeta Georgieva wrote: > 2014-05-19 13:42 GMT+03:00 Mark Thomas : >> >> On 19/05/2014 09:04, Mark Thomas wrote: >>> On 18/05/2014 15:19, Rémy Maucherat wrote: 2014-05-15 16:14 GMT+02:00 Mark Thomas : > The proposed 6.0.40 release is: > [ ] Broken - do not release > [X] Stable - go ahead and release as 6.0.40 Stable > Great job on clearing up all the issues. >>> >>> Thanks. Pity I created a regression (BZ 56529) that means I am going to >>> have to re-roll the release. I'll wait until Konstantin's additional fix >>> has one more vote and that start on a 6.0.41 RC. >> >> The above has been done so I'll start on 6.0.41 shortly. > > Should we include a fix for jdt also? (bug 56543) the current available > version is 4.4RC1 Nope. 6.0.x doesn't ship with an updated JDT JAR because it doesn't work with Java 5. If 4.4.RC1 works with Java 5 then we can look to update it when it is formally released. I don't think 6.0.x should depend on an RC. Mark - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
Re: 7.0.54 status
Ok, thank you, please keep up updated Romain Manni-Bucau Twitter: @rmannibucau Blog: http://rmannibucau.wordpress.com/ LinkedIn: http://fr.linkedin.com/in/rmannibucau Github: https://github.com/rmannibucau 2014-05-19 12:43 GMT+02:00 Mark Thomas : > On 19/05/2014 11:25, Violeta Georgieva wrote: > > 2014-05-19 13:19 GMT+03:00 Mark Thomas : > >> > >> On 19/05/2014 11:13, Violeta Georgieva wrote: > >>> Hi > >>> > >>> > >>> 2014-05-19 13:09 GMT+03:00 Romain Manni-Bucau : > > Hi guys, > > found the mail saying 7.0.54 will be tagged then some discussion about > > fix > to include inside then nothing (not sure it is linked to my box, > apache > mail issue or something else). > > Can you please give a status on 7.0.54. > >>> > >>> There is one more bug that needs a fix and I'll prepare a release > > candidate. > >> > >> Which one? > > > > https://issues.apache.org/bugzilla/show_bug.cgi?id=56518 > > That might take a while. I couldn't see an obvious fix. > > Given the available work-arounds (use a different connector, disable the > connection limit) I'd lean towards tagging what we have now. > > Mark > > > - > To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org > For additional commands, e-mail: dev-h...@tomcat.apache.org > >
Re: [VOTE][CANCELLED] Release Apache Tomcat 6.0.40
2014-05-19 13:54 GMT+03:00 Mark Thomas : > > On 19/05/2014 11:48, Violeta Georgieva wrote: > > 2014-05-19 13:42 GMT+03:00 Mark Thomas : > >> > >> On 19/05/2014 09:04, Mark Thomas wrote: > >>> On 18/05/2014 15:19, Rémy Maucherat wrote: > 2014-05-15 16:14 GMT+02:00 Mark Thomas : > > > The proposed 6.0.40 release is: > > [ ] Broken - do not release > > [X] Stable - go ahead and release as 6.0.40 Stable > > > Great job on clearing up all the issues. > >>> > >>> Thanks. Pity I created a regression (BZ 56529) that means I am going to > >>> have to re-roll the release. I'll wait until Konstantin's additional fix > >>> has one more vote and that start on a 6.0.41 RC. > >> > >> The above has been done so I'll start on 6.0.41 shortly. > > > > Should we include a fix for jdt also? (bug 56543) the current available > > version is 4.4RC1 > > Nope. 6.0.x doesn't ship with an updated JDT JAR because it doesn't work > with Java 5. > > If 4.4.RC1 works with Java 5 then we can look to update it when it is > formally released. I don't think 6.0.x should depend on an RC. ok thanks > > Mark > > > - > To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org > For additional commands, e-mail: dev-h...@tomcat.apache.org >
Re: [VOTE][CANCELLED] Release Apache Tomcat 6.0.40
On 19/05/2014 12:01, Violeta Georgieva wrote: > 2014-05-19 13:54 GMT+03:00 Mark Thomas : >> >> On 19/05/2014 11:48, Violeta Georgieva wrote: >>> 2014-05-19 13:42 GMT+03:00 Mark Thomas : On 19/05/2014 09:04, Mark Thomas wrote: > On 18/05/2014 15:19, Rémy Maucherat wrote: >> 2014-05-15 16:14 GMT+02:00 Mark Thomas : >> >>> The proposed 6.0.40 release is: >>> [ ] Broken - do not release >>> [X] Stable - go ahead and release as 6.0.40 Stable >>> >> Great job on clearing up all the issues. > > Thanks. Pity I created a regression (BZ 56529) that means I am going > to > have to re-roll the release. I'll wait until Konstantin's additional > fix > has one more vote and that start on a 6.0.41 RC. The above has been done so I'll start on 6.0.41 shortly. >>> >>> Should we include a fix for jdt also? (bug 56543) the current available >>> version is 4.4RC1 >> >> Nope. 6.0.x doesn't ship with an updated JDT JAR because it doesn't work >> with Java 5. >> >> If 4.4.RC1 works with Java 5 then we can look to update it when it is >> formally released. I don't think 6.0.x should depend on an RC. > > ok thanks For the record, 4.4.RC1 requires Java 6 so it looks like Tomcat 6 is going to be stuck on 4.3.1 to maintain Java 5 compatibility. Users are, of course, able to upgrade to a later version of ECJ if they wish. Mark - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
[Bug 56543] Jasper fails to compile JSP pages when running with JDK 1.8
https://issues.apache.org/bugzilla/show_bug.cgi?id=56543 --- Comment #2 from Violeta Georgieva --- ECJ 4.4RC1 is available. Should we wait for the official release? (which will happen end of June with Luna release) -- 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 56543] Jasper fails to compile JSP pages when running with JDK 1.8
https://issues.apache.org/bugzilla/show_bug.cgi?id=56543 --- Comment #3 from Mark Thomas --- I'd be concerned about regressions using an ECJ RC in a stable Tomcat version. Upgrading ECJ is as simple as replacing the JAR so users impacted by this bug have a simple fix available. -- 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.54
Hi, 2014-04-28 10:39 GMT+03:00 Violeta Georgieva : > > Hi, > > I would like to start preparing 7.0.54 for voting this afternoon. I'll start in a few hours. > If you want to add something to this release please reply here. > > Regards > Violeta
Re: [VOTE] Release Apache Tomcat 8.0.8
On 16/05/2014 21:55, Mark Thomas wrote: > The proposed Apache Tomcat 8.0.8 release is now available for voting. > > The main changes since 8.0.6 are: > - Fix BZ 56529 a regression in the fix for BZ 56481 > - Fix regression that broke Tomcat's copy of DBCP > - Small number of additional fixes > > The main changes since 8.0.5 are: > - Further NIO2 fixes which is now considered BETA > - Extend and improve memory leak protection and fix a few leaks that > crept in during the various refactorings > - Lots of general bug fixes > > > It can be obtained from: > https://dist.apache.org/repos/dist/dev/tomcat/tomcat-8/v8.0.8/ > The Maven staging repo is: > https://repository.apache.org/content/repositories/orgapachetomcat-1013/ > The svn tag is: > http://svn.apache.org/repos/asf/tomcat/tc8.0.x/tags/TOMCAT_8_0_8/ > > The proposed 8.0.8 release is: > [ ] Broken - do not release > [ ] Alpha - go ahead and release as 8.0.8 (alpha) > [ ] Beta - go ahead and release as 8.0.8 (beta) > [X] Stable - go ahead and release as 8.0.8 (stable) Unit tests all pass for BIO, NIO and APR/native on Linux, OSX and Windows with 64-bit Java. I've come the conclusion the the cookie work - if done carefully - can be done without destabilising 8.0.x therefore I am voting stable. 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 8.0.8
2014-05-19 14:51 GMT+02:00 Mark Thomas : > Unit tests all pass for BIO, NIO and APR/native on Linux, OSX and > Windows with 64-bit Java. > NIO2 included ? > > I've come the conclusion the the cookie work - if done carefully - can > be done without destabilising 8.0.x therefore I am voting stable. > > That would be a first ;) Maybe with the zillion weird unit tests that were added it is now possible, if you are willing to ignore the deluge of bug reports about formerly working cookies. Rémy
[VOTE] Release Apache Tomcat 6.0.41
The proposed Apache Tomcat 6.0.41 release candidate is now available for voting. The main changes since 6.0.40 are: - Fix BZ 56529 The main changes since 6.0.39 are: - Add support for using ecj-P20140317-1600.jar to use Java 8 syntax in JSPs - Update native library to 1.1.30 - Various improvements to XML processing along with a number of bug fixes. Full details are in the change log. It can be obtained from: https://dist.apache.org/repos/dist/dev/tomcat/tomcat-6/v6.0.41/ The Maven staging repo is: https://repository.apache.org/content/repositories/orgapachetomcat-1014/ The svn tag is: http://svn.apache.org/repos/asf/tomcat/tc6.0.x/tags/TOMCAT_6_0_41 The proposed 6.0.41 release is: [ ] Broken - do not release [ ] Stable - go ahead and release as 6.0.41 Stable Cheers, 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 8.0.8
On 19/05/2014 13:58, Rémy Maucherat wrote: > 2014-05-19 14:51 GMT+02:00 Mark Thomas : > >> Unit tests all pass for BIO, NIO and APR/native on Linux, OSX and >> Windows with 64-bit Java. > > > NIO2 included ? No. That still triggers failures for me. >> I've come the conclusion the the cookie work - if done carefully - can >> be done without destabilising 8.0.x therefore I am voting stable. >> > That would be a first ;) Maybe with the zillion weird unit tests that were > added it is now possible, if you are willing to ignore the deluge of bug > reports about formerly working cookies. My thinking is that we should be able to support the current approach and RFC6265 (and possibly other options if they make sense). As long as we don't change the default we should be OK. If/when we do change the default it should be a single config option to switch back. At least that is the plan... Mark - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
[Bug 56456] Suggesting lock-free endpoint state machine
https://issues.apache.org/bugzilla/show_bug.cgi?id=56456 Mark Thomas changed: What|Removed |Added Status|NEW |RESOLVED Resolution|--- |WONTFIX --- Comment #4 from Mark Thomas --- No sign of a test case. Feel free to re-open this if you have a test case that demonstrates that there is a performance problem here that needs solving. -- 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: r1595887 - in /tomcat/trunk: java/org/apache/catalina/connector/CoyoteAdapter.java java/org/apache/catalina/connector/LocalStrings.properties webapps/docs/changelog.xml
Author: kkolinko Date: Mon May 19 13:11:28 2014 New Revision: 1595887 URL: http://svn.apache.org/r1595887 Log: Fix https://issues.apache.org/bugzilla/show_bug.cgi?id=56399 Improve implementation of CoyoteAdapter.checkRecycled() to do not use an exception for flow control. Modified: tomcat/trunk/java/org/apache/catalina/connector/CoyoteAdapter.java tomcat/trunk/java/org/apache/catalina/connector/LocalStrings.properties tomcat/trunk/webapps/docs/changelog.xml Modified: tomcat/trunk/java/org/apache/catalina/connector/CoyoteAdapter.java URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/catalina/connector/CoyoteAdapter.java?rev=1595887&r1=1595886&r2=1595887&view=diff == --- tomcat/trunk/java/org/apache/catalina/connector/CoyoteAdapter.java (original) +++ tomcat/trunk/java/org/apache/catalina/connector/CoyoteAdapter.java Mon May 19 13:11:28 2014 @@ -664,26 +664,31 @@ public class CoyoteAdapter implements Ad org.apache.coyote.Response res) { Request request = (Request) req.getNote(ADAPTER_NOTES); Response response = (Response) res.getNote(ADAPTER_NOTES); -try { -if (request != null && request.getHost() != null) { -throw new RecycleRequiredException(); -} -if (response != null && response.getContentWritten() != 0) { -throw new RecycleRequiredException(); -} -} catch (RecycleRequiredException e) { -String message = sm.getString("coyoteAdapter.checkRecycled"); +String messageKey = null; +if (request != null && request.getHost() != null) { +messageKey = "coyoteAdapter.checkRecycled.request"; +} else if (response != null && response.getContentWritten() != 0) { +messageKey = "coyoteAdapter.checkRecycled.response"; +} +if (messageKey != null) { +// Log this request, as it has probably skipped the access log. +// The log() method will take care of recycling. +log(req, res, 0L); + if (connector.getState().isAvailable()) { -log.info(message, e); +if (log.isInfoEnabled()) { +log.info(sm.getString(messageKey), +new RecycleRequiredException()); +} } else { // There may be some aborted requests. // When connector shuts down, the request and response will not // be reused, so there is no issue to warn about here. -log.debug(message, e); +if (log.isDebugEnabled()) { +log.debug(sm.getString(messageKey), +new RecycleRequiredException()); +} } -// Log this request, as it has probably skipped the access log. -// The log() method will take care of recycling. -log(req, res, 0L); } } Modified: tomcat/trunk/java/org/apache/catalina/connector/LocalStrings.properties URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/catalina/connector/LocalStrings.properties?rev=1595887&r1=1595886&r2=1595887&view=diff == --- tomcat/trunk/java/org/apache/catalina/connector/LocalStrings.properties (original) +++ tomcat/trunk/java/org/apache/catalina/connector/LocalStrings.properties Mon May 19 13:11:28 2014 @@ -17,7 +17,8 @@ cometEvent.nullRequest=The event object coyoteAdapter.accesslogFail=Exception while attempting to add an entry to the access log coyoteAdapter.asyncDispatch=Exception while processing an asynchronous request -coyoteAdapter.checkRecycled=A non-recycled request encountered. It will be recycled forcedly. +coyoteAdapter.checkRecycled.request=Encountered a non-recycled request and recycled it forcedly. +coyoteAdapter.checkRecycled.response=Encountered a non-recycled response and recycled it forcedly. coyoteAdapter.debug=The variable [{0}] has value [{1}] coyoteAdapter.parsePathParam=Unable to parse the path parameters using encoding [{0}]. The path parameters in the URL will be ignored. Modified: tomcat/trunk/webapps/docs/changelog.xml URL: http://svn.apache.org/viewvc/tomcat/trunk/webapps/docs/changelog.xml?rev=1595887&r1=1595886&r2=1595887&view=diff == --- tomcat/trunk/webapps/docs/changelog.xml (original) +++ tomcat/trunk/webapps/docs/changelog.xml Mon May 19 13:11:28 2014 @@ -47,16 +47,20 @@ - -56526: Improved the StuckThreadDetectionValve to -optionally interrupt stuck threads to attempt to unblock them. -(slaurent) - + +56399: Improve implementation of CoyoteAdapter.checkRecycled() +to do not use an exception for f
svn commit: r1595893 - in /tomcat/trunk/java/org/apache/catalina: core/ApplicationFilterChain.java deploy/NamingResourcesImpl.java
Author: markt Date: Mon May 19 13:24:00 2014 New Revision: 1595893 URL: http://svn.apache.org/r1595893 Log: Code clean-up. No functional change. Merge exception handling blocks were code is identical. Spotted while reviewing use of ExceptionUtils.unwrapInvocationTargetException() Modified: tomcat/trunk/java/org/apache/catalina/core/ApplicationFilterChain.java tomcat/trunk/java/org/apache/catalina/deploy/NamingResourcesImpl.java Modified: tomcat/trunk/java/org/apache/catalina/core/ApplicationFilterChain.java URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/catalina/core/ApplicationFilterChain.java?rev=1595893&r1=1595892&r2=1595893&view=diff == --- tomcat/trunk/java/org/apache/catalina/core/ApplicationFilterChain.java (original) +++ tomcat/trunk/java/org/apache/catalina/core/ApplicationFilterChain.java Mon May 19 13:24:00 2014 @@ -241,17 +241,7 @@ final class ApplicationFilterChain imple support.fireInstanceEvent(InstanceEvent.AFTER_FILTER_EVENT, filter, request, response); -} catch (IOException e) { -if (filter != null) -support.fireInstanceEvent(InstanceEvent.AFTER_FILTER_EVENT, - filter, request, response, e); -throw e; -} catch (ServletException e) { -if (filter != null) -support.fireInstanceEvent(InstanceEvent.AFTER_FILTER_EVENT, - filter, request, response, e); -throw e; -} catch (RuntimeException e) { +} catch (IOException | ServletException | RuntimeException e) { if (filter != null) support.fireInstanceEvent(InstanceEvent.AFTER_FILTER_EVENT, filter, request, response, e); Modified: tomcat/trunk/java/org/apache/catalina/deploy/NamingResourcesImpl.java URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/catalina/deploy/NamingResourcesImpl.java?rev=1595893&r1=1595892&r2=1595893&view=diff == --- tomcat/trunk/java/org/apache/catalina/deploy/NamingResourcesImpl.java (original) +++ tomcat/trunk/java/org/apache/catalina/deploy/NamingResourcesImpl.java Mon May 19 13:24:00 2014 @@ -1043,10 +1043,7 @@ public class NamingResourcesImpl extends if (m != null) { try { m.invoke(resource, (Object[]) null); -} catch (IllegalArgumentException e) { -log.warn(sm.getString("namingResources.cleanupCloseFailed", -closeMethod, name, container), e); -} catch (IllegalAccessException e) { +} catch (IllegalArgumentException | IllegalAccessException e) { log.warn(sm.getString("namingResources.cleanupCloseFailed", closeMethod, name, container), e); } catch (InvocationTargetException e) { - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
[Bug 56446] Handling InvocationTargetException for PojoMessageHandlerWholeBase and PojoMessageHandlerPartialBase.onMessage()
https://issues.apache.org/bugzilla/show_bug.cgi?id=56446 Mark Thomas changed: What|Removed |Added Status|NEW |RESOLVED Resolution|--- |FIXED --- Comment #1 from Mark Thomas --- Thanks for the report. I have applied a variation of this to 8.0.x for 8.0.9 onwards. -- You are receiving this mail because: You are the assignee for the bug. - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
svn commit: r1595898 - in /tomcat/trunk: java/org/apache/tomcat/websocket/pojo/ webapps/docs/
Author: markt Date: Mon May 19 13:33:09 2014 New Revision: 1595898 URL: http://svn.apache.org/r1595898 Log: Fix https://issues.apache.org/bugzilla/show_bug.cgi?id=56446 Clearer handling of exceptions when calling a method on a POJO based WebSocket endpoint. Based on a suggestion by Eugene Chung. Modified: tomcat/trunk/java/org/apache/tomcat/websocket/pojo/PojoMessageHandlerBase.java tomcat/trunk/java/org/apache/tomcat/websocket/pojo/PojoMessageHandlerPartialBase.java tomcat/trunk/java/org/apache/tomcat/websocket/pojo/PojoMessageHandlerWholeBase.java tomcat/trunk/webapps/docs/changelog.xml Modified: tomcat/trunk/java/org/apache/tomcat/websocket/pojo/PojoMessageHandlerBase.java URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/tomcat/websocket/pojo/PojoMessageHandlerBase.java?rev=1595898&r1=1595897&r2=1595898&view=diff == --- tomcat/trunk/java/org/apache/tomcat/websocket/pojo/PojoMessageHandlerBase.java (original) +++ tomcat/trunk/java/org/apache/tomcat/websocket/pojo/PojoMessageHandlerBase.java Mon May 19 13:33:09 2014 @@ -25,6 +25,7 @@ import javax.websocket.MessageHandler; import javax.websocket.RemoteEndpoint; import javax.websocket.Session; +import org.apache.tomcat.util.ExceptionUtils; import org.apache.tomcat.websocket.WrappedMessageHandler; /** @@ -107,4 +108,15 @@ public abstract class PojoMessageHandler public final long getMaxMessageSize() { return maxMessageSize; } + + +protected final void handlePojoMethodException(Throwable t) { +t = ExceptionUtils.unwrapInvocationTargetException(t); +ExceptionUtils.handleThrowable(t); +if (t instanceof RuntimeException) { +throw (RuntimeException) t; +} else { +throw new RuntimeException(t); +} +} } Modified: tomcat/trunk/java/org/apache/tomcat/websocket/pojo/PojoMessageHandlerPartialBase.java URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/tomcat/websocket/pojo/PojoMessageHandlerPartialBase.java?rev=1595898&r1=1595897&r2=1595898&view=diff == --- tomcat/trunk/java/org/apache/tomcat/websocket/pojo/PojoMessageHandlerPartialBase.java (original) +++ tomcat/trunk/java/org/apache/tomcat/websocket/pojo/PojoMessageHandlerPartialBase.java Mon May 19 13:33:09 2014 @@ -66,11 +66,11 @@ public abstract class PojoMessageHandler } else { parameters[indexPayload] = message; } -Object result; +Object result = null; try { result = method.invoke(pojo, parameters); } catch (IllegalAccessException | InvocationTargetException e) { -throw new IllegalArgumentException(e); +handlePojoMethodException(e); } processResult(result); } Modified: tomcat/trunk/java/org/apache/tomcat/websocket/pojo/PojoMessageHandlerWholeBase.java URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/tomcat/websocket/pojo/PojoMessageHandlerWholeBase.java?rev=1595898&r1=1595897&r2=1595898&view=diff == --- tomcat/trunk/java/org/apache/tomcat/websocket/pojo/PojoMessageHandlerWholeBase.java (original) +++ tomcat/trunk/java/org/apache/tomcat/websocket/pojo/PojoMessageHandlerWholeBase.java Mon May 19 13:33:09 2014 @@ -75,11 +75,11 @@ public abstract class PojoMessageHandler } parameters[indexPayload] = payload; -Object result; +Object result = null; try { result = method.invoke(pojo, parameters); } catch (IllegalAccessException | InvocationTargetException e) { -throw new IllegalArgumentException(e); +handlePojoMethodException(e); } processResult(result); } Modified: tomcat/trunk/webapps/docs/changelog.xml URL: http://svn.apache.org/viewvc/tomcat/trunk/webapps/docs/changelog.xml?rev=1595898&r1=1595897&r2=1595898&view=diff == --- tomcat/trunk/webapps/docs/changelog.xml (original) +++ tomcat/trunk/webapps/docs/changelog.xml Mon May 19 13:33:09 2014 @@ -63,6 +63,15 @@ + + + +56446: Clearer handling of exceptions when calling a method +on a POJO based WebSocket endpoint. Based on a suggestion by Eugene +Chung. (markt) + + + - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
svn commit: r1595900 - in /tomcat/tc7.0.x/trunk: ./ java/org/apache/catalina/connector/ java/org/apache/coyote/ java/org/apache/coyote/ajp/ java/org/apache/coyote/http11/ webapps/docs/
Author: kkolinko Date: Mon May 19 13:37:45 2014 New Revision: 1595900 URL: http://svn.apache.org/r1595900 Log: Fix https://issues.apache.org/bugzilla/show_bug.cgi?id=56399 When recycling a Coyote request, ensure that Catalina request have been recycled. Merged r1594436 r1594924 r1595887 from tomcat/trunk. Modified: tomcat/tc7.0.x/trunk/ (props changed) tomcat/tc7.0.x/trunk/java/org/apache/catalina/connector/CoyoteAdapter.java tomcat/tc7.0.x/trunk/java/org/apache/catalina/connector/LocalStrings.properties tomcat/tc7.0.x/trunk/java/org/apache/coyote/Adapter.java tomcat/tc7.0.x/trunk/java/org/apache/coyote/ajp/AbstractAjpProcessor.java tomcat/tc7.0.x/trunk/java/org/apache/coyote/http11/AbstractHttp11Processor.java tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml Propchange: tomcat/tc7.0.x/trunk/ -- Merged /tomcat/trunk:r1594436,1594924,1595887 Modified: tomcat/tc7.0.x/trunk/java/org/apache/catalina/connector/CoyoteAdapter.java URL: http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/java/org/apache/catalina/connector/CoyoteAdapter.java?rev=1595900&r1=1595899&r2=1595900&view=diff == --- tomcat/tc7.0.x/trunk/java/org/apache/catalina/connector/CoyoteAdapter.java (original) +++ tomcat/tc7.0.x/trunk/java/org/apache/catalina/connector/CoyoteAdapter.java Mon May 19 13:37:45 2014 @@ -524,6 +524,44 @@ public class CoyoteAdapter implements Ad } +private static class RecycleRequiredException extends Exception { +private static final long serialVersionUID = 1L; +} + +@Override +public void checkRecycled(org.apache.coyote.Request req, +org.apache.coyote.Response res) { +Request request = (Request) req.getNote(ADAPTER_NOTES); +Response response = (Response) res.getNote(ADAPTER_NOTES); +String messageKey = null; +if (request != null && request.getHost() != null) { +messageKey = "coyoteAdapter.checkRecycled.request"; +} else if (response != null && response.getContentWritten() != 0) { +messageKey = "coyoteAdapter.checkRecycled.response"; +} +if (messageKey != null) { +// Log this request, as it has probably skipped the access log. +// The log() method will take care of recycling. +log(req, res, 0L); + +if (connector.getState().isAvailable()) { +if (log.isInfoEnabled()) { +log.info(sm.getString(messageKey), +new RecycleRequiredException()); +} +} else { +// There may be some aborted requests. +// When connector shuts down, the request and response will not +// be reused, so there is no issue to warn about here. +if (log.isDebugEnabled()) { +log.debug(sm.getString(messageKey), +new RecycleRequiredException()); +} +} +} +} + + @Override public String getDomain() { return connector.getDomain(); Modified: tomcat/tc7.0.x/trunk/java/org/apache/catalina/connector/LocalStrings.properties URL: http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/java/org/apache/catalina/connector/LocalStrings.properties?rev=1595900&r1=1595899&r2=1595900&view=diff == --- tomcat/tc7.0.x/trunk/java/org/apache/catalina/connector/LocalStrings.properties (original) +++ tomcat/tc7.0.x/trunk/java/org/apache/catalina/connector/LocalStrings.properties Mon May 19 13:37:45 2014 @@ -36,6 +36,8 @@ coyoteConnector.parseBodyMethodNoTrace=T # coyoteAdapter.read=The servlet did not read all available bytes during the processing of the read event coyoteAdapter.parsePathParam=Unable to parse the path parameters using encoding [{0}]. The path parameters in the URL will be ignored. +coyoteAdapter.checkRecycled.request=Encountered a non-recycled request and recycled it forcedly. +coyoteAdapter.checkRecycled.response=Encountered a non-recycled response and recycled it forcedly. coyoteAdapter.debug=The variable [{0}] has value [{1}] coyoteAdapter.accesslogFail=Exception while attempting to add an entry to the access log Modified: tomcat/tc7.0.x/trunk/java/org/apache/coyote/Adapter.java URL: http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/java/org/apache/coyote/Adapter.java?rev=1595900&r1=1595899&r2=1595900&view=diff == --- tomcat/tc7.0.x/trunk/java/org/apache/coyote/Adapter.java (original) +++ tomcat/tc7.0.x/trunk/java/org/apache/coyote/Adapter.java Mon May 19 13:37:45 2014 @@ -56,6 +56,19 @@ public interface Adapter { public void log(Request req, Response res, long time); /**
[Bug 56399] Re-factor request/response recycling so Coyote and Catalina objects are recycled simultaneously
https://issues.apache.org/bugzilla/show_bug.cgi?id=56399 --- Comment #7 from Konstantin Kolinko --- Improvements from the above comments were committed to trunk in r1595887 and will be in 8.0.9. Backported to Tomcat 7 in r1595900 to be in 7.0.54. -- You are receiving this mail because: You are the assignee for the bug. - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
Re: [VOTE] Release Apache Tomcat 8.0.8
On 2014-05-16, 4:55 PM, Mark Thomas wrote: The proposed 8.0.8 release is: [ ] Broken - do not release [ ] Alpha - go ahead and release as 8.0.8 (alpha) [ ] Beta - go ahead and release as 8.0.8 (beta) [X] Stable - go ahead and release as 8.0.8 (stable) Tested WebSocket and AsyncContext, NIO and NIO2. -- Jeanfrancois - 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
[jira] [Created] (MTOMCAT-269) Context file of additional web apps is ignored
Stefan Kopf created MTOMCAT-269: --- Summary: Context file of additional web apps is ignored Key: MTOMCAT-269 URL: https://issues.apache.org/jira/browse/MTOMCAT-269 Project: Apache Tomcat Maven Plugin Issue Type: Bug Components: tomcat6, tomcat7 Affects Versions: 2.2 Reporter: Stefan Kopf Assignee: Olivier Lamy (*$^¨%`£) While the default context file (/META-INF/context.xml) is respected for the project itself, it is ignored for the additional web apps. In org/apache/tomcat/maven/plugin/tomcat7/run/AbstractRunMojo.java line 1425: for ( AbstractWebapp additionalWebapp : getAdditionalWebapps() ) { String contextPath = additionalWebapp.getContextPath(); if ( !contextPath.startsWith( "/" ) ) { contextPath = "/" + contextPath; } addContextFromArtifact( container, contexts, getArtifact( additionalWebapp ), contextPath, additionalWebapp.getContextFile(), additionalWebapp.isAsWebapp() ); } Proposed fix: for ( AbstractWebapp additionalWebapp : getAdditionalWebapps() ) { String contextPath = additionalWebapp.getContextPath(); if ( !contextPath.startsWith( "/" ) ) { contextPath = "/" + contextPath; } String contextFile = null; if(additionalWebapp.getContextFile() != null) { contextFile = additionalWebapp.getContextFile(); } else { File defaultConfigFile = new File( configurationDir, "webapps/"+artifact.getArtifactId()+"/META-INF/context.xml" ); if(defaultConfigFile.exists()) { contextFile = defaultConfigFile.getAbsolutePath(); } } addContextFromArtifact( container, contexts, getArtifact( additionalWebapp ), contextPath, contextFile, additionalWebapp.isAsWebapp() ); } These might be a similar problem with tomcat6-maven-plugin -- This message was sent by Atlassian JIRA (v6.2#6252) - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
[jira] [Updated] (MTOMCAT-269) Context file of additional web apps is ignored
[ https://issues.apache.org/jira/browse/MTOMCAT-269?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Stefan Kopf updated MTOMCAT-269: Description: While the default context file (/META-INF/context.xml) is respected for the project itself, it is ignored for the additional web apps. {code:title=org/apache/tomcat/maven/plugin/tomcat7/run/AbstractRunMojo.java line 1425|borderStyle=solid} for ( AbstractWebapp additionalWebapp : getAdditionalWebapps() ) { String contextPath = additionalWebapp.getContextPath(); if ( !contextPath.startsWith( "/" ) ) { contextPath = "/" + contextPath; } addContextFromArtifact( container, contexts, getArtifact( additionalWebapp ), contextPath, additionalWebapp.getContextFile(), additionalWebapp.isAsWebapp() ); } {code} Proposed fix: {code:title=org/apache/tomcat/maven/plugin/tomcat7/run/AbstractRunMojo.java Proposed fix|borderStyle=solid} for ( AbstractWebapp additionalWebapp : getAdditionalWebapps() ) { String contextPath = additionalWebapp.getContextPath(); if ( !contextPath.startsWith( "/" ) ) { contextPath = "/" + contextPath; } String contextFile = null; if(additionalWebapp.getContextFile() != null) { contextFile = additionalWebapp.getContextFile(); } else { File defaultConfigFile = new File( configurationDir, "webapps/"+artifact.getArtifactId()+"/META-INF/context.xml" ); if(defaultConfigFile.exists()) { contextFile = defaultConfigFile.getAbsolutePath(); } } addContextFromArtifact( container, contexts, getArtifact( additionalWebapp ), contextPath, contextFile, additionalWebapp.isAsWebapp() ); } {code} These might be a similar problem with tomcat6-maven-plugin was: While the default context file (/META-INF/context.xml) is respected for the project itself, it is ignored for the additional web apps. {code:title=org/apache/tomcat/maven/plugin/tomcat7/run/AbstractRunMojo.java line 1425|borderStyle=solid} for ( AbstractWebapp additionalWebapp : getAdditionalWebapps() ) { String contextPath = additionalWebapp.getContextPath(); if ( !contextPath.startsWith( "/" ) ) { contextPath = "/" + contextPath; } addContextFromArtifact( container, contexts, getArtifact( additionalWebapp ), contextPath, additionalWebapp.getContextFile(), additionalWebapp.isAsWebapp() ); } {code} Proposed fix: for ( AbstractWebapp additionalWebapp : getAdditionalWebapps() ) { String contextPath = additionalWebapp.getContextPath(); if ( !contextPath.startsWith( "/" ) ) { contextPath = "/" + contextPath; } String contextFile = null; if(additionalWebapp.getContextFile() != null) { contextFile = additionalWebapp.getContextFile(); } else { File defaultConfigFile = new File( configurationDir, "webapps/"+artifact.getArtifactId()+"/META-INF/context.xml" ); if(defaultConfigFile.exists()) { contextFile = defaultConfigFile.getAbsolutePath(); } } addContextFromArtifact( container, contexts, getArtifact( additionalWebapp ), contextPath, contextFile, additionalWebapp.isAsWebapp() ); } These might be a similar problem with tomcat6-maven-plugin > Context file of additional web apps is ignored > -- > > Key: MTOMCAT-269 > URL: https://issues.apache.org/jira/browse/MTOMCAT-269 > Project: Apache Tomcat Maven Plugin > Issue Type: Bug > Components: tomcat6, tomcat7 >Affects Versions: 2.2 >Reporter: Stefan Kopf >Assignee: Olivier Lamy (*$^¨%`£) > > While the default context file (/META-INF/context.xml) is respected for the > project itself, it is ignored for the additional web apps. > {code:title=org/apache/tomcat/maven/plugin/tomcat7/run/AbstractRunMojo.java > line 1425|borderStyle=solid} > for ( AbstractWebapp additionalWebapp : getAdditionalWebapps() ) > { > String contextPath = additionalWebapp.getContextPath(); > if ( !contextPath.startsWith( "/" ) ) > { > contextPath = "/" + contextPath; > } > addContextFromArtifact( contai
[jira] [Updated] (MTOMCAT-269) Context file of additional web apps is ignored
[ https://issues.apache.org/jira/browse/MTOMCAT-269?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Stefan Kopf updated MTOMCAT-269: Description: While the default context file (/META-INF/context.xml) is respected for the project itself, it is ignored for the additional web apps. {code:title=org/apache/tomcat/maven/plugin/tomcat7/run/AbstractRunMojo.java line 1425|borderStyle=solid} for ( AbstractWebapp additionalWebapp : getAdditionalWebapps() ) { String contextPath = additionalWebapp.getContextPath(); if ( !contextPath.startsWith( "/" ) ) { contextPath = "/" + contextPath; } addContextFromArtifact( container, contexts, getArtifact( additionalWebapp ), contextPath, additionalWebapp.getContextFile(), additionalWebapp.isAsWebapp() ); } {code} Proposed fix: for ( AbstractWebapp additionalWebapp : getAdditionalWebapps() ) { String contextPath = additionalWebapp.getContextPath(); if ( !contextPath.startsWith( "/" ) ) { contextPath = "/" + contextPath; } String contextFile = null; if(additionalWebapp.getContextFile() != null) { contextFile = additionalWebapp.getContextFile(); } else { File defaultConfigFile = new File( configurationDir, "webapps/"+artifact.getArtifactId()+"/META-INF/context.xml" ); if(defaultConfigFile.exists()) { contextFile = defaultConfigFile.getAbsolutePath(); } } addContextFromArtifact( container, contexts, getArtifact( additionalWebapp ), contextPath, contextFile, additionalWebapp.isAsWebapp() ); } These might be a similar problem with tomcat6-maven-plugin was: While the default context file (/META-INF/context.xml) is respected for the project itself, it is ignored for the additional web apps. In org/apache/tomcat/maven/plugin/tomcat7/run/AbstractRunMojo.java line 1425: for ( AbstractWebapp additionalWebapp : getAdditionalWebapps() ) { String contextPath = additionalWebapp.getContextPath(); if ( !contextPath.startsWith( "/" ) ) { contextPath = "/" + contextPath; } addContextFromArtifact( container, contexts, getArtifact( additionalWebapp ), contextPath, additionalWebapp.getContextFile(), additionalWebapp.isAsWebapp() ); } Proposed fix: for ( AbstractWebapp additionalWebapp : getAdditionalWebapps() ) { String contextPath = additionalWebapp.getContextPath(); if ( !contextPath.startsWith( "/" ) ) { contextPath = "/" + contextPath; } String contextFile = null; if(additionalWebapp.getContextFile() != null) { contextFile = additionalWebapp.getContextFile(); } else { File defaultConfigFile = new File( configurationDir, "webapps/"+artifact.getArtifactId()+"/META-INF/context.xml" ); if(defaultConfigFile.exists()) { contextFile = defaultConfigFile.getAbsolutePath(); } } addContextFromArtifact( container, contexts, getArtifact( additionalWebapp ), contextPath, contextFile, additionalWebapp.isAsWebapp() ); } These might be a similar problem with tomcat6-maven-plugin > Context file of additional web apps is ignored > -- > > Key: MTOMCAT-269 > URL: https://issues.apache.org/jira/browse/MTOMCAT-269 > Project: Apache Tomcat Maven Plugin > Issue Type: Bug > Components: tomcat6, tomcat7 >Affects Versions: 2.2 >Reporter: Stefan Kopf >Assignee: Olivier Lamy (*$^¨%`£) > > While the default context file (/META-INF/context.xml) is respected for the > project itself, it is ignored for the additional web apps. > {code:title=org/apache/tomcat/maven/plugin/tomcat7/run/AbstractRunMojo.java > line 1425|borderStyle=solid} > for ( AbstractWebapp additionalWebapp : getAdditionalWebapps() ) > { > String contextPath = additionalWebapp.getContextPath(); > if ( !contextPath.startsWith( "/" ) ) > { > contextPath = "/" + contextPath; > } > addContextFromArtifact( container, contexts, getArtifact( > additionalWebapp ), contextPath, > additionalWebapp.getContextFile(), > additional
[Bug 56491] attribute references do not resolve to their values
https://issues.apache.org/bugzilla/show_bug.cgi?id=56491 Mark Thomas changed: What|Removed |Added Status|REOPENED|RESOLVED Resolution|--- |INVALID --- Comment #10 from Mark Thomas --- If validation is enabled for web.xml, this application will fail to start. If the correct syntax is used then 8.0.x correctly disables EL for Servlet 2.3 apps and enables EL for Servlet 3.0 apps. The use case of invalid XML and validation disabled is not one that we should be spending time on trying to make the behaviour consistent across Tomcat versions. -- You are receiving this mail because: You are the assignee for the bug. - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
buildbot success in ASF Buildbot on tomcat-7-trunk
The Buildbot has detected a restored build on builder tomcat-7-trunk while building ASF Buildbot. Full details are available at: http://ci.apache.org/builders/tomcat-7-trunk/builds/72 Buildbot URL: http://ci.apache.org/ Buildslave for this Build: bb-vm_ubuntu Build Reason: scheduler Build Source Stamp: [branch tomcat/tc7.0.x/trunk] 1595900 Blamelist: kkolinko Build succeeded! sincerely, -The Buildbot - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
[jira] [Created] (MTOMCAT-270) Additional web apps are not re-deployed properly
Stefan Kopf created MTOMCAT-270: --- Summary: Additional web apps are not re-deployed properly Key: MTOMCAT-270 URL: https://issues.apache.org/jira/browse/MTOMCAT-270 Project: Apache Tomcat Maven Plugin Issue Type: Bug Components: tomcat6, tomcat7 Affects Versions: 2.2 Reporter: Stefan Kopf Assignee: Olivier Lamy (*$^¨%`£) Additional Web apps are exploded into a directory under the webapps folder in the Tomcat config directory - but only if this folder does not yet exist. {code:org/apache/tomcat/maven/plugin/tomcat7/run/AbstractRunMojo.java line 1443|borderStyle=solid} File webapps = new File( configurationDir, "webapps" ); File artifactWarDir = new File( webapps, artifact.getArtifactId() ); if ( !artifactWarDir.exists() ) { //dont extract if exists artifactWarDir.mkdir(); ... {code} If the artifact is changed (i.e. when deploying a snapshot), it is not redeployed since the directory does already exist. Since the directory is just named after the artifact id and does not contain group id or version, it is also not re deployed even if the version of the dependency is changed. Proposed fix (simple): If the directory exists, it should be removed before exploding the web app. Problem: This does work correctly, but will cause some overhead since it will be always re-deploying. Proposed optimal fix: 1. The deployment directory where the webapp is exploded to should consist of groupId, artifactId and version, and not just the artifact id. For example: {code:org/apache/tomcat/maven/plugin/tomcat7/run/AbstractRunMojo.java suggested change|borderStyle=solid} private void addContextFromArtifact( Tomcat container, List contexts, Artifact artifact, String contextPath, File contextXml, boolean asWebApp ) throws MojoExecutionException, ServletException, IOException { getLog().info( "Deploy warfile: " + String.valueOf( artifact.getFile() ) + " to contextPath: " + contextPath ); File webapps = new File( configurationDir, "webapps" ); File artifactWarDir = new File( webapps, artifact.getGroupId() + "/" + artifact.getArtifactId() + "/" + artifact.getVersion() ); if ( !artifactWarDir.exists() ) ... {code} 2. The timestamp of the directory should be compared against the timestamp of the war file. If the war file is newer, the directory is deleted and redeployed: {code:org/apache/tomcat/maven/plugin/tomcat7/run/AbstractRunMojo.java suggested change|borderStyle=solid} getLog().info( "Deploy warfile: " + String.valueOf( artifact.getFile() ) + " to contextPath: " + contextPath ); File webapps = new File( configurationDir, "webapps" ); File artifactWarDir = new File( webapps, artifact.getGroupId() + "/" + artifact.getArtifactId() + "/" + artifact.getVersion() ); if( artifactWarDir.exists() ) { if( artifact.getFile().lastModified() > artifactWarDir.lastModified() ) { FileUtils.deleteDirectory( artifactWarDir ); } } if ( !artifactWarDir.exists() ) { //dont extract if exists artifactWarDir.mkdir(); try { {code} Please note that the changed directory layout proposed by this fix influences the fix proposed in MTOMCAT-269 -- This message was sent by Atlassian JIRA (v6.2#6252) - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
[jira] [Updated] (MTOMCAT-270) Additional web apps are not re-deployed properly
[ https://issues.apache.org/jira/browse/MTOMCAT-270?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Stefan Kopf updated MTOMCAT-270: Description: Additional Web apps are exploded into a directory under the webapps folder in the Tomcat config directory - but only if this folder does not yet exist. {code:title=org/apache/tomcat/maven/plugin/tomcat7/run/AbstractRunMojo.java line 1443|borderStyle=solid} File webapps = new File( configurationDir, "webapps" ); File artifactWarDir = new File( webapps, artifact.getArtifactId() ); if ( !artifactWarDir.exists() ) { //dont extract if exists artifactWarDir.mkdir(); ... {code} If the artifact is changed (i.e. when deploying a snapshot), it is not redeployed since the directory does already exist. Since the directory is just named after the artifact id and does not contain group id or version, it is also not re deployed even if the version of the dependency is changed. Proposed fix (simple): If the directory exists, it should be removed before exploding the web app. Problem: This does work correctly, but will cause some overhead since it will be always re-deploying. Proposed optimal fix: 1. The deployment directory where the webapp is exploded to should consist of groupId, artifactId and version, and not just the artifact id. For example: {code:org/apache/tomcat/maven/plugin/tomcat7/run/AbstractRunMojo.java suggested change|borderStyle=solid} private void addContextFromArtifact( Tomcat container, List contexts, Artifact artifact, String contextPath, File contextXml, boolean asWebApp ) throws MojoExecutionException, ServletException, IOException { getLog().info( "Deploy warfile: " + String.valueOf( artifact.getFile() ) + " to contextPath: " + contextPath ); File webapps = new File( configurationDir, "webapps" ); File artifactWarDir = new File( webapps, artifact.getGroupId() + "/" + artifact.getArtifactId() + "/" + artifact.getVersion() ); if ( !artifactWarDir.exists() ) ... {code} 2. The timestamp of the directory should be compared against the timestamp of the war file. If the war file is newer, the directory is deleted and redeployed: {code:title=org/apache/tomcat/maven/plugin/tomcat7/run/AbstractRunMojo.java suggested change|borderStyle=solid} getLog().info( "Deploy warfile: " + String.valueOf( artifact.getFile() ) + " to contextPath: " + contextPath ); File webapps = new File( configurationDir, "webapps" ); File artifactWarDir = new File( webapps, artifact.getGroupId() + "/" + artifact.getArtifactId() + "/" + artifact.getVersion() ); if( artifactWarDir.exists() ) { if( artifact.getFile().lastModified() > artifactWarDir.lastModified() ) { FileUtils.deleteDirectory( artifactWarDir ); } } if ( !artifactWarDir.exists() ) { //dont extract if exists artifactWarDir.mkdir(); try { {code} Please note that the changed directory layout proposed by this fix influences the fix proposed in MTOMCAT-269 was: Additional Web apps are exploded into a directory under the webapps folder in the Tomcat config directory - but only if this folder does not yet exist. {code:org/apache/tomcat/maven/plugin/tomcat7/run/AbstractRunMojo.java line 1443|borderStyle=solid} File webapps = new File( configurationDir, "webapps" ); File artifactWarDir = new File( webapps, artifact.getArtifactId() ); if ( !artifactWarDir.exists() ) { //dont extract if exists artifactWarDir.mkdir(); ... {code} If the artifact is changed (i.e. when deploying a snapshot), it is not redeployed since the directory does already exist. Since the directory is just named after the artifact id and does not contain group id or version, it is also not re deployed even if the version of the dependency is changed. Proposed fix (simple): If the directory exists, it should be removed before exploding the web app. Problem: This does work correctly, but will cause some overhead since it will be always re-deploying. Proposed optimal fix: 1. The deployment directory where the webapp is exploded to should consist of groupId, artifactId and version, and not just the artifact id. For example: {code:org/apache/tomcat/maven/plugin/tomcat7/run/AbstractRunMojo.java suggested change|borderStyle=solid} private void addContextFromArtifact( Tomcat container, List contexts, Artifact artifact, String contextPath, File contextXml, boolean asWebApp ) throws MojoExecutionException, ServletException, IOException { getLog().info( "Deploy warfile: " + String.valueOf( artifact.getFile() ) + " to co
[jira] [Updated] (MTOMCAT-270) Additional web apps are not re-deployed properly
[ https://issues.apache.org/jira/browse/MTOMCAT-270?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Stefan Kopf updated MTOMCAT-270: Description: Additional Web apps are exploded into a directory under the webapps folder in the Tomcat config directory - but only if this folder does not yet exist. {code:title=org/apache/tomcat/maven/plugin/tomcat7/run/AbstractRunMojo.java line 1443|borderStyle=solid} File webapps = new File( configurationDir, "webapps" ); File artifactWarDir = new File( webapps, artifact.getArtifactId() ); if ( !artifactWarDir.exists() ) { //dont extract if exists artifactWarDir.mkdir(); ... {code} If the artifact is changed (i.e. when deploying a snapshot), it is not redeployed since the directory does already exist. Since the directory is just named after the artifact id and does not contain group id or version, it is also not re deployed even if the version of the dependency is changed. Proposed fix (simple): If the directory exists, it should be removed before exploding the web app. Problem: This does work correctly, but will cause some overhead since it will be always re-deploying. Proposed optimal fix: 1. The deployment directory where the webapp is exploded to should consist of groupId, artifactId and version, and not just the artifact id. For example: {code:title=org/apache/tomcat/maven/plugin/tomcat7/run/AbstractRunMojo.java suggested change|borderStyle=solid} private void addContextFromArtifact( Tomcat container, List contexts, Artifact artifact, String contextPath, File contextXml, boolean asWebApp ) throws MojoExecutionException, ServletException, IOException { getLog().info( "Deploy warfile: " + String.valueOf( artifact.getFile() ) + " to contextPath: " + contextPath ); File webapps = new File( configurationDir, "webapps" ); File artifactWarDir = new File( webapps, artifact.getGroupId() + "/" + artifact.getArtifactId() + "/" + artifact.getVersion() ); if ( !artifactWarDir.exists() ) ... {code} 2. The timestamp of the directory should be compared against the timestamp of the war file. If the war file is newer, the directory is deleted and redeployed: {code:title=org/apache/tomcat/maven/plugin/tomcat7/run/AbstractRunMojo.java suggested change|borderStyle=solid} getLog().info( "Deploy warfile: " + String.valueOf( artifact.getFile() ) + " to contextPath: " + contextPath ); File webapps = new File( configurationDir, "webapps" ); File artifactWarDir = new File( webapps, artifact.getGroupId() + "/" + artifact.getArtifactId() + "/" + artifact.getVersion() ); if( artifactWarDir.exists() ) { if( artifact.getFile().lastModified() > artifactWarDir.lastModified() ) { FileUtils.deleteDirectory( artifactWarDir ); } } if ( !artifactWarDir.exists() ) { //dont extract if exists artifactWarDir.mkdir(); try { {code} Please note that the changed directory layout proposed by this fix influences the fix proposed in MTOMCAT-269 was: Additional Web apps are exploded into a directory under the webapps folder in the Tomcat config directory - but only if this folder does not yet exist. {code:title=org/apache/tomcat/maven/plugin/tomcat7/run/AbstractRunMojo.java line 1443|borderStyle=solid} File webapps = new File( configurationDir, "webapps" ); File artifactWarDir = new File( webapps, artifact.getArtifactId() ); if ( !artifactWarDir.exists() ) { //dont extract if exists artifactWarDir.mkdir(); ... {code} If the artifact is changed (i.e. when deploying a snapshot), it is not redeployed since the directory does already exist. Since the directory is just named after the artifact id and does not contain group id or version, it is also not re deployed even if the version of the dependency is changed. Proposed fix (simple): If the directory exists, it should be removed before exploding the web app. Problem: This does work correctly, but will cause some overhead since it will be always re-deploying. Proposed optimal fix: 1. The deployment directory where the webapp is exploded to should consist of groupId, artifactId and version, and not just the artifact id. For example: {code:org/apache/tomcat/maven/plugin/tomcat7/run/AbstractRunMojo.java suggested change|borderStyle=solid} private void addContextFromArtifact( Tomcat container, List contexts, Artifact artifact, String contextPath, File contextXml, boolean asWebApp ) throws MojoExecutionException, ServletException, IOException { getLog().info( "Deploy warfile: " + String.valueOf( artifact.getFile()
buildbot success in ASF Buildbot on tomcat-trunk
The Buildbot has detected a restored build on builder tomcat-trunk while building ASF Buildbot. Full details are available at: http://ci.apache.org/builders/tomcat-trunk/builds/88 Buildbot URL: http://ci.apache.org/ Buildslave for this Build: bb-vm_ubuntu Build Reason: scheduler Build Source Stamp: [branch tomcat/trunk] 1595893 Blamelist: kkolinko,markt Build succeeded! sincerely, -The Buildbot - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
Re: Tomcat commit e-mails missing
2014-05-14 1:32 GMT+04:00 Tony Stevenson : > Jake, > > As far as I know current emails should not be being delayed now. I.e. New > commits. > If specific mails are missing they can easily be generated on eris. > > > Sent from my iPad > > On 13 May 2014, at 16:40, Jake Farrell wrote: > > Hi Konstantin > The mail backlog is still processing from the issues last week [1]. We > appreciate your patience as this processes and if you continue to have > problems please let us know > > -Jake > > [1]: https://blogs.apache.org/infra/entry/mail_outage > > > On Thu, May 8, 2014 at 3:51 AM, Konstantin Kolinko > wrote: >> >> cc: dev >> >> Hi! >> >> Where are svn commit e-mails for Apache Tomcat? >> >> The last one received by dev@tomcat.a.o list was on May 2.(r1592052) >> http://mail-archives.apache.org/mod_mbox/tomcat-dev/201405.mbox/browser >> >> There were no e-mails for commits on May 3, 7 or today >> (r1593009 and later) >> cc: dev As a follow-up, I compared svn log for /tomcat versus my gmail mailbox and versus mail archive at [1] and can say that all commit e-mails sent during the outage have successfully arrived to both places. The longest delay among the e-mails that I received is 8 days 17 hours ("r1593132" message). From mail headers: Date: Wed, 07 May 2014 20:39:07 - Received: Fri, 16 May 2014 07:04:02 -0700 (PDT) As of now, I see no noticeable delays in mail delivery. So the issue is resolved. Thank you for your work! [1] http://mail-archives.apache.org/mod_mbox/tomcat-dev/201405.mbox/browser Best regards, Konstantin Kolinko - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
svn commit: r1595997 - in /tomcat/tc7.0.x/tags/TOMCAT_7_0_54: ./ build.properties.default
Author: violetagg Date: Mon May 19 19:15:46 2014 New Revision: 1595997 URL: http://svn.apache.org/r1595997 Log: Tag 7.0.54 Added: tomcat/tc7.0.x/tags/TOMCAT_7_0_54/ (props changed) - copied from r1595993, tomcat/tc7.0.x/trunk/ Modified: tomcat/tc7.0.x/tags/TOMCAT_7_0_54/build.properties.default Propchange: tomcat/tc7.0.x/tags/TOMCAT_7_0_54/ -- bugtraq:append = false Propchange: tomcat/tc7.0.x/tags/TOMCAT_7_0_54/ -- bugtraq:label = Bugzilla ID (optional) Propchange: tomcat/tc7.0.x/tags/TOMCAT_7_0_54/ -- --- bugtraq:message (added) +++ bugtraq:message Mon May 19 19:15:46 2014 @@ -0,0 +1 @@ +Fix https://issues.apache.org/bugzilla/show_bug.cgi?id=%BUGID% Propchange: tomcat/tc7.0.x/tags/TOMCAT_7_0_54/ -- bugtraq:number = true Propchange: tomcat/tc7.0.x/tags/TOMCAT_7_0_54/ -- bugtraq:url = https://issues.apache.org/bugzilla/show_bug.cgi?id=%BUGID% Propchange: tomcat/tc7.0.x/tags/TOMCAT_7_0_54/ -- bugtraq:warnifnoissue = false Propchange: tomcat/tc7.0.x/tags/TOMCAT_7_0_54/ -- --- svn:ignore (added) +++ svn:ignore Mon May 19 19:15:46 2014 @@ -0,0 +1,7 @@ +.* +build.properties +logs +nbproject +output +work +*.iml Propchange: tomcat/tc7.0.x/tags/TOMCAT_7_0_54/ -- --- svn:mergeinfo (added) +++ svn:mergeinfo Mon May 19 19:15:46 2014 @@ -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-1222329,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,1346365,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,1 352661,1352663,1352788,1352799,1353087,1353125,1353240,1353261,1353414,1353468,1353501,1
buildbot failure in ASF Buildbot on tomcat-trunk
The Buildbot has detected a new failure on builder tomcat-trunk while building ASF Buildbot. Full details are available at: http://ci.apache.org/builders/tomcat-trunk/builds/89 Buildbot URL: http://ci.apache.org/ Buildslave for this Build: bb-vm_ubuntu Build Reason: scheduler Build Source Stamp: [branch tomcat/trunk] 1595898 Blamelist: markt BUILD FAILED: failed compile_1 sincerely, -The Buildbot - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
[Bug 56387] Improve exceptions thrown by stopped WebappClassLoader (to help identify 'stopped state' as the cause of a NoClassDefFoundError)
https://issues.apache.org/bugzilla/show_bug.cgi?id=56387 Mark Thomas changed: What|Removed |Added Status|REOPENED|RESOLVED Resolution|--- |FIXED --- Comment #7 from Mark Thomas --- I agree that no evidence has been produced that supports the assertation that a state value of the started flag was observed. Note the state is volatile in Tomcat 8. I have improved the code that handles an attempt to load a class after a web application has been stopped. This will be in 8.0.9 onwards. -- You are receiving this mail because: You are the assignee for the bug. - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
svn commit: r1596004 - in /tomcat/trunk: java/org/apache/catalina/loader/WebappClassLoader.java webapps/docs/changelog.xml
Author: markt Date: Mon May 19 19:38:13 2014 New Revision: 1596004 URL: http://svn.apache.org/r1596004 Log: Fix https://issues.apache.org/bugzilla/show_bug.cgi?id=56387 Refactor handling of class loading attempts after web application stop. Modified: tomcat/trunk/java/org/apache/catalina/loader/WebappClassLoader.java tomcat/trunk/webapps/docs/changelog.xml Modified: tomcat/trunk/java/org/apache/catalina/loader/WebappClassLoader.java URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/catalina/loader/WebappClassLoader.java?rev=1596004&r1=1596003&r2=1596004&view=diff == --- tomcat/trunk/java/org/apache/catalina/loader/WebappClassLoader.java (original) +++ tomcat/trunk/java/org/apache/catalina/loader/WebappClassLoader.java Mon May 19 19:38:13 2014 @@ -852,10 +852,7 @@ public class WebappClassLoader extends U if (log.isDebugEnabled()) log.debug("findClass(" + name + ")"); -// Cannot load anything from local repositories if class loader is stopped -if (!state.isAvailable()) { -throw new ClassNotFoundException(name); -} +checkStateForClassLoading(name); // (1) Permission to define this class when using a SecurityManager if (securityManager != null) { @@ -1215,14 +1212,8 @@ public class WebappClassLoader extends U log.debug("loadClass(" + name + ", " + resolve + ")"); Class clazz = null; -// Log access to stopped classloader -if (!state.isAvailable()) { -try { -throw new IllegalStateException(); -} catch (IllegalStateException e) { -log.info(sm.getString("webappClassLoader.stopped", name), e); -} -} +// Log access to stopped class loader +checkStateForClassLoading(name); // (0) Check our previously loaded local class cache clazz = findLoadedClass0(name); @@ -1331,7 +1322,19 @@ public class WebappClassLoader extends U } throw new ClassNotFoundException(name); +} + +protected void checkStateForClassLoading(String className) { +// It is not permitted to load new classes once the web application has +// been stopped. +if (!state.isAvailable()) { +String msg = sm.getString("webappClassLoader.stopped", className); +IllegalStateException cause = new IllegalStateException(msg); +ClassNotFoundException cnfe = new ClassNotFoundException(); +cnfe.initCause(cause); +log.info(msg, cnfe); +} } Modified: tomcat/trunk/webapps/docs/changelog.xml URL: http://svn.apache.org/viewvc/tomcat/trunk/webapps/docs/changelog.xml?rev=1596004&r1=1596003&r2=1596004&view=diff == --- tomcat/trunk/webapps/docs/changelog.xml (original) +++ tomcat/trunk/webapps/docs/changelog.xml Mon May 19 19:38:13 2014 @@ -47,6 +47,12 @@ + + 56387: Improve the code that handles an attempt to load a + class after a web application has been stopped. Use common code to handle + this case regardless of the access path and don't throw an exception + purely to log a stack trace. (markt) + 56399: Improve implementation of CoyoteAdapter.checkRecycled() to do not use an exception for flow control. (kkolinko) - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
[Bug 56521] Reuse the output buffer in AbstractServletOutputStream
https://issues.apache.org/bugzilla/show_bug.cgi?id=56521 --- Comment #5 from Mark Thomas --- The other thing that would significantly reduce garbage is not to copy the data from the buffer to a new buffer if it is not fully written. -- 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: r1596047 - in /tomcat/tc7.0.x/trunk: ./ java/org/apache/catalina/valves/ test/org/apache/catalina/valves/ webapps/docs/ webapps/docs/config/
Author: slaurent Date: Mon May 19 20:26:23 2014 New Revision: 1596047 URL: http://svn.apache.org/r1596047 Log: Fix https://issues.apache.org/bugzilla/show_bug.cgi?id=56526 Improved StuckThreadDetectionValve to allow to interrupt stuck threads. merged r1595331 from trunk Added: tomcat/tc7.0.x/trunk/test/org/apache/catalina/valves/TestStuckThreadDetectionValve.java - copied unchanged from r1595331, tomcat/trunk/test/org/apache/catalina/valves/TestStuckThreadDetectionValve.java Modified: tomcat/tc7.0.x/trunk/ (props changed) tomcat/tc7.0.x/trunk/java/org/apache/catalina/valves/LocalStrings.properties tomcat/tc7.0.x/trunk/java/org/apache/catalina/valves/StuckThreadDetectionValve.java tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml tomcat/tc7.0.x/trunk/webapps/docs/config/valve.xml Propchange: tomcat/tc7.0.x/trunk/ -- Merged /tomcat/trunk:r1595331 Modified: tomcat/tc7.0.x/trunk/java/org/apache/catalina/valves/LocalStrings.properties URL: http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/java/org/apache/catalina/valves/LocalStrings.properties?rev=1596047&r1=1596046&r2=1596047&view=diff == --- tomcat/tc7.0.x/trunk/java/org/apache/catalina/valves/LocalStrings.properties (original) +++ tomcat/tc7.0.x/trunk/java/org/apache/catalina/valves/LocalStrings.properties Mon May 19 20:26:23 2014 @@ -57,6 +57,7 @@ sslValve.invalidProvider=The SSL provide #Stuck thread detection Valve stuckThreadDetectionValve.notifyStuckThreadDetected=Thread "{0}" (id={6}) has been active for {1} milliseconds (since {2}) to serve the same request for {4} and may be stuck (configured threshold for this StuckThreadDetectionValve is {5} seconds). There is/are {3} thread(s) in total that are monitored by this Valve and may be stuck. stuckThreadDetectionValve.notifyStuckThreadCompleted=Thread "{0}" (id={3}) was previously reported to be stuck but has completed. It was active for approximately {1} milliseconds.{2,choice,0#|0< There is/are still {2} thread(s) that are monitored by this Valve and may be stuck.} +stuckThreadDetectionValve.notifyStuckThreadInterrupted=Thread "{0}" (id={5}) has been interrupted because it was active for {1} milliseconds (since {2}) to serve the same request for {3} and was probably stuck (configured interruption threshold for this StuckThreadDetectionValve is {4} seconds). # HTTP status reports # All status codes registered with IANA can be found at Modified: tomcat/tc7.0.x/trunk/java/org/apache/catalina/valves/StuckThreadDetectionValve.java URL: http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/java/org/apache/catalina/valves/StuckThreadDetectionValve.java?rev=1596047&r1=1596046&r2=1596047&view=diff == --- tomcat/tc7.0.x/trunk/java/org/apache/catalina/valves/StuckThreadDetectionValve.java (original) +++ tomcat/tc7.0.x/trunk/java/org/apache/catalina/valves/StuckThreadDetectionValve.java Mon May 19 20:26:23 2014 @@ -23,7 +23,9 @@ import java.util.List; import java.util.Queue; import java.util.concurrent.ConcurrentHashMap; import java.util.concurrent.ConcurrentLinkedQueue; +import java.util.concurrent.Semaphore; import java.util.concurrent.atomic.AtomicInteger; +import java.util.concurrent.atomic.AtomicLong; import javax.servlet.ServletException; @@ -62,11 +64,21 @@ public class StuckThreadDetectionValve e private final AtomicInteger stuckCount = new AtomicInteger(0); /** + * Keeps count of the number of stuck threads that have been interruoted + */ +private AtomicLong interruptedThreadsCount = new AtomicLong(); + +/** * In seconds. Default 600 (10 minutes). */ private int threshold = 600; /** + * In seconds. Default is -1 to disable interruption. + */ +private int interruptThreadThreshold; + +/** * The only references we keep to actual running Thread objects are in * this Map (which is automatically cleaned in invoke()s finally clause). * That way, Threads can be GC'ed, eventhough the Valve still thinks they @@ -81,7 +93,7 @@ public class StuckThreadDetectionValve e new ConcurrentLinkedQueue(); /** - * Specify the threshold (in seconds) used when checking for stuck threads. + * Specifies the threshold (in seconds) used when checking for stuck threads. * If <=0, the detection is disabled. The default is 600 seconds. * * @param threshold @@ -100,6 +112,22 @@ public class StuckThreadDetectionValve e } +public int getInterruptThreadThreshold() { +return interruptThreadThreshold; +} + +/** + * Specifies the threshold (in seconds) before stuck threads are interrupted. + * If <=0, the interruption is disabled. The default is -1. + * If >=0, the value mus
[Bug 56545] New: Examples app security exceptions (8.0.8 release candidate)
https://issues.apache.org/bugzilla/show_bug.cgi?id=56545 Bug ID: 56545 Summary: Examples app security exceptions (8.0.8 release candidate) Product: Tomcat 8 Version: 8.0.5 Hardware: PC Status: NEW Severity: normal Priority: P2 Component: Examples Assignee: dev@tomcat.apache.org Reporter: knst.koli...@gmail.com Created attachment 31637 --> https://issues.apache.org/bugzilla/attachment.cgi?id=31637&action=edit (1) localhost.2014-05-20.log Testing examples web application in 8.0.8 release candidate running with Security Manager enabled, with NIO connector, JDK 7u55 32-bit, Win7, I see several issues. Steps to reproduce (1). 1. Edit conf/tomcat-users.xml and uncomment sample roles there. 2. Start bin/catalina.bat start -security 3. Access the following page: http://localhost:8080/examples/jsp/security/protected/index.jsp Expected: Login page Actual: Error 500 Access denied ("java.lang.RuntimePermission" "accessClassInPackage.org.apache.tomcat.util.http.parser") The stack trace is: java.security.AccessControlException: access denied ("java.lang.RuntimePermission" "accessClassInPackage.org.apache.tomcat.util.http.parser") at java.security.AccessControlContext.checkPermission(AccessControlContext.java:372) at java.security.AccessController.checkPermission(AccessController.java:559) at java.lang.SecurityManager.checkPermission(SecurityManager.java:549) at java.lang.SecurityManager.checkPackageAccess(SecurityManager.java:1525) at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:305) at java.lang.ClassLoader.loadClass(ClassLoader.java:412) at java.lang.ClassLoader.loadClass(ClassLoader.java:358) at org.apache.tomcat.util.http.parser.HttpParser.skipConstant(HttpParser.java:305) at org.apache.tomcat.util.http.parser.HttpParser.parseMediaType(HttpParser.java:192) at org.apache.tomcat.util.http.parser.MediaTypeCache.parse(MediaTypeCache.java:54) at org.apache.catalina.connector.Response.setContentType(Response.java:712) at org.apache.jsp.jsp.security.protected_.login_jsp._jspService(login_jsp.java:52) at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70) at javax.servlet.http.HttpServlet.service(HttpServlet.java:725) See attached "(1) localhost.2014-05-20.log" for the full stack trace. -- 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 56526] New option to interrupt stuck threads
https://issues.apache.org/bugzilla/show_bug.cgi?id=56526 --- Comment #4 from Sylvain Laurent --- merged to tomcat 7, will be available in 7.0.55. -- 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: r1596052 - in /tomcat/tc7.0.x/trunk: ./ java/org/apache/catalina/core/ test/org/apache/catalina/core/ webapps/docs/ webapps/docs/config/
Author: slaurent Date: Mon May 19 20:42:56 2014 New Revision: 1596052 URL: http://svn.apache.org/r1596052 Log: Fix https://issues.apache.org/bugzilla/show_bug.cgi?id=56461 New option to make context startup fail if a load-on-startup servlet fails merged r1595690 from trunk Modified: tomcat/tc7.0.x/trunk/ (props changed) tomcat/tc7.0.x/trunk/java/org/apache/catalina/core/StandardContext.java tomcat/tc7.0.x/trunk/java/org/apache/catalina/core/StandardHost.java tomcat/tc7.0.x/trunk/test/org/apache/catalina/core/TestStandardContext.java tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml tomcat/tc7.0.x/trunk/webapps/docs/config/context.xml tomcat/tc7.0.x/trunk/webapps/docs/config/host.xml Propchange: tomcat/tc7.0.x/trunk/ -- Merged /tomcat/trunk:r1595690 Modified: tomcat/tc7.0.x/trunk/java/org/apache/catalina/core/StandardContext.java URL: http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/java/org/apache/catalina/core/StandardContext.java?rev=1596052&r1=1596051&r2=1596052&view=diff == --- tomcat/tc7.0.x/trunk/java/org/apache/catalina/core/StandardContext.java (original) +++ tomcat/tc7.0.x/trunk/java/org/apache/catalina/core/StandardContext.java Mon May 19 20:42:56 2014 @@ -893,6 +893,8 @@ public class StandardContext extends Con private String containerSciFilter; +private Boolean failCtxIfServletStartFails; + // - Context Properties @@ -2816,8 +2818,32 @@ public class StandardContext extends Con this.renewThreadsWhenStoppingContext); } -// Context Methods +public Boolean getFailCtxIfServletStartFails() { +return failCtxIfServletStartFails; +} +public void setFailCtxIfServletStartFails( +Boolean failCtxIfServletStartFails) { +Boolean oldFailCtxIfServletStartFails = this.failCtxIfServletStartFails; +this.failCtxIfServletStartFails = failCtxIfServletStartFails; +support.firePropertyChange("failCtxIfServletStartFails", +oldFailCtxIfServletStartFails, +failCtxIfServletStartFails); +} + +protected boolean getComputedFailCtxIfServletStartFails() { +if(failCtxIfServletStartFails != null) { +return failCtxIfServletStartFails.booleanValue(); +} +//else look at Host config +if(getParent() instanceof StandardHost) { +return ((StandardHost)getParent()).isFailCtxIfServletStartFails(); +} +//else +return false; +} + +// Context Methods @Override public void addApplicationListener(String listener) { @@ -5184,7 +5210,7 @@ public class StandardContext extends Con * @param children Array of wrappers for all currently defined * servlets (including those not declared load on startup) */ -public void loadOnStartup(Container children[]) { +public boolean loadOnStartup(Container children[]) { // Collect "load on startup" servlets that need to be initialized TreeMap> map = @@ -5213,10 +5239,14 @@ public class StandardContext extends Con getName()), StandardWrapper.getRootCause(e)); // NOTE: load errors (including a servlet that throws // UnavailableException from tht init() method) are NOT -// fatal to application startup +// fatal to application startup, excepted if failDeploymentIfServletLoadedOnStartupFails is specified +if(getComputedFailCtxIfServletStartFails()) { +return false; +} } } } +return true; } @@ -5490,7 +5520,10 @@ public class StandardContext extends Con // Load and initialize all "load on startup" servlets if (ok) { -loadOnStartup(findChildren()); +if (!loadOnStartup(findChildren())){ +log.error("Error loadOnStartup"); +ok = false; +} } // Start ContainerBackgroundProcessor thread Modified: tomcat/tc7.0.x/trunk/java/org/apache/catalina/core/StandardHost.java URL: http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/java/org/apache/catalina/core/StandardHost.java?rev=1596052&r1=1596051&r2=1596052&view=diff == --- tomcat/tc7.0.x/trunk/java/org/apache/catalina/core/StandardHost.java (original) +++ tomcat/tc7.0.x/trunk/java/org/apache/catalina/core/StandardHost.java Mon May 19 20:42:56 2014 @@ -180,6
[Bug 56545] Examples app security exceptions (8.0.8 release candidate)
https://issues.apache.org/bugzilla/show_bug.cgi?id=56545 Konstantin Kolinko changed: What|Removed |Added OS||All --- Comment #1 from Konstantin Kolinko --- The workaround for the issue in Comment 0 is to add the following class to the value of classesToInitialize attribute of JreMemoryLeakPreventionListener in server.xml. E.g.: -- 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 56461] New option to make context startup fail if a load-on-startup servlet fails
https://issues.apache.org/bugzilla/show_bug.cgi?id=56461 --- Comment #5 from Sylvain Laurent --- merged to tomcat 7, will be availble in 7.0.55 -- 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 56545] Examples app security exceptions (8.0.8 release candidate)
https://issues.apache.org/bugzilla/show_bug.cgi?id=56545 --- Comment #2 from Konstantin Kolinko --- 4. On the login page, enter a username (role1) and password (see tomcat-users.xml). Press "Login" button. 5. Look into logs/localhost.2014-05-20.log. There is an exception thrown by Session attribute event listener. org.apache.catalina.session.StandardSession.setAttribute Session attribute event listener threw exception java.security.AccessControlException: access denied ("java.lang.RuntimePermission" "accessClassInPackage.org.apache.catalina.util") at java.security.AccessControlContext.checkPermission(AccessControlContext.java:372) at java.security.AccessController.checkPermission(AccessController.java:559) at java.lang.SecurityManager.checkPermission(SecurityManager.java:549) at java.lang.SecurityManager.checkPackageAccess(SecurityManager.java:1525) at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:305) at java.lang.ClassLoader.loadClass(ClassLoader.java:412) at java.lang.ClassLoader.loadClass(ClassLoader.java:358) at org.apache.catalina.users.MemoryUser.toString(MemoryUser.java:312) at javax.security.auth.Subject.toString(Subject.java:842) at javax.security.auth.Subject.toString(Subject.java:825) at java.lang.String.valueOf(String.java:2854) at java.lang.StringBuilder.append(StringBuilder.java:128) at listeners.SessionListener.attributeAdded(SessionListener.java:56) at org.apache.catalina.session.StandardSession.setAttribute(StandardSession.java:1546) 6. Press logout link ("you can log off by clicking here.") 7. The same exception is thrown for "attributeRemoved" event. >From the stacktrace (at org.apache.catalina.users.MemoryUser.toString(MemoryUser.java:312)) my guess is that it ties to call static method RequestUtil.filter(username). -- 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 56545] Examples app security exceptions (8.0.8 release candidate)
https://issues.apache.org/bugzilla/show_bug.cgi?id=56545 --- Comment #3 from Konstantin Kolinko --- Created attachment 31638 --> https://issues.apache.org/bugzilla/attachment.cgi?id=31638&action=edit (2) localhost.2014-05-20.log Log file with exceptions for issue in Comment 2. -- 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 56545] Examples app security exceptions (8.0.8 release candidate)
https://issues.apache.org/bugzilla/show_bug.cgi?id=56545 --- Comment #4 from Konstantin Kolinko --- The workaround for issue in Comment 2 is to add "org.apache.catalina.util.RequestUtil" to the value of classesToInitialize attribute. With the following configuration both issues are resolved: -- 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 56543] Jasper fails to compile JSP pages when running with JDK 1.8
https://issues.apache.org/bugzilla/show_bug.cgi?id=56543 --- Comment #4 from Remy Maucherat --- It would be a good plan to upgrade 8 asap, however, even if the JDT build is a bit "new". -- You are receiving this mail because: You are the assignee for the bug. - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
Re: [VOTE] Release Apache Tomcat 8.0.8
2014-05-17 0:55 GMT+04:00 Mark Thomas : > The proposed Apache Tomcat 8.0.8 release is now available for voting. > > The main changes since 8.0.6 are: > - Fix BZ 56529 a regression in the fix for BZ 56481 > - Fix regression that broke Tomcat's copy of DBCP > - Small number of additional fixes > > The main changes since 8.0.5 are: > - Further NIO2 fixes which is now considered BETA > - Extend and improve memory leak protection and fix a few leaks that > crept in during the various refactorings > - Lots of general bug fixes > > > It can be obtained from: > https://dist.apache.org/repos/dist/dev/tomcat/tomcat-8/v8.0.8/ > The Maven staging repo is: > https://repository.apache.org/content/repositories/orgapachetomcat-1013/ > The svn tag is: > http://svn.apache.org/repos/asf/tomcat/tc8.0.x/tags/TOMCAT_8_0_8/ The proposed 8.0.8 release is: [ ] Broken - do not release [ ] Alpha - go ahead and release as 8.0.8 (alpha) [x] Beta - go ahead and release as 8.0.8 (beta) [ ] Stable - go ahead and release as 8.0.8 (stable) Tested on Win7 with JDK 7u55 32-bit. Testsuite NIO,BIO,NIO2,APR - all tests passed successfully. Testing examples webapp with security manager enabled I encountered two issues when accessClassInPackage permission was denied. I filed this into Bugzilla as #56545 [1]. There is a workaround for those issues. If I configure "classesToInitialize" attribute on JreMemoryLeakPreventionListener as I described in comment 4 of BZ 56545, both issues disappear. [1] https://issues.apache.org/bugzilla/show_bug.cgi?id=56545 Also I was not able to get any sense from the Comet chat example (http://localhost:8080/examples/servlets/chat/). The connection for the /chat panel (the bottom panel in the frameset) that was supposed to be opened for some time, closed nearly immediately. Thus chat messages could be printed. The browser I was using is Firefox 29.0.1. Connector: NIO. I think this is not fatal and qualifies as beta. Best regards, Konstantin Kolinko - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
Re: buildbot failure in ASF Buildbot on tomcat-trunk
2014-05-19 23:30 GMT+04:00 : > The Buildbot has detected a new failure on builder tomcat-trunk while > building ASF Buildbot. > Full details are available at: > http://ci.apache.org/builders/tomcat-trunk/builds/89 > > Buildbot URL: http://ci.apache.org/ > > Buildslave for this Build: bb-vm_ubuntu > > Build Reason: scheduler > Build Source Stamp: [branch tomcat/trunk] 1595898 > Blamelist: markt > > BUILD FAILED: failed compile_1 > The failed test is "org.apache.catalina.valves.TestStuckThreadDetectionValve" x NIO. BIO and NIO2 runs were OK. http://ci.apache.org/projects/tomcat/tomcat8/1595898/ http://ci.apache.org/projects/tomcat/tomcat8/1595898/TEST-org.apache.catalina.valves.TestStuckThreadDetectionValve.NIO.txt A difference is that there was an attempt to load a class which failed on a stopped web application. Best regards, Konstantin Kolinko - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
Re: svn commit: r1596004 - in /tomcat/trunk: java/org/apache/catalina/loader/WebappClassLoader.java webapps/docs/changelog.xml
2014-05-19 23:38 GMT+04:00 : > Author: markt > Date: Mon May 19 19:38:13 2014 > New Revision: 1596004 > > URL: http://svn.apache.org/r1596004 > Log: > Fix https://issues.apache.org/bugzilla/show_bug.cgi?id=56387 > Refactor handling of class loading attempts after web application stop. > > Modified: > tomcat/trunk/java/org/apache/catalina/loader/WebappClassLoader.java > tomcat/trunk/webapps/docs/changelog.xml > > Modified: tomcat/trunk/java/org/apache/catalina/loader/WebappClassLoader.java > URL: > http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/catalina/loader/WebappClassLoader.java?rev=1596004&r1=1596003&r2=1596004&view=diff > == > --- tomcat/trunk/java/org/apache/catalina/loader/WebappClassLoader.java > (original) > +++ tomcat/trunk/java/org/apache/catalina/loader/WebappClassLoader.java Mon > May 19 19:38:13 2014 > @@ -852,10 +852,7 @@ public class WebappClassLoader extends U > if (log.isDebugEnabled()) > log.debug("findClass(" + name + ")"); > > -// Cannot load anything from local repositories if class loader is > stopped > -if (!state.isAvailable()) { > -throw new ClassNotFoundException(name); > -} > +checkStateForClassLoading(name); The old code threw a CNFE here. The new code throws nothing. > // (1) Permission to define this class when using a SecurityManager > if (securityManager != null) { > @@ -1215,14 +1212,8 @@ public class WebappClassLoader extends U > log.debug("loadClass(" + name + ", " + resolve + ")"); > Class clazz = null; > > -// Log access to stopped classloader > -if (!state.isAvailable()) { > -try { > -throw new IllegalStateException(); > -} catch (IllegalStateException e) { > -log.info(sm.getString("webappClassLoader.stopped", name), e); > -} > -} > +// Log access to stopped class loader > +checkStateForClassLoading(name); > > // (0) Check our previously loaded local class cache > clazz = findLoadedClass0(name); > @@ -1331,7 +1322,19 @@ public class WebappClassLoader extends U > } > > throw new ClassNotFoundException(name); > +} > + > > +protected void checkStateForClassLoading(String className) { > +// It is not permitted to load new classes once the web application > has > +// been stopped. > +if (!state.isAvailable()) { > +String msg = sm.getString("webappClassLoader.stopped", > className); > +IllegalStateException cause = new IllegalStateException(msg); > +ClassNotFoundException cnfe = new ClassNotFoundException(); It might be better to use "new ClassNotFoundException(className)". Though from the second look I see that the log message already mentions the class name. > +cnfe.initCause(cause); > +log.info(msg, cnfe); This method does not throw anything... Thus it is not really a "ClassNotFoundException", because a class is not really "not found", but execution continues further and it may occasionally find the class. > +} > } > As a test case it looks that org.apache.catalina.valves.TestStuckThreadDetectionValve occasionally causes this exception, as was noted by Buildbot (though that buildbot run was before this change, so it is not illustrative). http://ci.apache.org/projects/tomcat/tomcat8/1595898/ Best regards, Konstantin Kolinko - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
Re: svn commit: r1596004 - in /tomcat/trunk: java/org/apache/catalina/loader/WebappClassLoader.java webapps/docs/changelog.xml
On 19/05/2014 22:41, Konstantin Kolinko wrote: > 2014-05-19 23:38 GMT+04:00 : >> Author: markt >> Date: Mon May 19 19:38:13 2014 >> New Revision: 1596004 >> >> URL: http://svn.apache.org/r1596004 >> Log: >> Fix https://issues.apache.org/bugzilla/show_bug.cgi?id=56387 >> Refactor handling of class loading attempts after web application stop. >> >> Modified: >> tomcat/trunk/java/org/apache/catalina/loader/WebappClassLoader.java >> tomcat/trunk/webapps/docs/changelog.xml >> >> Modified: tomcat/trunk/java/org/apache/catalina/loader/WebappClassLoader.java >> URL: >> http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/catalina/loader/WebappClassLoader.java?rev=1596004&r1=1596003&r2=1596004&view=diff >> == >> --- tomcat/trunk/java/org/apache/catalina/loader/WebappClassLoader.java >> (original) >> +++ tomcat/trunk/java/org/apache/catalina/loader/WebappClassLoader.java Mon >> May 19 19:38:13 2014 >> @@ -852,10 +852,7 @@ public class WebappClassLoader extends U >> if (log.isDebugEnabled()) >> log.debug("findClass(" + name + ")"); >> >> -// Cannot load anything from local repositories if class loader is >> stopped >> -if (!state.isAvailable()) { >> -throw new ClassNotFoundException(name); >> -} >> +checkStateForClassLoading(name); > > The old code threw a CNFE here. The new code throws nothing. > >> // (1) Permission to define this class when using a SecurityManager >> if (securityManager != null) { >> @@ -1215,14 +1212,8 @@ public class WebappClassLoader extends U >> log.debug("loadClass(" + name + ", " + resolve + ")"); >> Class clazz = null; >> >> -// Log access to stopped classloader >> -if (!state.isAvailable()) { >> -try { >> -throw new IllegalStateException(); >> -} catch (IllegalStateException e) { >> -log.info(sm.getString("webappClassLoader.stopped", name), >> e); >> -} >> -} >> +// Log access to stopped class loader >> +checkStateForClassLoading(name); >> >> // (0) Check our previously loaded local class cache >> clazz = findLoadedClass0(name); >> @@ -1331,7 +1322,19 @@ public class WebappClassLoader extends U >> } >> >> throw new ClassNotFoundException(name); >> +} >> + >> >> +protected void checkStateForClassLoading(String className) { >> +// It is not permitted to load new classes once the web application >> has >> +// been stopped. >> +if (!state.isAvailable()) { >> +String msg = sm.getString("webappClassLoader.stopped", >> className); >> +IllegalStateException cause = new IllegalStateException(msg); >> +ClassNotFoundException cnfe = new ClassNotFoundException(); > > It might be better to use "new ClassNotFoundException(className)". > Though from the second look I see that the log message already > mentions the class name. > >> +cnfe.initCause(cause); >> +log.info(msg, cnfe); > > This method does not throw anything... Thus it is not really a > "ClassNotFoundException", because a class is not really "not found", > but execution continues further and it may occasionally find the > class. bah. I meant to throw CNFE at the end of that but got distracted thinking about logging. I'll fix that in a sec. >> +} >> } >> > > As a test case it looks that > org.apache.catalina.valves.TestStuckThreadDetectionValve > occasionally causes this exception, as was noted by Buildbot > (though that buildbot run was before this change, so it is not illustrative). > http://ci.apache.org/projects/tomcat/tomcat8/1595898/ Lets see what happens when I fix the above. Mark - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
svn commit: r1596065 - /tomcat/trunk/java/org/apache/catalina/loader/WebappClassLoader.java
Author: markt Date: Mon May 19 21:45:22 2014 New Revision: 1596065 URL: http://svn.apache.org/r1596065 Log: Follow up to r1596004. Actually throw the exception. Modified: tomcat/trunk/java/org/apache/catalina/loader/WebappClassLoader.java Modified: tomcat/trunk/java/org/apache/catalina/loader/WebappClassLoader.java URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/catalina/loader/WebappClassLoader.java?rev=1596065&r1=1596064&r2=1596065&view=diff == --- tomcat/trunk/java/org/apache/catalina/loader/WebappClassLoader.java (original) +++ tomcat/trunk/java/org/apache/catalina/loader/WebappClassLoader.java Mon May 19 21:45:22 2014 @@ -1325,7 +1325,7 @@ public class WebappClassLoader extends U } -protected void checkStateForClassLoading(String className) { +protected void checkStateForClassLoading(String className) throws ClassNotFoundException { // It is not permitted to load new classes once the web application has // been stopped. if (!state.isAvailable()) { @@ -1334,6 +1334,7 @@ public class WebappClassLoader extends U ClassNotFoundException cnfe = new ClassNotFoundException(); cnfe.initCause(cause); log.info(msg, cnfe); +throw cnfe; } } - 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.8
On 16.5.2014 22:55, Mark Thomas wrote: The proposed 8.0.8 release is: [ ] Broken - do not release [ ] Alpha - go ahead and release as 8.0.8 (alpha) [ ] Beta - go ahead and release as 8.0.8 (beta) [X] Stable - go ahead and release as 8.0.8 (stable) (non-binding) Tested .zip distribution on Windows 7 64-bit: - Tested TLS/SSL connectivity for BIO, NIO and APR connectors. - Crawled all links (except /manager, /host-manager and /examples/async*). No broken links found, except links to JavaDocs. - Smoke tests of BIO, NIO and APR, with and without TLS, all passed. - Tested with several webapps that are in active development. -Ognjen - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
[Bug 56546] New: Improve thread trace logging in WebappClassLoader.clearReferencesThreads()
https://issues.apache.org/bugzilla/show_bug.cgi?id=56546 Bug ID: 56546 Summary: Improve thread trace logging in WebappClassLoader.clearReferencesThreads() Product: Tomcat 8 Version: 8.0.5 Hardware: PC Status: NEW Severity: normal Priority: P2 Component: Catalina Assignee: dev@tomcat.apache.org Reporter: knst.koli...@gmail.com In r1574508 I added to Tomcat 8 the feature that when WebappClassLoader.clearReferencesThreads() detects a still-running thread in a web application, it prints not only a textual message, but also stacktrace of the problematic thread. This feature is released in 8.0.5 (8.0.4 onwards). In Comment 3 of BZ 56399 Remy raises the issue that this feature is too noisy. https://issues.apache.org/bugzilla/show_bug.cgi?id=56399#c3 For reference, the following test cases in tomcat 8.0.8 RC print this message: org.apache.catalina.connector.TestMaxConnections org.apache.catalina.loader.TestWebappClassLoaderExecutorMemoryLeak org.apache.tomcat.websocket.TestWsWebSocketContainer -- 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 56545] Examples app security exceptions
https://issues.apache.org/bugzilla/show_bug.cgi?id=56545 Mark Thomas changed: What|Removed |Added Version|8.0.5 |8.0.8 Summary|Examples app security |Examples app security |exceptions (8.0.8 release |exceptions |candidate) | --- Comment #5 from Mark Thomas --- Update version now I have added 8.0.8 to the list of versions for 8.0.x -- 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 56546] Improve thread trace logging in WebappClassLoader.clearReferencesThreads()
https://issues.apache.org/bugzilla/show_bug.cgi?id=56546 Konstantin Kolinko changed: What|Removed |Added OS||All --- Comment #1 from Konstantin Kolinko --- Possible ways to improve this: A. Reduce the log level for stack trace message from log.error() to log.info(). In the current code there are two "log.error()" messages at once, which looks like overkill. > log.error(sm.getString("webappClassLoader.warnThread", > getContextName(), threadName)); > log.error(sm.getString("webappClassLoader.stackTrace", > threadName, getStackTrace(thread))); B. Make this an opt-in feature. A new property on ? Or two properties, to distinct handling of "request threads" vs. "non-request" threads. C. Merge similar logs into a single message? (E.g. if there are many request threads that are stuck in the same place). I think "A." is a good and easy way to go. Any additional ideas, concerns? -- 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: r1596081 - /tomcat/trunk/test/org/apache/catalina/valves/TestStuckThreadDetectionValve.java
Author: kkolinko Date: Mon May 19 22:20:11 2014 New Revision: 1596081 URL: http://svn.apache.org/r1596081 Log: svn:eol-style=native Modified: tomcat/trunk/test/org/apache/catalina/valves/TestStuckThreadDetectionValve.java (props changed) Propchange: tomcat/trunk/test/org/apache/catalina/valves/TestStuckThreadDetectionValve.java -- svn:eol-style = native - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
svn commit: r1596084 - in /tomcat/tc7.0.x/trunk: ./ test/org/apache/catalina/valves/TestStuckThreadDetectionValve.java
Author: kkolinko Date: Mon May 19 22:22:30 2014 New Revision: 1596084 URL: http://svn.apache.org/r1596084 Log: svn:eol-style=native It is a merge of r1596081 from tomcat/trunk. Modified: tomcat/tc7.0.x/trunk/ (props changed) tomcat/tc7.0.x/trunk/test/org/apache/catalina/valves/TestStuckThreadDetectionValve.java (props changed) Propchange: tomcat/tc7.0.x/trunk/ -- Merged /tomcat/trunk:r1596081 Propchange: tomcat/tc7.0.x/trunk/test/org/apache/catalina/valves/TestStuckThreadDetectionValve.java -- svn:eol-style = native - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
svn commit: r1596088 - /tomcat/trunk/webapps/docs/changelog.xml
Author: kkolinko Date: Mon May 19 22:38:47 2014 New Revision: 1596088 URL: http://svn.apache.org/r1596088 Log: Correct indent Modified: tomcat/trunk/webapps/docs/changelog.xml Modified: tomcat/trunk/webapps/docs/changelog.xml URL: http://svn.apache.org/viewvc/tomcat/trunk/webapps/docs/changelog.xml?rev=1596088&r1=1596087&r2=1596088&view=diff == --- tomcat/trunk/webapps/docs/changelog.xml (original) +++ tomcat/trunk/webapps/docs/changelog.xml Mon May 19 22:38:47 2014 @@ -47,12 +47,12 @@ - - 56387: Improve the code that handles an attempt to load a - class after a web application has been stopped. Use common code to handle - this case regardless of the access path and don't throw an exception - purely to log a stack trace. (markt) - + +56387: Improve the code that handles an attempt to load a +class after a web application has been stopped. Use common code to handle +this case regardless of the access path and don't throw an exception +purely to log a stack trace. (markt) + 56399: Improve implementation of CoyoteAdapter.checkRecycled() to do not use an exception for flow control. (kkolinko) - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
svn commit: r1596090 - in /tomcat/trunk: java/org/apache/catalina/loader/WebappClassLoader.java webapps/docs/changelog.xml
Author: kkolinko Date: Mon May 19 22:44:26 2014 New Revision: 1596090 URL: http://svn.apache.org/r1596090 Log: Fix https://issues.apache.org/bugzilla/show_bug.cgi?id=56546 Reduce logging level for stack traces from SEVERE to INFO. Modified: tomcat/trunk/java/org/apache/catalina/loader/WebappClassLoader.java tomcat/trunk/webapps/docs/changelog.xml Modified: tomcat/trunk/java/org/apache/catalina/loader/WebappClassLoader.java URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/catalina/loader/WebappClassLoader.java?rev=1596090&r1=1596089&r2=1596090&view=diff == --- tomcat/trunk/java/org/apache/catalina/loader/WebappClassLoader.java (original) +++ tomcat/trunk/java/org/apache/catalina/loader/WebappClassLoader.java Mon May 19 22:44:26 2014 @@ -1822,12 +1822,12 @@ public class WebappClassLoader extends U if (isRequestThread(thread)) { log.error(sm.getString("webappClassLoader.warnRequestThread", getContextName(), threadName)); - log.error(sm.getString("webappClassLoader.stackTraceRequestThread", + log.info(sm.getString("webappClassLoader.stackTraceRequestThread", threadName, getStackTrace(thread))); } else { log.error(sm.getString("webappClassLoader.warnThread", getContextName(), threadName)); -log.error(sm.getString("webappClassLoader.stackTrace", +log.info(sm.getString("webappClassLoader.stackTrace", threadName, getStackTrace(thread))); } Modified: tomcat/trunk/webapps/docs/changelog.xml URL: http://svn.apache.org/viewvc/tomcat/trunk/webapps/docs/changelog.xml?rev=1596090&r1=1596089&r2=1596090&view=diff == --- tomcat/trunk/webapps/docs/changelog.xml (original) +++ tomcat/trunk/webapps/docs/changelog.xml Mon May 19 22:44:26 2014 @@ -67,6 +67,11 @@ optionally interrupt stuck threads to attempt to unblock them. (slaurent) + +56546: Reduce logging level for stack traces of stuck web +application threads printed by WebappClassLoader.clearReferencesThreads() +from error to info. (kkolinko) + - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
[Bug 56399] Re-factor request/response recycling so Coyote and Catalina objects are recycled simultaneously
https://issues.apache.org/bugzilla/show_bug.cgi?id=56399 --- Comment #8 from Konstantin Kolinko --- (In reply to Remy Maucherat from comment #3) > > Another related topic: the amount of > WebappClassLoader.clearReferencesThreads logging that happens running the > testsuite. This feature is a good idea, but with a lot of noise. I filed that as a separate issue: https://issues.apache.org/bugzilla/show_bug.cgi?id=56546 -- 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 56546] Improve thread trace logging in WebappClassLoader.clearReferencesThreads()
https://issues.apache.org/bugzilla/show_bug.cgi?id=56546 --- Comment #2 from Konstantin Kolinko --- I applied "A." in r1596090. D. Running org.apache.catalina.loader.TestWebappClassLoaderExecutorMemoryLeak, I think it will be more readable, if all the stack traces are printed at once, as 20-May-2014 hh:mm:ss.sss INFO [threadname] org.apache.catalina.loader.WebappClassLoader.clearReferencesThreads Stack traces of threads for web application [/foo]: Thread "name": stacktrace Thread "name": stacktrace Threads "name": stacktrace -- You are receiving this mail because: You are the assignee for the bug. - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
Re: [VOTE] Release Apache Tomcat 6.0.41
2014-05-19 16:58 GMT+04:00 Mark Thomas : > The proposed Apache Tomcat 6.0.41 release candidate is now available > for voting. > > The main changes since 6.0.40 are: > - Fix BZ 56529 > > The main changes since 6.0.39 are: > - Add support for using ecj-P20140317-1600.jar to use Java 8 syntax in > JSPs > - Update native library to 1.1.30 > - Various improvements to XML processing > > along with a number of bug fixes. Full details are in the change log. > > It can be obtained from: > https://dist.apache.org/repos/dist/dev/tomcat/tomcat-6/v6.0.41/ > The Maven staging repo is: > https://repository.apache.org/content/repositories/orgapachetomcat-1014/ > The svn tag is: > http://svn.apache.org/repos/asf/tomcat/tc6.0.x/tags/TOMCAT_6_0_41 The proposed 6.0.41 release is: [ ] Broken - do not release [x] Stable - go ahead and release as 6.0.41 Stable 1. Please upload the *.asc files. They are missing. Smoke testing with security manager enabled - OK (bio, nio, apr) with JDK 5u20 32-bit, Win7. No issues noted. Best regards, Konstantin Kolinko - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org
buildbot success in ASF Buildbot on tomcat-trunk
The Buildbot has detected a restored build on builder tomcat-trunk while building ASF Buildbot. Full details are available at: http://ci.apache.org/builders/tomcat-trunk/builds/91 Buildbot URL: http://ci.apache.org/ Buildslave for this Build: bb-vm_ubuntu Build Reason: scheduler Build Source Stamp: [branch tomcat/trunk] 1596090 Blamelist: kkolinko,markt Build succeeded! sincerely, -The Buildbot - To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org