Commit Graph

479 Commits

Author SHA1 Message Date
Ludovic Orban 76962e966a
Merge remote-tracking branch 'origin/jetty-12.0.x' into jetty-12.1.x 2024-09-16 09:32:11 +02:00
Ludovic Orban ceee65a7e5 #12268 do not rely on time
Signed-off-by: Ludovic Orban <lorban@bitronix.be>
2024-09-16 09:11:54 +02:00
Ludovic Orban 2018c439b6 #12268 reset _iterate flag when another processing is scheduled
Signed-off-by: Ludovic Orban <lorban@bitronix.be>
2024-09-16 09:11:54 +02:00
Olivier Lamy 65e9bba44c
next snapshot
Signed-off-by: Olivier Lamy <olamy@apache.org>
2024-09-03 21:44:43 +10:00
Olivier Lamy 816018a420
Updating to version 12.0.13 2024-09-03 13:03:43 +10:00
Ludovic Orban 8084cc575a fix flaky test by not asserting a number of idle threads that is above the minimum
Signed-off-by: Ludovic Orban <lorban@bitronix.be>
2024-09-02 19:34:15 +02:00
gregw e58eef20d7 Merge remote-tracking branch 'origin/jetty-12.0.x' into jetty-12.1.x 2024-09-02 11:51:07 +10:00
gregw eecf4cf555 Tagged tests as Isolated that modify the static RESOURCE_FACTORIES 2024-09-02 11:50:17 +10:00
Simone Bordet 4ee55c2a4d
Merged branch 'jetty-12.0.x' into 'jetty-12.1.x'.
Signed-off-by: Simone Bordet <simone.bordet@gmail.com>
2024-08-30 12:12:52 +02:00
Simone Bordet 1726c8778c
Fixes HttpClient Content.Source reads from arbitrary threads (#12203)
* Reworked HttpReceiverOverHTTP state machine, in particular:
** Introduced a boolean parameter to parseAndFill() and parse(), that specifies whether to notify the application demand callback.
   This is necessary because reads may happen from any threads, and must not notify the application demand callback.
   Only when there is no data, and fill interest is set, then the application demand callback must be notified.
** Removed action field to avoid lambda allocation.
** Now the application is called directly from the parse() method.
** Reading -1 from the network drives the parser by calling again parse(), rather than the parser directly.
  This allows to have a central place to notify the response success event.

* Fixed FastCGI similarly to HTTP/1.1.
* Removed leftover of the multiplex implementation.

* Fixed test flakyness in `NetworkTrafficListenerTest`: consume the request content before sending the response.

* Follow up after #10880: only abort the request if there is request content in `AuthenticationProtocolHandler` and `RedirectProtocolHandler`.
  This avoids the rare case where the response arrives before the request thread has modified the request state, even if the request has been fully sent over the network, causing the request to be failed even if it should not.

* added `SerializedInvoker` assertions about current thread invoking.
* Name all SerializedInvoker instances for better troubleshooting.

Signed-off-by: Simone Bordet <simone.bordet@gmail.com>
Signed-off-by: Ludovic Orban <lorban@bitronix.be>
Co-authored-by: Ludovic Orban <lorban@bitronix.be>
2024-08-30 12:01:43 +02:00
gregw 1ea02673ac Merge remote-tracking branch 'origin/jetty-12.0.x' into jetty-12.1.x 2024-08-28 20:29:02 +10:00
gregw 1bf074894a Merge branch 'fork/Tony-the-Tech/fix/12.0.x/SslContextFactory_use_credential' into jetty-12.0.x
Updated with call to check if old behaviour has been extended.
2024-08-28 09:13:22 +10:00
Simone Bordet f7e0e523d9
Merged branch 'jetty-12.0.x' into 'jetty-12.1.x'.
Signed-off-by: Simone Bordet <simone.bordet@gmail.com>
2024-08-27 10:05:20 +02:00
Simone Bordet 0420e926a1
Fixes #12171 - QoSHandler does not resume on a virtual thread. (#12174)
Now QoSHandler resumes requests using Request.getComponents().getExecutor().
This Executor is configured to be the virtual thread executor, if present, otherwise the Server Executor.

Removed warn() from VirtualThreads.isVirtualThread(), as it was too verbose.

Signed-off-by: Simone Bordet <simone.bordet@gmail.com>
2024-08-27 10:03:48 +02:00
Joakim Erdfelt c97f5d7ac8
Merge remote-tracking branch 'origin/jetty-12.0.x' into jetty-12.1.x 2024-08-26 11:50:22 -04:00
Simone Bordet 1e95e89ddc
Merged branch 'jetty-12.0.x' into 'jetty-12.1.x'.
Signed-off-by: Simone Bordet <simone.bordet@gmail.com>
2024-08-26 11:28:34 +02:00
Lachlan Roberts 8464340f07
Fix potential NPE from VirtualThreadPool
Signed-off-by: Lachlan Roberts <lachlan.p.roberts@gmail.com>
2024-08-26 12:36:53 +10:00
Greg Wilkins 7d7eeb3b1e
Experiment with IteratingCallback (#12040)
The previous semantic of `onCompleteFailure` has been renamed to `onFailure(Throwable)`, which is called immediately (but serialized) on either an abort or a failure.   A new `onCompleteFailure(Throwable)` method has been added that is called only after a `failed(throwable)` or a `abort(Throwable)` followed by `succeeded()` or `failed(Throwable)``

No usage has yet been made of the new `onCompleteFailure`, but the ICB implementation has been completely replaced by the one developed in #11876

Signed-off-by: Simone Bordet <simone.bordet@gmail.com>
Signed-off-by: Ludovic Orban <lorban@bitronix.be>
Co-authored-by: Simone Bordet <simone.bordet@gmail.com>
Co-authored-by: Ludovic Orban <lorban@bitronix.be>
2024-08-26 10:18:57 +10:00
Tony Copping 66e4bd862f Issue #12175 Updates based on feedback
Signed-off-by: Tony Copping <tony@sigsoft.ca>
2024-08-24 10:05:01 -06:00
Simone Bordet 8e6ad22b69
Merged branch 'jetty-12.0.x' into 'jetty-12.1.x'.
Signed-off-by: Simone Bordet <simone.bordet@gmail.com>
2024-08-21 11:38:00 +02:00
Simone Bordet 0644aaf88c
Fixes #12154 - Limit concurrent virtual threads. (#12155)
Updated VirtualThreadPool to limit the number of concurrent virtual threads using a Semaphore.

Updated modules and documentation.

Signed-off-by: Simone Bordet <simone.bordet@gmail.com>
2024-08-21 10:44:20 +02:00
Olivier Lamy 2ca9be96ae
change urls https://eclipse.dev to https://jetty.org (#12172)
* change urls https://eclipse.dev to  https://jetty.org

---------

Signed-off-by: Olivier Lamy <olamy@apache.org>
2024-08-21 07:18:20 +02:00
Greg Wilkins 8b4e13dbea
Jetty 12.1.x 12088 core requested session ID source (#12145)
add isRequestedSessionIdFromCookie/URL for core request

Co-authored-by: Jan Bartel <janb@webtide.com>
2024-08-20 15:14:37 +10:00
Tony Copping 2f22767dc1 Issue #12175 Update SslContextFactory to use Credential instead of Password
Signed-off-by: Tony Copping <tony@sigsoft.ca>
2024-08-19 18:41:35 -06:00
Simone Bordet 775c458960
Merged branch 'jetty-12.0.x' into 'jetty-12.1.x'.
Signed-off-by: Simone Bordet <simone.bordet@gmail.com>
2024-08-13 15:54:47 +02:00
Simone Bordet fc9cbda52f
Improved handling of 100 Continue (#12113)
* Now `HttpClient` removed the `Expect` header if there is no request content.
* Changed AbstractProxyServlet and ProxyHandler check for request content: now the Content-Type header is not taken into consideration.
* Now the server avoids sending the 100 Continue response if there is no request content.
* Now the request body is not defaulted if missing, but just kept null.

Signed-off-by: Simone Bordet <simone.bordet@gmail.com>
2024-08-13 15:06:50 +02:00
gregw 2ba2250ac8 updates from review
introduce default buffer size constant
2024-08-07 10:37:24 +02:00
Ludovic Orban 347dee0ba5 - Replace ByteBufferPool + size + directness with ByteBufferPool.Sized in HttpContent-related code
- Cleanup and javadoc HttpContent
 - Align and cleanup offset/length default values

Signed-off-by: Ludovic Orban <lorban@bitronix.be>
2024-08-07 10:37:24 +02:00
gregw bcd73c6a7b Merge remote-tracking branch 'origin/jetty-12.0.x' into jetty-12.1.x 2024-08-05 13:11:38 +10:00
Greg Wilkins abab5949ea
Fix #12128 Combined ClassLoader Resources (#12130)
Fix #12104 by returning a CombinedResource for a ClassLoader resource that has multiple directory matches.
2024-08-05 13:09:53 +10:00
Joakim Erdfelt d3af12957b
Updating to version 12.0.13-SNAPSHOT 2024-07-25 17:23:21 -05:00
Joakim Erdfelt cc6f1b74db
Updating to version 12.0.12 2024-07-25 16:57:59 -05:00
Ludovic Orban 834db77605
Implement HttpContent.writeTo() async API (#12020)
#8790 implement HttpContent.writeTo() async API

Signed-off-by: Ludovic Orban <lorban@bitronix.be>
2024-07-24 14:07:31 +02:00
Ludovic Orban 7b3e953e56
Merge remote-tracking branch 'origin/jetty-12.0.x' into merge/jetty-12.1.x/update-from-12_0 2024-07-19 11:02:16 +02:00
Greg Wilkins 12db285f17
Remove usage of a SecurityManager from EE11 (#12032)
Use callAs rather than doAs
Disable after java 21
2024-07-15 13:32:34 +10:00
Ludovic Orban 1a38b6884e
Make `Fields` interpret null values as empty strings (#12024)
#12018 make Fields interpret null values as empty strings

Signed-off-by: Ludovic Orban <lorban@bitronix.be>
2024-07-12 10:55:12 +02:00
Ludovic Orban 8f5207e6ca
Fix broken client tls negotiation (#11999)
#11965 make EMPTY_BUFFER not read-only anymore

Signed-off-by: Ludovic Orban <lorban@bitronix.be>
2024-07-10 16:52:51 +02:00
gregw 5903efdf96 Merge remote-tracking branch 'origin/jetty-12.0.x' into jetty-12.1.x
# Conflicts:
#	jetty-core/jetty-http3/jetty-http3-common/src/main/java/org/eclipse/jetty/http3/InstructionFlusher.java
#	jetty-core/jetty-io/src/main/java/org/eclipse/jetty/io/ArrayByteBufferPool.java
#	jetty-core/jetty-io/src/main/java/org/eclipse/jetty/io/content/BufferedContentSink.java
#	jetty-ee10/jetty-ee10-servlet/src/test/java/org/eclipse/jetty/ee10/servlet/ContextScopeListenerTest.java
#	jetty-ee9/jetty-ee9-nested/src/main/java/org/eclipse/jetty/ee9/nested/HttpOutput.java
2024-07-01 11:05:47 +10:00
Joakim Erdfelt f5abe07ade
Updating to version 12.0.12-SNAPSHOT 2024-06-27 19:09:24 -05:00
Joakim Erdfelt 9f90cedce3
Updating to version 12.0.11 2024-06-27 18:42:08 -05:00
Joakim Erdfelt c7ad22e861
Merge remote-tracking branch 'origin/jetty-12.0.x' into jetty-12.1.x 2024-06-27 06:45:25 -05:00
Ludovic Orban c0af0e6d8d
#11932 revert final modifier
Signed-off-by: Ludovic Orban <lorban@bitronix.be>
2024-06-27 11:47:54 +02:00
Ludovic Orban 6188757500
#11932 fix bug in case of invalid action + add test
Signed-off-by: Ludovic Orban <lorban@bitronix.be>
2024-06-27 11:47:53 +02:00
Ludovic Orban cea6b4ad98
#11932 improve javadoc
Signed-off-by: Ludovic Orban <lorban@bitronix.be>
2024-06-27 11:46:41 +02:00
Ludovic Orban 25bbdb5efc
#11932 refactor H3 message flusher to have ICB succeeded and failed final
Signed-off-by: Ludovic Orban <lorban@bitronix.be>
2024-06-27 11:46:39 +02:00
Ludovic Orban 6d0bddc07a
#11932 make succeeded and failed in ICB final + introduce onSuccess
Signed-off-by: Ludovic Orban <lorban@bitronix.be>
2024-06-27 11:46:18 +02:00
Greg Wilkins 15bcc5ecb0
Cleanups extracted from delayed PR #11876 (#11958)
* Cleanups extracted from delayed PR #11876

* Update from review
2024-06-26 16:49:58 +10:00
Joakim Erdfelt f78f4422f5
Issue #11925 - Fix Etag NPE when using URLResource and improve Base Resource is alias warning (#11930)
* Issue #11925 - ee9 DefaultServlet and suffix url-patterns.
* Issue #11925 - Fix NPE in EtagUtils with URLResource
* Issue #11925 - Make error message "Base Resource should not be an alias" more useful.
* Set <reuseForks> to false for problematic tests.
2024-06-25 08:11:35 -05:00
gregw 4228f8e76b Merge remote-tracking branch 'origin/jetty-12.0.x' into jetty-12.1.x 2024-06-25 09:32:38 +10:00
Greg Wilkins 36538d6e69
RetainableByteBuffer as mutable (#11801)
Tweaks to the RBB API to make the concept more uniform throughout the codebase.

* Make chunk a RBB
* Added Dynamic RBB as a replacement for both Accumulator and Aggregator

---------

Signed-off-by: Ludovic Orban <lorban@bitronix.be>
Co-authored-by: Ludovic Orban <lorban@bitronix.be>
2024-06-25 08:12:41 +10:00