Commit Graph

1883 Commits

Author SHA1 Message Date
Greg Wilkins c5fc35fa05 Merge branch 'jetty-9.4.x' into jetty-9.4.x-2022-FineGrainedComplianceModes 2017-12-23 11:12:48 +01:00
Simone Bordet 005ae95bea
Fixes #1949 - Client-side problems with digest authentication. (#1991)
Introduced ContentProvider.isReproducible() to detect whether the
request content can be provided more than once, and modified
ContentProvider implementation accordingly.

Modified AuthenticationProtocolHandler to not send an authenticated
request if the content is not reproducible.

Modified AuthenticationProtocolHandler to tolerate request failures.

Signed-off-by: Simone Bordet <simone.bordet@gmail.com>
2017-12-21 02:34:39 -08:00
Joakim Erdfelt 2dd970b055 Updating to version 9.2.24-SNAPSHOT 2017-12-18 10:43:47 -06:00
Joakim Erdfelt cdbe733684 Updating to version 9.2.23.v20171218 2017-12-18 09:06:48 -06:00
Simone Bordet b68fbc4cfb Merged branch 'jetty-9.3.x' into 'jetty-9.4.x'. 2017-12-16 23:36:53 +01:00
Simone Bordet 37388ef105 Merged branch 'jetty-9.2.x' into 'jetty-9.3.x'. 2017-12-16 23:28:05 +01:00
Simone Bordet eaa4c70cfc Issue #2065 - Backport #347 to Jetty 9.2.x.
Implemented as integer guard + timestamp.
The timestamp is not enough to guard against long times spent sending
(and/or in application callbacks during sends).
2017-12-16 22:25:59 +01:00
Simone Bordet ce4fad3deb Fixes #2065 - Backport #347 to Jetty 9.2.x. 2017-12-15 17:48:47 +01:00
Greg Wilkins c6c5a3b890 Merge branch 'issue-2022' of https://github.com/Baqend/jetty.project into jetty-9.4.x-2022-FineGrainedComplianceModes 2017-12-15 16:19:14 +01:00
fb 7ee8bb82c6 Same code style fixes and remove unnecessary code reformatting
Signed-off-by: fb <fb@baqend.com>
2017-12-15 15:23:17 +01:00
fb a324a5ad77 Implement weak http header parsing and make the compliance mode configurable in the client
Signed-off-by: fb <fb@baqend.com>
2017-12-15 15:13:48 +01:00
fb b76240e678 Fixes #2022 - Ignore invalid chars in http header names, when the compliance mode is not RFC7230
Signed-off-by: fb <fb@baqend.com>
2017-12-15 15:12:34 +01:00
Simone Bordet d3db89d7e3 Fixes #2019 - Expose HttpClientTransport in JMX.
Added missing @ManagedObject annotation to AbstractConnectorHttpClientTransport.

Also exported to JMX the "multiplexed" attribute for the FCGI transport
and the "useALPN" attribute for the HTTP/2 transport.

Signed-off-by: Simone Bordet <simone.bordet@gmail.com>
2017-12-14 12:28:46 +01:00
Simone Bordet ba5ed4c6ce Issue #2050 - Clarify ObjectMBean getObject[Name|Context]Basis() methods.
Clarified the role of the HttpClient name with respect to JMX.
Improved test case.

Signed-off-by: Simone Bordet <simone.bordet@gmail.com>
2017-12-14 11:24:43 +01:00
Simone Bordet f2bf3d63bc Fixes #2020 - Introduce a name for `HttpClient` instances.
Added HttpClientMBean, and overridden getObjectContextBasis() so that
the HttpClient name is inherited by children components such as the
HttpClientTransport, the ThreadPool, etc.

Signed-off-by: Simone Bordet <simone.bordet@gmail.com>
2017-12-14 11:24:43 +01:00
Joakim Erdfelt ff53002fac Updating to version 9.4.9-SNAPSHOT 2017-11-21 13:11:31 -07:00
Joakim Erdfelt 82b8fb23f7 Updating to version 9.4.8.v20171121 2017-11-21 12:33:52 -07:00
Greg Wilkins c66bacba02 Issue #922 (#1965) bytesIn/Out stats
Ensure -1 fill is not appended to bytesIn counts
Don't include discarded bytes from head responses in counts
refactored gather writes in HttpConnection to be clearer and removed
redundant buffer checks
2017-11-14 09:12:00 +01:00
Olivier Lamy 786f128808 implements connection.getBytes[In|Out] for http transport #922 (#1965)
* implements connection.getBytes[In|Out] for http transport, #922

Signed-off-by: olivier lamy <olamy@webtide.com>

* use LongAdder rather than AtomicLong

Signed-off-by: olivier lamy <olamy@webtide.com>

* changes by Greg review

Signed-off-by: olivier lamy <olamy@webtide.com>

* changes by Greg review

Signed-off-by: olivier lamy <olamy@webtide.com>
2017-11-14 08:41:47 +01:00
Jesse McConnell a72eb0001d Updating to version 9.3.23-SNAPSHOT 2017-10-30 15:39:57 -05:00
Jesse McConnell 705048cc49 Updating to version 9.3.22.v20171030 2017-10-30 15:16:29 -05:00
Simone Bordet 333c22d670 Issue #1924 - ManagedSelector livelock.
* Actually using the MAX_ACTION_PERIOD value rather than a harcoded one.
* Waking up the selector outside the sync block.
2017-10-30 00:36:01 +01:00
Greg Wilkins ab849e8cc5 Issue #1920 - Connect Timeouts with NonBlocking CreateEndPoint.
Added a LiveLock (BusyBlocking) test.
Modified ManagedSelector to fair share between actions and selecting
2017-10-28 14:55:40 +11:00
Simone Bordet 76e744979b Issue #1893 - Jetty HttpClient Connection TTL.
Removed test for TTL functionality.
Added test for the round robin behavior.
2017-10-25 11:22:46 +02:00
Simone Bordet 6e8242d1a4 Issue #1893 - Jetty HttpClient Connection TTL.
Removed the functionality, not needed anymore.
2017-10-25 11:02:33 +02:00
Simone Bordet ddf074d78f Merged branch 'jetty-9.3.x' into 'jetty-9.4.x'. 2017-10-23 17:37:23 +02:00
Simone Bordet 4d8ab1828e Merged branch 'jetty-9.2.x' into 'jetty-9.3.x'. 2017-10-23 17:36:39 +02:00
Simone Bordet e449387158 Fixes #1914 - jetty client fails to parse response with RFC2045 conformant Content-Type: charset="utf-8". 2017-10-23 17:36:11 +02:00
Simone Bordet 0d3827d882 Fixes #1893 - Jetty HttpClient Connection TTL.
Implemented live timeout on RoundRobinConnectionPool.
2017-10-19 17:47:35 +02:00
Simone Bordet d2fc88839c Added/fixed @ManagedObject annotation. 2017-10-19 17:47:35 +02:00
Simone Bordet 850e70f27c Fixes #1897 - Introduce a round-robin connection pool for HttpClient. 2017-10-16 18:21:36 +02:00
Simone Bordet 91c11f5a64 Fixes #1888 - Implement cookie matching on Path attribute.
Implemented path matching following RFC 6265.
2017-10-11 17:39:06 +02:00
Simone Bordet a436b9eb6c Fixes #1878 - Handle 100 Continue response without Expect header.
Fixed - again - accept().
2017-10-09 15:59:41 +02:00
Simone Bordet 6fd3351272 Fixes #1878 - Handle 100 Continue response without Expect header.
Fixed accept() to test for the response code being indeed 100.
2017-10-09 13:38:17 +02:00
Simone Bordet c69c7b29c7 Fixes #1878 - Handle 100 Continue response without Expect header. 2017-10-09 12:08:24 +02:00
Simone Bordet a4d7b4c4dc Removed unnecessary code. 2017-10-03 10:19:06 +02:00
Simone Bordet 3b98a6c000 Issue #1851 - Improve insufficient thread warnings/errors.
ThreadBudget -> ThreadPoolBudget.
Added selectors to the leased threads.
2017-10-02 13:40:31 +02:00
Simone Bordet 17a1484143 Code cleanups.
Removed unnecessary imports and fixed typos.
2017-10-02 11:43:45 +02:00
Greg Wilkins 7d98cbb870 Issue #1851 Improve insufficient thread warnings/errors
Squashed commit of the following:

commit 1d9e8e4b4d53898cb6435f67529347bd2ba82cf0
Merge: 7280594 55b0f10
Author: Greg Wilkins <gregw@webtide.com>
Date:   Thu Sep 28 07:20:37 2017 +1000

    Merge branch 'jetty-9.4.x' into jetty-9.4.x-1851-ThreadBudget

commit 7280594a0058538b603ad35625713a79830e9b93
Author: Greg Wilkins <gregw@webtide.com>
Date:   Wed Sep 27 22:48:58 2017 +1000

    fixed headers

commit f962f18e5b098ae40846ee3832736ee4650aed84
Author: Greg Wilkins <gregw@webtide.com>
Date:   Wed Sep 27 18:12:33 2017 +1000

    Issue #1851 added reset

commit a63894de284c8d8dc5ed031f1f6e0fccaf6c7715
Author: Greg Wilkins <gregw@webtide.com>
Date:   Wed Sep 27 18:08:53 2017 +1000

    Issue #1851 improved test

commit 8bcc460dc63273165305a7adcb88e991e30de4b7
Author: Greg Wilkins <gregw@webtide.com>
Date:   Wed Sep 27 18:03:47 2017 +1000

    Issue #1851 Improve insufficient thread warnings/errors

    Refactor approach to use Leases, to handle multiple executors

commit fe4be5f56594f342ab5c2e6c886397d9b4fe9c14
Merge: abc5eac a248d38
Author: Greg Wilkins <gregw@webtide.com>
Date:   Wed Sep 27 15:37:56 2017 +1000

    Merge branch 'jetty-9.4.x' into jetty-9.4.x-1851-ThreadBudget

commit abc5eac2b73d306a91b28ef4db778455095a5bdb
Author: Greg Wilkins <gregw@webtide.com>
Date:   Wed Sep 27 12:20:03 2017 +1000

    Issue #1851 Improve insufficient thread warnings/errors

    Created a ThreadBudget class that can be used to warn/error for
    registered and unregistered allocations of threads.

    The server on doStart does an unregistered check of all its components that
    implement the Allocation interface.

    The client will register itself as an Allocation if a shared Executor is used.
2017-09-28 07:35:05 +10:00
Simone Bordet 6aafc3b792 Fixes #1845 - Allow null User-Agent in HttpClient. 2017-09-25 13:03:26 +02:00
Greg Wilkins a6f02c26a8 Issue #1509 Review GZIPContentDecoder buffer pooling
A temporary fix that uses a hueristic to limit the pool size.

Perhaps such a hueristic should be the default for the queue size of all ByteBufferPools, as infinite queue size is rarely going to be a good thing?

Also, I think all the pools need to have better javadoc, plus an upper/lower bound of the size of buffer that they will pool, as gzip will tend to ask for lots of random sized buffers to put the expanded data into, some could be very
large and unlikely to be reused.
2017-09-21 14:29:58 +10:00
Joakim Erdfelt eee41174f2 Merge branch 'release-9.4.7' into jetty-9.4.x 2017-09-18 14:06:44 -07:00
Joakim Erdfelt d9865a02ba Updating to version 9.4.8-SNAPSHOT 2017-09-14 08:44:27 -07:00
Joakim Erdfelt 80fb788d0c Updating to version 9.4.7.v20170914 2017-09-14 07:35:18 -07:00
Simone Bordet aa4a77794e Issue #212 - HttpClient to support pluggable AuthenticationStore.
AuthenticationStore must be initialized eagerly.
2017-09-14 13:00:52 +02:00
Simone Bordet ce9be291d3 Fixes #212 - HttpClient to support pluggable AuthenticationStore. 2017-09-14 11:29:39 +02:00
Simone Bordet c402f8d5fa Fixed test after #1804. 2017-09-11 17:03:22 +02:00
Simone Bordet b078c910a7 Code cleanup: replaced anonymous inner classes with lambdas. 2017-09-11 17:02:32 +02:00
Simone Bordet 6c44538bb6 Fixes #1750 - PoolingHttpDestination creates ConnectionPool twice.
Now destinations needs to be started in tests, take 2.
2017-08-18 19:36:27 +02:00
Simone Bordet 7390707e07 Fixes #1750 - PoolingHttpDestination creates ConnectionPool twice.
Now destinations needs to be started in tests.
2017-08-17 16:37:13 +02:00
Simone Bordet 3b805123b8 Merged branch 'jetty-9.3.x' into 'jetty-9.4.x'. 2017-08-17 11:47:56 +02:00
Simone Bordet bcf96517bd Fixes #1750 - PoolingHttpDestination creates ConnectionPool twice. 2017-08-17 11:42:56 +02:00
Simone Bordet c395097812 Fixes #1749 - Dump HttpDestination exchange queue.
Improved code.
2017-08-17 11:42:27 +02:00
Simone Bordet 2bfe6fa964 Fixes #1749 - Dump HttpDestination exchange queue. 2017-08-17 11:15:23 +02:00
Joakim Erdfelt 1311052b15 Cleaning up state of branch to match the original jetty-9.4.x
+ Does not include changes to /jetty-cdi/
+ Does not include changes to /jetty-websocket/ for javax.websocket-1.1
2017-08-08 09:47:04 -07:00
Simone Bordet b1b569bd23 475546 - ClosedChannelException when connecting to HTTPS over HTTP proxy with CONNECT.
Not closing the connection if the request method is CONNECT.
2017-08-08 09:15:49 -07:00
Simone Bordet 8cfd971f92 JavaDoc clarification. 2017-08-08 09:15:14 -07:00
Simone Bordet 191b6e044f Fixes #1656 - Improve configurability of ConnectionPools.
Introduced ConnectionPool.Factory and HttpClientTransport.connectionPoolFactory.
This allows applications to create a ConnectionPool given the HttpDestination.
2017-08-08 09:14:19 -07:00
Joakim Erdfelt 3fdbcffbbd Updating to version 9.2.23-SNAPSHOT 2017-08-08 09:12:55 -07:00
Joakim Erdfelt a7bcac6d75 Updating to version 9.3.20.v20170531 2017-08-08 09:07:35 -07:00
Simone Bordet be970de6db 475546 - ClosedChannelException when connecting to HTTPS over HTTP proxy with CONNECT.
Not closing the connection if the request method is CONNECT.
2017-08-02 22:29:28 +02:00
Joakim Erdfelt 11a544d6ac Updating to version 9.3.22-SNAPSHOT 2017-08-01 11:26:37 -07:00
Joakim Erdfelt bb1d69ca52 Updating to version 9.3.21.M0 2017-08-01 10:47:04 -07:00
Joakim Erdfelt 4d2c299fe8 Updating to version 9.2.23-SNAPSHOT 2017-06-06 08:55:12 -07:00
Joakim Erdfelt 0af30bce5a Updating to version 9.2.22.v20170606 2017-06-06 07:03:05 -07:00
Joakim Erdfelt 6a3c40e935 Updating to version 9.4.7-SNAPSHOT 2017-05-31 17:26:34 -07:00
Joakim Erdfelt 8ba0f2d95d Updating to version 9.4.6.v20170531 2017-05-31 16:22:52 -07:00
Joakim Erdfelt 429380d36a Updating to version 9.3.21-SNAPSHOT 2017-05-31 16:10:04 -07:00
Joakim Erdfelt 0f3b1cbe36 Updating to version 9.3.20.v20170531 2017-05-31 15:24:57 -07:00
Simone Bordet 1ac103b6ce Merged branch 'jetty-9.3.x' into 'jetty-9.4.x'. 2017-05-17 13:16:21 +02:00
Simone Bordet d53af5d737 Fixes #523 - TLS close behaviour breaking session resumption.
Since requests cannot be connection delimited, don't call
sslEngine.closeInbound() on the server.

On the client, added a configuration parameter to allow missing
TLS Close Message, since many servers do that.

Introduced SslConnection.allowMissingCloseMessage so that it
throws in case of truncation attacks.
2017-05-17 13:07:21 +02:00
Joakim Erdfelt cf56168f7d Updating to version 9.3.20-SNAPSHOT 2017-05-02 15:26:56 -07:00
Joakim Erdfelt d36d57d5c7 Updating to version 9.3.19.v20170502 2017-05-02 14:31:51 -07:00
Joakim Erdfelt 782f36f157 Updating to version 9.4.6-SNAPSHOT 2017-05-02 14:29:09 -07:00
Joakim Erdfelt 9d8ad7489c Updating to version 9.4.5.v20170502 2017-05-02 13:22:18 -07:00
Joakim Erdfelt 92ea5bda21 Updating to version 9.4.5-SNAPSHOT 2017-04-14 14:43:36 -07:00
Joakim Erdfelt 3dc8f557c6 Updating to version 9.4.4.v20170414 2017-04-14 13:20:17 -07:00
Joakim Erdfelt 9e2aeda052 Updating to version 9.3.19-SNAPSHOT 2017-04-06 07:47:53 -07:00
Joakim Erdfelt 63273aa40b Updating to version 9.3.18.v20170406 2017-04-06 06:31:02 -07:00
Simone Bordet e7ac447d63 Fixes #1452 - Add tests for [want|need]ClientAuth. 2017-04-05 15:27:57 +02:00
Simone Bordet 7fc3dac5f3 Removed truststore.jks, not needed. 2017-04-05 15:27:57 +02:00
Simone Bordet c285d6f8bb Fixes #612 - Support HTTP Trailer.
Added support on both the server and the client, for HTTP/1 and HTTP/2.
2017-04-03 22:25:50 +02:00
Joakim Erdfelt 1360b863dc Updating to version 9.4.4-SNAPSHOT 2017-03-17 10:53:54 -07:00
Joakim Erdfelt 95e94b49d8 Updating to version 9.4.3.v20170317 2017-03-17 09:54:58 -07:00
Joakim Erdfelt a6a0ab991f Updating to version 9.3.18-SNAPSHOT 2017-03-17 09:48:19 -07:00
Joakim Erdfelt 307d23975e Updating to version 9.3.17.v20170317 2017-03-17 09:07:39 -07:00
Joakim Erdfelt 59c31a40e3 Merge remote-tracking branch 'origin/jetty-9.3.x' into jetty-9.4.x 2017-03-14 12:07:57 -07:00
Joakim Erdfelt f293f637c8 Issue #1394 - fix default character encoding for surefire testing 2017-03-13 11:10:10 -07:00
Joakim Erdfelt 01d539e2be Merge remote-tracking branch 'origin/jetty-9.3.x' into jetty-9.4.x 2017-03-09 14:20:19 -07:00
Joakim Erdfelt d2e35e239a Windows Test Issue
+ Changing from @Test(expect=<exception>) to
  @Rule ExpectedException for ...
  * no exception occuring when one is expected is a test failure
  * wrong exception is a test failure
  * wrong cause is a test failure
2017-03-09 06:51:57 -07:00
Greg Wilkins 0a2da4822d Merge remote-tracking branch 'origin/jetty-9.3.x' into jetty-9.4.x 2017-03-06 14:20:23 +11:00
Simone Bordet affeb67f1a Issue #1375 - Support pushed resources in HTTP client.
Implemented in the non-API HttpRequest class.
2017-03-05 19:01:08 +01:00
Joakim Erdfelt 523fab30bd Updating to version 9.4.3-SNAPSHOT 2017-02-20 08:13:31 -07:00
Joakim Erdfelt 4a674b9cc9 Updating to version 9.4.2.v20170220 2017-02-20 06:22:45 -07:00
Carter Kozak 1a2bb90465 Issue #1309 Client GZIPContentDecoder uses client ByteBufferPool
Previously the GZIPContentDecoder would allocate a new buffer for
each gzip encoded response.

Signed-off-by: Carter Kozak <c4kofony@gmail.com>
2017-02-07 09:53:39 -05:00
Simone Bordet 7923032582 Merged branch 'jetty-9.3.x' into 'jetty-9.4.x'. 2017-02-02 00:24:51 +01:00
Greg Wilkins 461c6082ae Issue #1296 - Introduce HTTP parser "content complete" event. 2017-02-01 23:54:36 +01:00
Jesse McConnell e695fc80d6 Updating to version 9.2.22-SNAPSHOT 2017-01-20 12:32:51 -06:00
Jesse McConnell 513b5e5f90 Updating to version 9.2.21.v20170120 2017-01-20 12:32:00 -06:00
Jesse McConnell d0c33ebe8b Updating to version 9.4.2-SNAPSHOT 2017-01-20 10:49:06 -06:00