Commit Graph

3644 Commits

Author SHA1 Message Date
Simone Bordet fe0e076055 Using capital case for static final field.
Signed-off-by: Simone Bordet <simone.bordet@gmail.com>
2020-12-02 17:47:56 +01:00
Simone Bordet 97b3f262ab Fixed scan(Callback) bug, returning early in case of failures.
More cleanups in code adding more privateness, getting rid of unnecessary exceptions, making fields final, etc.

Signed-off-by: Simone Bordet <simone.bordet@gmail.com>
2020-12-02 12:53:23 +01:00
Jan Bartel 8fe8cb8c27 Issue #5086 Add blocking method for immediate scan.
Signed-off-by: Jan Bartel <janb@webtide.com>
2020-12-02 10:27:08 +01:00
Jan Bartel c776eeb838 Merge remote-tracking branch 'origin/jetty-10.0.x' into jetty-10.0.x-5086-review-scanner 2020-12-02 09:03:46 +01:00
Jan Bartel e39ec6cab4 Issue #5086 Fix error on addFile
Signed-off-by: Jan Bartel <janb@webtide.com>
2020-12-02 08:02:09 +01:00
Jan Bartel 31cc298987 Issue #5086 Changes after review
Signed-off-by: Jan Bartel <janb@webtide.com>
2020-12-01 22:05:33 +01:00
Jan Bartel 90e48ba0b5 Issue #5086 Fix javadoc
Signed-off-by: Jan Bartel <janb@webtide.com>
2020-12-01 17:44:33 +01:00
Jan Bartel 115a72da65 Issue #5086 Fix checkstyle in test
Signed-off-by: Jan Bartel <janb@webtide.com>
2020-12-01 17:19:46 +01:00
Jan Bartel 4304c7861c Issue #5086 Improve ScannerTest
Signed-off-by: Jan Bartel <janb@webtide.com>
2020-12-01 15:55:45 +01:00
Ludovic Orban 845c6b457a merge jetty-9.4.x into jetty-10.0.x
Signed-off-by: Ludovic Orban <lorban@bitronix.be>
2020-12-01 15:26:25 +01:00
Ludovic Orban a26731c5ea merge jetty-9.4.x into jetty-10.0.x
Signed-off-by: Ludovic Orban <lorban@bitronix.be>
2020-12-01 15:25:25 +01:00
Ludovic Orban 44e6f4aeb8 sweep the entries list when the max usage count is changed
Signed-off-by: Ludovic Orban <lorban@bitronix.be>
2020-12-01 15:18:06 +01:00
Jan Bartel 4883332593 Issue #5086 Review and rework o.e.j.util.Scanner
Signed-off-by: Jan Bartel <janb@webtide.com>
2020-12-01 14:58:18 +01:00
Ludovic Orban 0ff1bfdd5e fix bug that messes up the max usage count when the entries' max usage counter overflows
Signed-off-by: Ludovic Orban <lorban@bitronix.be>
2020-12-01 10:02:31 +01:00
Simone Bordet c85cef4da5 Merged branch 'jetty-9.4.x' into 'jetty-10.0.x'.
Signed-off-by: Simone Bordet <simone.bordet@gmail.com>
2020-11-26 16:36:14 +01:00
Ludovic Orban aa8bd5d820 replace Trie interface and impls usage with new *Index interfaces and Builders
Signed-off-by: Ludovic Orban <lorban@bitronix.be>
2020-11-26 14:14:16 +01:00
Simone Bordet 68e70b47de
Merge pull request #5634 from eclipse/jetty-9.4.x-5310-http2_goaway
Review HTTP/2 GOAWAY handling
2020-11-26 11:29:44 +01:00
Ludovic Orban b4483d3b2a fix ArithmeticException "/ by zero"
Signed-off-by: Ludovic Orban <lorban@bitronix.be>
2020-11-26 08:59:44 +01:00
Lachlan 5941235725
Merge pull request #5726 from eclipse/jetty-9.4.x-websocketProxy
Implement and test a WebSocket Proxy with the 9.4 Jetty API
2020-11-26 16:55:36 +11:00
Joakim Erdfelt fe0a4f624e
Merge remote-tracking branch 'origin/release-9.4.35' into jetty-9.4.x 2020-11-25 15:56:09 -06:00
Lachlan Roberts ce11fb3e94 Merge remote-tracking branch 'origin/jetty-9.4.x' into jetty-9.4.x-websocketProxy 2020-11-25 23:05:51 +11:00
gregw 116705037e Accidentally committed 2020-11-25 10:19:07 +01:00
Simone Bordet 96e068582b Fixes #1923 - GCThreadLeakPreventer won't work with Java 9.
GCThreadLeakPreventer has been removed, since the issue
it was trying to fix was solved in Java 9+.

Signed-off-by: Simone Bordet <simone.bordet@gmail.com>
2020-11-24 22:20:35 +01:00
Joakim Erdfelt a133e195d8
Fixing checkstyle violations
Signed-off-by: Joakim Erdfelt <joakim.erdfelt@gmail.com>
2020-11-24 13:36:25 -06:00
gregw 0a70cba8ae Merge remote-tracking branch 'origin/jetty-9.4.x' into jetty-10.0.x
Signed-off-by: gregw <gregw@webtide.com>
2020-11-24 18:36:24 +01:00
Greg Wilkins 9f82ca0a80
Use File.list and File.walk within a try with resource (#5718)
* Use File.list and File.walk within a try with resource

The API contract of File.list and File.walk requires them to be closed after use.

* Fix from review

Left out filter

* Fix from review

Factored out deleteFile with better debug

* Fix from review

Can delete files whilst walking

* Fix from review

Restored sweepFile
fixed minor code suggestions
2020-11-24 18:12:42 +01:00
Lachlan Roberts b89adb8dae Improve WebSocketProxy, and write tests for it
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-11-24 18:55:09 +11:00
Joakim Erdfelt e8683cba9f Updating to version 9.4.36-SNAPSHOT 2020-11-20 16:05:27 -06:00
Joakim Erdfelt bdc54f03a5 Updating to version 9.4.35.v20201120 2020-11-20 15:05:50 -06:00
gregw 8884575f85 Merge remote-tracking branch 'origin/jetty-9.4.x' into jetty-10.0.x
Signed-off-by: gregw <gregw@webtide.com>
2020-11-12 17:17:55 +01:00
Greg Wilkins f4c32e788a
Fix #5562 Improve HTTP Field cache allocation (#5565)
* Fix #5562 Improve HTTP Field cache allocation

Fix #5562 by initially putting cacheable fields into a inexpensive arraylist.
Only create the Trie (with space and complexity costs) if a second request is received.

* Fixed NPE

* Feedback from review

Create `HttpHeader.isPseudo()`` method
improved clarity with `createFieldCacheIfNeeded()``

* Feedback from review

Only defer Trie creation to first cacheable field, not until next request.

* Updates from review

* Update from review

 + more javadoc
 + empty set return
2020-11-12 17:05:32 +01:00
gregw 6ea9f11bc1 Merge remote-tracking branch 'origin/jetty-9.4.x' into jetty-10.0.x 2020-11-11 17:49:03 +01:00
Greg Wilkins bb886ad932
Fix #5575 SEARCH method (#5576)
+ Added all IANA methods
 + Used Trie for most lookups
 + Fixed ArrayTernayTrie lookup
 + optimised GET, POST and HEAD

Co-authored-by: Joakim Erdfelt <joakim.erdfelt@gmail.com>
2020-11-11 17:48:08 +01:00
Simone Bordet 226d616a8a Issue 5310 - Review HTTP/2 GOAWAY handling.
Reimplemented close/idle_timeout/stop/onGoAway/input_shutdown following more closely the specification.

In particular, the semantic of sending a GOAWAY is now to:
* stop creation of new both local and remote streams
* record the last processed stream
* continue processing streams that are pending

This means that a GOAWAY is "graceful" in the sense that it allows for streams to be completed by applications.

The semantic of stop() and idle timeout is harsher: for pending streams a RST_STREAM is sent to the other peer and they are failed locally.

Added support for GOAWAY with 2^31-1 lastStreamId.

Added support for a peer to send and receive multiple GOAWAY frames.

Reviewed the stream creation/destruction mechanism so that when the last stream completes after a GOAWAY, proper actions can be run to tear down the connection.

Signed-off-by: Simone Bordet <simone.bordet@gmail.com>
2020-11-10 10:07:19 +01:00
Greg Wilkins 1904d326fc
Fixes #5521 ResourceCollection NPE (#5527)
* Fixes #5521 ResourceCollection NPE

Fix constructor and addPath so that all resources in a RC must exist when created.

* Fixes #5521 ResourceCollection NPE

Cleanup the vestiges of non existent directories detected by resource ending in /

* Fixes #5521 ResourceCollection NPE

Revert adding paths ending in / as jar:file resource needs them

* feedback from review

improved javadoc.
2020-11-04 08:56:17 +01:00
Joakim Erdfelt edaadff55b Updating to version 9.4.35-SNAPSHOT 2020-11-02 09:04:51 -06:00
Joakim Erdfelt e46af88704 Updating to version 9.4.34.v20201102 2020-11-02 08:03:51 -06:00
Simone Bordet 40fd98d6a9 Merged branch 'jetty-9.4.x' into 'jetty-10.0.x'. 2020-11-02 10:47:03 +01:00
Simone Bordet a1b3d3319d
Merge pull request #5491 from eclipse/jetty-9.4.x-5488-jetty-dir.css
Fixes #5488 - jetty-dir.css not found when using JPMS.
2020-11-02 10:40:19 +01:00
Joakim Erdfelt 3aba60c31f
Merge remote-tracking branch 'origin/jetty-9.4.x' into jetty-10.0.x 2020-10-30 13:12:50 -05:00
Joakim Erdfelt 249cb02a75
Issue #5535 - Removing irrelevant lines on test
Signed-off-by: Joakim Erdfelt <joakim.erdfelt@gmail.com>
2020-10-30 11:22:46 -05:00
Joakim Erdfelt 074b4f90f7
Issue #5535 - Adding regex include/exclude of Protocols to SslContextFactory
Signed-off-by: Joakim Erdfelt <joakim.erdfelt@gmail.com>
2020-10-30 10:29:35 -05:00
Joakim Erdfelt c969fba71a
Issue #5531 - Using .setExcludeProtocols correctly.
Signed-off-by: Joakim Erdfelt <joakim.erdfelt@gmail.com>
2020-10-29 20:28:21 -05:00
Joakim Erdfelt cff4771375
Issue #5531 - Test excluded protocol behavior
Signed-off-by: Joakim Erdfelt <joakim.erdfelt@gmail.com>
2020-10-29 13:57:20 -05:00
Joakim Erdfelt dadd299e47
Cleanup of SslContextFactoryTest
Signed-off-by: Joakim Erdfelt <joakim.erdfelt@gmail.com>
2020-10-29 13:44:21 -05:00
Lachlan 5bb47c954c
Merge pull request #5517 from eclipse/jetty-10.0.x-5493-StatisticsHandler
Issue #5493 - Fix and simplify graceful shutdown of StatisticsHandler
2020-10-29 08:55:22 +11:00
Greg Wilkins d3bdeefa1a Merge remote-tracking branch 'origin/jetty-9.4.x' into jetty-10.0.x
Signed-off-by: Greg Wilkins <gregw@webtide.com>
2020-10-28 18:01:56 +01:00
Greg Wilkins 7a0de6af3a
Fixes #5498 ServletHolder cleanup (#5514)
* Fixes #55498 ServletHolder cleanup

Various cleanups for #5498 including:
 + renaming multiple `_servlet` fields in inner classes to avoid confusion
 + better comments in prepare method to describe why it is needed
 + call prepare from Invoker servlet
 + The `_servlet` field is not set until after the servlet is initialized
 + Consistent wrapping of `SingleThreadedWrapper` now in `initServlet`
 + The `getServlet` method now looks the volatile `_servlet` to avoid locking if possible
 + The `handle` method now calls `getServletInstance` as servlet will have been initialized in `prepare`
 + Found and fixed race with making unavaiable servlet available again
 + fixed nanotime overflow
 + fixed several compiler warnings/suggestions
 + removed while true from unavailable servlet
 + Do not destroy servlets unless init has been called.
 + Added TODOs about calling predestroy on instances not created by the holder.
 + Do not destroy servlets unless init has been called.
 + Added TODOs about calling predestroy on instances not created by the holder.
 + improved dump and toString
2020-10-28 17:46:49 +01:00
gregw c793b54781 Merge remote-tracking branch 'origin/jetty-9.4.x' into jetty-10.0.x
Signed-off-by: gregw <gregw@webtide.com>
2020-10-28 15:31:02 +01:00
Greg Wilkins 6698a314ee
Fixes #5521 ResourceCollection list NPE (#5523)
Fixes #5521 ResourceCollection list NPE
2020-10-28 15:23:29 +01:00
Lachlan Roberts d6751c9936 Issue #5493 - Fix and simplify graceful shutdown of StatisticsHandler
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-10-27 15:40:58 +11:00
Simone Bordet 4a4a73df2e Fixes #5488 - jetty-dir.css not found when using JPMS.
Moved jetty-dir.css from jetty-util to jetty-server,
so that it can be found by ResourceHandler when using JPMS.

Updated DefaultServlet to call a ResourceHandler method
to retrieve the stylesheet.

Signed-off-by: Simone Bordet <simone.bordet@gmail.com>
2020-10-22 16:48:27 +02:00
Joakim Erdfelt e726eefb0b Updating to version 9.4.34-SNAPSHOT 2020-10-20 18:55:39 -05:00
Joakim Erdfelt 1be6875565 Updating to version 9.4.33.v20201020 2020-10-20 18:28:51 -05:00
Joakim Erdfelt 05f08fec4c
Merge remote-tracking branch 'origin/jetty-9.4.x' into jetty-10.0.x 2020-10-20 17:35:56 -05:00
Joakim Erdfelt fa6c8f7dec
Issue #5480 - Only delete non-persist temp dir if not-empty
Signed-off-by: Joakim Erdfelt <joakim.erdfelt@gmail.com>
2020-10-20 17:19:54 -05:00
Joakim Erdfelt 0e98c370fd
Issue #5480 - NPE protection on IO.delete(File)
Signed-off-by: Joakim Erdfelt <joakim.erdfelt@gmail.com>
2020-10-20 16:28:36 -05:00
Joakim Erdfelt 5045244f54
Merge remote-tracking branch 'origin/jetty-9.4.x' into jetty-10.0.x 2020-10-17 05:38:31 -05:00
Joakim Erdfelt fed8484d88
Merge pull request #5458 from eclipse/jetty-9.4.x-5451-temp-perms-cleanup
Issue #5451 - Removing file/dir permission management from codebase
2020-10-17 05:28:13 -05:00
Joakim Erdfelt 1e9c736692
Merge remote-tracking branch 'origin/jetty-9.4.x' into jetty-10.0.x 2020-10-16 17:51:32 -05:00
Joakim Erdfelt 97f795160c Fixing windows build/test issues. 2020-10-16 13:54:27 -05:00
Joakim Erdfelt d612f12cf6
Issue #5451 - Removing file/dir permission management from codebase
Signed-off-by: Joakim Erdfelt <joakim.erdfelt@gmail.com>
2020-10-16 13:17:28 -05:00
Joakim Erdfelt e12c3ce50b
Merge remote-tracking branch 'origin/jetty-9.4.x' into jetty-10.0.x 2020-10-16 08:11:42 -05:00
Joakim Erdfelt fdd880b66b
Issue #5451 - Cleanup of temp file cleanup.
Signed-off-by: Joakim Erdfelt <joakim.erdfelt@gmail.com>
2020-10-15 18:10:38 -05:00
Lachlan Roberts 4690aa51ba allow override of shared CompressionPools in WebSocketServerComponents
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-10-14 22:28:26 +11:00
Lachlan Roberts 0e3cfe8fc2 Issue #5287 - share compression pools and size with max num threads
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-10-14 22:28:26 +11:00
Lachlan Roberts 7cac3d76bb Issue #5287 - close deflater on release if non-pooled entry
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-10-14 22:28:26 +11:00
Lachlan Roberts 608a895aab Issue #5287 - make default CompressionPool capacity 1024
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-10-14 22:28:26 +11:00
Lachlan Roberts ef816fcc42 DeflaterPoolBenchmark should manage lifecycle of the CompressionPool
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-10-14 22:28:26 +11:00
Lachlan Roberts dd06008ff4 Issue #5287 - remove IllegalArgumentException from CompressionPool Entry
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-10-14 22:28:26 +11:00
Lachlan Roberts 5dc0242986 Issue #5287 - Changes from review & fix broken tests from NPE
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-10-14 22:28:26 +11:00
Lachlan Roberts d241c6694b Issue #5287 - Pool the entries instead of just the Deflater/Inflaters
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-10-14 22:28:26 +11:00
Lachlan Roberts 21576f2312 Issue #5287 - fix usages of new CompressionPool
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-10-14 22:28:26 +11:00
Lachlan Roberts b239fa07c6 Issue #5287 - rework CompressionPool to use the jetty-util pool
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-10-14 22:28:26 +11:00
Simone Bordet 1cd15e8d85
Fixes #5379 - Better handling for wrong SNI. (#5398)
* Fixes #5379 - Better handling for wrong SNI.

Reworked the SNI logic.
Added support for IP addresses in the SAN extension of certificates in the X509 class.
Fixed keystores to have CN=localhost and SAN with ip=127.0.0.1 and ip=[::1].
Fixed tests that were not using the correct Host header.

Signed-off-by: Simone Bordet <simone.bordet@gmail.com>
2020-10-12 15:48:53 +02:00
Joakim Erdfelt 85e257fc98 Updating to version 9.4.33-SNAPSHOT 2020-09-30 11:53:09 -05:00
Joakim Erdfelt de97d26f7b Updating to version 9.4.32.v20200930 2020-09-30 11:03:24 -05:00
Joakim Erdfelt ad2446dd6c
Merge remote-tracking branch 'origin/jetty-9.4.x' into jetty-10.0.x 2020-09-29 11:24:28 -05:00
Joakim Erdfelt 3423375a97
Issue #5357 - Updating to https://eclipse.org/ (#5358)
* Issue #5357 - Updating to https://eclipse.org/

 - Removing redundant <url> refs in pom.xml
 - Correcting bad indenting from merge
 - Correcting mailing list references
 - Correcting bugs.eclipse.org references
 - Correcting text file references
 - Correcting html references
 - Correcting further references
 - Correcting download.eclipse.org reference
 - Adding test for demo-base /proxy/current/
 - Ensuring jetty-client is included in javadoc-proxy.war/WEB-INF/lib

Signed-off-by: Joakim Erdfelt <joakim.erdfelt@gmail.com>
2020-09-29 11:02:32 -05:00
Chris Walker 70c8822eef
Updated module descriptions for consistency. Resolves #5313 2020-09-23 13:10:47 -05:00
Joakim Erdfelt c16b8f3a61
Fixing ResourceCollection exists() and getInputStream()
Signed-off-by: Joakim Erdfelt <joakim.erdfelt@gmail.com>
2020-09-22 14:10:49 -05:00
Joakim Erdfelt 33286db44b
Merge remote-tracking branch 'origin/jetty-10.0.x' into jetty-10.0.x-5133-webappcontext-extraclasspath-cleanup 2020-09-22 12:24:01 -05:00
Joakim Erdfelt f6bcbda689
Issue #5133 - Changes from Review with jan & greg
Signed-off-by: Joakim Erdfelt <joakim.erdfelt@gmail.com>
2020-09-21 09:42:26 -05:00
Lachlan df085a610f
Merge pull request #5248 from eclipse/jetty-10.0.x-5198-UpdateGzipHandler
Issue #5198 - update gzip handler
2020-09-21 10:41:16 +10:00
Joakim Erdfelt 6cf6b78a16
Issue #5246 - Adding DeflaterPool to GzipHandler.dump
Signed-off-by: Joakim Erdfelt <joakim.erdfelt@gmail.com>
2020-09-17 10:27:15 -05:00
gregw f3f918ade2 fix merge
Signed-off-by: gregw <gregw@webtide.com>
2020-09-16 23:34:38 +02:00
gregw b7a4c36286 Merge remote-tracking branch 'origin/jetty-9.4.x' into jetty-10.0.x
Signed-off-by: gregw <gregw@webtide.com>
2020-09-16 18:31:51 +02:00
Greg Wilkins ba22c08fde
Alternative Pool Strategies (#5218)
* Speculative idea to make a pluggable Pool strategy

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

* Speculative idea to make a pluggable Pool strategy

 + javadoc

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

* Speculative idea to make a pluggable Pool strategy

 + Added a ThreadLocalStrategy for a single cached item
 + Tell strategies about newly reserved entries
 + Fixed multiplexing test that was dependent on the impl of the cache

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

* Speculative idea to make a pluggable Pool strategy

 + added tests

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

* Feedback from review

 + Don't have a fallback iteration, instead make a SearchStrategy and DualStrategy

* Feedback from review

 + split strategies into Cache and Strategies

* Feedback from review

 + Added reserve and release

* Improved Pool Strategies:

+ reverted to post notifications for removed, reserved and released.
+ Added a few more strategies that need to be benchmarked, that use the list iterator.

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

* Testing all the different strategies

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

* More simplifications and made LRU work (ish)

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

* javadoc

* More javadoc

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

* JMH Test

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

* one strategy

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

* test

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

* Split implementations:

 + pluggable strategies
 + hard coded

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

* More benchmarks

* Built in strategy

* removed strategies version and simplified to single configurable solution.

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

* updates from review

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

* better javadoc

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

* Updated ConnectionPool classes to use Pool strategies

* Small javadocs fixes.

Signed-off-by: Simone Bordet <simone.bordet@gmail.com>

* Updates from review

* javadoc

Co-authored-by: Simone Bordet <simone.bordet@gmail.com>
2020-09-16 18:27:26 +02:00
Greg Wilkins 780e1207c7
Issue #5254 List/Show modules (#5257)
* Issue #5254 List/Show modules

 * simplified --list-modules output
 * added --show-module

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

* improve module descriptions

Signed-off-by: Greg Wilkins <gregw@webtide.com>
2020-09-14 18:07:16 +02:00
Lachlan Roberts f2abf21df6 Move AsciiLowerCaseSet to jetty-util & changes from review
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-09-10 08:02:59 +10:00
Lachlan Roberts 2ed89cbccd Issue #5246 - add Inflater/Deflater pools to server dump
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-09-09 10:39:15 +10:00
Lachlan Roberts 3bdd82eb5e Issue #5198 - GzipHandler should use InflaterPool as well as DeflaterPool
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-09-08 15:27:21 +10:00
gregw d7b3d62982 Merge remote-tracking branch 'origin/jetty-9.4.x' into jetty-10.0.x
Signed-off-by: gregw <gregw@webtide.com>
2020-09-07 15:59:27 +02:00
Greg Wilkins 7ecf42e3f8
Issue #5162 CDI embedded integration improvements (#5177)
* Issue #5162 CDI embedded integration improvements

Clean up CDI integration and documentation to better support embedded usage.
 + made listener public
 + added utility class for SCIs

* Issue #5162 CDI embedded integration improvements

Clean up CDI integration and documentation to better support embedded usage.
 + moved EmbeddedWeldTest to jetty-embedded

* fix javadoc

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

* Issue #5162 CDI embedded integration improvements

ventilated text

* fix test pom

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

* Fixed javadoc

* Fixed javadoc

* Issue #5162 CDI embedded integration improvements

Moved tests to jetty-cdi to avoid consequences to other tests in embedded

* trailing new line

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

* updates from review

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

* Feedback from review
2020-09-07 14:00:20 +02:00
Lachlan Roberts 76b38d20d4 Merge remote-tracking branch 'origin/jetty-9.4.x' into jetty-10.0.x 2020-09-04 17:18:36 +10:00
Lachlan Roberts 1d1bbc49f7 Issue #5201 - change format for QTP dump from review
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-09-04 13:55:26 +10:00
Lachlan Roberts 26ae875d1c Merge remote-tracking branch 'origin/jetty-9.4.x' into jetty-9.4.x-5201-QueuedThreadPoolDump 2020-09-03 15:00:47 +10:00
Lachlan Roberts 85c8c6510e Issue #5201 - Fix issues with test after changes to QTP dump
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-09-03 10:34:18 +10:00
Lachlan Roberts 0a59a2b090 Issue #5201 - simplify the QueuedThreadPool detailed dump
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-09-03 06:58:55 +10:00
Simone Bordet 37f93bb71b Merged branch 'jetty-9.4.x' into 'jetty-10.0.x'. 2020-09-02 09:57:36 +02:00
Simone Bordet bec2cdbee7 Fixes #5204 - SNI does not work with PKIX.
Updates after review.

Signed-off-by: Simone Bordet <simone.bordet@gmail.com>
2020-08-27 18:06:12 +02:00
Simone Bordet f084f3c09b Fixes #5204 - SNI does not work with PKIX.
Introduced SslContextFactory.Server.aliasMapper, a function
that transforms the alias.
This function is invoked by the SNI logic to unmangle the
alias leaked by the TLS implementation due to bug
https://bugs.openjdk.java.net/browse/JDK-8246262.

Signed-off-by: Simone Bordet <simone.bordet@gmail.com>
2020-08-26 22:25:27 +02:00
Joakim Erdfelt ccc863726b
Issue #5133 - Updates based on review
Signed-off-by: Joakim Erdfelt <joakim.erdfelt@gmail.com>
2020-08-26 12:19:22 -05:00
gregw b03bdb9db4 Merge remote-tracking branch 'origin/jetty-9.4.x' into jetty-10.0.x
Signed-off-by: gregw <gregw@webtide.com>
2020-08-24 18:09:16 +02:00
Greg Wilkins 1159fa399f
Issue #5095 - XmlConfiguration Parser Pool (#5148)
* Issue #5095 XmlConfiguration Parser Pool

Use a pool of parsers rather than a shared static

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

* Some updates to the new Pool class:

 + fixed a race with pending reservations
 + use a pending counter
 + Reservation API to simplify Entry API
 + removed public methods on Entry API

* Some updates to the new Pool class:

 + fixed a race with pending reservations
 + use a pending counter
 + Reservation API to simplify Entry API
 + removed public methods on Entry API

* Updates from review

* Updates from review
Tests for cache size and acquire with creator

* Method no longer required with Reservation

* update from the feedback on the feedback of the feedback from the review.

Moved enable to Entry, removed Reservation class and clarified usage in javadoc

* Issue #5095 XmlConfiguration locking  Use pool instead of static shared instance

* removed fake test

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

* Issue #5095 XmlConfiguration locking  Use pool instead of static shared instance

updates from review
2020-08-24 18:00:28 +02:00
Jan Bartel 77779ed6d8
Issue #4996 - Regularlize logging (#5167)
* Issue #4996 Regularize logging

Signed-off-by: Jan Bartel <janb@webtide.com>

Co-authored-by: Joakim Erdfelt <joakim.erdfelt@gmail.com>
2020-08-24 17:15:13 +02:00
Simone Bordet 823e713ee4 Merged branch 'jetty-9.4.x' into 'jetty-10.0.x'. 2020-08-22 17:35:25 +02:00
Simone Bordet 2d3f0e0c10 Improved logging and toString() implementations,
small refactorings in code and tests.

Signed-off-by: Simone Bordet <simone.bordet@gmail.com>
2020-08-22 17:31:12 +02:00
Joakim Erdfelt b35c4332b2
Issue #5133 - Fixing ResourceCollection(String) when no entries provided.
Signed-off-by: Joakim Erdfelt <joakim.erdfelt@gmail.com>
2020-08-20 13:35:48 -05:00
Joakim Erdfelt 5d3711c3c0
Merge remote-tracking branch 'origin/jetty-10.0.x' into jetty-10.0.x-5133-webappcontext-extraclasspath-cleanup 2020-08-13 11:12:20 -05:00
Simone Bordet ac4ea4550e Merged branch 'jetty-9.4.x' into 'jetty-10.0.x'. 2020-08-13 16:52:35 +02:00
Simone Bordet 26c2d34439 Issue #4809 - Set a max number of requests per connection.
Improved Pool.reserve(int) logic to take into account the
fact that an entry can accommodate maxMultiplex acquires.

This reduces connection openings for HTTP/2 in case of
spikes of requests.

Signed-off-by: Simone Bordet <simone.bordet@gmail.com>
2020-08-13 16:52:06 +02:00
Joakim Erdfelt 00f4859e33
Merge remote-tracking branch 'origin/jetty-9.4.x' into jetty-10.0.x
Signed-off-by: Joakim Erdfelt <joakim.erdfelt@gmail.com>
2020-08-12 16:04:06 -05:00
Joakim Erdfelt 9b5b43a2fd
Fixing KeyStoreScannerTest
Signed-off-by: Joakim Erdfelt <joakim.erdfelt@gmail.com>
2020-08-12 15:50:11 -05:00
Joakim Erdfelt 6848403d34
Issue #5133 - Reworking WebAppContext.extraClasspath
+ Reverting name ResourceFactory.newResource(String)
  to .getResource(String)
+ Reintroducing Resource.getResource(String)
+ ResourceHandler.getResource(String) cleaned up
  in light of Exception handling requirement
+ Resource.addPath(String) implementations can
  never return null now

Signed-off-by: Joakim Erdfelt <joakim.erdfelt@gmail.com>
2020-08-12 13:06:09 -05:00
Joakim Erdfelt 0b0d7d3282
Issue #5133 - Reworking WebAppContext.extraClasspath
+ Now parsed by WebAppContext into List<Resource>
+ Reintroduced Resource.fromList
+ Refactored ResourceFactory to never return null
  and always throw an exception if unable to
  get/create/resolve the Resource

Signed-off-by: Joakim Erdfelt <joakim.erdfelt@gmail.com>
2020-08-12 12:50:02 -05:00
Joakim Erdfelt ccdd20b7bc
Merge remote-tracking branch 'origin/jetty-9.4.x' into jetty-10.0.x 2020-08-12 10:27:33 -05:00
Joakim Erdfelt e632d2454b
Merge pull request #5131 from eclipse/jetty-9.4.x-5129-extraclasspath-glob
Issue #5129 - WebAppContext.setExtraClasspath(String) cleanup
2020-08-12 10:08:53 -05:00
Simone Bordet ae713d65d9 Merged branch 'jetty-9.4.x' into 'jetty-10.0.x'. 2020-08-12 16:17:06 +02:00
Simone Bordet 4a0af046b8 Closes #4809 - Set a max number of requests per connection.
Implemented as part of #4975.

Added a test case that proves that the connection is closed
when the max usage count is reached.

Improved logging.

Signed-off-by: Simone Bordet <simone.bordet@gmail.com>
2020-08-12 16:14:51 +02:00
gregw cd42fd1635 Merge remote-tracking branch 'origin/jetty-9.4.x' into jetty-10.0.x
Signed-off-by: gregw <gregw@webtide.com>
2020-08-12 11:42:36 +02:00
Greg Wilkins 25e3f1c1e0
Pool class refinements (#5117)
* Some updates to the new Pool class:

 + fixed a race with pending reservations
 + use a pending counter
 + Reservation API to simplify Entry API
 + removed public methods on Entry API

* Some updates to the new Pool class:

 + fixed a race with pending reservations
 + use a pending counter
 + Reservation API to simplify Entry API
 + removed public methods on Entry API

* Updates from review

* Updates from review
Tests for cache size and acquire with creator

* Method no longer required with Reservation

* update from the feedback on the feedback of the feedback from the review.

Moved enable to Entry, removed Reservation class and clarified usage in javadoc

* Issue #5095 XmlConfiguration locking  Use pool instead of static shared instance

fixed javadoc

* Issue #5095 XmlConfiguration locking  Use pool instead of static shared instance

fixed javadoc

* Issue #5095 XmlConfiguration locking  Use pool instead of static shared instance

fixed javadoc

* Issue #5095 XmlConfiguration locking  Use pool instead of static shared instance

updates from review
2020-08-12 11:27:25 +02:00
Simone Bordet 16cd552995 Merged branch 'jetty-9.4.x' into 'jetty-10.0.x'. 2020-08-11 21:00:43 +02:00
Simone Bordet f73b282050
Merge pull request #5128 from eclipse/jetty-9.4.x-5079-ipv6_brackets
Fixes #5079 - :authority header for IPv6 address not having square br…
2020-08-11 20:04:46 +02:00
Joakim Erdfelt 4a19ef4bb2 Issue #5129 - disabling ResourceTest.testGlobPath on WINDOWS for stability 2020-08-11 08:51:04 -05:00
Joakim Erdfelt 150dc22f0a
Issue #5129 - Reverting Resource.fromReferences()
+ Will migrate to jetty-10.0.x

Signed-off-by: Joakim Erdfelt <joakim.erdfelt@gmail.com>
2020-08-11 08:15:27 -05:00
olivier lamy c198d26e6b Updating to version 10.0.0-SNAPSHOT 2020-08-11 16:47:55 +08:00
olivier lamy 429b091578 Updating to version 10.0.0.beta1 2020-08-11 16:47:54 +08:00
Joakim Erdfelt 5b8c343a2b
Issue #5129 - Fleshing out glob testcase a bit more
Signed-off-by: Joakim Erdfelt <joakim.erdfelt@gmail.com>
2020-08-10 14:46:32 -05:00
Joakim Erdfelt 52f5218900
Issue #5129 - Resource.fromReferences no longer needs DefaultFactory
Signed-off-by: Joakim Erdfelt <joakim.erdfelt@gmail.com>
2020-08-10 14:42:02 -05:00
Joakim Erdfelt e8098986e6
Issue #5129 - Simplify Resource reference list behavior
+ Introduce new Resource.fromReferences to help with
  parsing delimited resource reference lists.

Signed-off-by: Joakim Erdfelt <joakim.erdfelt@gmail.com>
2020-08-10 11:30:39 -05:00
Joakim Erdfelt 55f4e4fa63
Issue #5129 - WebAppContext.setExtraClasspath(String) cleanup
+ More tests for both relative and absolute path references
+ More testing that will trigger quirks on Windows builds
  so that we can catch regressions faster
+ Reworked WebInfConfiguration to be glob aware in a way
  similar to how WebAppClassLoader behaves.
+ Reworked Resource.newResource(String) to delegate
  canonical path resolution to PathResource
+ Guarded PathResource's usage of Path.toAbsolutePath()
  to ignore valid conditions where the Path cannot be
  resolved to an absolute path (yet)
+ Normalize resolved paths in PathResource

Signed-off-by: Joakim Erdfelt <joakim.erdfelt@gmail.com>
2020-08-10 10:42:38 -05:00
Joakim Erdfelt 4957c091d0
Correct typo
Signed-off-by: Joakim Erdfelt <joakim.erdfelt@gmail.com>
2020-08-10 10:40:56 -05:00
Simone Bordet d53d9d8a1d Fixes #5079 - :authority header for IPv6 address not having square brackets.
On the client:
* Origin.Address.host is passed through HostPort.normalizeHost(),
so that if it is IPv6 is bracketed.
Now the ipv6 address passed to an `HttClient` request is bracketed.
* HttpRequest was de-bracketing the host, but now it does not anymore.

On the server:
* Request.getLocalAddr(), getLocalName(), getRemoteAddr(),
getRemoteHost(), getServerName(), when dealing with an IPv6 address,
return it bracketed.
The reason to return bracketed IPv6 also from *Addr() methods is that
if it is used with InetAddress/InetSocketAddress it still works, but
often it is interpreted as a URI host so brackets are necessary.
* DoSFilter was blindly bracketing - now it does not.

Added a number of test cases, and fixed those that expected
non-bracketed IPv6.

Signed-off-by: Simone Bordet <simone.bordet@gmail.com>
2020-08-07 15:53:19 +02:00
Simone Bordet c49035570e Merged branch 'jetty-10.0.x' into 'jetty-10.0.x-convert_synchronized_to_autolock'. 2020-08-04 16:32:55 +02:00
Simone Bordet edd6ca2ee1 Issue #5083 - Convert synchronized usages to AutoLock.
Updates after review.

Signed-off-by: Simone Bordet <simone.bordet@gmail.com>
2020-08-04 15:43:39 +02:00
Simone Bordet fe56838b63 Fixed copyright headers.
Signed-off-by: Simone Bordet <simone.bordet@gmail.com>
2020-07-31 19:18:07 +02:00
Simone Bordet 55f51fa0b5 Fixed copyright headers.
Signed-off-by: Simone Bordet <simone.bordet@gmail.com>
2020-07-31 19:01:59 +02:00
Simone Bordet d2df0fc2e9 Fixes after review of #4975.
Signed-off-by: Simone Bordet <simone.bordet@gmail.com>
2020-07-31 17:59:55 +02:00
Simone Bordet 2fe01626a5 Merged branch 'jetty-9.4.x' into 'jetty-10.0.x'. 2020-07-31 17:47:37 +02:00
Ludovic Orban e9dad975e6 Re-implement HTTP connection pooling with a non-queuing algorithm
Signed-off-by: Ludovic Orban <lorban@bitronix.be>
2020-07-31 10:36:43 +02:00
Greg Wilkins 66ec16006e
Issue #5088 Review ContextHandler locking (#5094)
* Issue #5088 Review ContextHandler locking

The locking was primarily as a memory guard for the availability status, which was already volatile.
Have instead using an AtomicReference with a simple state machine layered on top of start/stop lifecycle.
There was also protection for AttributesMap, which is no longer needed as AttributesMap is now concurrent.

* Issue #5088

updates from review

* Issue #5088

updates from review (better this time)
2020-07-30 17:58:34 +02:00
Greg Wilkins 7adbf247ec
Issue #5093 Static UrlEncoded (#5098)
* Issue #5093 Static UrlEncoded

Updated UrlEncoded to static only class with no synchronization

* Fixed additional tests

* fixed formatting

Signed-off-by: gregw <gregw@webtide.com>
2020-07-30 17:57:38 +02:00
Joakim Erdfelt 36b42ca65d
Issue #3916 - Fix whitespace between boundary and part headers
Signed-off-by: Joakim Erdfelt <joakim.erdfelt@gmail.com>
2020-07-30 09:13:01 -05:00
Simone Bordet 089e51f0bc Fixes #5083 - Convert synchronized usages to AutoLock.
Updates after review.

Signed-off-by: Simone Bordet <simone.bordet@gmail.com>
2020-07-29 15:34:01 +02:00
Lachlan Roberts 1be0220988 Issue #4919 - make the SessionTracker the one to implement Graceful shutdown
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-07-28 17:38:41 +10:00
Simone Bordet 8d69fc41a7 Fixes #5083 - Convert synchronized usages to AutoLock.
* Replaced relevant usages of synchronized with AutoLock.
* Made AutoLock serializable since classes that use it may be stored in the HttpSession.
* Added convenience methods to AutoLock to execute lambdas with the lock held.
* Introduced AutoLock.WithCondition to use a Lock and a Condition together.

Signed-off-by: Simone Bordet <simone.bordet@gmail.com>
2020-07-27 23:14:05 +02:00
Joakim Erdfelt fe9deae849 Updating to version 9.4.32-SNAPSHOT 2020-07-23 13:53:47 -05:00
Joakim Erdfelt 450ba27947 Updating to version 9.4.31.v20200723 2020-07-23 12:46:54 -05:00
Lachlan Roberts 9f3864af7e Merge remote-tracking branch 'origin/jetty-9.4.x' into jetty-10.0.x 2020-07-23 18:08:20 +10:00
Lachlan Roberts 38a94879f9 Issue #5062 - KeyStoreScannerTest should use manual scanning to avoid timing issues
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-07-21 11:31:40 +10:00
Lachlan Roberts ef60808bae fix licence headers and imports from merge
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-07-16 09:27:46 +10:00
Lachlan Roberts f0f153cc97 Merge remote-tracking branch 'origin/jetty-9.4.x' into jetty-10.0.x 2020-07-16 09:10:07 +10:00
Lachlan bbb0f6617c
Merge pull request #5042 from eclipse/jetty-9.4.x-5019-SslReload
Issue #5019 - hot-reload SSL certificates if keystore file changed
2020-07-16 09:09:03 +10:00
Lachlan Roberts c09e4d6f86 Merge remote-tracking branch 'origin/jetty-9.4.x' into jetty-10.0.x
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-07-16 08:46:29 +10:00
Lachlan 42ea202858
Merge pull request #5047 from eclipse/jetty-9.4.x-moduleCommentDoNotEdit
the "DO NOT EDIT" comment in .mod files should start with '#'
2020-07-16 08:43:00 +10:00
Lachlan Roberts 0f7d99c3bf add documentation for ssl-reload, change exception message in SslContextFactory
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-07-15 19:01:15 +10:00
gregw eb1e0b6d51 Merge remote-tracking branch 'origin/jetty-9.4.x' into jetty-10.0.x 2020-07-15 10:52:57 +02:00
Sergey Tselovalnikov 6b57654b03
Avoid large allocations of temporary buffers in BuferUtil (#5045)
* Avoid large allocations of tmp buffers in buferutil

Signed-off-by: Sergey Tselovalnikov <sergeicelov@gmail.com>

* review feedback

Signed-off-by: Sergey Tselovalnikov <sergeicelov@gmail.com>
2020-07-15 10:07:27 +02:00
Lachlan Roberts de1b6745c5 the DO NOT EDIT comment in .mod files should start with '#'
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-07-15 16:47:22 +10:00
Lachlan Roberts c40ba69222 add null checks in SslContextFactory for _factory, which could be null if reload failed
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-07-15 15:35:22 +10:00
Lachlan Roberts 2541f1f648 add javadoc for KeyStoreScanner class
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-07-15 11:20:57 +10:00
Jan Bartel 3b9def69bc Merge remote-tracking branch 'origin/jetty-9.4.x' into jetty-10.0.x 2020-07-14 14:11:15 +02:00
Jan Bartel b1e08ba4e0
Issue #5020 Make servlets,filters,listeners beans again (#5028)
* Issue #5020 Make servlets,filters,listeners beans again

Signed-off-by: Jan Bartel <janb@webtide.com>
2020-07-14 11:20:20 +02:00
Lachlan Roberts a83844df32 changes from review
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-07-14 16:10:07 +10:00
Lachlan Roberts 62ee077b79 move code of ssl-reload module to jetty-util, move module files to jetty-server
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-07-13 23:11:09 +10:00
olivier lamy eefe3d202b revert fail release
Signed-off-by: olivier lamy <oliver.lamy@gmail.com>
2020-07-10 15:04:22 +10:00
olivier lamy 9619a5a743 Updating to version 10.0.0.beta1 2020-07-10 14:23:28 +10:00
olivier lamy aaeffb719e Updating to version 10.0.0-SNAPSHOT 2020-07-09 12:25:34 +10:00
olivier lamy 23c99ffdbe Updating to version 10.0.0.beta1 2020-07-09 11:20:55 +10:00
Simone Bordet 383061a695 Merged 'jetty-9.4.x' into 'jetty-10.0.x'. 2020-07-02 09:29:03 +02:00
Zac Duncan c77ad80d94 add constructor that takes in all params that super needs.
Signed-off-by: Zac Duncan <zac.duncan@gmail.com>
2020-07-02 09:28:09 +02:00
Joakim Erdfelt 6df6fa33b8 Updating to version 9.4.31-SNAPSHOT 2020-06-11 08:24:34 -05:00
Joakim Erdfelt 271836e4c1 Updating to version 9.4.30.v20200611 2020-06-11 07:21:18 -05:00
Greg Wilkins fb6a445639
Issue #4741 No Servlet Path (#4898)
* Issue #4741 HttpServletMapping

This completes the refactoring started in #4851, using
the HttpServletMapping field to avoid having the servletPath field
in the Request and instead have a pathInContext field.

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

* Issue #4741 HttpServletMapping

reverted ResourceService changes

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

* Issue #4741 HttpServletMapping

fixed gzip handler

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

* Issue #4741 HttpServletMapping

Fixed several TODOs left in the code
removed _contextPath field and used an attributes lookup for include
replaced setContextPaths with setContext

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

* Issue #4741 HttpServletMapping

Used the same pattern from the contextPath changes for servletPath and pathInfo.   Now the servletPathMapping is always set on the request and only if the dispatch is an include do the effected methods look deeper for the source values.

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

* Issue #4741 HttpServletMapping

Improved javadoc

Signed-off-by: Greg Wilkins <gregw@webtide.com>
2020-05-28 12:17:22 +02:00
Lachlan Roberts 423777ed02 fix AbstractThreadPoolTest from merge from 9.4.x
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-05-27 19:35:38 +10:00
Greg Wilkins b8c7a9509a Merge remote-tracking branch 'origin/jetty-9.4.x' into jetty-10.0.x
Signed-off-by: Greg Wilkins <gregw@webtide.com>
2020-05-27 10:11:51 +02:00
Joakim Erdfelt 051e102122
Merge remote-tracking branch 'origin/release-9.4.29' into jetty-9.4.x 2020-05-25 08:43:41 -05:00
Lachlan 4611379c86
Merge pull request #4882 from eclipse/jetty-9.4.x-4873-ExecutorThreadPoolJoin
Issue #4873 - fix timeout on ExecutorThreadPool.join()
2020-05-25 14:07:28 +10:00
Lachlan Roberts 74f9b464a6 Issue #4873 - generalize test for all ThreadPools
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-05-22 10:49:42 +10:00
Joakim Erdfelt 5d6f3e2ddc Updating to version 9.4.30-SNAPSHOT 2020-05-21 13:42:25 -05:00
Joakim Erdfelt 77c232aed8 Updating to version 9.4.29.v20200521 2020-05-21 12:04:14 -05:00
Simone Bordet 3af43c8ac3 Merged branch 'jetty-9.4.x' into 'jetty-10.0.x'. 2020-05-21 18:36:36 +02:00
Greg Wilkins b9466823c8 Issue #4892 Async JSON
Handle encoded cached strings (or not).

Signed-off-by: Greg Wilkins <gregw@webtide.com>
2020-05-21 11:44:30 +02:00
Lachlan Roberts ae0b70fbfc Issue #4873 - add test to reproduce the ExecutorThreadPool.join() issue
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-05-20 00:45:05 +10:00
Lachlan Roberts 590b1a6ab1 Issue #4873 - fix timeout on ExecutorThreadPool.join()
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-05-18 11:49:12 +10:00
Lachlan Roberts ccaca1892e Merge remote-tracking branch 'origin/jetty-9.4.x' into jetty-10.0.x 2020-05-14 13:37:13 +10:00
Lachlan Roberts 9f39fd1dd1 Issue #4861 - reduce garbage created by the async request attributes
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-05-12 18:28:23 +10:00
Simone Bordet 63bfb43b2f Merged branch 'jetty-9.4.x' into 'jetty-10.0.x'. 2020-05-08 15:23:00 +02:00
Lachlan 908331acbd
Add jetty to ShutdownThread name. 2020-05-08 18:46:09 +10:00
Lachlan Roberts bb967cb841 Issue #4789 - Name the ShutdownThread
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-05-08 15:07:27 +10:00
Olivier Lamy 78992a126c
Start a mongo instance for testing using docker via java code (#4840)
* remove slow mongo maven plugin which was forking an external process and now run mongodb in a container so we can even now test with different version using -Dmongo.docker.version

Signed-off-by: olivier lamy <oliver.lamy@gmail.com>
2020-05-08 07:06:03 +10: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
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
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 426c80bf6d Fixes #4778 - Enforcing SNI when there are only non-wildcards certificates.
If SNI is required, wrap the KeyManagers with SniX509ExtendedKeyManager.
Updated the main keystore file to only have one certificate (instead of two),
since there never was the need for two certificates in the tests.

Signed-off-by: Simone Bordet <simone.bordet@gmail.com>
2020-04-18 18:15:03 +02:00
Greg Wilkins 6694f94cd5 Merge remote-tracking branch 'origin/jetty-9.4.x' into jetty-10.0.x
Signed-off-by: Greg Wilkins <gregw@webtide.com>
2020-04-15 18:50:19 +02:00
Lachlan 4388c376ba
Merge pull request #4704 from eclipse/jetty-9.4.x-4235-OpenIdErrors
Issue #4235 - communicate reason of OpenID auth failure to error page
2020-04-15 09:42:06 +10:00
Lachlan Roberts 0de5976651 Issue 4235 - changes from review
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-04-14 21:34:26 +10:00
Joakim Erdfelt 5699b9ff3d Updating to version 9.4.29-SNAPSHOT 2020-04-08 13:15:04 -05:00
Joakim Erdfelt ab228fde9e Updating to version 9.4.28.v20200408 2020-04-08 12:33:56 -05:00
Michael Mayer 9079fa63b3
Improve keystore exception message when keystore is not valid (#4759)
Signed-off-by: Michael Mayer <michael@schnittstabil.de>
2020-04-08 10:13:10 -05:00
Michael Mayer a640701d78
Improve keystore exception message when keystore is not valid (#4759)
Signed-off-by: Michael Mayer <michael@schnittstabil.de>
2020-04-08 15:36:52 +02:00
Greg Wilkins e3d670d61d
Issue #4713 Async dispatch with query. (#4721)
* Issue #4713 Async dispatch with query.

+ Preserve the entire URI with query when startAsync(req,res) is used.
+ merge any query string from dispatch path with either original query or preserved query from forward

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

* Issue #4713 asyncDispatch with query parameters

Signed-off-by: Greg Wilkins <gregw@webtide.com>
2020-03-30 16:23:26 +02:00
Lachlan af899b0e68
Merge pull request #4602 from eclipse/jetty-10.0.x-4340-ServiceLoader
Issue #4340 - Continue after ServiceLoader ServiceConfigurationError
2020-03-25 10:30:38 +11:00
Lachlan Roberts 4bc32e314b Issue #4235 - communicate reason of OpenID auth failure to error page
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-03-24 21:36:41 +11:00
Chris Walker da3bd1da8b Merge branch 'jetty-9.4.x' into jetty-10.0.x
# Conflicts:
#	jetty-documentation/src/main/asciidoc/development/frameworks/weld.adoc
#	jetty-http/src/test/java/org/eclipse/jetty/http/MultiPartFormInputStreamTest.java
2020-03-20 14:30:22 -05:00
Joakim Erdfelt 7e0fff9a89
Merge pull request #4686 from eclipse/jetty-10.0.x-4685-slf4j-impl-not-included
Issue #4685 - jetty-slf4j-impl not a compile/runtime dependency.
2020-03-20 12:04:32 -05:00
Joakim Erdfelt 43419802b7
Issue #4685 - Declare <scope> for jetty-slf4j-impl everywhere
Signed-off-by: Joakim Erdfelt <joakim.erdfelt@gmail.com>
2020-03-20 11:12:08 -05:00
Joakim Erdfelt 2c600f2b68
Issue #4685 - Mark jetty-slf4j-impl as test scope by default
+ Update logging in test-hazelcast-sessions
+ Update logging in test-infinispan-sessions

Signed-off-by: Joakim Erdfelt <joakim.erdfelt@gmail.com>
2020-03-20 09:55:15 -05:00
Lachlan Roberts 04cecaaaef Issue #4340 - Change usages to more closely follow previous behaviours
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-03-20 17:02:49 +11:00
Joakim Erdfelt a16abe1693
Issue #4685 - jetty-slf4j-impl not a compile/runtime dependency.
+ Mark as a test dependency

Signed-off-by: Joakim Erdfelt <joakim.erdfelt@gmail.com>
2020-03-19 17:46:41 -05:00
Simone Bordet 2940eb8ab5 Merged branch 'jetty-10.0.x' into 'jetty-10.0.x-4382-h1_to_h2_upgrade'. 2020-03-18 11:44:06 +01:00
Lachlan Roberts c658ae7056 Issue #4673 - fix MultiPart parsing for content split in boundary
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-03-18 11:22:40 +11:00
Lachlan Roberts 9363a3c39a Issue #4340 - changes from review
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-03-17 15:14:52 +11:00
Lachlan Roberts 30d36ed68c Merge branch jetty-10.0.x into jetty-10.0.x-4340-ServiceLoader
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-03-17 15:00:30 +11:00
Joakim Erdfelt 57604d0955
Issue #4572 - Mechanical Change to use org.slf4j
Signed-off-by: Joakim Erdfelt <joakim.erdfelt@gmail.com>
2020-03-16 15:48:25 -05:00
Joakim Erdfelt 8b7e64915f
Issue #4572 - Replace Jetty Logging with SLF4J
* Introducing jetty-slf4j-impl
* Make Jetty use org.slf4j
* Removed most of org.eclipse.jetty.util.log classes
* Left org.eclipse.jetty.util.log.Log and
       org.eclipse.jetty.util.log.Logger but as
  simple bridge classes that are deprecated
* Migrated code using org.eclipse.jetty.util.log.StacklessLogging
  to org.eclipse.jetty.logging.StacklessLogging found in
  the jetty-slf4j-impl
* Moved logging start modules from jetty-util to jetty-home
* Simplified logging start modules
* Updated code that was using StdErrLog directly
* Updating module-info.java for org.slf4j
* removing org.eclipse.jetty.util.log.class references
* jetty-start supports manually declared default provider
  + and we use it to default "logging" to the "logging-jetty" provider
* Cleaning up jetty-maven-plugin and IT testing for Logging
* Using old slf4j for it testing
* Updating compiler config to show Xlint:exports warnings
* Updating console-capture and logging-noop
* Adding slf4j bridge (capture) jetty modules
* Updates to jetty logging module locations
* Changing reference to slf4j dependent mod
* Process requested enabled modules in topological order
* Limiting inclusions in shaded jetty-start
  + Also adding note to jetty-util classes that are used by
    jetty-start
* Default logging level on baseline logging config is INFO (not DEBUG)
* Changing from system to server classes in logging
* Updating other modules to use new logging names

Signed-off-by: Joakim Erdfelt <joakim.erdfelt@gmail.com>
2020-03-16 11:21:54 -05:00
Greg Wilkins ca74fbeb32 Merge remote-tracking branch 'origin/jetty-9.4.x' into jetty-10.0.x 2020-03-16 10:23:58 +01:00
Lachlan Roberts 7af220dade Issue #4340 - shortcut method for the serviceStream
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-03-16 09:42:32 +11:00
Simone Bordet 466517a0e8 Issue #4382 - Support HTTP/1 upgrade to HTTP/2 in HttpClient.
* Moved implementation of UpgradeTo from HTTP2ServerConnection
  to HTTP2Connection, since now also the client connection
  can be upgraded to.
* Split HTTP2Session.newStream(), since now the client must
  be able to create the implicit stream 1 corresponding to
  the HTTP/1.1 upgrade request, so that the HTTP/2 response
  after the upgrade finds the stream.
* The HTTP/1.1 upgrade mechanism has been generalized.
  Before it was based on HttpConnectionUpgrader and a hook
  in HttpChannelOverHTTP.exchangeTerminating().
  Now it is based on UpgradeProtocolHandler that when sees
  a 101 response it will trigger the upgrade mechanism.
* Introduced ConnectionPool.accept(Connection) to transfer
  a connection from the HTTP/1.1 connection pool to the
  HTTP/2 connection pool after the upgrade.

Signed-off-by: Simone Bordet <simone.bordet@gmail.com>
2020-03-13 15:59:13 +01:00
Lachlan Roberts a6b2b3ff98 Merge remote-tracking branch 'origin/jetty-10.0.x' into jetty-10.0.x-4340-ServiceLoader
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-03-13 17:02:26 +11:00
Lachlan Roberts edd671146d Issue #4340 - ServiceLoader stream which doesn't break if hasNext throws
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-03-13 16:59:33 +11:00
Lachlan Roberts dbd89ce1c7 Issue #4645 - validate port range & return 400 on bad forwarded headers
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-03-11 18:31:25 +11:00
Lachlan Roberts fef25e7825 Merge branch jetty-10.0.x into jetty-10.0.x-4538-MessageReaderWriter 2020-03-11 14:23:47 +11:00
Jan Bartel dfd3875dbc
Jetty 10.0.x 4506 metadata complete (#4587)
* Issue #4506 Do not introspect annotations on metadata-complete fragments

Signed-off-by: Jan Bartel <janb@webtide.com>
2020-03-09 15:34:04 +01:00
olivier lamy 1c4a21c9be Merge branch 'jetty-9.4.x' into jetty-10.0.x 2020-03-09 14:28:53 +10:00
Joakim Erdfelt f2a4c6b615
Issue #4620 - Better support for alt PrintStream in StdErrLog
Signed-off-by: Joakim Erdfelt <joakim.erdfelt@gmail.com>
2020-03-02 12:03:37 -06:00
Lachlan Roberts 355d21317b Issue #4340 - Changes from review
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-03-02 10:16:38 +11:00
Lachlan 6151fc0c36
Merge pull request #4615 from eclipse/jetty-10.0.x-4598-InetAccessHandler
Issue #4598 - rework InetAccessHandler to use path mappings
2020-03-01 18:43:32 +11:00
Lachlan Roberts 97c55e27cc Issue #4340 - remove TypeUtil.load and use flatMap() on streams instead
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-02-29 11:06:32 +11:00
Lachlan Roberts 6832912d49 Issue #4340 - Implement TypeUtil.load(ServiceLoader) with Streams
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-02-28 12:15:27 +11:00
Joakim Erdfelt 8aabb52557 Updating to version 9.4.28-SNAPSHOT 2020-02-27 13:03:44 -06:00
Joakim Erdfelt a304fd9f35 Updating to version 9.4.27.v20200227 2020-02-27 12:21:57 -06:00
Simone Bordet a2a75e8ecc Merged branch 'jetty-9.4.x' into 'jetty-10.0.x'. 2020-02-27 13:31:18 +01:00
Simone Bordet 75893dac9c Fixes #4612 - ReservedThreadExecutor hangs when the last reserved thread idles out.
Explicitly removing the idled out thread from the stack,
rather than calling tryExecute().
Side benefit is that we are now removing idled out threads
that are least recently used.

Signed-off-by: Simone Bordet <simone.bordet@gmail.com>
2020-02-27 13:26:53 +01:00
Lachlan Roberts ccd6c845e5 Merge remote-tracking branch 'origin/jetty-9.4.x-4598-InetAccessHandler' into jetty-10.0.x-4598-InetAccessHandler 2020-02-27 19:34:16 +11:00
Lachlan Roberts 2edc4920fd Issue #4598 - fix InetAccessHandlerTest expectations to fit new behavior
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-02-27 18:29:29 +11:00
Lachlan Roberts 3c551e960c Issue #4598 - rework InetAccessHandler to use only one IncludeExcludeSet
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-02-27 15:41:35 +11:00
Greg Wilkins 277ce5f3a5 Merge remote-tracking branch 'origin/jetty-9.4.x' into jetty-10.0.x 2020-02-26 14:36:22 +01:00
Joakim Erdfelt d082e54301
Issue #4606 - fixing formatTick use of `now`
Signed-off-by: Joakim Erdfelt <joakim.erdfelt@gmail.com>
2020-02-26 07:01:53 -06:00
Lachlan Roberts 67e88abbe9 Issue #4340 - loadFirst can take a predicate to match a service provider
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-02-26 10:35:31 +11:00
Lachlan Roberts a277c30b81 Issue #4340 - Move ServiceLoaderUtil.load method to TypeUtil.loadAll
- increase MAX_ERRORS to 1000
- introduce a loadFirst method

Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-02-26 10:26:29 +11:00
Lachlan Roberts a7f4d2606b Issue #4340 - always pass in ServiceLoader to ServiceLoaderUtil
this prevents errors where jetty-util must declare it uses the provider
class in module.info

Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-02-25 19:49:23 +11:00
Lachlan Roberts 81424f1f44 Issue #4340 - Continuing after ServiceLoader ServiceConfigurationError
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-02-25 19:49:22 +11:00
Lachlan Roberts bb7e48043d Issue #4598 - Add URI mapping to InetAccessHandler
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-02-25 14:58:48 +11:00
Joakim Erdfelt 0e536407a9
Issue #4567 - Backport of StdErrLog 10.0.x for Throwable behavior change
Signed-off-by: Joakim Erdfelt <joakim.erdfelt@gmail.com>
2020-02-20 13:45:40 -06:00
Joakim Erdfelt e894da5b21
Fixing noinspection warning
Signed-off-by: Joakim Erdfelt <joakim.erdfelt@gmail.com>
2020-02-20 13:42:53 -06:00