Re: nio connector configuration

2009-02-19 Thread Peter Warren
Sorry to bump this thread. I'm willing to pay for some assistance if anyone's interested in helping. I'm trying to figure out 2 problems when running my system under a light-moderate load test: 1) why do my comet timeout events not get generated on time (supposed to be every 50 seconds, averagin

Re: nio connector configuration

2009-02-13 Thread Peter Warren
I'm trying to figure out how best to configure nio so that my comet timeout events get generated in a timely manner. I have the comet events set to generate a timeout every 50 seconds. Works fine with few users. Under a moderate but reasonable load the timeout gets generated on average every 113

Re: nio connector configuration

2009-02-11 Thread Peter Warren
Thanks for the tips. Very helpful. >> I also get the warning when trying to use keepAliveTimeout. >> Is this property available for the nio connector? > > No; it's only listed under the older connector (the one labeled "Standard > Implementation" that then somewhat ambiguously refers to HTTP).

nio connector configuration

2009-02-11 Thread Peter Warren
Looking for nio configuration tips for 6.0.18... I have an ajax app that uses a single socket connection for sending standard http requests and receiving responses, and another socket connection to listen via comet for messages pushed out by the server. A comet timeout is generated every 50 second

Re: comet end vs. client_disconnect

2009-02-11 Thread Peter Warren
> CLIENT_DISCONNECT is only used a subtype of ERROR > and that happens when the socket is closed from the client side When a client disconnects (i.e. socket is closed from the client side), I see an END event on both Windows and Ubuntu. I expected an ERROR event with a subtype of CLIENT_DISCONNEC

comet end vs. client_disconnect

2009-02-11 Thread Peter Warren
How do I distinguish between a comet END event generated due to a client disconnect and an end event generated for some other reason? I'm using tomcat 6.0.18 with the nio connector. On both windows xp sp3 and ubuntu 8.10, I'm seeing END events generated when a client disconnects and for other sit

Re: comet loop after webapp re-start

2009-02-05 Thread Peter Warren
Thanks for the pointer. That bug does look related, as does this one: http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=6403933 -- fixed against java 7. - To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additiona

Re: comet loop after webapp re-start

2009-02-04 Thread Peter Warren
> What JVM are you using? The stack trace doesn't look like anything that a > HotSpot JVM would produce. It's Sun Java 1.6.0_10-b33. I grabbed the trace from my eclipse debugger. And I see the loop when running both with and without vm debug flags. Peter -

comet loop after webapp re-start

2009-02-04 Thread Peter Warren
I'm running tomcat 6.0.18 on Ubuntu 8.10. I have a comet application that maintains an open connection with tomcat. If I re-start my webapp and then close the client connection, tomcat goes into a loop and chews up all cpu. This server is not live and only has my single client. The ClientPoller

Re: comet end event

2008-01-29 Thread Peter Warren
> > Could you indulge me and try the client with the sleep? > > > just did, worked exactly as before. > event: BEGIN, subtype: null > event: READ, subtype: null > Read 10 bytes: comet test for session: A01334D0AC22505DCD4B323820963FEC > read error > event: ERROR, subtype: TIMEOUT Hmm, not sure whe

Re: comet end event

2008-01-29 Thread Peter Warren
Could you indulge me and try the client with the sleep? I see the end event when there's a break/delay between sending a chunk and sending the last chunk. It is legal http to send the last chunk separately from preceding chunks, isn't it? > getting a -1 on a inputstream.read is normal (even for

Re: comet end event

2008-01-28 Thread Peter Warren
not an official version, but you can test it out and see how > your test works > > Filip > > > Peter Warren wrote: > > I put up a war file at: http://www.nomad.org/comet_test.war. > > > > It includes the webapp, source for the comet servlet & client, and the

Re: comet end event

2008-01-25 Thread Peter Warren
I put up a war file at: http://www.nomad.org/comet_test.war. It includes the webapp, source for the comet servlet & client, and the server.xml file. Let me know if I missed anything. As I mentioned before, I've also used your cometgui.jar client and see the end event generated when using it as w

Re: comet end event

2008-01-22 Thread Peter Warren
r.append(hexChunkLength); > outputBuffer.append(DELIMITER); > outputBuffer.append(chunkData); > outputBuffer.append(DELIMITER); > byte[] outputBytes = outputBuffer.toString().getBytes(ENCODING); > outputStream.write(outputBytes); > outputStrea

Re: comet end event

2008-01-22 Thread Peter Warren
outputStream.write(outputBytes); outputStream.flush(); } } On Jan 22, 2008 9:07 AM, Filip Hanik - Dev Lists <[EMAIL PROTECTED]> wrote: > I still don't get the END event, however, thanks for pointing it out, > you did find a regression bug about the timeout > &

Re: comet end event

2008-01-21 Thread Peter Warren
} } while (inputStream.available() > 0); } } On Jan 21, 2008 11:53 AM, Filip Hanik - Dev Lists <[EMAIL PROTECTED]> wrote: > answers inline > > Peter Warren wrote: > > First off, thanks for your responses. The contributors to this lis

Re: comet client doesn't receive server response

2008-01-21 Thread Peter Warren
t you are seeing, a regular servlet, ends the response right away > > Filip > > > Peter Warren wrote: > > What is interesting to me is that the exact same client code only > > using a different url (i.e. to a normal http servlet, not a comet > > servlet) succeeds. Is t

Re: comet end event

2008-01-21 Thread Peter Warren
20, 2008 8:15 PM, Filip Hanik - Dev Lists <[EMAIL PROTECTED]> wrote: > > now I get it. I just ran through a test case, and an END event was not > thrown just because there was an end chunk. > the response is very much still open at that point > > > Filip > > Peter

Re: comet end event

2008-01-19 Thread Peter Warren
writes are possible, just not after the END or > ERROR events have been issued > > Filip > > > Peter Warren wrote: > > Does that mean that HttpURLConnection cannot be used for comet > > requests with asynchronous (i.e. delayed) responses? > > > > It would

Re: comet end event

2008-01-19 Thread Peter Warren
rror, you MUST close the Comet event > > Filip > > > Peter Warren wrote: > > What do I do to make the END event stop repeating? I don't want to > > close the CometEvent yet because the server is waiting for data to > > send to the client. If I don't close th

comet end event

2008-01-18 Thread Peter Warren
What do I do to make the END event stop repeating? I don't want to close the CometEvent yet because the server is waiting for data to send to the client. If I don't close the comet event, the END event repeats incessantly. I'm using an unsigned applet as a comet client. To accommodate proxies,

Re: Comet Development

2008-01-16 Thread Peter Warren
This post (http://www.nabble.com/comet-questions-td14673697.html#a14673697) contains test code for both a client & comet servlet. See if it helps. On Jan 16, 2008 10:35 AM, Siobhan <[EMAIL PROTECTED]> wrote: > To anyone who has successfully used Comet: > > > > I've been trying to use Comet with T

Re: comet client doesn't receive server response

2008-01-15 Thread Peter Warren
e end (or some high amount of > data), to run the checks. In my case, this buffering lasts for minutes, > with no byte sent back to the browser. > > I think this can be a simple point to check... > > Hugs, > > Leonardo Fraga > Web Developer > [EMAIL PROTECTED] > >

Re: comet questions

2008-01-15 Thread Peter Warren
comet timeout event every 10 secs. Setting it to 2 mins gives a comet timeout every 2 mins. The docs don't mention any link between the connectionTimeout settings and comet timeout events that I can find. Connector config: On Jan 9, 2008 12:23 PM, Peter Warren <[EMAIL PROTECTED

comet client doesn't receive server response

2008-01-10 Thread Peter Warren
I posted this question along with some others recently. I'm re-posting it in its own thread with some additional information. I have a comet client app that works on all the machines I've tested except one. The failing machine sends a comet request to the server and then waits indefinitely for t

Re: comet questions

2008-01-09 Thread Peter Warren
} } } On Jan 7, 2008 4:43 PM, Filip Hanik - Dev Lists <[EMAIL PROTECTED]> wrote: > The time when it is called without a subtype, is if the > application(servlet) has an unhandled exception > > in terms of timeout, that should work just dandy, unless the client > dis

Re: comet questions

2008-01-07 Thread Peter Warren
Buffer when you wanna flush it out (ie > after you've written to and flushed your stream). > > also, there have been some bug fixes, that you can get from SVN, or wait > for 6.0.16 to come out > > Filip > > > Peter Warren wrote: > > I have some comet q

comet questions

2008-01-07 Thread Peter Warren
I have some comet questions. I'm using the tomcat 6.0.x trunk as of last Friday. 1) My comet event timeout setting being honored. How come? I set the timeout for 3 hours but a timeout event gets generated every 2 minutes. If I inspect the comet event for which the timeout is triggered, I see a

Re: Tomcat memory issues

2007-09-07 Thread Peter Warren
s? - org.apache.catalina.connector.ResponseFacade (ACCA) - [] (ACCB) - org.apache.catalina.connector.Request (ACCC) Peter On 9/7/07, Morten <[EMAIL PROTECTED]> wrote: > > "Peter Warren" <[EMAIL PROTECTED]> skrev i en meddelelse > news:[EMAIL PROTECTED] > > Is it

Re: Tomcat memory issues

2007-09-06 Thread Peter Warren
Is it possible you're caching Request or Response objects somewhere and not releasing them? I just did a bunch of memory profiling and many of the classes you mention are the same classes I see when I open and don't close a bunch of connections to the server. -

comet webapp memory optimization

2007-09-05 Thread Peter Warren
I have a webapp that maintains many concurrent comet connections. Transmissions between the client and server are small and infrequent. I'm trying to lessen the memory usage by playing with buffer configurations. To test various configurations, I wrote a client that opens 2000 connections to a c

comet read & httpsession timeout

2007-08-16 Thread Peter Warren
A comet read event doesn't update the last accessed time of an HttpSession -- which means comet read events will never prevent an http session (not the comet session) from timing out and the connection getting closed. Is that by design? If so, can anyone offer me suggestions on how to handle long

Re: multiple comet requests

2007-08-14 Thread Peter Warren
take a look and see why it is happening, Filip Peter Warren wrote: How do you send multiple requests to the same comet servlet? Sending multiple chunks of a single request is fine. My problem occurs after the client ends the chunked transaction by sending "0CRLFCRLF" to the server.

multiple comet requests

2007-08-14 Thread Peter Warren
How do you send multiple requests to the same comet servlet? Sending multiple chunks of a single request is fine. My problem occurs after the client ends the chunked transaction by sending "0CRLFCRLF" to the server. The comet servlet correctly registers the END event. But then the client subseq

Re: comet read event

2007-06-04 Thread Peter Warren
.getSession(true).getId()); } else if (n < 0) { log("comet read error"); } } while (is.available() > 0); return inputBuffer.toString(); } } Filip Hanik - Dev Lists wrote: > why don't you make your test available,

Re: [maybe not solved] comet read event

2007-06-01 Thread Peter Warren
gerous waters my friend. the comet is somewhat like > a real socket, and sending up new HTTP headers might end up just being > data for the Comet servlet. > > Filip > > Peter Warren wrote: >> My client code was the problem. I had been thinking of the comet >> interaction

Re: [solved] comet read event

2007-06-01 Thread Peter Warren
ystem.out.println(line); out.close(); urlConn.disconnect(); } Peter Warren wrote: > Thanks for the suggestion. I changed the comet test servlet to read > directly from the input stream as shown in the advanced io example. I'm > still seeing the same behavior. No comet read event g

Re: tomcat comet, not working...

2007-05-29 Thread Peter Warren
Filip, could you post some client code that sends two separate messages to the server on the same output stream and generates both a begin event and then a subsequent read event. Thanks, Peter (I'm the guy who started the "comet read event" thread. I never heard back after you asked me which conn

Re: comet read event

2007-05-23 Thread Peter Warren
Yes, I'm using the NIO connector. Here is the config line from my server.xml: Are there any other configuration options I need to set? Peter Filip Hanik - Dev Lists wrote: > and you are using the APR or the NIO connector right? > > Filip > > Peter Warren wrot

Re: comet read event

2007-05-23 Thread Peter Warren
utBuffer.toString(); } Filip Hanik - Dev Lists wrote: > take a look at the documentation, the way you are reading it is > incorrect. > you need to take advantage of the available() method > > Filip > > Peter Warren wrote: >> My BEGIN block in my comet servlet now loo

comet read event

2007-05-22 Thread Peter Warren
anik wrote: > > it could be because the data from the request already came in with the request. > when the BEGIN happens, perform the actions as if there was a READ as well, ie, empty out the buffer. > > Filip Peter Warren wrote: > The following client code generates a comet BEGIN ev

comet read event

2007-05-22 Thread Peter Warren
The following client code generates a comet BEGIN event on the server but not a subsequent READ event, as I was expecting. How come? Is my code wrong? Are my expectations wrong? See sequence of events commented in code below. // client test method that sends messages to server and listens

Re: virtual host getRealPath

2006-11-05 Thread Peter Warren
Chris, The application is an image gallery. I want to be able to drop images into directories anywhere underneath the "gallery" webapp directory and have the images automatically displayed as thumbnails in a table. Users can click on a thumbnail for the full-size image. I have an index.

Re: virtual host getRealPath

2006-11-04 Thread Peter Warren
Hi Chris, Thanks for your response. After poking around a little more, it seems that the call application.getRealPath(request.getServletPath()) provides the proper local file path for me. Any reason not to use that? Peter Christopher Schultz <[EMAIL PROTECTED]> wrote: Peter, > I'm tr

virtual host getRealPath

2006-11-03 Thread Peter Warren
I'm trying to figure out why I get repeated directory names when calling "application.getRealPath(request.getRequestURI())" from an index.jsp file. Clearly there's something about virtual hosts and contexts that I'm missing. Using Tomcat 5.5 & 6.0 in standalone mode under Windows XP, I see the fo

threads, performance, and exceptions

2006-10-01 Thread Peter Warren
I have an application that links users so they can chat. My client operates within a browser. To be firewall friendly and avoid client server sockets listening for incoming requests, I implemented the client so that it makes http requests and sits and waits (maybe for minutes on end) until it get