Skip to content

Conversation

@gregw
Copy link
Contributor

@gregw gregw commented Sep 23, 2025

Fix #13613. Due to a limitation in the implementation of try-with-resource, we should avoid rethrowing the same exception. This PR makes a lazy copy of the exception in Chunk.next(Chunk).

Fix #13613. Due to a limitation in the implementation of try-with-resource, we should avoid rethrowing the same exception.  This PR makes a copy of the exception.
Fix #13613. Due to a limitation in the implementation of try-with-resource, we should avoid rethrowing the same exception.  This PR makes a copy of the exception.
@gregw gregw requested review from lorban and sbordet September 23, 2025 23:28
Fix #13613. Due to a limitation in the implementation of try-with-resource, we should avoid rethrowing the same exception.  This PR makes a copy of the exception.
@gregw gregw requested review from lorban and sbordet September 26, 2025 02:42
@gregw gregw requested a review from sbordet September 26, 2025 23:00
@sbordet sbordet requested review from joakime and sbordet September 29, 2025 09:48
Signed-off-by: Simone Bordet <simone.bordet@gmail.com>
sbordet and others added 2 commits September 29, 2025 18:37
…lures.

Now that a new Chunk with a new failure is returned, retain the failure from
the second read only if the second failure's cause is different from the
failure of the first read.

Signed-off-by: Simone Bordet <simone.bordet@gmail.com>
lorban
lorban previously approved these changes Sep 30, 2025
Signed-off-by: Simone Bordet <simone.bordet@gmail.com>
@gregw gregw changed the title Fix/12.1.x/13613 do not rethrow Do not rethrow Content.Source exceptions Sep 30, 2025
@gregw gregw merged commit 501dc71 into jetty-12.1.x Oct 1, 2025
6 of 10 checks passed
@github-project-automation github-project-automation bot moved this from 👀 In review to ✅ Done in Jetty 12.1.2 - FROZEN Oct 1, 2025
@gregw gregw deleted the fix/12.1.x/13613-do-not-rethrow branch October 1, 2025 22:41
lorban added a commit that referenced this pull request Oct 8, 2025
Due to a limitation in the implementation of try-with-resource, we should avoid rethrowing the same exception. This PR makes a copy of the exception.

Backport of #13614 to fix #13675

Signed-off-by: Ludovic Orban <lorban@bitronix.be>
lorban added a commit that referenced this pull request Oct 8, 2025
Due to a limitation in the implementation of try-with-resource, we should avoid rethrowing the same exception. This PR makes a copy of the exception.

Backport of #13614 to fix #13675

Signed-off-by: Ludovic Orban <lorban@bitronix.be>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

No open projects
Status: ✅ Done

Development

Successfully merging this pull request may close these issues.

HttpInput#read rethrows already thrown exception, leading to possible self-suppressing exception issue

5 participants