Commit Graph

3327 Commits

Author SHA1 Message Date
Lachlan f23236b09d
Merge pull request #4775 from eclipse/jetty-10.0.x-4771-WebSocketMessageHandlerTests
Issue #4771 - cleanup and add tests for the unused ws message handlers
2020-04-20 08:43:39 +10:00
Greg Wilkins 2addb6a655
Jetty 10.0.x use HandlerList instead of HandlerCollection (#4757)
* Use HandlerList instead of HandlerCollection

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

* Use HandlerList instead of HandlerCollection

Signed-off-by: Greg Wilkins <gregw@webtide.com>
2020-04-15 18:42:28 +02:00
Lachlan Roberts 4047e31ce7 Issue #4771 - cleanup and add tests for the different ws message handlers
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-04-15 10:50:27 +10:00
Simone Bordet 51c42f2849 Improvements to the Jetty client documentation, protocols section.
Signed-off-by: Simone Bordet <simone.bordet@gmail.com>
2020-04-03 15:48:54 +02:00
Lachlan d595c59622
Merge pull request #4702 from eclipse/jetty-10.0.x-4603-WS_HTTP2_NPE
Issue #4603 - avoid NPE during websocket HTTP/2 upgrade
2020-03-27 09:44:24 +11:00
Lachlan Roberts 85ea14e33d Issue #4603 - clarifications in comments and improve test
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-03-25 22:43:43 +11:00
Lachlan ea80253cca
Merge pull request #4694 from eclipse/jetty-10.0.x-4691-consistent_methodhandles_lookup
Issue #4691 - use static methods with javadoc to get MethodHandle lookups
2020-03-25 10:31:37 +11: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 c0b6d9f677 Issue #4691 - changes from review
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-03-24 14:30:02 +11:00
Lachlan Roberts 04cc21fe40 Issue #4691 - use static methods with javadoc to get MethodHandle lookup
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-03-23 16:43:09 +11:00
Lachlan Roberts d4c2893843 Issue #4691 - Remove unnecessary throws from getMethodHandleLookup.
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-03-23 11:44:06 +11:00
Simone Bordet 10f4fda0de Issue #4691 - Use MethodHandles.lookup() consistently in WebSocket code.
* Using MethodHandles.publicLookup().in(...) instead of privateLookupIn(...).
* Moved test WebSocket EndPoint classes into the proper package, otherwise
  they would not be accessible because the test package is not exported.

Signed-off-by: Simone Bordet <simone.bordet@gmail.com>
2020-03-22 16:42:13 +01:00
Joakim Erdfelt e385dea838
Do not deploy websocket test projects
Signed-off-by: Joakim Erdfelt <joakim.erdfelt@gmail.com>
2020-03-20 14:04:04 -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 99f1f8b897
Issue #4685 - Cleanup from review
Signed-off-by: Joakim Erdfelt <joakim.erdfelt@gmail.com>
2020-03-20 11:07:25 -05:00
Joakim Erdfelt 9492a5379c
Issue #4685 - eliminate <version> in jetty-slf4j-impl
Signed-off-by: Joakim Erdfelt <joakim.erdfelt@gmail.com>
2020-03-20 10:42:36 -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 9cbd9ab44e Merged 'jetty-10.0.x' into 'jetty-10.0.x-4382-h1_to_h2_upgrade'. 2020-03-19 18:17:57 +01:00
Olivier Lamy 0541c5efb4
fix javadoc aggregate generation by using last maven javadoc plugin 3.2.0 (#4675)
Signed-off-by: olivier lamy <oliver.lamy@gmail.com>
2020-03-19 07:06:13 +10: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
Greg Wilkins e35b3b29d6
Issue #4656 generalise XmlConfiguration elements (#4661)
* Issue #4656 generalise XmlConfiguration elements

Extended the use of Id, Class elements

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

* Issue #4657 Validation in XmlConfiguration

Default to validate if xerces is in the name
Fixed test harness to prepend DTD.

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

* Issue #4657 Validation in XmlConfiguration

WIP on adding validation to XMLs

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

* Issue #4656 - Fix bad xml id attribute usage in jetty-maven-plugin

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

Co-authored-by: Joakim Erdfelt <joakim.erdfelt@gmail.com>
2020-03-17 09:38:21 +01: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
Lachlan Roberts e050160101 Merge branch jetty-10.0.x into jetty-10.0.x-WebSocket-JPMS
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-03-17 11:07:29 +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
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 ac69c53077 jetty websocket modules should not transitively export websocket-core
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-03-13 12:07:36 +11:00
Lachlan Roberts a0626adad5 javax websocket modules should not transitively export websocket-core
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-03-12 16:21:07 +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
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 adbb3f165e Issue #4571 - review UTF-8 validation in MessageSinks
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-02-20 19:00:53 +11:00
Lachlan Roberts 34fd1481b8 Issue #4571 - always close MessageSink before completing the Future
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-02-20 18:47:04 +11:00
Lachlan Roberts b2eddff228 Issue #4571 - fix broken tests
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-02-19 19:38:26 +11:00
Lachlan Roberts bc6c950304 add missing licence header
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-02-19 19:33:11 +11:00
Lachlan Roberts 5c839d791d Issue #4538 - allow MessageInputStream not to read to EOF
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-02-19 19:31:26 +11:00
Lachlan Roberts 97abed549b Issue #4538 - Combine MessageWriterTests, add test for UTF-8 validation
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-02-19 16:13:22 +11:00
Lachlan Roberts 1b123b87a9 Issue #4538 - add invalid utf8 validation tests for MessageReader
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-02-19 11:32:37 +11:00
Lachlan Roberts 2467d5a8c5 Issue #4538 - Rework MessageInputStream and MessageReader
Message reader now validates UTF8

Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-02-19 11:32:26 +11:00
Lachlan Roberts 6eccc7ebce Issue #4538 - MessageWriter delegates to MessageOutputStream
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-02-19 11:32:15 +11:00
Lachlan Roberts e2f86f9a19 Issue #4538 - simplify MessageInputStream and DispatchedMessageSink
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-02-19 11:32:03 +11:00
Lachlan Roberts 71b11f0887 Issue #4571 - simplify partial MessageSinks reduce copying
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-02-19 11:26:56 +11:00
Lachlan Roberts 36cccd2c88 Issue #4571 - optimise aggregating text and binary MessageSinks
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-02-19 11:25:05 +11:00
Lachlan 5fe202f29f
Issue #4548 - clean up websocket removing duplicated and unused classes (#4549)
Create new module websocket-util which contains implementation classes shared by websocket-jetty and websocket-javax. Many of these classes had to be changed as the javax and jetty versions of them differed slightly.

Also includes general cleanups, removed unused interfaces and classes, etc..
2020-02-18 21:43:54 +11:00
Olivier Lamy abdb9f2ff6
Jetty 10.0.x methodhandles lookup linkage (#4552)
* use a lookup dedicated to the target class (webapp classloader) to avoid collision with server classloader

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

* cleanup war test dependencies

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

* remove empty lines

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

* make it clear it is a bad websocket webapp only for testing purpose and add a good websocket webapp

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

* no need anymore of this dependency

Signed-off-by: olivier lamy <oliver.lamy@gmail.com>
2020-02-09 11:59:57 +10:00
Lachlan e4c1984fd0
Merge pull request #4536 from eclipse/jetty-10.0.x-4447-websocketModules
Issue #4447 - separate modules for jetty and javax websockets
2020-02-07 16:15:27 +11:00
Lachlan Roberts b3144dd401 Issue #4447 - update websocket-jetty module description
Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
2020-02-07 16:14:32 +11:00