Commit Graph

287 Commits

Author SHA1 Message Date
Greg Wilkins b47f9ef605 cleaned up OSGi manifest creation 2014-08-15 19:35:49 +10:00
Simone Bordet 48b1f9f3f1 Implemented HTTP/2 push functionality.
A PushCacheFilter contains the logic to associate secondary resources
to primary resources.
PushCacheFilter calls a Jetty-specific API on the request dispatcher:
Dispatcher.push(ServletRequest). This is a technology preview of the
push functionality slated for Servlet 4.0.
The push() invocation arrives to the transport and it is converted to
HTTP/2 specific PUSH_PROMISE, along with the mechanism to simulate
the request for the secondary resource.
2014-08-14 23:05:35 +02:00
Simone Bordet 20963c9c61 Refactored host and port to local variables. 2014-08-12 18:54:50 +02:00
Simone Bordet e147ce9528 Updated flow control implementation to detect when senders exceed
allowed windows.
2014-08-12 16:37:41 +02:00
Simone Bordet 4f4c3604a2 Made the test more reliable. 2014-08-12 16:27:33 +02:00
Simone Bordet 107a4fff20 Fixed handling of INITIAL_WINDOW_SIZE setting.
It must update only stream windows, and not the session window.
2014-08-11 18:43:50 +02:00
Simone Bordet f8086dc7c2 Refactored the send of the SETTINGS frame from the client.
It's now sent after a call to onPreface(), which has been moved to
the common interface Session.Listener (from ServerSession.Listener),
so that client applications can customize the SETTINGS to send to the
server.
2014-08-08 23:52:20 +02:00
Simone Bordet 6b9a069d9d Waiting for all the frames to arrive before stopping. 2014-08-08 01:11:59 +02:00
Simone Bordet 466d8db8d8 Sending a SETTINGS frame after the preface, as required by the spec. 2014-08-08 01:11:59 +02:00
Simone Bordet abd139cc1b Reworked flow control implementation. Splitted HTTP2Flusher out of HTTP2Session.
Flow control window updates are now processed by the flusher, so that
it is the only component that handles window updates.
In the process of this refactoring, HTTP2Flusher was refactored out
of HTTP2Session.
2014-08-06 15:42:36 +02:00
Simone Bordet 2cd53831c0 Refactored onReadTimeout() to parent class. 2014-08-06 15:39:29 +02:00
Simone Bordet 636c7eaeae Fixed handling of max concurrent streams.
There is a difference between the value set via configuration, that
always refer to remote streams (streams initiated by remote peers),
and the value received via SETTINGS frame, that always refer to local
streams (streams initiated locally).
2014-08-05 02:01:34 +02:00
Simone Bordet 20925ded97 Fixed insertion of frame header buffer at the right index.
In case the lease is not empty, the frame header buffer must not be
inserted at index 0, but just before the frame body buffer.
2014-08-04 12:15:14 +02:00
Simone Bordet 35f0103add Added HTTP2 tests for multiple requests. 2014-08-03 00:27:28 +02:00
Simone Bordet 87c4c5efd3 Updated to point to webtide.com, now HTTP/2 enabled. 2014-08-02 00:02:25 +02:00
Simone Bordet 51e4885911 Made HTTP2Client support SSL so that it can be used to test websites that serve HTTP2. 2014-08-01 19:03:29 +02:00
Simone Bordet 67fd213263 Moved http2.parser.ErrorCode to http2.ErrorCodes. 2014-08-01 15:03:49 +02:00
Greg Wilkins 30123607c6 Major refactor of metadata and HttpURI
This refactor strives to remove duplication between the Metadata class and the HttpURI class.

Both classes have been made mutable (as they partially were anyway so best not to pretend).

HttpURI now holds the decomposed strings rather than a single string with indexes. This allows it to be rebuilt after changing just parts of the URI. It is now a lot more similar to the
JVM URI class and we could consider replacing it (after checking peformance).

Next step is to refactor the Request class to prevent it duplicating these fields.
2014-07-24 15:49:52 +10:00
Greg Wilkins f9ffefbe13 refactored to avoid copying MetaData.Request instances 2014-07-11 16:35:25 +10:00
Simone Bordet 603985dcd2 Implemented gentler shutdown in case of reading -1.
This allows big responses to be sent even if the request half closes
the connection.
2014-06-27 17:06:07 +02:00
Simone Bordet f09b81835e Improved handling of RST_STREAM frames. 2014-06-24 12:35:06 +02:00
Simone Bordet 4211653095 Fixed tests. 2014-06-18 16:09:52 +02:00
Greg Wilkins beb5918c3c fixed client 2014-06-18 13:59:02 +02:00
Simone Bordet 9d9260e634 Implemented idle timeout functionality for streams. 2014-06-18 13:57:37 +02:00
Simone Bordet 4dca6a71d3 Update Parser constructor to take additional parameters needed by
HpackDecoder.
2014-06-18 11:40:11 +02:00
Simone Bordet 9c95e29088 Implemented idle timeout functionality for both client and server. 2014-06-18 11:18:48 +02:00
Simone Bordet 82a2dfd03a Fixed infinite loop when receiving a SETTINGS frame. 2014-06-17 18:51:09 +02:00
Simone Bordet 6d1e5c9a07 Fixed tests to make the generator and the parser have the same scope. 2014-06-17 11:04:32 +02:00
Simone Bordet 31b7f0a592 Fixed references to MetaData, that has been moved to the jetty-http module. 2014-06-17 09:28:50 +02:00
Simone Bordet 334db9fe72 Updated version to 9.3.0-SNAPSHOT. 2014-06-16 21:33:03 +02:00
Simone Bordet a500701bda Fixed notification of Session's promise upon connect: it must be
notified only after we have successfully sent the preface bytes.
2014-06-15 16:39:23 +02:00
Simone Bordet 18c3e395df More flow control tests. 2014-06-13 23:03:49 +02:00
Simone Bordet b3aa67e0a9 Implemented PING functionality. 2014-06-13 17:59:17 +02:00
Simone Bordet 388262227e Split the generation of frames into 2: flow-controlled and
non-flow-controlled.
This gives better code separation and proper removal of streams when
flow controlled frames complete.
2014-06-13 16:28:54 +02:00
Simone Bordet b30152df27 Removed generation of padding bytes, which simplified the code a lot.
Implemented slicing of flow controlled data to never exceed the flow
control window.
2014-06-13 14:08:56 +02:00
Simone Bordet 5ed4f312cd Implemented flow control. 2014-06-13 13:51:42 +02:00
Simone Bordet 8e4c6b7fdd Put some more flesh on the HTTP2 implementation. 2014-06-11 18:26:48 +02:00