Re: Issue with Chunked Transfer Encoding in Tomcat 10.1.25-10.1.28 with Spring

2024-08-13 Thread Itzhak Fadida
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..@.@..

[ANN] Apache Tomcat Connectors 1.2.50 released

2024-08-13 Thread Mark Thomas

The Apache Tomcat Connectors project is part of the Tomcat project and
provides web server plugins for httpd (mod_jk) and IIS (ISAPI) to 
connect those web servers with Tomcat and other backends.


The Apache Tomcat Project is proud to announce the release of version
1.2.50 of the Apache Tomcat Connectors.
This version fixes a number of bugs found in previous releases.

Full details of these changes and new features,
are available in the Apache Tomcat Connectors changelog:
https://tomcat.apache.org/connectors-doc/miscellaneous/changelog.html

In addition to the usual source release, this release includes Windows
binaries for the JK ISAPI connector for IIS.

Downloads:
https://tomcat.apache.org/download-connectors.cgi

Thank you,
--
The Apache Tomcat Team

-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



Re: Issue with Chunked Transfer Encoding in Tomcat 10.1.25-10.1.28 with Spring

2024-08-13 Thread Mark Thomas

On 13/08/2024 09:48, Itzhak Fadida wrote:

Thank you for your reply. I created a repository that demonstrates the issue.

https://github.com/tzahifadida/test-chunked


Thanks. That is very helpful.

git bisect has identified this commit:

https://github.com/apache/tomcat/commit/92e3c7a7adc574a859ab70333bf930561dcf1e9d

as the cause of the change in behaviour.

That makes sense as it is a change to the processing of chunked requests.

I need to debug this further to figure out what and where the root cause is.

Mark

-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



Migration to Tomcat Assistance

2024-08-13 Thread Baez, Melvin L
Hi all,

I'm reaching out to the community seeking assistance. I support Tomcat from an 
infrastructure perspective and assist our developers with migrating a set of 
existing applications from WebSphere and TomEE to Tomcat as the application web 
server.
We are trying to come up with a streamlined process of helping applications 
move to Tomcat, while accommodating their specific requirements.
I'm looking for utilities, scripts, cheatsheets that can assist us. Also, if 
there are other references of mapping libraries/jar files to features that 
would be helpful.

Thanks in advance!



[cid:image001.png@01DAED9D.98BEF230]
Melvin L Baez Jr
Specialist, Technology Engineer
Proud Nationwide Member
IT I&O Ops Web Middleware
W 614-677-7281
bae...@nationwide.com