+ Any schedulers created are named (for ease of debug) and daemon
so they do not stop the JVM exiting.
+ If the server.doStart() fails, it calls server.doStop to ensure
connectors are stopped, ports are free etc.
+ cleanup of addBean handling of scheduler in proxy
Signed-off-by: Greg Wilkins <gregw@webtide.com>
Modified jetty-client content decoding to be fully non-blocking;
this allows for a better backpressure and less usage of the buffer
pool.
Modified GZIPContentDecoder to aggregate decoded ByteBuffers in
a smarter way that avoids too many data copies and pollution of
the buffer pool with intermediate size buffers.
Removed duplicate test GZIPContentDecoderTest.
Improved javadocs and improved AsyncMiddleManServlet
to release buffers used by the GZIPContentDecoder.
Signed-off-by: Simone Bordet <simone.bordet@gmail.com>
Updating SslContextFactory configuration for tests, since
the change in the default endPointIdentificationAlgorithm
makes the test failing as the certificates are not valid
for the local host, which is different depending on where
the tests are run (locally, jenkins).
Signed-off-by: Simone Bordet <simone.bordet@gmail.com>
* Cleanup the dump implementation
* improved the clarity of utility methods for dump and updated most dump methods
* fixed upgrade filter dump
* Improved dump after review
* Moved dumpObjects to Dumpable
* implemented dumpBeans with dumpObjects
* less verbose dump
* Dump streams
* fixed dump test
Signed-off-by: Greg Wilkins <gregw@webtide.com>
Signed-off-by: Simone Bordet <simone.bordet@gmail.com>
+ Changes needed for new Junit 5
+ Migrating from Vintage junit API to Jupiter junit API
+ Relies on SNAPSHOT jetty-test-helper
- this will be a formal release once this issue has been
resolved satisfactory
+ Have jenkins always pull latest SNAPSHOT for each build
+ Adding jetty.snapshots repository
+ Using surefire 2.22.0 per advice from junit
+ Ensuring <reuseForks>true</reuseForks> to work around issue junit-team/junit5#801
+ Disabling <forkMode>always</forkMode> in maven-surefire-plugin
due to bug https://github.com/junit-team/junit5/issues/801
+ OSGi tests must remain at vintage due to PaxExam
+ Moving from vintage TestingDir to jupiter WorkDir
+ Fixing imports to use jupiter, not vintage
+ Migrating vintage ExpectedException to jupiter assertThrows
+ Migrating vintage TestName to jupiter TestInfo
+ Migrating @RunWith(Parameterized.class)
to @ParameterizedTest with Argument Sources
+ Migrating assertTrue(val.contains(needle))
to assertThat(val, containsString(needle))
+ Aligning junit versions per recommendations from @sormuras
+ Adjusting parameter order change for assertEquals()
+ Test LifeCycle Annotation Migration
junit 4 | junit 5 / jupiter
------------ | -----------
@Before | @BeforeEach
@After | @AfterEach
@BeforeClass | @BeforeAll
@AfterClass | @AfterAll
Signed-off-by: Joakim Erdfelt <joakim.erdfelt@gmail.com>
Signed-off-by: olivier lamy <oliver.lamy@gmail.com>
`AsyncMiddleManServlet.Transparent` class should extend `AsyncMiddleManServlet`
so the consumers can override the `newServerResponseContentTransformer` &
`newServerResponseContentTransformer` to provide their own ContentTransformer.
The way it is structured right now makes it impossible to use
`AsyncMiddleManServlet.Transparent` servlet as a middle man servlet.
Signed-off-by: Assim Deodia <assim.deodia@gmail.com>
From the RFC: "Comparison of expectation values is case-insensitive for unquoted tokens (including the 100-continue token), and is case-sensitive for quoted-string expectation-extensions. "
Signed-off-by: Steven Schlansker <stevenschlansker@gmail.com>
Modified the logic to invoke the transformer when there are input bytes
but there are no decoded bytes and it's the last content.
Could not write a test case for this though.
+ Upgrading to jetty-test-helper 4.0
+ Removing use of org.eclipse.jetty.toolchain.test.SimpleRequest
+ Removing use of org.eclipse.jetty.toolchain.test.http.SimpleHttpParser
+ Removing use of org.eclipse.jetty.toolchain.test.http.SimpleHttpResponse
+ Updating long since deprecated (and now removed) known quirky methods
in jetty-test-helper and the test classes.
Improved to the toString and dump output of connections, endpoints and channel to assist with debugging
made the SSL callbacks and runnables Invocable to avoid thread starvation.
Removed wake() call from within pollContent
Instead the EOF status is evaluated :
- when setReadListener is called
- when read returns -1
- when run() is called before calling either onDataAvailable or onAllDataRead
Squashed commit of the following:
commit 6a345356998331a90e60c7ee8ee590920464c72f
Merge: 92bc0e9 60d9001
Author: Greg Wilkins <gregw@webtide.com>
Date: Mon Nov 7 09:46:23 2016 +1100
Merge branch 'jetty-9.4.x' into jetty-9.4.x-issue-1074
commit 92bc0e9f3aafdce2f4aa7b2fde31affc942be042
Author: Greg Wilkins <gregw@webtide.com>
Date: Sat Nov 5 18:24:00 2016 +1100
Issue #1074
Do not do async IO callbacks if completed
commit ee220a12d1e6c5f6e39b4597a209c5043aa775cf
Author: Greg Wilkins <gregw@webtide.com>
Date: Sat Nov 5 16:22:55 2016 +1100
Issue #1074
Turned off debug
improved proxy test to be able to run with debug on
commit e2fb0b9ef1ec422a2c82cb388820581e359234ba
Author: Greg Wilkins <gregw@webtide.com>
Date: Sat Nov 5 15:37:27 2016 +1100
Issue #1074
Improved test cases
Handle early EOF
commit 3c47c022fe7e48f82e41d9a208073b64cfeb5af7
Author: Greg Wilkins <gregw@webtide.com>
Date: Sat Nov 5 12:28:15 2016 +1100
provisional implementation
Reduce the transformations needed on header fields, so they can be more often
set directly and no need to split and recombine.
The Content-Length field is added IF it is needed for framing or if it was explicitly set
The Transfer-Encoding: chunk field is used only as a hint that there is content.
Connection fields are used as is, but are checked for close and keep-alive
Introduced overridable ContinueProtocolHandler.onContinue(), and
making sure that proxy servlets use a ContinueProtocolHandler
subclass to intercept 100 Continue responses from the server, so that
they can relay it properly to the client.
Using https scheme in CONNECT request if the proxy is secure.
A Proxy must not match its own address.
Resolved correctly request URI in case of CONNECT requests.