Thank you for your reply. I created a repository that demonstrates the issue.
https://github.com/tzahifadida/test-chunked
Currently it is set to 10.1.25 and fails. If you change it to 10.1.19
(in the pom.xml 10.1.19) it will
succeed. It should show 5 postings and not 1 in the output. The test
can be run with “mvn test”.
The output of the tcpdump is the same for both.
The success dump and output (you can see the deltas are greater than 0
indicating they were received one by one):
2024-08-13T11:39:29.873+03:00 INFO 9753 --- [ Thread-1]
o.s.boot.SpringApplication : No active profile set,
falling back to 1 default profile: "default"
2024-08-13T11:39:30.344+03:00 INFO 9753 --- [ Thread-1]
o.s.b.w.embedded.tomcat.TomcatWebServer : Tomcat initialized with
port(s): 8080 (http)
2024-08-13T11:39:30.350+03:00 INFO 9753 --- [ Thread-1]
o.apache.catalina.core.StandardService : Starting service [Tomcat]
2024-08-13T11:39:30.350+03:00 INFO 9753 --- [ Thread-1]
o.apache.catalina.core.StandardEngine: Starting Servlet engine:
[Apache Tomcat/10.1.19]
2024-08-13T11:39:30.397+03:00 INFO 9753 --- [ Thread-1]
o.a.c.c.C.[Tomcat].[localhost].[/] : Initializing Spring
embedded WebApplicationContext
2024-08-13T11:39:30.398+03:00 INFO 9753 --- [ Thread-1]
w.s.c.ServletWebServerApplicationContext : Root WebApplicationContext:
initialization completed in 499 ms
2024-08-13T11:39:30.582+03:00 INFO 9753 --- [ Thread-1]
o.s.b.w.embedded.tomcat.TomcatWebServer : Tomcat started on port(s):
8080 (http) with context path ''
2024-08-13T11:39:30.586+03:00 INFO 9753 --- [ Thread-1]
o.s.boot.SpringApplication : Started application in
0.944 seconds (process running for 1.334)
2024-08-13T11:39:34.693+03:00 INFO 9753 --- [nio-8080-exec-1]
o.a.c.c.C.[Tomcat].[localhost].[/] : Initializing Spring
DispatcherServlet 'dispatcherServlet'
2024-08-13T11:39:34.693+03:00 INFO 9753 --- [nio-8080-exec-1]
o.s.web.servlet.DispatcherServlet: Initializing Servlet
'dispatcherServlet'
2024-08-13T11:39:34.694+03:00 INFO 9753 --- [nio-8080-exec-1]
o.s.web.servlet.DispatcherServlet: Completed initialization in
1 ms
2024-08-13T11:39:34.708+03:00 INFO 9753 --- [nio-8080-exec-1]
com.example.chunked.ChunkedController: EndPoint Controller /post
2024-08-13T11:39:35.630+03:00 INFO 9753 --- [nio-8080-exec-1]
com.example.chunked.ChunkedController: Reading from POST stream:
PostingData 0 , delta: 922, counter: 1
2024-08-13T11:39:36.633+03:00 INFO 9753 --- [nio-8080-exec-1]
com.example.chunked.ChunkedController: Reading from POST stream:
PostingData 1 , delta: 1001, counter: 2
2024-08-13T11:39:37.637+03:00 INFO 9753 --- [nio-8080-exec-1]
com.example.chunked.ChunkedController: Reading from POST stream:
PostingData 2 , delta: 1003, counter: 3
2024-08-13T11:39:38.642+03:00 INFO 9753 --- [nio-8080-exec-1]
com.example.chunked.ChunkedController: Reading from POST stream:
PostingData 3 , delta: 1004, counter: 4
2024-08-13T11:39:39.646+03:00 INFO 9753 --- [nio-8080-exec-1]
com.example.chunked.ChunkedController: Reading from POST stream:
PostingData 4 , delta: 1004, counter: 5
11:39:34.653512 IP localhost.49328 > localhost.http-alt: Flags [P.],
seq 1784064028:1784064203, ack 571601977, win 6379, options
[nop,nop,TS val 3085463629 ecr 2661427862], length 175: HTTP: POST
/post HTTP/1.1
E.@.@...jV.."..9...
..pM..*.POST /post HTTP/1.1
Content-Type: application/octet-stream
User-Agent: Java/22.0.2
Host: localhost:8080
Accept: */*
Connection: keep-alive
Transfer-Encoding: chunked
11:39:35.628844 IP localhost.49328 > localhost.http-alt: Flags [P.],
seq 175:194, ack 1, win 6379, options [nop,nop,TS val 3085464606 ecr
2661427863], length 19: HTTP
E..G..@.@...jV.."..9.;.
..t...*.e
PostingData 0
11:39:36.633382 IP localhost.49328 > localhost.http-alt: Flags [P.],
seq 194:213, ack 1, win 6379, options [nop,nop,TS val 3085465610 ecr
2661428840], length 19: HTTP
E..G..@.@...jV.."..9.;.
..x
...he
PostingData 1
11:39:37.637367 IP localhost.49328 > localhost.http-alt: Flags [P.],
seq 213:232, ack 1, win 6379, options [nop,nop,TS val 3085466614 ecr
2661429844], length 19: HTTP
E..G..@.@...jV.."..9.;.
..{...2Te
PostingData 2
11:39:38.641831 IP localhost.49328 > localhost.http-alt: Flags [P.],
seq 232:251, ack 1, win 6379, options [nop,nop,TS val 3085467618 ecr
2661430848], length 19: HTTP
E..G..@.@...jV.."..9.;.
..6@e
PostingData 3
11:39:39.645695 IP localhost.49328 > localhost.http-alt: Flags [P.],
seq 251:270, ack 1, win 6379, options [nop,nop,TS val 3085468623 ecr
2661431852], length 19: HTTP
E..G..@.@...jV.."..9.;.
..:,e
PostingData 4
11:39:39.646338 IP localhost.49328 > localhost.http-alt: Flags [P.],
seq 270:273, ack 1, win 6379, options [nop,nop,TS val 3085468623 ecr
2661432857], length 3: HTTP
E..7..@.@..