svn commit: r1492105 - in /tomcat/sandbox: storeconfig6/trunk/src/main/resources/org/apache/catalina/storeconfig/ storeconfig7/trunk/src/main/resources/org/apache/catalina/storeconfig/

2013-06-12 Thread remm
Author: remm
Date: Wed Jun 12 08:06:20 2013
New Revision: 1492105

URL: http://svn.apache.org/r1492105
Log:
Fix type

Modified:

tomcat/sandbox/storeconfig6/trunk/src/main/resources/org/apache/catalina/storeconfig/mbeans-descriptors.xml
   (props changed)

tomcat/sandbox/storeconfig6/trunk/src/main/resources/org/apache/catalina/storeconfig/server-registry.xml
   (props changed)

tomcat/sandbox/storeconfig7/trunk/src/main/resources/org/apache/catalina/storeconfig/mbeans-descriptors.xml
   (props changed)

tomcat/sandbox/storeconfig7/trunk/src/main/resources/org/apache/catalina/storeconfig/server-registry.xml
   (props changed)

Propchange: 
tomcat/sandbox/storeconfig6/trunk/src/main/resources/org/apache/catalina/storeconfig/mbeans-descriptors.xml
--
--- svn:mime-type (original)
+++ svn:mime-type Wed Jun 12 08:06:20 2013
@@ -1 +1 @@
-application/xml
+text/xml

Propchange: 
tomcat/sandbox/storeconfig6/trunk/src/main/resources/org/apache/catalina/storeconfig/server-registry.xml
--
--- svn:mime-type (original)
+++ svn:mime-type Wed Jun 12 08:06:20 2013
@@ -1 +1 @@
-application/xml
+text/xml

Propchange: 
tomcat/sandbox/storeconfig7/trunk/src/main/resources/org/apache/catalina/storeconfig/mbeans-descriptors.xml
--
--- svn:mime-type (original)
+++ svn:mime-type Wed Jun 12 08:06:20 2013
@@ -1 +1 @@
-application/xml
+text/xml

Propchange: 
tomcat/sandbox/storeconfig7/trunk/src/main/resources/org/apache/catalina/storeconfig/server-registry.xml
--
--- svn:mime-type (original)
+++ svn:mime-type Wed Jun 12 08:06:20 2013
@@ -1 +1 @@
-application/xml
+text/xml



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



svn commit: r1492130 - /tomcat/trunk/test/org/apache/catalina/nonblocking/TestNonBlockingAPI.java

2013-06-12 Thread markt
Author: markt
Date: Wed Jun 12 10:07:18 2013
New Revision: 1492130

URL: http://svn.apache.org/r1492130
Log:
Re-write client to provide greater insight into why an invalid chunk is 
invalid. This helped track down the non-blocking write issues with the 
APR/native connector.

Modified:
tomcat/trunk/test/org/apache/catalina/nonblocking/TestNonBlockingAPI.java

Modified: 
tomcat/trunk/test/org/apache/catalina/nonblocking/TestNonBlockingAPI.java
URL: 
http://svn.apache.org/viewvc/tomcat/trunk/test/org/apache/catalina/nonblocking/TestNonBlockingAPI.java?rev=1492130&r1=1492129&r2=1492130&view=diff
==
--- tomcat/trunk/test/org/apache/catalina/nonblocking/TestNonBlockingAPI.java 
(original)
+++ tomcat/trunk/test/org/apache/catalina/nonblocking/TestNonBlockingAPI.java 
Wed Jun 12 10:07:18 2013
@@ -17,14 +17,16 @@
 package org.apache.catalina.nonblocking;
 
 import java.io.IOException;
+import java.io.InputStream;
 import java.io.OutputStream;
 import java.net.HttpURLConnection;
+import java.net.Socket;
 import java.net.URL;
-import java.util.Arrays;
 import java.util.HashMap;
 import java.util.List;
 import java.util.Map;
 
+import javax.net.SocketFactory;
 import javax.servlet.AsyncContext;
 import javax.servlet.AsyncEvent;
 import javax.servlet.AsyncListener;
@@ -45,13 +47,24 @@ import org.apache.catalina.startup.Bytes
 import org.apache.catalina.startup.TesterServlet;
 import org.apache.catalina.startup.Tomcat;
 import org.apache.catalina.startup.TomcatBaseTest;
+import org.apache.tomcat.util.buf.B2CConverter;
 import org.apache.tomcat.util.buf.ByteChunk;
 import org.apache.tomcat.util.buf.ByteChunk.ByteOutputChannel;
 
 public class TestNonBlockingAPI extends TomcatBaseTest {
 
-public static final long bytesToDownload = 1024 * 1024 * 5;
+private static final byte[] CHUNK = new byte[1024 * 1024];
+private static final long WRITE_SIZE  = CHUNK.length * 5;
 
+static {
+byte[] seq = new byte[] {'0', '1', '2', '3', '4', '5', '6', '7',
+'8', '9', 'A', 'B', 'C', 'D', 'E', 'F'};
+int i = 0;
+while (i < CHUNK.length) {
+System.arraycopy(seq, 0, CHUNK, i, 16);
+i += 16;
+}
+}
 
 @Test
 public void testNonBlockingRead() throws Exception {
@@ -89,40 +102,104 @@ public class TestNonBlockingAPI extends 
 tomcat.getConnector().setProperty("socket.txBufSize", "1024");
 tomcat.start();
 
-Map> resHeaders = new HashMap<>();
-ByteChunk slowReader = new ByteChunk();
-slowReader.setLimit(1); // FIXME BUFFER IS BROKEN, 0 doesn't work
-slowReader.setByteOutputChannel(new ByteOutputChannel() {
-long counter = 0;
-long delta = 0;
+SocketFactory factory = SocketFactory.getDefault();
+Socket s = factory.createSocket("localhost", getPort());
 
-@Override
-public void realWriteBytes(byte[] cbuf, int off, int len) throws 
IOException {
-try {
-if (len == 0)
-return;
-counter += len;
-delta += len;
-if (counter > bytesToDownload) {
-System.out.println("ERROR Downloaded more than 
expected ERROR");
-} else if (counter == bytesToDownload) {
-System.out.println("Download complete(" + 
bytesToDownload + " bytes)");
-// } else if (counter > (1966086)) {
-// System.out.println("Download almost complete, 
missing bytes ("+counter+")");
-} else if (delta > (bytesToDownload / 16)) {
-System.out.println("Read " + counter + " bytes.");
-delta = 0;
-Thread.sleep(500);
-}
-} catch (Exception x) {
-throw new IOException(x);
+ByteChunk result = new ByteChunk();
+OutputStream os = s.getOutputStream();
+os.write(("GET / HTTP/1.1\r\n" +
+"Host: localhost:" + getPort() + "\r\n" +
+"Connection: close\r\n" +
+"\r\n").getBytes(B2CConverter.ISO_8859_1));
+os.flush();
+
+InputStream is = s.getInputStream();
+byte[] buffer = new byte[8192];
+
+int read = 0;
+int readSinceLastPause = 0;
+while (read != -1) {
+read = is.read(buffer);
+if (read > 0) {
+result.append(buffer, 0, read);
+}
+readSinceLastPause += read;
+if (readSinceLastPause > WRITE_SIZE / 16) {
+readSinceLastPause = 0;
+Thread.sleep(500);
+}
+}
+
+os.close();
+is.close();
+s.close();
+
+// Validate the result.
+// Response line
+String resultString 

Re: svn commit: r1491976 - /tomcat/trunk/java/javax/servlet/ServletRequest.java

2013-06-12 Thread Mark Thomas
On 11/06/2013 23:49, Konstantin Kolinko wrote:
> This was for setAttribute(), removeAttribute().
> 
> 1. There is also documentation for getAttribute().

I'll fix that shortly.

> 2. There is also documentation for similar methods in ServletContext.

I'm working my way through the Servlet 3.1 spec and will get to those
soon (hopefully)

> 3. I suspect that only sun/oracle prefixes are reserved "for use by oracle"
> (Reading Servlet 3.0, java.*, javax.* are reserved in general. Only
> sun/com.sun prefixes were reserved specifically by Sun).

Correct. I'll fix the text.

Mark



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



svn commit: r1492133 - /tomcat/trunk/java/javax/servlet/ServletRequest.java

2013-06-12 Thread markt
Author: markt
Date: Wed Jun 12 10:15:49 2013
New Revision: 1492133

URL: http://svn.apache.org/r1492133
Log:
Fix javadoc.
- spec reserves java.* and java.*
- needed to update getAttribute() too
- add missing '>'

Modified:
tomcat/trunk/java/javax/servlet/ServletRequest.java

Modified: tomcat/trunk/java/javax/servlet/ServletRequest.java
URL: 
http://svn.apache.org/viewvc/tomcat/trunk/java/javax/servlet/ServletRequest.java?rev=1492133&r1=1492132&r2=1492133&view=diff
==
--- tomcat/trunk/java/javax/servlet/ServletRequest.java (original)
+++ tomcat/trunk/java/javax/servlet/ServletRequest.java Wed Jun 12 10:15:49 2013
@@ -52,9 +52,11 @@ public interface ServletRequest {
  * This allows information to be embedded into a request before a
  * {@link RequestDispatcher} call.
  * 
- * Attribute names should follow the same conventions as package names. 
This
- * specification reserves names matching java.*,
- * javax.*, and sun.*.
+ * Attribute names should follow the same conventions as package names.
+ * Names beginning with java.* and javax.* are
+ * reserved for use by the Servlet specification. Names beginning with
+ * sun.*, com.sun.*, oracle.* and
+ * com.oracle.*) are reserved for use by Oracle Corporation.
  *
  * @param name
  *a String specifying the name of the attribute
@@ -299,9 +301,11 @@ public interface ServletRequest {
  * {@link RequestDispatcher}.
  * 
  * Attribute names should follow the same conventions as package names.
- * Names beginning with java.*, javax.*,
+ * Names beginning with java.* and javax.* are
+ * reserved for use by the Servlet specification. Names beginning with
  * sun.*, com.sun.*, oracle.* and
- * com.oracle.*
+ * com.oracle.*) are reserved for use by Oracle Corporation.
+ * 
  * If the object passed in is null, the effect is the same as calling
  * {@link #removeAttribute}. 
  * It is warned that when the request is dispatched from the servlet 
resides
@@ -322,9 +326,10 @@ public interface ServletRequest {
  * handled.
  * 
  * Attribute names should follow the same conventions as package names.
- * Names beginning with java.*, javax.*,
+ * Names beginning with java.* and javax.* are
+ * reserved for use by the Servlet specification. Names beginning with
  * sun.*, com.sun.*, oracle.* and
- * com.oracle.*com.oracle.*) are reserved for use by Oracle Corporation.
  *
  * @param name
  *a String specifying the name of the attribute to



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



svn commit: r1492136 - in /tomcat/trunk/java/javax/servlet: ReadListener.java ServletInputStream.java

2013-06-12 Thread markt
Author: markt
Date: Wed Jun 12 10:31:29 2013
New Revision: 1492136

URL: http://svn.apache.org/r1492136
Log:
Add some Javadoc for non-blocking IO on the request.

Modified:
tomcat/trunk/java/javax/servlet/ReadListener.java
tomcat/trunk/java/javax/servlet/ServletInputStream.java

Modified: tomcat/trunk/java/javax/servlet/ReadListener.java
URL: 
http://svn.apache.org/viewvc/tomcat/trunk/java/javax/servlet/ReadListener.java?rev=1492136&r1=1492135&r2=1492136&view=diff
==
--- tomcat/trunk/java/javax/servlet/ReadListener.java (original)
+++ tomcat/trunk/java/javax/servlet/ReadListener.java Wed Jun 12 10:31:29 2013
@@ -19,11 +19,34 @@ package javax.servlet;
 import java.io.IOException;
 
 /**
- * TODO SERVLET 3.1
+ * Receives notification of read events when using the non-blocking IO.
  *
+ * @since Servlet 3.1
  */
 public interface ReadListener extends java.util.EventListener{
+
+/**
+ * Invoked when data is available to read. The container will invoke this
+ * method the first time for a request as soon as there is data to read.
+ * Subsequent invocations will only if a call to
+ * {@link ServletInputStream#isReady()} has returned false and data has
+ * subsequently become available to read.
+ *
+ * @throws IOException
+ */
 public abstract void onDataAvailable() throws IOException;
+
+/**
+ * Invoked when the request bdy has been fully read.
+ *
+ * @throws IOException
+ */
 public abstract void onAllDataRead() throws IOException;
+
+/**
+ * Invoked if an error occurs while reading the request body.
+ *
+ * @param throwable The exception that occurred
+ */
 public abstract void onError(java.lang.Throwable throwable);
 }

Modified: tomcat/trunk/java/javax/servlet/ServletInputStream.java
URL: 
http://svn.apache.org/viewvc/tomcat/trunk/java/javax/servlet/ServletInputStream.java?rev=1492136&r1=1492135&r2=1492136&view=diff
==
--- tomcat/trunk/java/javax/servlet/ServletInputStream.java (original)
+++ tomcat/trunk/java/javax/servlet/ServletInputStream.java Wed Jun 12 10:31:29 
2013
@@ -85,6 +85,8 @@ public abstract class ServletInputStream
 /**
  * Returns true if all the data has been read from the stream,
  * else false.
+ *
+ * @since Servlet 3.1
  */
 public abstract boolean isFinished();
 
@@ -93,6 +95,8 @@ public abstract class ServletInputStream
  * false. If this method is called and returns false, the
  * container will invoke {@link ReadListener#onDataAvailable()} when data 
is
  * available.
+ *
+ * @since Servlet 3.1
  */
 public abstract boolean isReady();
 
@@ -108,6 +112,8 @@ public abstract class ServletInputStream
  *  if the {@link ReadListener} has already
  *  been set
  * @throws NullPointerException If listener is null
+ *
+ * @since Servlet 3.1
  */
 public abstract void setReadListener(ReadListener listener);
 }



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



svn commit: r1492167 - /tomcat/trunk/java/org/apache/catalina/tribes/group/interceptors/TcpFailureDetector.java

2013-06-12 Thread markt
Author: markt
Date: Wed Jun 12 12:05:05 2013
New Revision: 1492167

URL: http://svn.apache.org/r1492167
Log:
Fix autoboxing warning

Modified:

tomcat/trunk/java/org/apache/catalina/tribes/group/interceptors/TcpFailureDetector.java

Modified: 
tomcat/trunk/java/org/apache/catalina/tribes/group/interceptors/TcpFailureDetector.java
URL: 
http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/catalina/tribes/group/interceptors/TcpFailureDetector.java?rev=1492167&r1=1492166&r2=1492167&view=diff
==
--- 
tomcat/trunk/java/org/apache/catalina/tribes/group/interceptors/TcpFailureDetector.java
 (original)
+++ 
tomcat/trunk/java/org/apache/catalina/tribes/group/interceptors/TcpFailureDetector.java
 Wed Jun 12 12:05:05 2013
@@ -276,7 +276,7 @@ public class TcpFailureDetector extends 
 } else {
 if (removeSuspectsTimeout > 0) {
 long timeNow = System.currentTimeMillis();
-int timeIdle = (int) ((timeNow - removeSuspects.get(m)) / 
1000L);
+int timeIdle = (int) ((timeNow - 
removeSuspects.get(m).longValue()) / 1000L);
 if (timeIdle > removeSuspectsTimeout) {
 removeSuspects.remove(m); // remove suspect member
 }



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



[Bug 55094] New: the source tar file contains an old version of the docs.

2013-06-12 Thread bugzilla
https://issues.apache.org/bugzilla/show_bug.cgi?id=55094

Bug ID: 55094
   Summary: the source tar file contains an old version of the
docs.
   Product: Tomcat Connectors
   Version: unspecified
  Hardware: PC
OS: Linux
Status: NEW
  Severity: normal
  Priority: P2
 Component: Documentation
  Assignee: dev@tomcat.apache.org
  Reporter: jfcl...@gmail.com

If you look to the index.html of /tomcat-connectors-1.2.37-src/docs/ you get:
14 May 2012 - JK-1.2.36 released
Which is the previous release we should have the current release there may be
without a date and released.

-- 
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



[jira] [Created] (MTOMCAT-227) Can't use slf4j-jcl with tomcat7:run

2013-06-12 Thread Tony Chemit (JIRA)
Tony Chemit created MTOMCAT-227:
---

 Summary: Can't use slf4j-jcl with tomcat7:run
 Key: MTOMCAT-227
 URL: https://issues.apache.org/jira/browse/MTOMCAT-227
 Project: Apache Tomcat Maven Plugin
  Issue Type: Bug
  Components: tomcat7
Affects Versions: 2.1
Reporter: Tony Chemit
Assignee: Olivier Lamy (*$^¨%`£)


I use in my war the slf4j-jcl, which is not compatible with the jcl-over-slf4j 
used in the plugin dependencies.

I give you a little project that show the problem.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

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



[jira] [Updated] (MTOMCAT-227) Can't use slf4j-jcl with tomcat7:run

2013-06-12 Thread Tony Chemit (JIRA)

 [ 
https://issues.apache.org/jira/browse/MTOMCAT-227?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Tony Chemit updated MTOMCAT-227:


Attachment: MTOMCAT-227.tgz

To see the problem just do a 
mvn package

> Can't use slf4j-jcl with tomcat7:run
> 
>
> Key: MTOMCAT-227
> URL: https://issues.apache.org/jira/browse/MTOMCAT-227
> Project: Apache Tomcat Maven Plugin
>  Issue Type: Bug
>  Components: tomcat7
>Affects Versions: 2.1
>Reporter: Tony Chemit
>Assignee: Olivier Lamy (*$^¨%`£)
> Attachments: MTOMCAT-227.tgz
>
>
> I use in my war the slf4j-jcl, which is not compatible with the 
> jcl-over-slf4j used in the plugin dependencies.
> I give you a little project that show the problem.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

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



Re: [Bug 55006] Add http proxy support for ClientEndpoint using system properties

2013-06-12 Thread Christopher Schultz
Niki,

Perhaps you should put some of this discussion into the Bugzilla issue
so it can be tracked more easily by anyone interested in the progress.

-chris

On 6/4/13 1:55 AM, Niki Dokovski wrote:
> On Tue, Jun 4, 2013 at 12:01 AM, Rossen Stoyanchev <
> rstoyanc...@gopivotal.com> wrote:
> 
>> On Mon, Jun 3, 2013 at 10:27 AM, Niki Dokovski  wrote:
>>
>>> On Mon, Jun 3, 2013 at 3:44 PM, Niki Dokovski 
>> wrote:Further
>>> on, if you choose to use connectToServer call that has the
>>> ClientEndpointConfig param you are losing the annotation approach as the
>>> first param of this call has to be an instance of an Endpoint. Hence your
>>> class can not be just annotated. hmmm Mark where can we bring this
>>> discussion?
>>
>>
>> This is not very obvious from the API but ClientEndpointConfig (and
>> ServerEndpointConfig) are not meant to be used with annotated endpoints. In
>> other words, I think the methods accepting those types are for use with
>> type-based endpoints (i.e. javax.websocket.Endpoint). So as far as I can
>> see user properties can be updated before the session starts only for
>> type-based endpoints.
>>
> 
> Exactly, What is the rationale behind this?
> Still an annotated endpoint can supply
> javax.websocket.ClientEndpointConfig.Configurator
> but has no access to the user properties from there. May be the
> javax.websocket.ClientEndpointConfig.Configurator
> can be extended to provide access to the map.
> 
> cheers
> 
> 
>>
>> Rossen
>>
> 



signature.asc
Description: OpenPGP digital signature


[Bug 55095] New: isV0Separator method fail on production environment - IllegalArgumentException : Control character in cookie value or attribute.

2013-06-12 Thread bugzilla
https://issues.apache.org/bugzilla/show_bug.cgi?id=55095

Bug ID: 55095
   Summary: isV0Separator method fail on production environment -
IllegalArgumentException : Control character in cookie
value or attribute.
   Product: Tomcat 7
   Version: 7.0.40
  Hardware: All
OS: Linux
Status: NEW
  Severity: normal
  Priority: P2
 Component: Catalina
  Assignee: dev@tomcat.apache.org
  Reporter: javier.dura...@mercadolibre.com

I'm getting a low percent of requests failed due to an exception in the
org/apache/tomcat/util/http/CookieSupport class.

here is the code section:

   public static final boolean isV0Separator(final char c) {
if (c < 0x20 || c >= 0x7f) {
if (c != 0x09) {
throw new IllegalArgumentException(
"Control character in cookie value or attribute.");
}
}

return V0_SEPARATOR_FLAGS[c];
}

I believe that the problem is in the Cookie class:
org/apache/tomcat/util/http/Cookies, in the "processCookieHeader" method line
340.

I'm using the ALLOW_HTTP_SEPARATORS_IN_V0 flag, but the call to the
isV0Separator method is before that, so it gets the Exception and then it
cannot check the flag.

It is possible to ignore this cookies? They are from a external domain so I
cannot modify then, and I don't want to loose request because of this
validation, I would like to ignore it.

My stacktrace is:

java.lang.IllegalArgumentException: Control character in cookie value or
attribute.
org.apache.tomcat.util.http.CookieSupport.isV0Separator
(CookieSupport.java:153)
org.apache.tomcat.util.http.Cookies.processCookieHeader (Cookies.java:340)
 org.apache.tomcat.util.http.Cookies.processCookies (Cookies.java:168)
 org.apache.tomcat.util.http.Cookies.getCookieCount (Cookies.java:106)
…catalina.connector.CoyoteAdapter.parseSessionCookiesId
(CoyoteAdapter.java:932)
…ache.catalina.connector.CoyoteAdapter.postParseRequest
(CoyoteAdapter.java:689)
org.apache.catalina.connector.CoyoteAdapter.service
(CoyoteAdapter.java:403)
…g.apache.coyote.http11.AbstractHttp11Processor.process
(AbstractHttp11Processor.java:1008)
…ote.AbstractProtocol$AbstractConnectionHandler.process
(AbstractProtocol.java:589)
…apache.tomcat.util.net.JIoEndpoint$SocketProcessor.run (JIoEndpoint.java:310)
 java.util.concurrent.ThreadPoolExecutor$Worker.runTask
(ThreadPoolExecutor.java:886)
 java.util.concurrent.ThreadPoolExecutor$Worker.run
(ThreadPoolExecutor.java:908)
   java.lang.Thread.run (Thread.java:662)

Thanks

-- 
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 55095] isV0Separator method fail on production environment - IllegalArgumentException : Control character in cookie value or attribute.

2013-06-12 Thread bugzilla
https://issues.apache.org/bugzilla/show_bug.cgi?id=55095

Mark Thomas  changed:

   What|Removed |Added

 Status|NEW |RESOLVED
 Resolution|--- |INVALID

--- Comment #1 from Mark Thomas  ---
The HTTP header is not valid and that is before Tomcat even tries to parse it
as a cookie header. There is no way to bypass this check and no such option
will be added because of the potential security issues associated with control
characters in HTTP headers.

-- 
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: r1492331 - in /tomcat/tc7.0.x/trunk: ./ java/javax/servlet/ java/org/apache/catalina/ java/org/apache/catalina/core/ java/org/apache/catalina/deploy/ java/org/apache/catalina/startup/ test

2013-06-12 Thread markt
Author: markt
Date: Wed Jun 12 18:31:30 2013
New Revision: 1492331

URL: http://svn.apache.org/r1492331
Log:
With clarification from the EG for Servlet 3.1 section 4.4 finally makes sense. 
Implement the necessary restriction and add a test case.

Added:

tomcat/tc7.0.x/trunk/java/org/apache/catalina/deploy/ApplicationListener.java
  - copied unchanged from r1492307, 
tomcat/trunk/java/org/apache/catalina/deploy/ApplicationListener.java
tomcat/tc7.0.x/trunk/test/org/apache/catalina/core/TesterTldListener.java
  - copied unchanged from r1492307, 
tomcat/trunk/test/org/apache/catalina/core/TesterTldListener.java
tomcat/tc7.0.x/trunk/test/webapp-3.0/WEB-INF/listener.tld
  - copied unchanged from r1492307, 
tomcat/trunk/test/webapp-3.0/WEB-INF/listener.tld
Modified:
tomcat/tc7.0.x/trunk/   (props changed)
tomcat/tc7.0.x/trunk/java/javax/servlet/ServletContext.java
tomcat/tc7.0.x/trunk/java/org/apache/catalina/Context.java
tomcat/tc7.0.x/trunk/java/org/apache/catalina/core/LocalStrings.properties
tomcat/tc7.0.x/trunk/java/org/apache/catalina/core/StandardContext.java
tomcat/tc7.0.x/trunk/java/org/apache/catalina/deploy/WebXml.java
tomcat/tc7.0.x/trunk/java/org/apache/catalina/startup/FailedContext.java
tomcat/tc7.0.x/trunk/java/org/apache/catalina/startup/TldConfig.java
tomcat/tc7.0.x/trunk/java/org/apache/catalina/startup/WebAnnotationSet.java
tomcat/tc7.0.x/trunk/test/org/apache/catalina/core/TestAsyncContextImpl.java

tomcat/tc7.0.x/trunk/test/org/apache/catalina/core/TestNamingContextListener.java
tomcat/tc7.0.x/trunk/test/org/apache/catalina/core/TestStandardContext.java
tomcat/tc7.0.x/trunk/test/org/apache/catalina/core/TesterContext.java
tomcat/tc7.0.x/trunk/test/org/apache/catalina/startup/TestListener.java

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

Modified: tomcat/tc7.0.x/trunk/java/javax/servlet/ServletContext.java
URL: 
http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/java/javax/servlet/ServletContext.java?rev=1492331&r1=1492330&r2=1492331&view=diff
==
--- tomcat/tc7.0.x/trunk/java/javax/servlet/ServletContext.java (original)
+++ tomcat/tc7.0.x/trunk/java/javax/servlet/ServletContext.java Wed Jun 12 
18:31:30 2013
@@ -105,14 +105,27 @@ public interface ServletContext {
 
 /**
  * @return TODO
- * @throws UnsupportedOperationException
+ * @throws UnsupportedOperationExceptionIf called from a
+ *{@link 
ServletContextListener#contextInitialized(ServletContextEvent)}
+ *method of a {@link ServletContextListener} that was not defined in a
+ *web.xml file, a web-fragment.xml file nor annotated with
+ *{@link javax.servlet.annotation.WebListener}. For example, a
+ *{@link ServletContextListener} defined in a TLD would not be able to
+ *use this method.
+ *
  * @since Servlet 3.0 TODO SERVLET3 - Add comments
  */
 public int getEffectiveMajorVersion();
 
 /**
  * @return TODO
- * @throws UnsupportedOperationException
+ * @throws UnsupportedOperationExceptionIf called from a
+ *{@link 
ServletContextListener#contextInitialized(ServletContextEvent)}
+ *method of a {@link ServletContextListener} that was not defined in a
+ *web.xml file, a web-fragment.xml file nor annotated with
+ *{@link javax.servlet.annotation.WebListener}. For example, a
+ *{@link ServletContextListener} defined in a TLD would not be able to
+ *use this method.
  * @since Servlet 3.0 TODO SERVLET3 - Add comments
  */
 public int getEffectiveMinorVersion();
@@ -429,7 +442,13 @@ public interface ServletContext {
  * @param value
  * @return TODO
  * @throws IllegalStateException
- * @throws UnsupportedOperationException
+ * @throws UnsupportedOperationExceptionIf called from a
+ *{@link 
ServletContextListener#contextInitialized(ServletContextEvent)}
+ *method of a {@link ServletContextListener} that was not defined in a
+ *web.xml file, a web-fragment.xml file nor annotated with
+ *{@link javax.servlet.annotation.WebListener}. For example, a
+ *{@link ServletContextListener} defined in a TLD would not be able to
+ *use this method.
  * @since Servlet 3.0 TODO SERVLET3 - Add comments
  */
 public boolean setInitParameter(String name, String value);
@@ -518,6 +537,13 @@ public interface ServletContext {
  * @return TODO
  * @throws IllegalStateException
  * If the context has already been initialised
+ * @throws UnsupportedOperationExceptionIf called from a
+ *{@link 
ServletContextListener#contextInitialized(ServletContextEvent)}
+ *method of a {@link ServletContextListener} that was not defin

svn commit: r1492336 - in /tomcat/trunk/java/org/apache/catalina: core/StandardContext.java deploy/ApplicationListener.java

2013-06-12 Thread markt
Author: markt
Date: Wed Jun 12 18:34:53 2013
New Revision: 1492336

URL: http://svn.apache.org/r1492336
Log:
Better name

Modified:
tomcat/trunk/java/org/apache/catalina/core/StandardContext.java
tomcat/trunk/java/org/apache/catalina/deploy/ApplicationListener.java

Modified: tomcat/trunk/java/org/apache/catalina/core/StandardContext.java
URL: 
http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/catalina/core/StandardContext.java?rev=1492336&r1=1492335&r2=1492336&view=diff
==
--- tomcat/trunk/java/org/apache/catalina/core/StandardContext.java (original)
+++ tomcat/trunk/java/org/apache/catalina/core/StandardContext.java Wed Jun 12 
18:34:53 2013
@@ -4730,7 +4730,7 @@ public class StandardContext extends Con
 ApplicationListener listener = listeners[i];
 results[i] = instanceManager.newInstance(
 listener.getClassName());
-if (listener.isFromTLD()) {
+if (listener.isAllowedPluggability()) {
 tldListeners.add(results[i]);
 }
 } catch (Throwable t) {
@@ -4792,7 +4792,7 @@ public class StandardContext extends Con
 new ServletContextEvent(getServletContext());
 ServletContextEvent tldEvent = null;
 if (tldListeners.size() > 0) {
-tldEvent = new ServletContextEvent(new TldListenerServletContext(
+tldEvent = new ServletContextEvent(new 
NoPluggabilityServletContext(
 getServletContext()));
 }
 for (int i = 0; i < instances.length; i++) {
@@ -6538,11 +6538,12 @@ public class StandardContext extends Con
 }
 
 
-private static class TldListenerServletContext implements ServletContext {
+private static class NoPluggabilityServletContext
+implements ServletContext {
 
 private final ServletContext sc;
 
-public TldListenerServletContext(ServletContext sc) {
+public NoPluggabilityServletContext(ServletContext sc) {
 this.sc = sc;
 }
 

Modified: tomcat/trunk/java/org/apache/catalina/deploy/ApplicationListener.java
URL: 
http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/catalina/deploy/ApplicationListener.java?rev=1492336&r1=1492335&r2=1492336&view=diff
==
--- tomcat/trunk/java/org/apache/catalina/deploy/ApplicationListener.java 
(original)
+++ tomcat/trunk/java/org/apache/catalina/deploy/ApplicationListener.java Wed 
Jun 12 18:34:53 2013
@@ -23,11 +23,12 @@ package org.apache.catalina.deploy;
 public class ApplicationListener {
 
 private final String className;
-private final boolean fromTLD;
+private final boolean allowedPluggability;
 
-public ApplicationListener(String className, boolean fromTLD) {
+public ApplicationListener(String className,
+boolean allowedPluggability) {
 this.className = className;
-this.fromTLD = fromTLD;
+this.allowedPluggability = allowedPluggability;
 }
 
 
@@ -36,7 +37,7 @@ public class ApplicationListener {
 }
 
 
-public boolean isFromTLD() {
-return fromTLD;
+public boolean isAllowedPluggability() {
+return allowedPluggability;
 }
 }
\ No newline at end of file



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



svn commit: r1492343 - /tomcat/trunk/java/org/apache/catalina/core/ApplicationContext.java

2013-06-12 Thread markt
Author: markt
Date: Wed Jun 12 18:38:51 2013
New Revision: 1492343

URL: http://svn.apache.org/r1492343
Log:
Implemented

Modified:
tomcat/trunk/java/org/apache/catalina/core/ApplicationContext.java

Modified: tomcat/trunk/java/org/apache/catalina/core/ApplicationContext.java
URL: 
http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/catalina/core/ApplicationContext.java?rev=1492343&r1=1492342&r2=1492343&view=diff
==
--- tomcat/trunk/java/org/apache/catalina/core/ApplicationContext.java 
(original)
+++ tomcat/trunk/java/org/apache/catalina/core/ApplicationContext.java Wed Jun 
12 18:38:51 2013
@@ -897,13 +897,6 @@ public class ApplicationContext
 getContextPath()));
 }
 
-// TODO SERVLET3
-// throw UnsupportedOperationException - if this context was passed to 
the
-// {@link 
ServletContextListener#contextInitialized(javax.servlet.ServletContextEvent)}
-// method of a {@link ServletContextListener} that was not declared
-// in web.xml, a web-fragment or annotated with
-// {@link javax.servlet.annotation.WebListener}.
-
 FilterDef filterDef = context.findFilterDef(filterName);
 
 // Assume a 'complete' FilterRegistration is one that has a class and
@@ -1041,13 +1034,6 @@ public class ApplicationContext
 getContextPath()));
 }
 
-// TODO SERVLET3
-// throw UnsupportedOperationException - if this context was passed to 
the
-// {@link 
ServletContextListener#contextInitialized(javax.servlet.ServletContextEvent)}
-// method of a {@link ServletContextListener} that was not declared
-// in web.xml, a web-fragment or annotated with
-// {@link javax.servlet.annotation.WebListener}.
-
 Wrapper wrapper = (Wrapper) context.findChild(servletName);
 
 // Assume a 'complete' ServletRegistration is one that has a class and
@@ -1272,13 +1258,6 @@ public class ApplicationContext
 getContextPath()));
 }
 
-// TODO SERVLET3
-// throw UnsupportedOperationException - if this context was passed to 
the
-// {@link 
ServletContextListener#contextInitialized(javax.servlet.ServletContextEvent)}
-// method of a {@link ServletContextListener} that was not declared
-// in web.xml, a web-fragment or annotated with
-// {@link javax.servlet.annotation.WebListener}.
-
 boolean match = false;
 if (t instanceof ServletContextAttributeListener ||
 t instanceof ServletRequestListener ||



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



svn commit: r1492346 - in /tomcat/tc7.0.x/trunk: ./ java/org/apache/catalina/core/StandardContext.java java/org/apache/catalina/deploy/ApplicationListener.java

2013-06-12 Thread markt
Author: markt
Date: Wed Jun 12 18:40:34 2013
New Revision: 1492346

URL: http://svn.apache.org/r1492346
Log:
Better name

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/deploy/ApplicationListener.java

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

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=1492346&r1=1492345&r2=1492346&view=diff
==
--- tomcat/tc7.0.x/trunk/java/org/apache/catalina/core/StandardContext.java 
(original)
+++ tomcat/tc7.0.x/trunk/java/org/apache/catalina/core/StandardContext.java Wed 
Jun 12 18:40:34 2013
@@ -4836,7 +4836,7 @@ public class StandardContext extends Con
 ApplicationListener listener = listeners[i];
 results[i] = instanceManager.newInstance(
 listener.getClassName());
-if (listener.isFromTLD()) {
+if (listener.isAllowedPluggability()) {
 tldListeners.add(results[i]);
 }
 } catch (Throwable t) {
@@ -4897,7 +4897,7 @@ public class StandardContext extends Con
 new ServletContextEvent(getServletContext());
 ServletContextEvent tldEvent = null;
 if (tldListeners.size() > 0) {
-tldEvent = new ServletContextEvent(new TldListenerServletContext(
+tldEvent = new ServletContextEvent(new 
NoPluggabilityServletContext(
 getServletContext()));
 }
 for (int i = 0; i < instances.length; i++) {
@@ -6719,11 +6719,12 @@ public class StandardContext extends Con
 }
 
 
-private static class TldListenerServletContext implements ServletContext {
+private static class NoPluggabilityServletContext
+implements ServletContext {
 
 private final ServletContext sc;
 
-public TldListenerServletContext(ServletContext sc) {
+public NoPluggabilityServletContext(ServletContext sc) {
 this.sc = sc;
 }
 

Modified: 
tomcat/tc7.0.x/trunk/java/org/apache/catalina/deploy/ApplicationListener.java
URL: 
http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/java/org/apache/catalina/deploy/ApplicationListener.java?rev=1492346&r1=1492345&r2=1492346&view=diff
==
--- 
tomcat/tc7.0.x/trunk/java/org/apache/catalina/deploy/ApplicationListener.java 
(original)
+++ 
tomcat/tc7.0.x/trunk/java/org/apache/catalina/deploy/ApplicationListener.java 
Wed Jun 12 18:40:34 2013
@@ -23,11 +23,12 @@ package org.apache.catalina.deploy;
 public class ApplicationListener {
 
 private final String className;
-private final boolean fromTLD;
+private final boolean allowedPluggability;
 
-public ApplicationListener(String className, boolean fromTLD) {
+public ApplicationListener(String className,
+boolean allowedPluggability) {
 this.className = className;
-this.fromTLD = fromTLD;
+this.allowedPluggability = allowedPluggability;
 }
 
 
@@ -36,7 +37,7 @@ public class ApplicationListener {
 }
 
 
-public boolean isFromTLD() {
-return fromTLD;
+public boolean isAllowedPluggability() {
+return allowedPluggability;
 }
 }
\ No newline at end of file



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



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

2013-06-12 Thread markt
Author: markt
Date: Wed Jun 12 18:42:03 2013
New Revision: 1492348

URL: http://svn.apache.org/r1492348
Log:
Implemented

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

Modified: 
tomcat/tc7.0.x/trunk/java/org/apache/catalina/core/ApplicationContext.java
URL: 
http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/java/org/apache/catalina/core/ApplicationContext.java?rev=1492348&r1=1492347&r2=1492348&view=diff
==
--- tomcat/tc7.0.x/trunk/java/org/apache/catalina/core/ApplicationContext.java 
(original)
+++ tomcat/tc7.0.x/trunk/java/org/apache/catalina/core/ApplicationContext.java 
Wed Jun 12 18:42:03 2013
@@ -956,13 +956,6 @@ public class ApplicationContext
 getContextPath()));
 }
 
-// TODO SERVLET3
-// throw UnsupportedOperationException - if this context was passed to 
the
-// {@link 
ServletContextListener#contextInitialized(javax.servlet.ServletContextEvent)}
-// method of a {@link ServletContextListener} that was not declared
-// in web.xml, a web-fragment or annotated with
-// {@link javax.servlet.annotation.WebListener}.
-
 FilterDef filterDef = context.findFilterDef(filterName);
 
 // Assume a 'complete' FilterRegistration is one that has a class and
@@ -1101,13 +1094,6 @@ public class ApplicationContext
 getContextPath()));
 }
 
-// TODO SERVLET3
-// throw UnsupportedOperationException - if this context was passed to 
the
-// {@link 
ServletContextListener#contextInitialized(javax.servlet.ServletContextEvent)}
-// method of a {@link ServletContextListener} that was not declared
-// in web.xml, a web-fragment or annotated with
-// {@link javax.servlet.annotation.WebListener}.
-
 Wrapper wrapper = (Wrapper) context.findChild(servletName);
 
 // Assume a 'complete' ServletRegistration is one that has a class and
@@ -1333,13 +1319,6 @@ public class ApplicationContext
 getContextPath()));
 }
 
-// TODO SERVLET3
-// throw UnsupportedOperationException - if this context was passed to 
the
-// {@link 
ServletContextListener#contextInitialized(javax.servlet.ServletContextEvent)}
-// method of a {@link ServletContextListener} that was not declared
-// in web.xml, a web-fragment or annotated with
-// {@link javax.servlet.annotation.WebListener}.
-
 boolean match = false;
 if (t instanceof ServletContextAttributeListener ||
 t instanceof ServletRequestListener ||



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



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

2013-06-12 Thread markt
Author: markt
Date: Wed Jun 12 18:42:31 2013
New Revision: 1492350

URL: http://svn.apache.org/r1492350
Log:
Remove unnecessary warnings

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

Modified: 
tomcat/tc7.0.x/trunk/java/org/apache/catalina/core/ApplicationContext.java
URL: 
http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/java/org/apache/catalina/core/ApplicationContext.java?rev=1492350&r1=1492349&r2=1492350&view=diff
==
--- tomcat/tc7.0.x/trunk/java/org/apache/catalina/core/ApplicationContext.java 
(original)
+++ tomcat/tc7.0.x/trunk/java/org/apache/catalina/core/ApplicationContext.java 
Wed Jun 12 18:42:31 2013
@@ -985,7 +985,6 @@ public class ApplicationContext
 public  T createFilter(Class c)
 throws ServletException {
 try {
-@SuppressWarnings("unchecked")
 T filter = (T) 
context.getInstanceManager().newInstance(c.getName());
 return filter;
 } catch (IllegalAccessException e) {
@@ -1128,7 +1127,6 @@ public class ApplicationContext
 public  T createServlet(Class c)
 throws ServletException {
 try {
-@SuppressWarnings("unchecked")
 T servlet = (T) 
context.getInstanceManager().newInstance(c.getName());
 context.dynamicServletCreated(servlet);
 return servlet;
@@ -1353,7 +1351,6 @@ public class ApplicationContext
 public  T createListener(Class c)
 throws ServletException {
 try {
-@SuppressWarnings("unchecked")
 T listener =
 (T) context.getInstanceManager().newInstance(c.getName());
 if (listener instanceof ServletContextListener ||



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



svn commit: r1492358 - in /tomcat/trunk/java/org/apache/catalina: core/StandardContext.java deploy/ApplicationListener.java

2013-06-12 Thread markt
Author: markt
Date: Wed Jun 12 18:44:57 2013
New Revision: 1492358

URL: http://svn.apache.org/r1492358
Log:
Align name with logic

Modified:
tomcat/trunk/java/org/apache/catalina/core/StandardContext.java
tomcat/trunk/java/org/apache/catalina/deploy/ApplicationListener.java

Modified: tomcat/trunk/java/org/apache/catalina/core/StandardContext.java
URL: 
http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/catalina/core/StandardContext.java?rev=1492358&r1=1492357&r2=1492358&view=diff
==
--- tomcat/trunk/java/org/apache/catalina/core/StandardContext.java (original)
+++ tomcat/trunk/java/org/apache/catalina/core/StandardContext.java Wed Jun 12 
18:44:57 2013
@@ -4730,7 +4730,7 @@ public class StandardContext extends Con
 ApplicationListener listener = listeners[i];
 results[i] = instanceManager.newInstance(
 listener.getClassName());
-if (listener.isAllowedPluggability()) {
+if (listener.isPluggabilityBlocked()) {
 tldListeners.add(results[i]);
 }
 } catch (Throwable t) {

Modified: tomcat/trunk/java/org/apache/catalina/deploy/ApplicationListener.java
URL: 
http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/catalina/deploy/ApplicationListener.java?rev=1492358&r1=1492357&r2=1492358&view=diff
==
--- tomcat/trunk/java/org/apache/catalina/deploy/ApplicationListener.java 
(original)
+++ tomcat/trunk/java/org/apache/catalina/deploy/ApplicationListener.java Wed 
Jun 12 18:44:57 2013
@@ -23,12 +23,12 @@ package org.apache.catalina.deploy;
 public class ApplicationListener {
 
 private final String className;
-private final boolean allowedPluggability;
+private final boolean pluggabilityBlocked;
 
 public ApplicationListener(String className,
-boolean allowedPluggability) {
+boolean pluggabilityBlocked) {
 this.className = className;
-this.allowedPluggability = allowedPluggability;
+this.pluggabilityBlocked = pluggabilityBlocked;
 }
 
 
@@ -37,7 +37,7 @@ public class ApplicationListener {
 }
 
 
-public boolean isAllowedPluggability() {
-return allowedPluggability;
+public boolean isPluggabilityBlocked() {
+return pluggabilityBlocked;
 }
 }
\ No newline at end of file



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



svn commit: r1492359 - in /tomcat/tc7.0.x/trunk: ./ java/org/apache/catalina/core/StandardContext.java java/org/apache/catalina/deploy/ApplicationListener.java

2013-06-12 Thread markt
Author: markt
Date: Wed Jun 12 18:45:29 2013
New Revision: 1492359

URL: http://svn.apache.org/r1492359
Log:
Align name with logic

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/deploy/ApplicationListener.java

Propchange: tomcat/tc7.0.x/trunk/
--
  Merged /tomcat/trunk:r1492343,1492358

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=1492359&r1=1492358&r2=1492359&view=diff
==
--- tomcat/tc7.0.x/trunk/java/org/apache/catalina/core/StandardContext.java 
(original)
+++ tomcat/tc7.0.x/trunk/java/org/apache/catalina/core/StandardContext.java Wed 
Jun 12 18:45:29 2013
@@ -4836,7 +4836,7 @@ public class StandardContext extends Con
 ApplicationListener listener = listeners[i];
 results[i] = instanceManager.newInstance(
 listener.getClassName());
-if (listener.isAllowedPluggability()) {
+if (listener.isPluggabilityBlocked()) {
 tldListeners.add(results[i]);
 }
 } catch (Throwable t) {

Modified: 
tomcat/tc7.0.x/trunk/java/org/apache/catalina/deploy/ApplicationListener.java
URL: 
http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/java/org/apache/catalina/deploy/ApplicationListener.java?rev=1492359&r1=1492358&r2=1492359&view=diff
==
--- 
tomcat/tc7.0.x/trunk/java/org/apache/catalina/deploy/ApplicationListener.java 
(original)
+++ 
tomcat/tc7.0.x/trunk/java/org/apache/catalina/deploy/ApplicationListener.java 
Wed Jun 12 18:45:29 2013
@@ -23,12 +23,12 @@ package org.apache.catalina.deploy;
 public class ApplicationListener {
 
 private final String className;
-private final boolean allowedPluggability;
+private final boolean pluggabilityBlocked;
 
 public ApplicationListener(String className,
-boolean allowedPluggability) {
+boolean pluggabilityBlocked) {
 this.className = className;
-this.allowedPluggability = allowedPluggability;
+this.pluggabilityBlocked = pluggabilityBlocked;
 }
 
 
@@ -37,7 +37,7 @@ public class ApplicationListener {
 }
 
 
-public boolean isAllowedPluggability() {
-return allowedPluggability;
+public boolean isPluggabilityBlocked() {
+return pluggabilityBlocked;
 }
 }
\ No newline at end of file



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



svn commit: r1492382 - /tomcat/trunk/java/javax/servlet/annotation/WebListener.java

2013-06-12 Thread markt
Author: markt
Date: Wed Jun 12 19:18:05 2013
New Revision: 1492382

URL: http://svn.apache.org/r1492382
Log:
Add additional listener type for 3.1

Modified:
tomcat/trunk/java/javax/servlet/annotation/WebListener.java

Modified: tomcat/trunk/java/javax/servlet/annotation/WebListener.java
URL: 
http://svn.apache.org/viewvc/tomcat/trunk/java/javax/servlet/annotation/WebListener.java?rev=1492382&r1=1492381&r2=1492382&view=diff
==
--- tomcat/trunk/java/javax/servlet/annotation/WebListener.java (original)
+++ tomcat/trunk/java/javax/servlet/annotation/WebListener.java Wed Jun 12 
19:18:05 2013
@@ -33,7 +33,8 @@ import java.lang.annotation.Target;
  * {@link javax.servlet.ServletContextAttributeListener},
  * {@link javax.servlet.ServletContextListener},
  * {@link javax.servlet.ServletRequestAttributeListener},
- * {@link javax.servlet.ServletRequestListener} 
+ * {@link javax.servlet.ServletRequestListener} or
+ * {@link javax.servlet.http.HttpSessionIdListener}
  * 
  *
  * E.g. @WebListener



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



buildbot failure in ASF Buildbot on tomcat-7-trunk

2013-06-12 Thread buildbot
The Buildbot has detected a new failure on builder tomcat-7-trunk while 
building ASF Buildbot.
Full details are available at:
 http://ci.apache.org/builders/tomcat-7-trunk/builds/1236

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] 1492331
Blamelist: markt

BUILD FAILED: failed compile_1

sincerely,
 -The Buildbot





Re: svn commit: r1492331 - in /tomcat/tc7.0.x/trunk: ./ java/javax/servlet/ java/org/apache/catalina/ java/org/apache/catalina/core/ java/org/apache/catalina/deploy/ java/org/apache/catalina/startup/

2013-06-12 Thread Konstantin Kolinko
2013/6/12  :
> Author: markt
> Date: Wed Jun 12 18:31:30 2013
> New Revision: 1492331
>
> URL: http://svn.apache.org/r1492331
> Log:
> With clarification from the EG for Servlet 3.1 section 4.4 finally makes 
> sense. Implement the necessary restriction and add a test case.
>
> Added:
> 
> tomcat/tc7.0.x/trunk/java/org/apache/catalina/deploy/ApplicationListener.java
>   - copied unchanged from r1492307, 
> tomcat/trunk/java/org/apache/catalina/deploy/ApplicationListener.java
> tomcat/tc7.0.x/trunk/test/org/apache/catalina/core/TesterTldListener.java
>   - copied unchanged from r1492307, 
> tomcat/trunk/test/org/apache/catalina/core/TesterTldListener.java
> tomcat/tc7.0.x/trunk/test/webapp-3.0/WEB-INF/listener.tld
>   - copied unchanged from r1492307, 
> tomcat/trunk/test/webapp-3.0/WEB-INF/listener.tld
> Modified:
> tomcat/tc7.0.x/trunk/   (props changed)
> tomcat/tc7.0.x/trunk/java/javax/servlet/ServletContext.java
> tomcat/tc7.0.x/trunk/java/org/apache/catalina/Context.java
> tomcat/tc7.0.x/trunk/java/org/apache/catalina/core/LocalStrings.properties
> tomcat/tc7.0.x/trunk/java/org/apache/catalina/core/StandardContext.java
> tomcat/tc7.0.x/trunk/java/org/apache/catalina/deploy/WebXml.java
> tomcat/tc7.0.x/trunk/java/org/apache/catalina/startup/FailedContext.java
> tomcat/tc7.0.x/trunk/java/org/apache/catalina/startup/TldConfig.java
> 
> tomcat/tc7.0.x/trunk/java/org/apache/catalina/startup/WebAnnotationSet.java
> 
> tomcat/tc7.0.x/trunk/test/org/apache/catalina/core/TestAsyncContextImpl.java
> 
> tomcat/tc7.0.x/trunk/test/org/apache/catalina/core/TestNamingContextListener.java
> 
> tomcat/tc7.0.x/trunk/test/org/apache/catalina/core/TestStandardContext.java
> tomcat/tc7.0.x/trunk/test/org/apache/catalina/core/TesterContext.java
> tomcat/tc7.0.x/trunk/test/org/apache/catalina/startup/TestListener.java
>

1. Do not forget to update the changelog.

2. Looking at update of javadoc in j.s.ServletContext java,

Why is there restriction for getEffectiveMajorVersion(),
getEffectiveMinorVersion() methods?

They are not used for programmatic configuration of
servlets/filters/listeners and they are not mentioned in Chapter 4.4,
so I think there should not be such restriction on calling them.

3. You changed a method in o.a.c.Context.  We usually add methods
there, but do not change the existing ones.

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: r1492397 - in /tomcat/trunk: ./ java/org/apache/catalina/authenticator/ java/org/apache/catalina/connector/ java/org/apache/catalina/realm/ java/org/apache/jasper/compiler/ java/org/apache

2013-06-12 Thread markt
Author: markt
Date: Wed Jun 12 19:49:56 2013
New Revision: 1492397

URL: http://svn.apache.org/r1492397
Log:
Various version updates:
Servlet 3.0 -> 3.1
JSP 2.2 -> 2.3
EL 2.2 -> 3.0

Modified:
tomcat/trunk/BUILDING.txt
tomcat/trunk/RELEASE-NOTES
tomcat/trunk/build.xml
tomcat/trunk/java/org/apache/catalina/authenticator/FormAuthenticator.java
tomcat/trunk/java/org/apache/catalina/authenticator/package.html
tomcat/trunk/java/org/apache/catalina/connector/CoyoteAdapter.java
tomcat/trunk/java/org/apache/catalina/realm/package.html
tomcat/trunk/java/org/apache/jasper/compiler/Validator.java
tomcat/trunk/java/org/apache/jasper/resources/LocalStrings.properties
tomcat/trunk/java/org/apache/jasper/resources/LocalStrings_es.properties
tomcat/trunk/java/org/apache/jasper/resources/LocalStrings_fr.properties
tomcat/trunk/java/org/apache/jasper/resources/LocalStrings_ja.properties
tomcat/trunk/res/META-INF/el-api.jar.manifest
tomcat/trunk/res/META-INF/jsp-api.jar.manifest
tomcat/trunk/res/META-INF/servlet-api.jar.manifest
tomcat/trunk/test/org/apache/catalina/mapper/TestMapperContextRoot.java
tomcat/trunk/webapps/docs/appdev/deployment.xml
tomcat/trunk/webapps/docs/appdev/introduction.xml
tomcat/trunk/webapps/docs/class-loader-howto.xml
tomcat/trunk/webapps/docs/index.xml
tomcat/trunk/webapps/docs/jasper-howto.xml
tomcat/trunk/webapps/docs/project.xml

Modified: tomcat/trunk/BUILDING.txt
URL: 
http://svn.apache.org/viewvc/tomcat/trunk/BUILDING.txt?rev=1492397&r1=1492396&r2=1492397&view=diff
==
--- tomcat/trunk/BUILDING.txt (original)
+++ tomcat/trunk/BUILDING.txt Wed Jun 12 19:49:56 2013
@@ -22,8 +22,8 @@ $Id$
 
 
 This subproject contains the source code for Tomcat @VERSION_MAJOR_MINOR@, a 
container that
-implements the Servlet 3.1 and JSP 2.2 specifications from the Java
-Community Process .
+implements the Servlet 3.1, JSP 2.3, EL 3.0 and WebSocket 1.0 specifications
+from the Java Community Process .
 
 Note: If you just need to run Apache Tomcat, it is not necessary to build
 it. You may simply download a binary distribution. It is cross-platform.

Modified: tomcat/trunk/RELEASE-NOTES
URL: 
http://svn.apache.org/viewvc/tomcat/trunk/RELEASE-NOTES?rev=1492397&r1=1492396&r2=1492397&view=diff
==
--- tomcat/trunk/RELEASE-NOTES (original)
+++ tomcat/trunk/RELEASE-NOTES Wed Jun 12 19:49:56 2013
@@ -105,11 +105,11 @@ for use by web applications (by placing 
 * catalina-ha.jar (High availability package)
 * catalina-tribes.jar (Group communication)
 * ecj-@JDT_VERSION@.jar (Eclipse JDT Java compiler)
-* el-api.jar (EL 2.2 API)
+* el-api.jar (EL 3.0 API)
 * jasper.jar (Jasper 2 Compiler and Runtime)
 * jasper-el.jar (Jasper 2 EL implementation)
-* jsp-api.jar (JSP 2.2 API)
-* servlet-api.jar (Servlet 3.0 API)
+* jsp-api.jar (JSP 2.3 API)
+* servlet-api.jar (Servlet 3.1 API)
 * tomcat-api.jar (Interfaces shared by Catalina and Jasper)
 * tomcat-coyote.jar (Tomcat connectors and utility classes)
 * tomcat-dbcp.jar (package renamed database connection pool based on Commons 
DBCP)

Modified: tomcat/trunk/build.xml
URL: 
http://svn.apache.org/viewvc/tomcat/trunk/build.xml?rev=1492397&r1=1492396&r2=1492397&view=diff
==
--- tomcat/trunk/build.xml (original)
+++ tomcat/trunk/build.xml Wed Jun 12 19:49:56 2013
@@ -657,7 +657,7 @@
   filesId="files.annotations-api"
   manifest="${tomcat.manifests}/annotations-api.jar.manifest" />
 
-
+
 
 
-
+
 
 
-
+
 
 
-
+
 
 
-
+
 http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/catalina/authenticator/FormAuthenticator.java?rev=1492397&r1=1492396&r2=1492397&view=diff
==
--- tomcat/trunk/java/org/apache/catalina/authenticator/FormAuthenticator.java 
(original)
+++ tomcat/trunk/java/org/apache/catalina/authenticator/FormAuthenticator.java 
Wed Jun 12 19:49:56 2013
@@ -44,7 +44,7 @@ import org.apache.tomcat.util.http.MimeH
 
 /**
  * An Authenticator and Valve implementation of FORM BASED
- * Authentication, as described in the Servlet API Specification, Version 2.2.
+ * Authentication, as described in the Servlet API Specification.
  *
  * @author Craig R. McClanahan
  * @author Remy Maucherat

Modified: tomcat/trunk/java/org/apache/catalina/authenticator/package.html
URL: 
http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/catalina/authenticator/package.html?rev=1492397&r1=1492396&r2=1492397&view=diff
==
--- tomcat/trunk/java/org/apache/catalina/auth

svn commit: r1492401 - /tomcat/trunk/build.xml

2013-06-12 Thread markt
Author: markt
Date: Wed Jun 12 19:54:44 2013
New Revision: 1492401

URL: http://svn.apache.org/r1492401
Log:
Javadoc SE and EE version updates

Modified:
tomcat/trunk/build.xml

Modified: tomcat/trunk/build.xml
URL: 
http://svn.apache.org/viewvc/tomcat/trunk/build.xml?rev=1492401&r1=1492400&r2=1492401&view=diff
==
--- tomcat/trunk/build.xml (original)
+++ tomcat/trunk/build.xml Wed Jun 12 19:54:44 2013
@@ -1755,9 +1755,9 @@ Apache Tomcat ${version} native binaries
   
   
   
-  http://docs.oracle.com/javase/6/docs/api/"/>
+  http://docs.oracle.com/javase/7/docs/api/"/>
   http://commons.apache.org/proper/commons-io/javadocs/api-release/"/>
-  http://docs.oracle.com/javaee/6/api/"/>
+  http://docs.oracle.com/javaee/7/api/"/>
   
 
 



-
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

2013-06-12 Thread buildbot
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/1237

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] 1492359
Blamelist: markt

Build succeeded!

sincerely,
 -The Buildbot





svn commit: r1492403 - in /tomcat/trunk/webapps/docs: project.xml websocketapi/ websocketapi/index.html

2013-06-12 Thread markt
Author: markt
Date: Wed Jun 12 20:01:16 2013
New Revision: 1492403

URL: http://svn.apache.org/r1492403
Log:
Add stub for WebSocket Javadoc (it is already in the full Javadoc build)

Added:
tomcat/trunk/webapps/docs/websocketapi/   (with props)
tomcat/trunk/webapps/docs/websocketapi/index.html   (with props)
Modified:
tomcat/trunk/webapps/docs/project.xml

Modified: tomcat/trunk/webapps/docs/project.xml
URL: 
http://svn.apache.org/viewvc/tomcat/trunk/webapps/docs/project.xml?rev=1492403&r1=1492402&r2=1492403&view=diff
==
--- tomcat/trunk/webapps/docs/project.xml (original)
+++ tomcat/trunk/webapps/docs/project.xml Wed Jun 12 20:01:16 2013
@@ -84,6 +84,8 @@
 
 
 
+
 http://tomcat.apache.org/connectors-doc/"/>
 

Propchange: tomcat/trunk/webapps/docs/websocketapi/
--
bugtraq:append = false

Propchange: tomcat/trunk/webapps/docs/websocketapi/
--
bugtraq:label = Bugzilla ID (optional)

Propchange: tomcat/trunk/webapps/docs/websocketapi/
--
--- bugtraq:message (added)
+++ bugtraq:message Wed Jun 12 20:01:16 2013
@@ -0,0 +1 @@
+Fix https://issues.apache.org/bugzilla/show_bug.cgi?id=%BUGID%

Propchange: tomcat/trunk/webapps/docs/websocketapi/
--
bugtraq:url = https://issues.apache.org/bugzilla/show_bug.cgi?id=%BUGID%

Added: tomcat/trunk/webapps/docs/websocketapi/index.html
URL: 
http://svn.apache.org/viewvc/tomcat/trunk/webapps/docs/websocketapi/index.html?rev=1492403&view=auto
==
--- tomcat/trunk/webapps/docs/websocketapi/index.html (added)
+++ tomcat/trunk/webapps/docs/websocketapi/index.html Wed Jun 12 20:01:16 2013
@@ -0,0 +1,34 @@
+
+http://www.w3.org/TR/REC-html40/strict.dtd";>
+
+
+
+API docs
+
+
+
+
+The WebSocket Javadoc is not installed by default. Download and install
+the "fulldocs" package to get it.
+
+You can also access the javadoc online in the Tomcat
+http://tomcat.apache.org/tomcat-@VERSION_MAJOR_MINOR@-doc/";>
+documentation bundle.
+
+
+

Propchange: tomcat/trunk/webapps/docs/websocketapi/index.html
--
svn:eol-style = native



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



Re: svn commit: r1492331 - in /tomcat/tc7.0.x/trunk: ./ java/javax/servlet/ java/org/apache/catalina/ java/org/apache/catalina/core/ java/org/apache/catalina/deploy/ java/org/apache/catalina/startup/

2013-06-12 Thread Mark Thomas

On 12/06/2013 20:43, Konstantin Kolinko wrote:

2013/6/12  :

Author: markt
Date: Wed Jun 12 18:31:30 2013
New Revision: 1492331

URL: http://svn.apache.org/r1492331
Log:
With clarification from the EG for Servlet 3.1 section 4.4 finally makes sense. 
Implement the necessary restriction and add a test case.

Added:
 
tomcat/tc7.0.x/trunk/java/org/apache/catalina/deploy/ApplicationListener.java
   - copied unchanged from r1492307, 
tomcat/trunk/java/org/apache/catalina/deploy/ApplicationListener.java
 tomcat/tc7.0.x/trunk/test/org/apache/catalina/core/TesterTldListener.java
   - copied unchanged from r1492307, 
tomcat/trunk/test/org/apache/catalina/core/TesterTldListener.java
 tomcat/tc7.0.x/trunk/test/webapp-3.0/WEB-INF/listener.tld
   - copied unchanged from r1492307, 
tomcat/trunk/test/webapp-3.0/WEB-INF/listener.tld
Modified:
 tomcat/tc7.0.x/trunk/   (props changed)
 tomcat/tc7.0.x/trunk/java/javax/servlet/ServletContext.java
 tomcat/tc7.0.x/trunk/java/org/apache/catalina/Context.java
 tomcat/tc7.0.x/trunk/java/org/apache/catalina/core/LocalStrings.properties
 tomcat/tc7.0.x/trunk/java/org/apache/catalina/core/StandardContext.java
 tomcat/tc7.0.x/trunk/java/org/apache/catalina/deploy/WebXml.java
 tomcat/tc7.0.x/trunk/java/org/apache/catalina/startup/FailedContext.java
 tomcat/tc7.0.x/trunk/java/org/apache/catalina/startup/TldConfig.java
 tomcat/tc7.0.x/trunk/java/org/apache/catalina/startup/WebAnnotationSet.java
 
tomcat/tc7.0.x/trunk/test/org/apache/catalina/core/TestAsyncContextImpl.java
 
tomcat/tc7.0.x/trunk/test/org/apache/catalina/core/TestNamingContextListener.java
 tomcat/tc7.0.x/trunk/test/org/apache/catalina/core/TestStandardContext.java
 tomcat/tc7.0.x/trunk/test/org/apache/catalina/core/TesterContext.java
 tomcat/tc7.0.x/trunk/test/org/apache/catalina/startup/TestListener.java



1. Do not forget to update the changelog.


Ack.


2. Looking at update of javadoc in j.s.ServletContext java,

Why is there restriction for getEffectiveMajorVersion(),
getEffectiveMinorVersion() methods?

They are not used for programmatic configuration of
servlets/filters/listeners and they are not mentioned in Chapter 4.4,
so I think there should not be such restriction on calling them.


You might think that. I might agree. However, the Servlet 3.0 Javadoc 
says there should be a restriction.



3. You changed a method in o.a.c.Context.  We usually add methods
there, but do not change the existing ones.


Yes, I did. Drat. I put some text in the release notes saying that I 
wouldn't do that. I'll fix that.


Mark


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



svn commit: r1492415 - in /tomcat/tc7.0.x/trunk: java/org/apache/catalina/ java/org/apache/catalina/core/ java/org/apache/catalina/startup/ test/org/apache/catalina/core/ webapps/docs/

2013-06-12 Thread markt
Author: markt
Date: Wed Jun 12 20:41:33 2013
New Revision: 1492415

URL: http://svn.apache.org/r1492415
Log:
Fix API compatibility issues with r1492331

Modified:
tomcat/tc7.0.x/trunk/java/org/apache/catalina/Context.java
tomcat/tc7.0.x/trunk/java/org/apache/catalina/core/StandardContext.java
tomcat/tc7.0.x/trunk/java/org/apache/catalina/startup/FailedContext.java
tomcat/tc7.0.x/trunk/java/org/apache/catalina/startup/WebAnnotationSet.java
tomcat/tc7.0.x/trunk/test/org/apache/catalina/core/TesterContext.java
tomcat/tc7.0.x/trunk/webapps/docs/changelog.xml

Modified: tomcat/tc7.0.x/trunk/java/org/apache/catalina/Context.java
URL: 
http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/java/org/apache/catalina/Context.java?rev=1492415&r1=1492414&r2=1492415&view=diff
==
--- tomcat/tc7.0.x/trunk/java/org/apache/catalina/Context.java (original)
+++ tomcat/tc7.0.x/trunk/java/org/apache/catalina/Context.java Wed Jun 12 
20:41:33 2013
@@ -725,6 +725,18 @@ public interface Context extends Contain
 
 
 /**
+ * Add a new Listener class name to the set of Listeners
+ * configured for this application.
+ *
+ * @param listener Java class name of a listener class
+ * 
+ * @deprecated Use {@link #addApplicationListener(ApplicationListener)}
+ */
+@Deprecated
+public void addApplicationListener(String listener);
+
+
+/**
  * Add a new application parameter for this application.
  *
  * @param parameter The new application parameter
@@ -898,8 +910,12 @@ public interface Context extends Contain
 /**
  * Return the set of application listener class names configured
  * for this application.
+ * 
+ * @deprecated  The return type of this method will be changing to
+ *  {@link ApplicationListener}[] in Tomcat 8 
  */
-public ApplicationListener[] findApplicationListeners();
+@Deprecated
+public String[] findApplicationListeners();
 
 
 /**

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=1492415&r1=1492414&r2=1492415&view=diff
==
--- tomcat/tc7.0.x/trunk/java/org/apache/catalina/core/StandardContext.java 
(original)
+++ tomcat/tc7.0.x/trunk/java/org/apache/catalina/core/StandardContext.java Wed 
Jun 12 20:41:33 2013
@@ -2780,6 +2780,12 @@ public class StandardContext extends Con
 //  Context Methods
 
 
+@Override
+public void addApplicationListener(String listener) {
+addApplicationListener(new ApplicationListener(listener, false));
+}
+
+
 /**
  * Add a new Listener class name to the set of Listeners
  * configured for this application.
@@ -3423,9 +3429,15 @@ public class StandardContext extends Con
  * for this application.
  */
 @Override
-public ApplicationListener[] findApplicationListeners() {
+public String[] findApplicationListeners() {
 
-return (applicationListeners);
+ArrayList list =
+new ArrayList(applicationListeners.length);
+for (ApplicationListener applicationListener: applicationListeners) {
+list.add(applicationListener.getClassName());
+}
+
+return list.toArray(new String[list.size()]);
 
 }
 
@@ -4824,7 +4836,7 @@ public class StandardContext extends Con
 log.debug("Configuring application event listeners");
 
 // Instantiate the required listeners
-ApplicationListener listeners[] = findApplicationListeners();
+ApplicationListener listeners[] = applicationListeners;
 Object results[] = new Object[listeners.length];
 boolean ok = true;
 Set tldListeners = new HashSet();

Modified: 
tomcat/tc7.0.x/trunk/java/org/apache/catalina/startup/FailedContext.java
URL: 
http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/java/org/apache/catalina/startup/FailedContext.java?rev=1492415&r1=1492414&r2=1492415&view=diff
==
--- tomcat/tc7.0.x/trunk/java/org/apache/catalina/startup/FailedContext.java 
(original)
+++ tomcat/tc7.0.x/trunk/java/org/apache/catalina/startup/FailedContext.java 
Wed Jun 12 20:41:33 2013
@@ -450,7 +450,9 @@ public class FailedContext extends Lifec
 @Override
 public void addApplicationListener(ApplicationListener listener) { /* 
NO-OP */ }
 @Override
-public ApplicationListener[] findApplicationListeners() { return null; }
+public void addApplicationListener(String listener) { /* NO-OP */ }
+@Override
+public String[] findApplicationListeners() { return null; }
 @Override
 public void removeApplicationListener(String 

svn commit: r1492435 - /tomcat/trunk/test/org/apache/coyote/http11/upgrade/TestUpgrade.java

2013-06-12 Thread markt
Author: markt
Date: Wed Jun 12 21:36:15 2013
New Revision: 1492435

URL: http://svn.apache.org/r1492435
Log:
Speed up failure. 300s was for debugging.

Modified:
tomcat/trunk/test/org/apache/coyote/http11/upgrade/TestUpgrade.java

Modified: tomcat/trunk/test/org/apache/coyote/http11/upgrade/TestUpgrade.java
URL: 
http://svn.apache.org/viewvc/tomcat/trunk/test/org/apache/coyote/http11/upgrade/TestUpgrade.java?rev=1492435&r1=1492434&r2=1492435&view=diff
==
--- tomcat/trunk/test/org/apache/coyote/http11/upgrade/TestUpgrade.java 
(original)
+++ tomcat/trunk/test/org/apache/coyote/http11/upgrade/TestUpgrade.java Wed Jun 
12 21:36:15 2013
@@ -116,7 +116,7 @@ public class TestUpgrade extends TomcatB
 Socket socket =
 SocketFactory.getDefault().createSocket("localhost", 
getPort());
 
-socket.setSoTimeout(30);
+socket.setSoTimeout(1);
 
 InputStream is = socket.getInputStream();
 OutputStream os = socket.getOutputStream();



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



svn commit: r1492451 - /tomcat/trunk/java/org/apache/catalina/connector/OutputBuffer.java

2013-06-12 Thread markt
Author: markt
Date: Wed Jun 12 22:12:51 2013
New Revision: 1492451

URL: http://svn.apache.org/r1492451
Log:
r1491962 broke HTTP upgrade on some platforms (including the CI). Ensure that 
HTTP upgrade responses are flushed as the normal code path for this is bypassed 
when using HTTP upgrade.

Modified:
tomcat/trunk/java/org/apache/catalina/connector/OutputBuffer.java

Modified: tomcat/trunk/java/org/apache/catalina/connector/OutputBuffer.java
URL: 
http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/catalina/connector/OutputBuffer.java?rev=1492451&r1=1492450&r2=1492451&view=diff
==
--- tomcat/trunk/java/org/apache/catalina/connector/OutputBuffer.java (original)
+++ tomcat/trunk/java/org/apache/catalina/connector/OutputBuffer.java Wed Jun 
12 22:12:51 2013
@@ -24,6 +24,7 @@ import java.security.PrivilegedException
 import java.util.HashMap;
 
 import javax.servlet.WriteListener;
+import javax.servlet.http.HttpServletResponse;
 
 import org.apache.catalina.Globals;
 import org.apache.coyote.ActionCode;
@@ -284,7 +285,12 @@ public class OutputBuffer extends Writer
 }
 }
 
-doFlush(false);
+if (coyoteResponse.getStatus() ==
+HttpServletResponse.SC_SWITCHING_PROTOCOLS) {
+doFlush(true);
+} else {
+doFlush(false);
+}
 closed = true;
 
 // The request should have been completely read by the time the 
response



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



[Tomcat Wiki] Update of "Specifications" by KonstantinKolinko

2013-06-12 Thread Apache Wiki
Dear Wiki user,

You have subscribed to a wiki page or wiki category on "Tomcat Wiki" for change 
notification.

The "Specifications" page has been changed by KonstantinKolinko:
https://wiki.apache.org/tomcat/Specifications?action=diff&rev1=29&rev2=30

Comment:
Update links to Servlet 3.1 specification, now that its Final Release is 
available

  ||Online Javadoc: ||<-2> [[http://docs.oracle.com/javaee/6/api/|Java EE 6]]||
  
  ||Spec versions: ||Servlet 3.1 ||
- ||Main page: || [[http://www.jcp.org/en/jsr/summary?id=340|JSR340]] ||
+ ||Main page: || [[http://www.jcp.org/en/jsr/detail?id=340|JSR340]] ||
  ||Java.net project: || [[http://java.net/projects/servlet-spec/|servlet-spec 
]]||
- ||Stable: || Work in progress ||
- ||Date: || ||
- ||Download Page: || ||
- ||Online Javadoc: || ||
+ ||Stable: || Final Release ||
+ ||Date: || 28 May, 2013 ||
+ ||Download Page: || 
[[http://jcp.org/aboutJava/communityprocess/final/jsr340/index.html|Overview]]<>
 
[[http://download.oracle.com/otndocs/jcp/servlet-3_1-fr-eval-spec/index.html|Direct
 Download]] ||
+ ||Online Javadoc: || [[http://docs.oracle.com/javaee/7/api/|Java EE 7]] ||
  
  == JavaServer Pages and Expression Language Specifications ==
  

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



[Tomcat Wiki] Update of "Specifications" by KonstantinKolinko

2013-06-12 Thread Apache Wiki
Dear Wiki user,

You have subscribed to a wiki page or wiki category on "Tomcat Wiki" for change 
notification.

The "Specifications" page has been changed by KonstantinKolinko:
https://wiki.apache.org/tomcat/Specifications?action=diff&rev1=30&rev2=31

Comment:
Update links to JSP 2.3 and EL 3.0 specs. They have been published.

  
  == JavaServer Pages and Expression Language Specifications ==
  
+ JSP 2.3 is the second maintenance release of JSP 2.1 (JSR 245). Expression 
Language 3.0 is JSR 341.
+ 
- JSP 2.2 is a maintenance release of JSP 2.1. Both are part of JSR 245.
+ JSP 2.2 is the first maintenance release of JSP 2.1 (JSR 245).
+ 
+ JSP 2.1 is JSR 245.
  
  JSP 2.0 is JSR 152.
  
  Expression Language was covered by JSP 2.0 and JSP 2.1 specifications, but 
became a separate document starting with JSP 2.2.
- 
- JSP 2.3 is expected to be a minor update to JSP 2.2 under JSR 245. Expression 
Language 3.0 is JSR 341.
  
  ||Spec versions: ||JSP 2.0 ||
  ||Main page: ||[[http://www.jcp.org/en/jsr/summary?id=152|JSR152]] ||
@@ -63, +65 @@

  
  ||Spec versions: ||JSP 2.1 ||JSP 2.2, EL 2.2 ||
  ||Main page: ||[[http://www.jcp.org/en/jsr/summary?id=245|JSR245]] 
||[[http://www.jcp.org/en/jsr/summary?id=245|JSR245]] ||
- ||Stable: ||Final Release ||Maintenance Release ||
+ ||Stable: ||Final Release ||Maintenance Release<>''The naming is 
according to JSR 245. The title page of the<>JSP specification document 
says "Maintenace Release 2"'' ||
  ||Date: ||11 May, 2006 ||10 Dec, 2009 ||
  ||Download Page: 
||[[http://jcp.org/aboutJava/communityprocess/final/jsr245/index.html|Overview]]<>
 
[[http://download.oracle.com/otndocs/jcp/jsp-2.1-fr-eval-spec-oth-JSpec/|Direct 
Download]] 
||[[http://jcp.org/aboutJava/communityprocess/mrel/jsr245/index.html|Overview]]<>
 [[http://download.oracle.com/otndocs/jcp/jsp-2.2-mrel-eval-oth-JSpec/|Direct 
Download - JSP 2.2]]<> 
[[http://download.oracle.com/otndocs/jcp/expression_language-2.2-mrel-eval-oth-JSpec/|Direct
 Download - EL 2.2]] ||
  ||Online Javadoc: || [[http://docs.oracle.com/javaee/5/api/|Java EE 5]]|| 
[[http://docs.oracle.com/javaee/6/api/|Java EE 6]]||
  
  ||Spec versions: ||JSP 2.3 || EL 3.0 ||
- ||Main page: ||[[http://www.jcp.org/en/jsr/summary?id=245|JSR245]] ? 
||[[http://www.jcp.org/en/jsr/detail?id=341|JSR341]] ||
+ ||Main page: ||[[http://www.jcp.org/en/jsr/detail?id=245|JSR245]] 
||[[http://www.jcp.org/en/jsr/detail?id=341|JSR341]] ||
  ||Java.net project: || 
[[http://java.net/projects/jsp-spec-public/|jsp-spec-public ]] ? || 
[[http://java.net/projects/el-spec/|el-spec]] ||
- ||Stable: ||<-2> Work in progress ||
- ||Date: || || ||
- ||Download Page: || || ||
- ||Online Javadoc: || || ||
+ ||Stable: || Maintenance Release 2<>''The naming is according to JSR 245. 
The title page of the<>JSP specification document says "Maintenace Release 
3"'' || Final Release ||
+ ||Date: || 12 Jun, 2013 || 22 May, 2013 ||
+ ||Download Page: || 
[[http://jcp.org/aboutJava/communityprocess/mrel/jsr245/index2.html|Overview]]<>[[http://download.oracle.com/otndocs/jcp/jsp-2_3-mrel2-eval-spec/|Direct
 Download]] || 
[[http://jcp.org/aboutJava/communityprocess/final/jsr341/index.html|Overview]]<>[[http://download.oracle.com/otndocs/jcp/el-3_0-fr-eval-spec/index.html|Direct
 Download]] ||
+ ||Online Javadoc: || [[http://docs.oracle.com/javaee/7/api/|Java EE 7]] || ||
  
  == Java API for WebSocket ==
  

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



[Tomcat Wiki] Update of "Specifications" by KonstantinKolinko

2013-06-12 Thread Apache Wiki
Dear Wiki user,

You have subscribed to a wiki page or wiki category on "Tomcat Wiki" for change 
notification.

The "Specifications" page has been changed by KonstantinKolinko:
https://wiki.apache.org/tomcat/Specifications?action=diff&rev1=31&rev2=32

Comment:
Update links to WebSocket 1.0 specification, now that its Final Release is 
available. Add link to BZ 51181.

  
  == Java API for WebSocket ==
  
- Java API for !WebSocket is JSR 356. This is a work in progress, an 
implementation is to be included in Tomcat 8.
+ Java API for !WebSocket is JSR 356. An implementation is to be included in 
Tomcat 8. See also 
[[https://issues.apache.org/bugzilla/show_bug.cgi?id=51181#c64|Bug 51181]].
  
  ||Spec versions: ||Java API for !WebSocket 1.0 ||
  ||Main page: || [[http://www.jcp.org/en/jsr/summary?id=356|JSR356]] ||
  ||Java.net project: || 
[[http://java.net/projects/websocket-spec/|websocket-spec ]]||
- ||Stable: || Work in progress ||
- ||Date: || ||
- ||Download Page: || ||
- ||Online Javadoc: || ||
+ ||Stable: || Final Release ||
+ ||Date: || 22 May, 2013 ||
+ ||Download Page: || 
[[http://jcp.org/aboutJava/communityprocess/final/jsr356/index.html|Overview]]<>[[http://download.oracle.com/otndocs/jcp/websocket-1_0-fr-eval-spec/index.html|Direct
 Download]] ||
+ ||Online Javadoc: || [[http://docs.oracle.com/javaee/7/api/|Java EE 7]] ||
  
  
  == See Also ==

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