Skip to content
This repository has been archived by the owner on Mar 20, 2021. It is now read-only.

End chunk not send correctly #7

Closed
glassfishrobot opened this issue Jul 4, 2007 · 10 comments
Closed

End chunk not send correctly #7

glassfishrobot opened this issue Jul 4, 2007 · 10 comments

Comments

@glassfishrobot
Copy link

Hello,

In the grizzly http, the "0\r\n\r\n" ending for a HTTP message is not send in a
seperate chunk but appended to the last data chunk.

Here is a more visual explenation:

grizzly chunked HTTP response

chunk 1 <<
HTTP/1.1 200 OK
Transform-Encoding: chunked
.. other headers

1234
hello world
0

end chunk 1 <<


other servers chunked HTTP response

chunk 1 <<
HTTP/1.1 200 OK
Transform-Encoding: chunked
.. other headers

1234
hello world

end chunk 1 <<

chunk 2 <<
HTTP/1.1 200 OK
Transform-Encoding: chunked
.. other headers

0

end chunk 2 <<


Other HTTP servers send the "0\r\n\r\n" in a seperate (as the last) chunk.
As far as I got from the HTTP spec it is supposed to be like that.

Environment

Operating System: All
Platform: All

Affected Versions

[1.9.22]

@glassfishrobot
Copy link
Author

Reported by marlor@java.net

@glassfishrobot
Copy link
Author

Was assigned to jfarcand@java.net

@glassfishrobot
Copy link
Author

marlor@java.net said:
Created an attachment (id=1)
Test case (netbeans project)

@glassfishrobot
Copy link
Author

File: grizzlyTest.zip
Attached By: marlor@java.net

@glassfishrobot
Copy link
Author

jfarcand@java.net said:
Looking at it.

@glassfishrobot
Copy link
Author

jfarcand@java.net said:
Change the version. Investigating....

@glassfishrobot
Copy link
Author

jfarcand@java.net said:
Fix target...

@glassfishrobot
Copy link
Author

oleksiys@java.net said:
As I understand it's not bug.
According to RFC [1] it's not required (or even possible) to send header for each chunk.
Chunks are sent in frame of single response.

WBR.

http://www.w3.org/Protocols/rfc2616/rfc2616-sec3.html#sec3.6.1

@glassfishrobot
Copy link
Author

Marked as incomplete on Wednesday, December 16th 2009, 6:14:16 pm

@glassfishrobot
Copy link
Author

This issue was imported from java.net JIRA GRIZZLY-7

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

1 participant