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, I've had to change my comet client to use HttpURLConnection
instead of Sockets.  (Accessing ProxySelector from an applet to create
a socket with a proxy generates an AccessControlException.)

HttpURLConnection unfortunately sends a 0crlf when its input stream is
retrieved for reading.  This generates a Comet END event.  Short of
closing the comet event, how can I make the server stop notifying me
of END events?  I can't close the comet event because I want to hold
onto the comet output stream for use later to send data to the client.

>From the comet docs:
EventType.END: End may be called to end the processing of the request.
Fields that have been initialized in the begin method should be reset.
After this event has been processed, the request and response objects,
as well as all their dependent objects will be recycled and used to
process other requests. End will also be called when data is available
and the end of file is reached on the request input (this usually
indicates the client has pipelined a request).

This seems to indicate that even if I could get the END event to go
away quietly, the comet event's output stream might no longer be
usable anyway.

It seems to me I have 3 options:
1) figure out how to make the comet END event stop repeating and hope
it's output stream still works
2) figure out how to keep HttpURLConnection from sending 0crlf (don't
know if that can be done)
2) use sockets with ProxySelector (which requires signing my applet
and getting users to grant it privileges)

Thanks,
Peter

---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to