svn commit: r1531599 - /tomcat/tc7.0.x/trunk/webapps/docs/web-socket-howto.xml

2013-10-12 Thread kpreisser
Author: kpreisser
Date: Sat Oct 12 21:59:12 2013
New Revision: 1531599

URL: http://svn.apache.org/r1531599
Log:
- Link to correct location of Tomcat7's WebSocket examples.
- The examples using the deprecated API have been restored as of r1525279 so 
link to them (in trunk) instead of the 7.0.42 tag.

Modified:
tomcat/tc7.0.x/trunk/webapps/docs/web-socket-howto.xml

Modified: tomcat/tc7.0.x/trunk/webapps/docs/web-socket-howto.xml
URL: 
http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/webapps/docs/web-socket-howto.xml?rev=1531599&r1=1531598&r2=1531599&view=diff
==
--- tomcat/tc7.0.x/trunk/webapps/docs/web-socket-howto.xml (original)
+++ tomcat/tc7.0.x/trunk/webapps/docs/web-socket-howto.xml Sat Oct 12 21:59:12 
2013
@@ -43,9 +43,9 @@
 
 There are several example applications that demonstrate how the WebSocket 
API
can be used. You will need to look at both the client side http://svn.apache.org/viewvc/tomcat/trunk/webapps/examples/websocket/";>
+   
href="http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/webapps/examples/websocket/";>
HTML and the server side http://svn.apache.org/viewvc/tomcat/trunk/webapps/examples/WEB-INF/classes/websocket/";>
+   
href="http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/webapps/examples/WEB-INF/classes/websocket/";>
code.
 
 
@@ -105,12 +105,10 @@
 
 There are also several example applications that demonstrate how the
WebSocket API can be used. You'll need to look at both the client side http://svn.apache.org/viewvc/tomcat/tc7.0.x/tags/TOMCAT_7_0_42/webapps/examples/websocket/";>
+   
href="http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/webapps/examples/websocket-deprecated/";>
HTML and the server side http://svn.apache.org/viewvc/tomcat/tc7.0.x/tags/TOMCAT_7_0_42/webapps/examples/WEB-INF/classes/websocket/";>
-   code. Note that as of 7.0.43, these sample applications have been
-   refactored to use the JSR-356 WebSocket implementation so the links above 
are
-   for the 7.0.42 tag.
+   
href="http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/webapps/examples/WEB-INF/classes/websocket/tc7/";>
+   code.
 
 
 



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



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

2013-10-12 Thread kpreisser
Author: kpreisser
Date: Sat Oct 12 22:03:10 2013
New Revision: 1531600

URL: http://svn.apache.org/r1531600
Log:
Update some comments.

Modified:

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

Modified: 
tomcat/trunk/webapps/examples/WEB-INF/classes/websocket/drawboard/DrawboardEndpoint.java
URL: 
http://svn.apache.org/viewvc/tomcat/trunk/webapps/examples/WEB-INF/classes/websocket/drawboard/DrawboardEndpoint.java?rev=1531600&r1=1531599&r2=1531600&view=diff
==
--- 
tomcat/trunk/webapps/examples/WEB-INF/classes/websocket/drawboard/DrawboardEndpoint.java
 (original)
+++ 
tomcat/trunk/webapps/examples/WEB-INF/classes/websocket/drawboard/DrawboardEndpoint.java
 Sat Oct 12 22:03:10 2013
@@ -158,7 +158,7 @@ public final class DrawboardEndpoint ext
 // (starting with char '1'), and pong messages 
(starting
 // with char '0').
 // Draw messages should look like this:
-// ID|type,colR,colB,colG,colA,thickness,x1,y1,x2,y2
+// 
ID|type,colR,colB,colG,colA,thickness,x1,y1,x2,y2,lastInChain
 
 boolean dontSwallowException = false;
 try {

Modified: 
tomcat/trunk/webapps/examples/WEB-INF/classes/websocket/drawboard/Room.java
URL: 
http://svn.apache.org/viewvc/tomcat/trunk/webapps/examples/WEB-INF/classes/websocket/drawboard/Room.java?rev=1531600&r1=1531599&r2=1531600&view=diff
==
--- tomcat/trunk/webapps/examples/WEB-INF/classes/websocket/drawboard/Room.java 
(original)
+++ tomcat/trunk/webapps/examples/WEB-INF/classes/websocket/drawboard/Room.java 
Sat Oct 12 22:03:10 2013
@@ -229,7 +229,7 @@ public final class Room {
 
 
 /**
- * Broadcasts the given drawboard message to all connected players.
+ * Broadcasts the given drawboard message to all connected players.
  * Note: For DrawMessages, please use
  * {@link #broadcastDrawMessage(DrawMessage)}
  * as this method will buffer them and prefix them with the correct
@@ -274,7 +274,7 @@ public final class Room {
 private void broadcastTimerTick() {
 // For each Player, send all per Player buffered
 // DrawMessages, prefixing each DrawMessage with the player's
-// lastReceuvedMessageId.
+// lastReceivedMessageId.
 // Multiple messages are concatenated with "|".
 
 for (Player p : players) {
@@ -329,6 +329,7 @@ public final class Room {
 public void shutdown() {
 roomExecutor.shutdown();
 drawmessageBroadcastTimer.cancel();
+// TODO: Dispose of BufferedImage and Graphics2D
 }
 
 
@@ -337,7 +338,7 @@ public final class Room {
  * {@link Room} and the {@link Client}.
  *
  * Note: This means a player object is actually a join between Room and
- * Endpoint.
+ * Client.
  */
 public final class Player {
 
@@ -356,8 +357,6 @@ public final class Room {
 
 /**
  * Buffered DrawMessages that will be sent by a Timer.
- * TODO: This should be refactored to be in a Room-Player join class
- * as this is room-specific.
  */
 private final List bufferedDrawMessages =
 new ArrayList<>();



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



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

2013-10-12 Thread kpreisser
Author: kpreisser
Date: Sat Oct 12 22:04:39 2013
New Revision: 1531601

URL: http://svn.apache.org/r1531601
Log:
Update some comments.

Modified:
tomcat/tc7.0.x/trunk/   (props changed)

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

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

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

Modified: 
tomcat/tc7.0.x/trunk/webapps/examples/WEB-INF/classes/websocket/drawboard/DrawboardEndpoint.java
URL: 
http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/webapps/examples/WEB-INF/classes/websocket/drawboard/DrawboardEndpoint.java?rev=1531601&r1=1531600&r2=1531601&view=diff
==
--- 
tomcat/tc7.0.x/trunk/webapps/examples/WEB-INF/classes/websocket/drawboard/DrawboardEndpoint.java
 (original)
+++ 
tomcat/tc7.0.x/trunk/webapps/examples/WEB-INF/classes/websocket/drawboard/DrawboardEndpoint.java
 Sat Oct 12 22:04:39 2013
@@ -158,7 +158,7 @@ public final class DrawboardEndpoint ext
 // (starting with char '1'), and pong messages 
(starting
 // with char '0').
 // Draw messages should look like this:
-// ID|type,colR,colB,colG,colA,thickness,x1,y1,x2,y2
+// 
ID|type,colR,colB,colG,colA,thickness,x1,y1,x2,y2,lastInChain
 
 boolean dontSwallowException = false;
 try {

Modified: 
tomcat/tc7.0.x/trunk/webapps/examples/WEB-INF/classes/websocket/drawboard/Room.java
URL: 
http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/webapps/examples/WEB-INF/classes/websocket/drawboard/Room.java?rev=1531601&r1=1531600&r2=1531601&view=diff
==
--- 
tomcat/tc7.0.x/trunk/webapps/examples/WEB-INF/classes/websocket/drawboard/Room.java
 (original)
+++ 
tomcat/tc7.0.x/trunk/webapps/examples/WEB-INF/classes/websocket/drawboard/Room.java
 Sat Oct 12 22:04:39 2013
@@ -231,7 +231,7 @@ public final class Room {
 
 
 /**
- * Broadcasts the given drawboard message to all connected players.
+ * Broadcasts the given drawboard message to all connected players.
  * Note: For DrawMessages, please use
  * {@link #broadcastDrawMessage(DrawMessage)}
  * as this method will buffer them and prefix them with the correct
@@ -276,7 +276,7 @@ public final class Room {
 private void broadcastTimerTick() {
 // For each Player, send all per Player buffered
 // DrawMessages, prefixing each DrawMessage with the player's
-// lastReceuvedMessageId.
+// lastReceivedMessageId.
 // Multiple messages are concatenated with "|".
 
 for (Player p : players) {
@@ -331,6 +331,7 @@ public final class Room {
 public void shutdown() {
 roomExecutor.shutdown();
 drawmessageBroadcastTimer.cancel();
+// TODO: Dispose of BufferedImage and Graphics2D
 }
 
 
@@ -339,7 +340,7 @@ public final class Room {
  * {@link Room} and the {@link Client}.
  *
  * Note: This means a player object is actually a join between Room and
- * Endpoint.
+ * Client.
  */
 public final class Player {
 
@@ -358,8 +359,6 @@ public final class Room {
 
 /**
  * Buffered DrawMessages that will be sent by a Timer.
- * TODO: This should be refactored to be in a Room-Player join class
- * as this is room-specific.
  */
 private final List bufferedDrawMessages =
 new ArrayList();



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



buildbot exception in ASF Buildbot on tomcat-trunk

2013-10-12 Thread buildbot
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/5102

Buildbot URL: http://ci.apache.org/

Buildslave for this Build: bb-vm_ubuntu

Build Reason: scheduler
Build Source Stamp: [branch tomcat/trunk] 1531600
Blamelist: kpreisser

BUILD FAILED: exception compile upload_2

sincerely,
 -The Buildbot




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



Re: [Tomcat 8.0.x trunk] APR sendfile problem

2013-10-12 Thread Ognjen Blagojevic

Konstantin,

On 12.10.2013 3:52, Konstantin Preißer wrote:

I am testing tcnative-1.1.29 RC, with Tomcat 8.0.x trunk (r1531461) on
Win7 64-bit. I have HTTPS configured. I can't get any response larger
than 50 kB.

...

Now, this is interesting: I know that 50 kB limit usually smells like
sendfile issue. So I tried to add EITHER useSendfile="true" or
useSendfile="false" to the above configuration, and with either of those
attributes the problem is resolved.


I also tried this now with trunk (r1531312) and Native 1.1.29 RC on Windows 8 
64-bit with Java 1.7.0_40, and can confirm the behavior:
With the above configuration for a SSL HTTP APR connector, I cannot receive the contents of 
"/docs/manager-howto.html", whereas it works if I either add useSendfile="true" or 
useSendfile="false".


Thank you for verifying.

I now re-read the docs, and realized that sendfile is not allowed with 
HTTPS, so one should always add useSendfile="false" to HTTPS APR connector.


It is strange that useSendfile="true", and not adding attribute 
useSendfile at all behaves differently, but this is, IMO, minor issue in 
interpreting server.xml.




Additionally, I regularly got following exceptions and crashes when playing with the 
Drawboard example (using brush to draw on it, or press F5 so that a binary websocket 
message with the PNG image is sent to the browser). They happen independent of the 
presence and value of the "sendFile" attribute, but they do not happen with a 
Non-SSL HTTP APR connector.


Was "sendFile" a typo? It should be "useSendfile".

-Ognjen

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



Re: [VOTE] Release Apache Tomcat Native 1.1.29

2013-10-12 Thread Ognjen Blagojevic

Mladen,

On 10.10.2013 15:18, Mladen Turk wrote:

Version 1.1.29 is bug fixing release.
The proposed release artefacts can be found at [1],
and the build was done using tag [2].

The VOTE will remain open for at least 48 hours.

The Apache Tomcat Native 1.1.29 is
  [X] Stable, go ahead and release
  [ ] Broken because of ...


Tested with Tomcat 8 trunk on Win7 64-bit with Java 1.7.0_40.

-Ognjen

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



RE: [Tomcat 8.0.x trunk] APR sendfile problem

2013-10-12 Thread Konstantin Preißer
Hi Ognjen,

> -Original Message-
> From: Ognjen Blagojevic [mailto:ognjen.d.blagoje...@gmail.com]
> Sent: Sunday, October 13, 2013 12:11 AM

> Konstantin,

> > Additionally, I regularly got following exceptions and crashes when playing
> with the Drawboard example (using brush to draw on it, or press F5 so that a
> binary websocket message with the PNG image is sent to the browser). They
> happen independent of the presence and value of the "sendFile" attribute,
> but they do not happen with a Non-SSL HTTP APR connector.
> 
> Was "sendFile" a typo? It should be "useSendfile".

Yes, I meant the "useSendfile" attribute.


Regards,
Konstantin Preißer


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



RE: [Tomcat 8.0.x trunk] APR sendfile problem

2013-10-12 Thread Konstantin Preißer


> -Original Message-
> From: Ognjen Blagojevic [mailto:ognjen.d.blagoje...@gmail.com]
> Sent: Sunday, October 13, 2013 12:11 AM
> To: Tomcat Developers List
> Subject: Re: [Tomcat 8.0.x trunk] APR sendfile problem
> 
> Konstantin,
> 
> On 12.10.2013 3:52, Konstantin Preißer wrote:
> > I also tried this now with trunk (r1531312) and Native 1.1.29 RC on Windows
> 8 64-bit with Java 1.7.0_40, and can confirm the behavior:
> > With the above configuration for a SSL HTTP APR connector, I cannot
> receive the contents of "/docs/manager-howto.html", whereas it works if I
> either add useSendfile="true" or useSendfile="false".
> 
> Thank you for verifying.
> 
> I now re-read the docs, and realized that sendfile is not allowed with
> HTTPS, so one should always add useSendfile="false" to HTTPS APR
> connector.
> 
> It is strange that useSendfile="true", and not adding attribute
> useSendfile at all behaves differently, but this is, IMO, minor issue in
> interpreting server.xml.

BTW, if I revert the changes in r1530269 (in AprEndpoint) then that specific 
issue does no longer appear when "useSendfile" attribute is not specified on 
the SSL connector - then Firefox shows the correct contents if I request 
"/docs/manager-howto.html".


Regards,
Konstantin Preißer


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