Commit Graph

20729 Commits

Author SHA1 Message Date
Lachlan 2e1c01ac8c
Merge pull request #4723 from eclipse/jetty-10.0.x-WebSocketServlet
Issue #4722 - remove websocket-servlet
2020-05-07 22:45:04 +10:00
olivier lamy c8c341f9b4 fix license header
Signed-off-by: olivier lamy <oliver.lamy@gmail.com>
2020-05-06 07:40:10 +10:00
Joakim Erdfelt eba5028bcf
Merge remote-tracking branch 'origin/jetty-9.4.x' into jetty-10.0.x 2020-05-05 10:03:27 -05:00
Joakim Erdfelt e4fd49dc36
Merge pull request #4838 from eclipse/jetty-9.4.x-4835-gziphandler-flush
Issue #4835 - Addressing flush/commit with GzipHttpOutputInterceptor
2020-05-05 09:54:41 -05:00
Joakim Erdfelt 1d734e1daf
Merge pull request #4779 from eclipse/jetty-10.0.x-4770-simplify-gzip-testing
Issue #4770 - Deprecate GzipTester
2020-05-05 09:54:23 -05:00
Simone Bordet 1c22de433b Merged branch 'jetty-9.4.x' into 'jetty-10.0.x'.
Signed-off-by: Simone Bordet <simone.bordet@gmail.com>
2020-05-04 19:11:26 +02:00
Joakim Erdfelt adeb6084b2
Issue #4770 - GzipHandler testing (Addressing PR review)
Signed-off-by: Joakim Erdfelt <joakim.erdfelt@gmail.com>
2020-05-04 11:52:56 -05:00
Simone Bordet 0ab2b42055
Merge pull request #4823 from eclipse/jetty-9.4.x-4798-recover_selector_failures
Issue #4798 - Recover from Selector Failures
2020-05-04 17:43:28 +02:00
Simone Bordet 66d78b2059 Issue #4778 - Enforcing SNI when there are only non-wildcards certificates.
Fixed test case after merge.

Signed-off-by: Simone Bordet <simone.bordet@gmail.com>
2020-05-04 17:13:51 +02:00
Joakim Erdfelt d58da0f7d2
Issue #4824 - Addressing flush/commit with GzipHttpOutputInterceptor
Signed-off-by: Joakim Erdfelt <joakim.erdfelt@gmail.com>
2020-05-04 09:22:08 -05:00
Simone Bordet 99ecfca439 Merged branch 'jetty-9.4.x' into 'jetty-10.0.x'. 2020-05-04 13:00:15 +02:00
Simone Bordet 2fa161c515
Merge pull request #4790 from eclipse/jetty-9.4.x-4778-sni_with_one_certificate
Fixes #4778 - Enforcing SNI when there are only non-wildcards certifi…
2020-05-04 11:35:04 +02:00
Lachlan 07551baef7
Merge pull request #4810 from eclipse/jetty-10.0.x-LinkageErrorInvestigation
Issue #4800 - fix WebSocket LinkageError and invalid PathParam type handling
2020-05-04 11:17:29 +10:00
Simone Bordet 267039f3f5 Improvements to the Jetty server documentation.
Added section on JMX.

Signed-off-by: Simone Bordet <simone.bordet@gmail.com>
2020-05-03 21:19:10 +02:00
Joakim Erdfelt c645d0f7c4
Issue #4835 - Addressing flush/commit with GzipHttpOutputInterceptor
Signed-off-by: Joakim Erdfelt <joakim.erdfelt@gmail.com>
2020-05-01 14:42:08 -05:00
Jan Bartel f154151016
Jetty 10.0.x 4825 pushbuilder (#4829)
* Issue #4825 Implement spec requirements for Request.newPushBuilder

Signed-off-by: Jan Bartel <janb@webtide.com>
2020-05-01 11:07:06 +02:00
Lachlan Roberts e5cca92199 Merge remote-tracking branch 'origin/jetty-10.0.x' into jetty-10.0.x-WebSocketServlet
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-05-01 15:46:03 +10:00
olivier lamy fe28b33166 Merge branch 'jetty-9.4.x' into jetty-10.0.x 2020-05-01 13:06:05 +10:00
Lachlan Roberts 9bc9082ff3 Fix broken WebSocket UTF-8 continuation test
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-05-01 13:01:40 +10:00
Olivier Lamy abb26d0781
Jetty 9.4.x hazelcast fix non needed dependency (#4832)
* no need to websocket dependency in jetty-hazelcast

Signed-off-by: olivier lamy <oliver.lamy@gmail.com>

* fix dependency

Signed-off-by: olivier lamy <oliver.lamy@gmail.com>
2020-05-01 11:21:42 +10:00
Lachlan Roberts 3a3c5e5df3 Fix broken OSGI tests due to websocket-util-server
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-05-01 01:35:19 +10:00
Simone Bordet 0a028b663b Issue #4798 - Better handling of fatal Selector failures.
More updates after review.

Signed-off-by: Simone Bordet <simone.bordet@gmail.com>
2020-04-30 10:55:29 +02:00
Lachlan Roberts 1ad600ea49 fix WS DistributionTest incorrect test expectation
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-04-30 10:14:43 +10:00
Simone Bordet fa94cc2f6c Merged branch 'jetty-9.4.x' into 'jetty-10.0.x'. 2020-04-29 17:07:25 +02:00
Simone Bordet ac97bc3b31
Merge pull request #4803 from lorban/jetty-9.4.x-channel-recycling-h2
Solve lock contention creating HTTP2 streams (#2188) …
2020-04-29 15:18:50 +02:00
Lachlan Roberts b0e57ffd6d Merge remote-tracking branch 'origin/jetty-10.0.x' into jetty-10.0.x-LinkageErrorInvestigation 2020-04-29 22:52:33 +10:00
Lachlan Roberts bf5d4ea554 Issue #4800 - Revert MethodHandle changes & update DistributionTests
- It seems it is correct to use the `MethodHandles.publicLookup().in()`
but this does not work if same webapp is deployed twice, so the
MethodHandle changes have been reverted and the test has been disabled
until a resolution to https://bugs.openjdk.java.net/browse/JDK-8244090.

- The DistributionTest has been changed to properly reproduce the issue.
There must be a class in the signature of the websocket endpoint which
is available to both webapps and the client must send and receive an echo
message to ensure that the onOpen MethodHandle is actually invoked.

Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-04-29 22:52:26 +10:00
Ludovic Orban 6729a6f689 Solve lock contention creating HTTP2 streams (#2188) while fixing race condition that breaks http channels recycling (#4695)
Signed-off-by: Ludovic Orban <lorban@bitronix.be>
2020-04-29 14:25:51 +02:00
Simone Bordet 8c75eeccce Issue #4798 - Better handling of fatal Selector failures.
Updates after review.

Signed-off-by: Simone Bordet <simone.bordet@gmail.com>
2020-04-29 11:57:06 +02:00
Greg Wilkins 81c46638cd
Jetty 10.0.x 4814 configuring connection factory (#4815)
* Issue #4814 Configuring Connection Factory

Redo of this PR without Attributes improvements (moved to #4816).
Add a ConnectionFactory.Configuring interface to all connectors to be configured during doStart.
I have some concern about shared HttpConfigurations.

Signed-off-by: Greg Wilkins <gregw@webtide.com>

* updates from review

Signed-off-by: Greg Wilkins <gregw@webtide.com>
2020-04-29 11:45:08 +02:00
olivier lamy 4a4626614c ooops checkstyle
Signed-off-by: olivier lamy <oliver.lamy@gmail.com>
2020-04-29 15:22:35 +10:00
olivier lamy c5f8cf2f6a add a parameter to add jvm args
Signed-off-by: olivier lamy <oliver.lamy@gmail.com>
2020-04-29 14:11:41 +10:00
Joakim Erdfelt 1b5ad92d36
Merge remote-tracking branch 'origin/jetty-9.4.x' into jetty-10.0.x 2020-04-28 13:46:12 -05:00
Joakim Erdfelt 3998e657cc
Merge remote-tracking branch 'origin/jetty-9.3.x' into jetty-9.4.x 2020-04-28 13:45:29 -05:00
Joakim Erdfelt 85e3a4b5a6
Merge remote-tracking branch 'origin/jetty-9.2.x' into jetty-9.3.x 2020-04-28 13:44:12 -05:00
Joakim Erdfelt f9a215f18d
Merge branch 'origin/jetty-10.0.x' into jetty-10.0.x-4770-simplify-gzip-testing 2020-04-28 11:33:31 -05:00
Joakim Erdfelt ce78b195d1
Merge pull request #4811 from eclipse/jetty-9.2.x-old-android-workarounds
Issue #4819 - Workarounds for old (pre API 24) Android SDKs
2020-04-28 11:31:12 -05:00
Greg Wilkins 8c7e34f37d
Jetty 10.0.x immutable meta data (#4777)
Made HttpURI, HttpFields and MetaData immutable.  The first two follow the same builder pattern and MetaData is constructor injection only.

* Immutable version of HttpFields

Preserve API and usage of HttpFields class while providing a read only interface and immutable implementation.

Signed-off-by: Greg Wilkins <gregw@webtide.com>

* Immutable version of HttpFields

Use an ArrayList in HttpFields. While slightly slower than the array, it will mostly be used as a builder pattern for an Immutable

Signed-off-by: Greg Wilkins <gregw@webtide.com>

* Immutable version of HttpFields

Fixed exception type.

Signed-off-by: Greg Wilkins <gregw@webtide.com>

* Immutable version of HttpFields

asImmutable method

Signed-off-by: Greg Wilkins <gregw@webtide.com>

* Immutable MetaData

Made HttpURIU immutable with a builder pattern.
MetaData immutable and working within http module.

Signed-off-by: Greg Wilkins <gregw@webtide.com>

* Immutable MetaData

Fixes from review

Signed-off-by: Greg Wilkins <gregw@webtide.com>

* Immutable MetaData

Passing tests upto and including jetty-server

Signed-off-by: Greg Wilkins <gregw@webtide.com>

* Immutable MetaData

Cleanup of HttpURI.Builder API as suggested in PR.

Signed-off-by: Greg Wilkins <gregw@webtide.com>

* Immutable MetaData

Added builder for MetaData.Request

Signed-off-by: Greg Wilkins <gregw@webtide.com>

* Immutable MetaData

more api fixes

Signed-off-by: Greg Wilkins <gregw@webtide.com>

* Immutable MetaData

WIP making HttpFiels itself immutable.  Currently working up to jetty-servlet.

Need to consider if content-length really is meta data and how much and when can we trust it.

Signed-off-by: Greg Wilkins <gregw@webtide.com>

* Immutable MetaData

WIP

Need to consider if content-length really is meta data and how much and when can we trust it. Also need to consider difference between h2 and h1 authority in metadata.

Signed-off-by: Greg Wilkins <gregw@webtide.com>

* Immutable MetaData WIP

jetty-client and jetty-servlet passing tests.

Signed-off-by: Greg Wilkins <gregw@webtide.com>

* Immutable MetaData WIP

Better align the style of immutability between `HttpFields` and `HttpURI`.
They both now have static build() and from() methods, plus Builder and Immutable implementations.
Potentially `Builder` could be renamed as `Mutable`

Signed-off-by: Greg Wilkins <gregw@webtide.com>

* Immutable MetaData WIP

http2-server tests passed

Signed-off-by: Greg Wilkins <gregw@webtide.com>

* Immutable MetaData WIP

http2-client tests passed

Signed-off-by: Greg Wilkins <gregw@webtide.com>

* Immutable MetaData WIP

cleann build?

Signed-off-by: Greg Wilkins <gregw@webtide.com>

* Immutable MetaData WIP

fix

Signed-off-by: Greg Wilkins <gregw@webtide.com>

* Immutable MetaData WIP

more test fixes

Signed-off-by: Greg Wilkins <gregw@webtide.com>

* Immutable MetaData WIP

Cleanups, mostly using EMPTY when appropriate.

Signed-off-by: Greg Wilkins <gregw@webtide.com>

* Immutable MetaData WIP

Cleanups, use immutable

Signed-off-by: Greg Wilkins <gregw@webtide.com>

* Immutable MetaData WIP

No trailers for connect

Signed-off-by: Greg Wilkins <gregw@webtide.com>

* Immutable MetaData WIP

Fix CONNECT path handling

Signed-off-by: Greg Wilkins <gregw@webtide.com>

* Immutable MetaData WIP

fixed rewrite query handling

Signed-off-by: Greg Wilkins <gregw@webtide.com>

* Immutable MetaData WIP

rename Builders to Muttables

Signed-off-by: Greg Wilkins <gregw@webtide.com>

* Immutable MetaData WIP

misc cleanups

Signed-off-by: Greg Wilkins <gregw@webtide.com>

* Immutable MetaData WIP

Revert to using arrays due to garbage generated by streams and iterators (12% of a simple benchmark!).
Even if this garbage is an artifact of the JIT being disabled by observation, it can hide other allocations, so best to just use simple arrays!

Signed-off-by: Greg Wilkins <gregw@webtide.com>

* Immutable MetaData WIP

More optimizations and better test coverage.

Signed-off-by: Greg Wilkins <gregw@webtide.com>

* Immutable Metadata

various cleanups

Signed-off-by: Greg Wilkins <gregw@webtide.com>

* Immutable MetaData WIP

More optimizations

Signed-off-by: Greg Wilkins <gregw@webtide.com>

* Immutable MetaData WIP

review changes

Signed-off-by: Greg Wilkins <gregw@webtide.com>

* Immutable MetaData WIP

changes after review:
 + less usage of Mutable
 + more usage of EMPTY
 + restored fragment handling

Signed-off-by: Greg Wilkins <gregw@webtide.com>

* Immutable MetaData WIP

changes after review:
 + less usage of Mutable
 + less usage of asImmutable

Signed-off-by: Greg Wilkins <gregw@webtide.com>

* Immutable MetaData WIP

changes after review:
 + less usage of Mutable

Signed-off-by: Greg Wilkins <gregw@webtide.com>

* Immutable MetaData

changes after review:
 + better handling of URI in ContextHandler

Signed-off-by: Greg Wilkins <gregw@webtide.com>

* Immutable MetaData

changes after review:
 + downcast in test to access mutable response headers.

Signed-off-by: Greg Wilkins <gregw@webtide.com>

* Immutable MetaData

changes after review:
 + use put instead of add for one time headers

Signed-off-by: Greg Wilkins <gregw@webtide.com>

* private

Signed-off-by: Greg Wilkins <gregw@webtide.com>
2020-04-28 13:36:44 +02:00
Jan Bartel 4bf80d9653 Merge remote-tracking branch 'origin/jetty-9.4.x' into jetty-10.0.x 2020-04-28 11:40:20 +02:00
Jan Bartel e2af6419ae
Issue #4820 jetty-deployer.xml should be jetty-deploy.xml for osgi (#4821)
Signed-off-by: Jan Bartel <janb@webtide.com>
2020-04-28 11:38:38 +02:00
Greg Wilkins ef4d1fac04 fixed bad merge
Signed-off-by: Greg Wilkins <gregw@webtide.com>
2020-04-28 10:52:02 +02:00
Greg Wilkins eacb79f4e7 Merge remote-tracking branch 'origin/jetty-9.4.x' into jetty-10.0.x
Signed-off-by: Greg Wilkins <gregw@webtide.com>
2020-04-28 10:29:41 +02:00
Greg Wilkins 8fcbf6d590
Improve Attributes Handling (#4816)
* Spun out from #4814 Improve Attributes Handling

Improve attribute handling to reduce garbage and improve lookup.
Introduced a Wrapper so that request can remove any layers on reset.

Signed-off-by: Greg Wilkins <gregw@webtide.com>

* Issue #4814 - Exposing AttributeMap.getAttributeNameSet() on Attributes.

The underlying AttributesMap already has a .getAttributeNameSet()
method, expose it on the Attributes interface.

Signed-off-by: Joakim Erdfelt <joakim.erdfelt@gmail.com>

* Allow a set to override a secure attribute.

Signed-off-by: Greg Wilkins <gregw@webtide.com>

* Issue #4814 - Attributes.getAttributeNames() is now defaulted

The Attributes.getAttributeNames() will use the
.getAttributeNameSet() by default now.

Updated all Attributes.Wrapper impls to use this new behavior

Signed-off-by: Joakim Erdfelt <joakim.erdfelt@gmail.com>

Co-authored-by: Joakim Erdfelt <joakim.erdfelt@gmail.com>
2020-04-28 10:16:29 +02:00
Simone Bordet 8fec7b1530 Merged branch 'jetty-9.4.x' into 'jetty-10.0.x'. 2020-04-27 23:30:55 +02:00
Simone Bordet 797d8fa9a2 Improvements to the Jetty server documentation.
Added section on WebAppContext class loading.

Signed-off-by: Simone Bordet <simone.bordet@gmail.com>
2020-04-27 23:29:51 +02:00
Simone Bordet 8929791e6c
Merge pull request #4791 from eclipse/jetty-9.4.x-4787-mutable_host_port_client_request
Fixes #4787 - Make org.eclipse.jetty.client.HttpRequest's host name w…
2020-04-27 23:29:29 +02:00
Simone Bordet 952a20f81c Issue #4798 - Better handling of fatal Selector failures.
Implemented selector recovery by transferring
all keys to a newly created selector.

Updated code so that it does not assume that the
SelectionKey never changes.
2020-04-27 23:19:06 +02:00
Simone Bordet 46ad90598c Code cleanups. 2020-04-27 22:57:57 +02:00
Jan Bartel ef9d3eba0a Merge remote-tracking branch 'origin/jetty-9.4.x' into jetty-10.0.x 2020-04-27 16:14:27 +02:00
Jan Bartel 3c1f42c1c7 Issue #4818
Signed-off-by: Jan Bartel <janb@webtide.com>
2020-04-27 16:12:44 +02:00