• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
  • Mikalai Zaikin

runing servlet on was4.0 from silverstream

Posts: 3
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
We are having problems with SilverStream/Websphere's implementation of chunked transfer when trying to make a
httprequest from SilverStream to a servlet located at a Websphere 4.0 server.
We are getting a SilverStream specific IOException saying "Invalid trailer for chunked transfer."
The request from SilverStream is:
GET /personKunde/servlet/kundeinfoServlet?knr=0465532889 HTTP/1.1
Connection: Keep-Alive
Date: Tue, 13 Nov 2001 09:39:56 GMT
Accept: */*
Accept-Language: enUS;q=1.0
Host: Z002815.intra.gjensidige.no:8080
User-Agent: SilverStream Client/10.0

And the response from WebSphere is:
HTTP/1.1 200 OK
Date: Tue, 13 Nov 2001 09:40:13 GMT
Server: IBM_HTTP_SERVER/1.3.19 Apache/1.3.20 (Win32)
Keep-Alive: timeout=15, max=100
Connection: Keep-Alive
Transfer-Encoding: chunked
Content-Type: text/html
Content-Language: en
<?xml version="1.0" encoding="iso-8859-1" ?>
<kundeinfo versjonsnr="1" feilmelding="">
<adresse type="BESOK"><linje1>Elm Street17</linje1>
<land></land></adresse><telefon type="HJEMME">22 33 91</telefon></kundeinfo>

I guess it's the "0" byte it doesn't understand, i.e. it doesn't think it's a trailer or something.
The exception that we get in silverstream is
java.io.IOException: Invalid trailer for chunked transfer.
at com.sssw.shr.http.ChunkedInputStream.readTrailer(ChunkedInputStream.java:136)
at com.sssw.shr.http.ChunkedInputStream.read(ChunkedInputStream.java:155)
at java.io.InputStream.read(InputStream.java:91)
at java.io.InputStreamReader.fill(InputStreamReader.java:173)
at java.io.InputStreamReader.read(InputStreamReader.java:249)
at java.io.BufferedReader.fill(BufferedReader.java:139)
at java.io.BufferedReader.readLine(BufferedReader.java:299)
at java.io.BufferedReader.readLine(BufferedRead.....
Since SilverStream has a class called ChunkedInputStream it does understand chunked transfers.
We have tested with servlets that doesn't use chunked transfers, and that works well with SilverStream,
the problem is that we have to use chunked transfer on the servlet at WebSphere.
So, what's wrong?
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
    Bookmark Topic Watch Topic
  • New Topic