Thanks for the reply. The truncation or zero bytes happens on both
compressed or none compressed incoming stream. I also tried use follow code
to detect the missing bytes:
  BufferedInputStream buf= new BufferedInputStream(req.getInputStream());
  bytes = buf.available();
The available() method always return correct length as returned from
contentLength(). But when reading the data out, the truncation still may
happen and the last read always with 5 minutes delay. I am so far failed to
find a reliable servlet or stream method to find out such problem forehand
without delay. The cause of the problem is even more puzzling.

Dunping

-----Original Message-----
From: Nic Ferrier [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, August 28, 2001 3:36 AM
To: [EMAIL PROTECTED]
Subject: Re: ServletInputstream empty or truncated


> Here is some relevant code:


This is the bit I wouldn't trust:

>   BufferedReader rd = new BufferedReader(
>       new InputStreamReader(Decompressor.decompressData(
>                              Decompressor.ZLIB_COMPRESSED,
inputstream) ) );

What happens if you take compression out of it and send the data to the
server un-encrypted?


Nic Ferrier

___________________________________________________________________________
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff SERVLET-INTEREST".

Archives: http://archives.java.sun.com/archives/servlet-interest.html
Resources: http://java.sun.com/products/servlet/external-resources.html
LISTSERV Help: http://www.lsoft.com/manuals/user/user.html

___________________________________________________________________________
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff SERVLET-INTEREST".

Archives: http://archives.java.sun.com/archives/servlet-interest.html
Resources: http://java.sun.com/products/servlet/external-resources.html
LISTSERV Help: http://www.lsoft.com/manuals/user/user.html

Reply via email to