SlideShare a Scribd company logo
1 of 87
HTTP/2 Comes to Java
What Servlet 4.0 Means to You
Ed Burns
@edburns
Java EE Specification Team
Oracle
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
Safe Harbor Statement
The following is intended to outline our general product direction. It is intended for
information purposes only, and may not be incorporated into any contract. It is not a
commitment to deliver any material, code, or functionality, and should not be relied upon
in making purchasing decisions. The development, release, and timing of any features or
functionality described for Oracle’s products remains at the sole discretion of Oracle.
2
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
Our Plan for Your Time Investment
Why HTTP/2?
HTTP/2 Big Features
How Servlet Might Expose These Features
Java SE 9 Support for HTTP/2
Summary and Current Status
1
2
3
4
5
3
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
Our Plan for Your Time Investment
Why HTTP/2?
HTTP/2 Big Features
How Servlet Might Expose These Features
Java SE 9 Support for HTTP/2
Summary and Current Status
1
2
3
4
5
4
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
Why HTTP/2?
A Real Life Example
index.html
style1.css
style2.css
.
.
.
script1.js
script9.js
pic1.jpg
pic8.jpg
.
.
.
photo1.png
photo2.png
.
.
.
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
Why HTTP/2?
• Head-of-Line blocking
Problems in HTTP/1.1
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
Why HTTP/2?
• HTTP Pipelining
Problems in HTTP/1.1
style1.css
style2.css
Client Server
index.html
index.html
style1.css
style2.css
script1.js
.
.
.
script2.js
.
.
.
script1.js
script2.js
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
Why HTTP/2?
• Inefficient use of TCP sockets
Problems in HTTP/1.1
Client ServerClient Server
Client Server
Client Server
Client Server
Client Server
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
Why HTTP/2?
• Much of what we do in web-apps is a hack to work around shortcomings in
HTTP/1.1
– File concatenation and image sprites
– Domain sharding
– Inlined assets
What is an optimization?
9
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
File Concatenation and Image Sprites
TCP Efficiency Improves with Larger Files
10
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
File Concatenation and Image Sprites
TCP Efficiency Improves with Larger Files
11
• Modern web page now consists of more than 90 resources fetched from 15
distinct hosts
• Solution:
– Just work around it by shoving more than one logical file into one physical file.
– Seminal article: A List Apart http://alistapart.com/article/sprites
– Useful tool: SpritePad http://spritepad.wearekiss.com/
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
File Concatenation and Image Sprites
TCP Efficiency Improves with Larger Files
12
.ic-AerospaceAndDefense-wht-on-gray, .ic-AerospaceAndDefense-wht-on-
red, .ic-Airline-wht-on-gray, .ic-Airline-wht-on-red{
background: url(sprites.png) no-repeat;
}
.ic-AerospaceAndDefense-wht-on-gray{
background-position: 0 0;
width: 80px;
height: 80px;
}
.ic-AerospaceAndDefense-wht-on-red{
background-position: -81px 0;
width: 80px;
height: 80px;
}
.ic-Airline-wht-on-gray{
background-position: 0 -80px ;
width: 80px;
height: 80px;
}
.ic-Airline-wht-on-red{
background-position: -81px -79px ;
width: 80px;
height: 80px;
}
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
Domain Sharding
Split page resources across several hosts to work around browser limits
13
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
Inlined Assets
• data URLs
• <img
src="data:image/gif;base64,R0lGODlhEAAOALMAAOazToeHh0tLS/7LZv/0jv
b29t/f3//Ub/
/ge8WSLf/rhf/3kdbW1mxsbP//mf///yH5BAAAAAAALAAAAAAQAA4…" />
Base64 Encoding Will Never Die
14
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
Our Plan for Your Time Investment
Why HTTP/2?
HTTP/2 Big Features
How Servlet Might Expose These Features
Java SE 9 Support for HTTP/2
Summary and Current Status
1
2
3
4
5
15
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
HTTP/2 is really just a new transport
layer underneath HTTP/1.1
– same request/response model
– no new methods
– no new headers
– no new usage patterns from
application layer
– no new usage of URL spec and other
lower level specs
Network Programming Review
16
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
Standing on the Shoulders
17
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
Network Programming Review
18
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
Network Programming Review
19
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
Network Programming Review
20
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
Network Programming Review
21
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
Network Programming Review
22
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
Network Programming Review
23
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
Network Programming Review
24
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
• HTTP/1.0
– Sockets are a throwaway resource
– Specification says very little about how
sockets are to be used
– Browsers free to open many sockets to
the same server
Network Programming Review
25
Credit: chrisjstanley flickr
The Socket Angle
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
Network Programming Review
26
The Socket Angle
• HTTP/2
– Sockets seen as a scarce resource
– Specification says much about how
they are to be used
– Only one open per server
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
Network Programming Review
27
The Socket Angle
• It would be like if we took the
existing Servlet specification
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
Network Programming Review
28
The Socket Angle
• It would be like if we took the
existing Servlet specification
and added a new layer underneath
it
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
Network Programming Review
The Socket Angle
Client ServerClient Server
Client Server
Client Server
Client Server
Client Server
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
Network Programming Review
Solution in HTTP/2
Client Server
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
Network Programming Review
• HTTP/1.0 was designed to be easy to implement with contemporary
development practices of 1991
– text based protocol
– leaves flow control to the TCP layer
– easy to write a parser
– simple socket lifecycle
The Adoption Angle
31
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
Network Programming Review
• HTTP/2 is much more complicated to implement
– state machine
– header compression
– binary framing (arguably easier than text based for parsing)
The Adoption Angle
32
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
• HTTP/2 is much more complicated
to implement
– No more
telnet host 80
GET /somepage.html rnrn
33
Network Programming Review
The Adoption Angle
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
• HTTP/2 is much more complicated
to implement
– No more
telnet host 80
GET /somepage.html rnrn
34
Network Programming Review
The Adoption Angle
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
• Request/Response multiplexing
• Binary Framing
• Stream Prioritization
• Server Push
• Header Compression
• Upgrade from HTTP/1.1
• ALPN
• 101 Switching Protocols
35
HTTP/2 Big Ticket Feature Review
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | 36
HTTP/2 Big Ticket Feature Review
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
HTTP/2 Request Response Multiplexing
• Fully bi-directional
• Enabled by defining some terms
– Connection
A TCP socket
– Stream
A “channel” within a connection
– Message
A logical message, such as a request or a response
– Frame
The smallest unit of communication in HTTP/2.
37
Lets you do more things with a single TCP connection
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
HTTP/2 Request Response Multiplexing
38
Connections, Streams, Messages, Frames
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
HTTP/2 Request Response Multiplexing
• Once you break the communication down into frames, you can interweave
the logical streams over a single TCP connection.
• Yet another idea from the 1960s is new again.
39
Connections, Streams, Messages, Frames
Browser
ServerSingle TCP connection for HTTP 2
STREAM'4'
HEADERS'
STREAM'9'
HEADERS'
STREAM'7'
DATA'
STREAM'7'
HEADERS'
STREAM'2'
HEADERS'
STREAM'2'
DATA'
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
HTTP/2 Binary Framing
• Solves Head-Of-Line (HOL) blocking problem
• Type field can be DATA, HEADERS, PRIORITY, RST_STREAM, SETTINGS,
PUSH_PROMISE, PING, GOAWAY, WINDOW_UPDATE, CONTINUATION
40
Enabled by dumping newline delimited ASCII
Length (24)
Type (8) Flags (8)
R Stream Identifier (31)
Frame Payload (0 …)
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
HTTP/2 Header Compression
• Observation: most of the headers
are the same in a given stream
– Host: Accept: user-agent: etc.
• Why send them every time?
• Have the server and the client keep
tables of headers, then just send
references and updates to the
tables.
41
Known as HPACK
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
HTTP/2 Binary Framing
GET /index.html HTTP/1.1
Host: example.com
Accept: text/html
42
Example 1
HEADERS
+ END_STREAM
+ END_HEADERS
:method: GET
:scheme: http
:path: /index.html
:authority: example.org
accept: text/html
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
HTTP/2 Binary Framing
HTTP/1.1 200 OK
Content-Length: 11
Content-Type: text/html
Hello World
43
Example 2
HEADERS
- END_STREAM
+ END_HEADERS
:status: 200
content-length: 11
content-type: text/html
DATA
+ END_STREAM
Hello World
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
HTTP/2 Stream Prioritization
• Stream Dependency in HEADERS Frame
• PRIORITY frame type
• An additional 40 bytes
– Stream id (31)
– Weight (8): [1, 256]
– Exclusive bit (1)
• Only a suggestion
44
S
A
B C
4 12
A
B CD
4 16 12
exclusive = 0
A
B C
D
4 12
16
exclusive = 1
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
HTTP/2 Server Push
• Eliminates the need for resource inlining.
• Lets the server populate the browser’s cache in advance of the browser
asking for the resource to put in the cache.
• No corresponding JavaScript API, but can be combined with SSE
– Server pushes stuff into the browser’s cache.
– Server uses SSE to tell the browser to go fetch it (but we know it’s already in the
browser’s cache).
45
E
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
HTTP/2 Upgrade from HTTP/1.1
• Not secure
– We have to use port 80
– Use existing 101 Switching Protocols from HTTP/1.1
• Secure
– Application Layer Protocol Negotiation (ALPN)
46
Secure or not-secure?
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
Criticism of HTTP/2
• HOL blocking is still a problem, just shuffled around
– HOL blocking can still happen in HEADERS frames
• No h2c in Firefox or Chrome
– Mention the IETF RFC-7258
• Carbon footprint for all that HPACK encoding/decoding
• Numerous new DoS attack vectors
• HTTP/2 is orthogonal to WebSocket
Everybody's a Critic
47
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
Criticism of HTTP/2
• Poul Henning-Kamp's rant just before WGLC
– http://queue.acm.org/detail.cfm?id=2716278
Everybody's a Critic
48
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
Criticism of HTTP/2
• Poul Henning-Kamp's rant just before WGLC
– http://queue.acm.org/detail.cfm?id=2716278
Everybody's a Critic
49
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
Criticism of HTTP/2
• Poul Henning-Kamp's rant just before WGLC
– http://queue.acm.org/detail.cfm?id=2716278
Everybody's a Critic
50
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
Criticism of HTTP/2
• Poul Henning-Kamp's rant just before WGLC
– http://queue.acm.org/detail.cfm?id=2716278
Everybody's a Critic
51
Credit: Michael Fritz
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
Don't take my word for it
• HTTP/2 isn't one spec, it's two specs
– HTTP/2 protocol
– HPACK
• Built on top of many other specs
52
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
Don't take my word for it
53
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
Don't take my word for it
54
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
Aside
Servlet and Reactive
Programming
55
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
Reactive Programming
56
Responsive
Message Driven
ResilientElastic
image credit: reactivemanifesto.org
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
Servlet 4.0 and Reactive Programming
• Non-blocking IO in Servlet 3.1
– ServletInputStream
• #setReadListener, #isReady
– ServletOutputStream
• #setWriteListener, #isReady
– ReadListener
• #onDataAvailable, #onAllDataRead, #onError
– WriteListener
• #onWritePossible, #onError
57
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
Servlet 4.0 and Reactive Programming
• Asynchronous in Servlet 3.0
– ServletRequest#startAsync
– AsyncContext
• #addListener, #dispatch, #complete
– AsyncListener
• #onComplete, #onError, #onStartAsync, #onTimeout
• Event-driven
– Server-Sent Events
58
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
Our Plan for Your Time Investment
Why HTTP/2?
HTTP/2 Big Features
How Servlet Might Expose These Features
Java SE 9 Support for HTTP/2
Summary and Current Status
1
2
3
4
5
59
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
Our Plan for Your Time Investment
Why HTTP/2?
HTTP/2 Big Features
How Servlet Might Expose These Features
Java SE 9 Support for HTTP/2
Summary and Current Status
1
2
3
4
5
60
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
• Allow server to understand client
supplied stream priorities
• Allow server to set priority of
responses
• Allow frameworks to effectively
leverage server push
– flexible strategies for leveraging push
• Leverage ALPN
Abstractions Endure
61
Servlet API is Well Positioned to Enable HTTP/2 Optimizations
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
• Existing API is designed for One Request == One Response.
• HTTP/2 destroys this assumption.
• It will be challenging to do justice to the new reality of One Request == One
or More Responses.
• We must not simply bolt the “One or More Responses” concept onto some
convenient part of the existing API.
62
Challenges in Exposing HTTP/2 Features in Servlet API
Servlet 4.0 Big Ticket New Features
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
• Request/Response multiplexing
• Binary Framing
• Stream Prioritization
• Server Push
• Header Compression
• Upgrade from HTTP/1.1
– ALPN
– 101 Switching Protocols
63
HTTP/2 Features
Servlet 4.0 Big Ticket New Features
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
• Request/Response multiplexing
• Binary Framing
• Stream Prioritization
• Server Push
• Header Compression
• Upgrade from HTTP/1.1
– ALPN
– 101 Switching Protocols
64
HTTP/2 Features Potentially Exposed in Servlet API
Servlet 4.0 Big Ticket New Features
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
• Add method HttpServletRequest and HttpServletResponse
– int getStreamId()
65
Request/Response Multiplexing
Servlet 4.0 Big Ticket New Features
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
• Add a new class Priority
– boolean exclusive
– int streamId
– int weight
– Priority dependency
• Add method to HttpServletRequest
– Priority getPriority()
• Add methods to HttpServletResponse
– Priority getPriority()
– void setPriority(Priority p)
66
Stream Prioritization
Servlet 4.0 Big Ticket New Features
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
• Push resource to client for a given url and headers
• May add callback for completion or error of a push
• Not at all a replacement for WebSocket
• Really useful for frameworks that build on Servlet, such as JSF
• Two implementation strategies
– dispatch synthetic request
– builder API
67
Server Push
Servlet 4.0 Big Ticket New Features
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | 68
Server Push via dispatch of
synthetic request
Servlet 4.0
Big Ticket
New Features
Browser
Server Thread A
servlet.service()
GET /index.html
Server
discovers
browser will
need style.css
and script.js
request.dispatchPushRequest("style.css")
request.dispatchPushRequest("script.js")
Server Thread B
servlet.service()
synthetic GET /style.css
synthetic GET /script.js
Server Thread C
servlet.service()
style.css
script.js
index.html
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
Server Push
public class FacesServlet implements Servlet {
public void service(ServletRequest req,
ServletResponse resp) throws IOException, ServletException {
//..
HttpServletRequest request = (HttpServletRequest) req;
try {
ResourceHandler handler =
context.getApplication().getResourceHandler();
if (handler.isResourceRequest(context)) {
handler.handleResourceRequest(context);
} else {
lifecycle.attachWindow(context);
lifecycle.execute(context);
lifecycle.render(context);
}
}
}
Example of Potential Use from JSF
69
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
Server Push
public class ExternalContextImpl extends ExternalContext {
//…
public String encodeResourceURL(String url) {
if (null == url) {
String message = MessageUtils.getExceptionMessageString
(MessageUtils.NULL_PARAMETERS_ERROR_MESSAGE_ID, "url");
throw new NullPointerException(message);
}
Map attrs = getResourceAttrs();
((HttpServletRequest) request).dispatchPushRequest(url, attrs);
return ((HttpServletResponse) response).encodeURL(url);
}
//…
}
Example of Potential Use from JSF
70
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | 71
Server Push via Builder API
Servlet 4.0
Big Ticket
New Features
Browser
Server Thread A
servlet.service()
GET /index.html
Server
discovers
browser will
need style.css
and script.js
request.getPushBuilder()
PushBuilder 1 in
Thread A
setPath("/style.css")
setPath("/script.js")
PushBuilder 2 in
Thread B
style.css
script.js
index.html
request.getPushBuilder()
push()
push()
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
Our Plan for Your Time Investment
Why HTTP/2?
HTTP/2 Big Features
How Servlet Might Expose These Features
Java SE 9 Support for HTTP/2
Summary and Current Status
1
2
3
4
5
72
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
Java SE 9 Support for HTTP/2
• JEP 110 http://openjdk.java.net/jeps/110
• Easy to use API
• Covers only the most common use cases
• Supports both HTTP/1.1 and 2
• Builds on Java API classes going back to Java 1.2!
73
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
Java SE 9 Support for HTTP/2
74
HttpClientHttpClient.Builder
HttpRequest.Builder
HttpRequestHttpRequest
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
Java SE 9 Support for HTTP/2
• A handful of classes
– HttpClient, built by HttpClient.Builder
• Holds information for creating one or more HttpRequests
– HttpRequest, built by HttpRequest.Builder
• one request/response interaction
– HttpResponse
– Body Processors
• HttpRequestBodyProcessor
• HttpResponseBodyProcessor
Small footprint
75
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
Java SE 9 Support for HTTP/2
• Blocking mode: one thread per request/response
– send request
– get response
• Non-blocking mode
– Using ExecutorService and CompletableFuture
• Full support for HTTP/2 Server Push
Small footprint
76
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
Java SE 9 Support for HTTP/2
HttpResponse response = HttpRequest
.create(new URI("http://www.foo.com"))
.send(HttpRequest.noBody());
String responseBody =
response.body(HttpResponse.asString());
77
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
Java SE 9 Support for HTTP/2
//Simple blocking -- all execution from calling thread
HttpResponse r1 = HttpRequest.create(new URI("http://www.foo.com/"))
.method("GET")
.send(HttpRequest.noBody());
int responseCode = r1.responseCode());
String body = r1.body(HttpResponse.asString());
HttpResponse r2 = HttpRequest.create(new URI("http://www.foo.com/"))
.method("GET")
.send(HttpRequest.noBody());
System.out.println("Response was " + r1.responseCode());
File body = r2.body(HttpResponse.asFile("/tmp/response.txt));
// Content stored in /tmp/response.txt
HttpResponse<Void> r3 = HttpRequest.create(new URI("http://www.foo.com/"))
.method("POST")
.send(HttpRequest.fromString("param1=1, param2=2"));
Void body = r3.body(HttpResponse.ignoreBody()); // body is Void in this case
78
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
Java SE 9 Support for HTTP/2
// Async support, fully leverages SE 8 features
// Fetch three resources asynchronously. If all fetch ok
// send a further request to confirm work done
// Set up initial three requests
String[] filenames = {"foo.txt", "bar.txt", "blah.txt"};
CompletableFuture<File> futures[] = new CompletableFuture[filenames.length];
URI base = new URI("http://foo.com/resources")
URI finalResult = new URI("http://foo.com/confirm");
for (int i=0; i<filenames.length; i++) {
String filename = filenames[i];
URI uri = base.resolve(filename);
futures[i] = HttpRequest.create(uri)
.method("GET")
.sendAsync(HttpRequest.noBody())
.thenApply((HttpResponse resp) -> {
return resp.body(HttpResponse.asFile("/tmp/" + filename));
});
}
79
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
Java SE 9 Support for HTTP/2
// Set up dependent request upon completion of all of the above
CompletableFuture<String>; last =
CompletableFuture.allOf(futures)
.thenCompose((Void v) -> {
return HttpRequest.create(finalResult)
.method("POST")
.build()
.sendAsync(HttpRequest.noBody())
.thenApply((HttpResponse resp) -> {
return resp.body(HttpResponse.asString());
});
});
// when we get to this point, no blocking has occurred and the
// initial requests are in progress
String lastResponse = last.join(); // -- wait for all work to complete
System.out.println(lastResponse);
80
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
Java SE 9 Support for HTTP/2
• Negotiation of HTTP/2 from 1.1
– ALPN or plaintext
• Server Push
– Support for PUSH_PROMISE frames
• HPACK parameters
HTTP/2 features
81
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
Our Plan for Your Time Investment
Why HTTP/2?
HTTP/2 Big Features
How Servlet Might Expose These Features
Java SE 9 Support for HTTP/2
Summary and Current Status
1
2
3
4
5
82
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
Summary and Current Status
• Servlet 4.0 brings HTTP/2 to Java EE
– 100% compliant implementation of HTTP/2
– Expose key features to the API
• Server Push
• Stream Prioritization
• Request/Response multiplexing
83
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
Summary and Current Status: HTTP/2
• December 2015 Submit HTTP/2 to IESG for consideration as a Proposed
Standard DONE
• January 2015 Submit HTTP/2 to RFC Editor DONE
• May 2015 Publish HTTP/2 as an RFC 7540/7541 DONE
84
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
Summary and Current Status
• JSR-369 formed on 22 September 2014
• Tentative Delivery Schedule, revised as of 2015-06-05!
– Q3 2014: expert group formed
– Q3 2015: early draft
– Q4 2015: public review
– Q2 2016: proposed final draft
– Q1-2 2017: final release
https://blogs.oracle.com/theaquarium/entry/java_ee_8_roadmap_update
85
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
How to Get Involved
• Adopt a JSR
– http://glassfish.org/adoptajsr/
• The Aquarium
– http://blogs.oracle.com/theaquarium/
• Java EE 8 Reference Implementation
– http://glasfish.org
86
Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
Safe Harbor Statement
The preceding is intended to outline our general product direction. It is intended for
information purposes only, and may not be incorporated into any contract. It is not a
commitment to deliver any material, code, or functionality, and should not be relied upon
in making purchasing decisions. The development, release, and timing of any features or
functionality described for Oracle’s products remains at the sole discretion of Oracle.
87

More Related Content

What's hot

Batch Applications for Java Platform 1.0: Java EE 7 and GlassFish
Batch Applications for Java Platform 1.0: Java EE 7 and GlassFishBatch Applications for Java Platform 1.0: Java EE 7 and GlassFish
Batch Applications for Java Platform 1.0: Java EE 7 and GlassFishArun Gupta
 
Burns jsf-confess-2015
Burns jsf-confess-2015Burns jsf-confess-2015
Burns jsf-confess-2015Edward Burns
 
Java EE 7 from an HTML5 Perspective, JavaLand 2015
Java EE 7 from an HTML5 Perspective, JavaLand 2015Java EE 7 from an HTML5 Perspective, JavaLand 2015
Java EE 7 from an HTML5 Perspective, JavaLand 2015Edward Burns
 
WebSocket in Enterprise Applications 2015
WebSocket in Enterprise Applications 2015WebSocket in Enterprise Applications 2015
WebSocket in Enterprise Applications 2015Pavel Bucek
 
WebSockets in Enterprise Applications
WebSockets in Enterprise ApplicationsWebSockets in Enterprise Applications
WebSockets in Enterprise ApplicationsPavel Bucek
 
How to Thrive on REST/WebSocket-Based Microservices
How to Thrive on REST/WebSocket-Based MicroservicesHow to Thrive on REST/WebSocket-Based Microservices
How to Thrive on REST/WebSocket-Based MicroservicesPavel Bucek
 
Java EE 8 - An instant snapshot
Java EE 8 - An instant snapshot Java EE 8 - An instant snapshot
Java EE 8 - An instant snapshot David Delabassee
 
Down-to-Earth Microservices with Java EE
Down-to-Earth Microservices with Java EEDown-to-Earth Microservices with Java EE
Down-to-Earth Microservices with Java EEReza Rahman
 
HTTP/2 in the Java Platform -- Java Champions call February 2016
HTTP/2 in the Java Platform -- Java Champions call February 2016HTTP/2 in the Java Platform -- Java Champions call February 2016
HTTP/2 in the Java Platform -- Java Champions call February 2016Ed Burns
 
Java API for WebSocket 1.0: Java EE 7 and GlassFish
Java API for WebSocket 1.0: Java EE 7 and GlassFishJava API for WebSocket 1.0: Java EE 7 and GlassFish
Java API for WebSocket 1.0: Java EE 7 and GlassFishArun Gupta
 
2015 UJUG, Servlet 4.0 portion
2015 UJUG, Servlet 4.0 portion2015 UJUG, Servlet 4.0 portion
2015 UJUG, Servlet 4.0 portionmnriem
 
Java EE 8: What Servlet 4.0 and HTTP/2 mean to you
Java EE 8: What Servlet 4.0 and HTTP/2 mean to youJava EE 8: What Servlet 4.0 and HTTP/2 mean to you
Java EE 8: What Servlet 4.0 and HTTP/2 mean to youAlex Theedom
 
JSF 2.2 Input Output JavaLand 2015
JSF 2.2 Input Output JavaLand 2015JSF 2.2 Input Output JavaLand 2015
JSF 2.2 Input Output JavaLand 2015Edward Burns
 
Java EE 8 Adopt a JSR : JSON-P 1.1 & MVC 1.0
Java EE 8 Adopt a JSR : JSON-P 1.1 & MVC 1.0Java EE 8 Adopt a JSR : JSON-P 1.1 & MVC 1.0
Java EE 8 Adopt a JSR : JSON-P 1.1 & MVC 1.0David Delabassee
 
JavaScript Frameworks and Java EE – A Great Match
JavaScript Frameworks and Java EE – A Great MatchJavaScript Frameworks and Java EE – A Great Match
JavaScript Frameworks and Java EE – A Great MatchReza Rahman
 
Seven Points for Applying Java EE 7
Seven Points for Applying Java EE 7Seven Points for Applying Java EE 7
Seven Points for Applying Java EE 7Hirofumi Iwasaki
 
Finally, EE Security API JSR 375
Finally, EE Security API JSR 375Finally, EE Security API JSR 375
Finally, EE Security API JSR 375Alex Kosowski
 

What's hot (17)

Batch Applications for Java Platform 1.0: Java EE 7 and GlassFish
Batch Applications for Java Platform 1.0: Java EE 7 and GlassFishBatch Applications for Java Platform 1.0: Java EE 7 and GlassFish
Batch Applications for Java Platform 1.0: Java EE 7 and GlassFish
 
Burns jsf-confess-2015
Burns jsf-confess-2015Burns jsf-confess-2015
Burns jsf-confess-2015
 
Java EE 7 from an HTML5 Perspective, JavaLand 2015
Java EE 7 from an HTML5 Perspective, JavaLand 2015Java EE 7 from an HTML5 Perspective, JavaLand 2015
Java EE 7 from an HTML5 Perspective, JavaLand 2015
 
WebSocket in Enterprise Applications 2015
WebSocket in Enterprise Applications 2015WebSocket in Enterprise Applications 2015
WebSocket in Enterprise Applications 2015
 
WebSockets in Enterprise Applications
WebSockets in Enterprise ApplicationsWebSockets in Enterprise Applications
WebSockets in Enterprise Applications
 
How to Thrive on REST/WebSocket-Based Microservices
How to Thrive on REST/WebSocket-Based MicroservicesHow to Thrive on REST/WebSocket-Based Microservices
How to Thrive on REST/WebSocket-Based Microservices
 
Java EE 8 - An instant snapshot
Java EE 8 - An instant snapshot Java EE 8 - An instant snapshot
Java EE 8 - An instant snapshot
 
Down-to-Earth Microservices with Java EE
Down-to-Earth Microservices with Java EEDown-to-Earth Microservices with Java EE
Down-to-Earth Microservices with Java EE
 
HTTP/2 in the Java Platform -- Java Champions call February 2016
HTTP/2 in the Java Platform -- Java Champions call February 2016HTTP/2 in the Java Platform -- Java Champions call February 2016
HTTP/2 in the Java Platform -- Java Champions call February 2016
 
Java API for WebSocket 1.0: Java EE 7 and GlassFish
Java API for WebSocket 1.0: Java EE 7 and GlassFishJava API for WebSocket 1.0: Java EE 7 and GlassFish
Java API for WebSocket 1.0: Java EE 7 and GlassFish
 
2015 UJUG, Servlet 4.0 portion
2015 UJUG, Servlet 4.0 portion2015 UJUG, Servlet 4.0 portion
2015 UJUG, Servlet 4.0 portion
 
Java EE 8: What Servlet 4.0 and HTTP/2 mean to you
Java EE 8: What Servlet 4.0 and HTTP/2 mean to youJava EE 8: What Servlet 4.0 and HTTP/2 mean to you
Java EE 8: What Servlet 4.0 and HTTP/2 mean to you
 
JSF 2.2 Input Output JavaLand 2015
JSF 2.2 Input Output JavaLand 2015JSF 2.2 Input Output JavaLand 2015
JSF 2.2 Input Output JavaLand 2015
 
Java EE 8 Adopt a JSR : JSON-P 1.1 & MVC 1.0
Java EE 8 Adopt a JSR : JSON-P 1.1 & MVC 1.0Java EE 8 Adopt a JSR : JSON-P 1.1 & MVC 1.0
Java EE 8 Adopt a JSR : JSON-P 1.1 & MVC 1.0
 
JavaScript Frameworks and Java EE – A Great Match
JavaScript Frameworks and Java EE – A Great MatchJavaScript Frameworks and Java EE – A Great Match
JavaScript Frameworks and Java EE – A Great Match
 
Seven Points for Applying Java EE 7
Seven Points for Applying Java EE 7Seven Points for Applying Java EE 7
Seven Points for Applying Java EE 7
 
Finally, EE Security API JSR 375
Finally, EE Security API JSR 375Finally, EE Security API JSR 375
Finally, EE Security API JSR 375
 

Viewers also liked

2015 JavaOne EJB/CDI Alignment
2015 JavaOne EJB/CDI Alignment2015 JavaOne EJB/CDI Alignment
2015 JavaOne EJB/CDI AlignmentDavid Blevins
 
What's next for Java API for WebSocket (JSR 356)
What's next for Java API for WebSocket (JSR 356)What's next for Java API for WebSocket (JSR 356)
What's next for Java API for WebSocket (JSR 356)Pavel Bucek
 
Reactive Java EE - Let Me Count the Ways!
Reactive Java EE - Let Me Count the Ways!Reactive Java EE - Let Me Count the Ways!
Reactive Java EE - Let Me Count the Ways!Reza Rahman
 
HTTP/2 Comes to Java - What Servlet 4.0 Means to You
HTTP/2 Comes to Java - What Servlet 4.0 Means to YouHTTP/2 Comes to Java - What Servlet 4.0 Means to You
HTTP/2 Comes to Java - What Servlet 4.0 Means to YouDavid Delabassee
 
Java EE 8: What Servlet 4 and HTTP2 Mean
Java EE 8: What Servlet 4 and HTTP2 MeanJava EE 8: What Servlet 4 and HTTP2 Mean
Java EE 8: What Servlet 4 and HTTP2 MeanAlex Theedom
 
Introducing Apache Unomi - JavaOne 2015 Session
Introducing Apache Unomi - JavaOne 2015 SessionIntroducing Apache Unomi - JavaOne 2015 Session
Introducing Apache Unomi - JavaOne 2015 SessionSerge Huber
 
Java EE 7 (Lyon JUG & Alpes JUG - March 2014)
Java EE 7 (Lyon JUG & Alpes JUG  - March 2014)Java EE 7 (Lyon JUG & Alpes JUG  - March 2014)
Java EE 7 (Lyon JUG & Alpes JUG - March 2014)David Delabassee
 
Project Avatar (Lyon JUG & Alpes JUG - March 2014)
Project Avatar (Lyon JUG & Alpes JUG  - March 2014)Project Avatar (Lyon JUG & Alpes JUG  - March 2014)
Project Avatar (Lyon JUG & Alpes JUG - March 2014)David Delabassee
 
State of Securing Restful APIs s12gx2015
State of Securing Restful APIs s12gx2015State of Securing Restful APIs s12gx2015
State of Securing Restful APIs s12gx2015robwinch
 
Container sig#1 ansible-container
Container sig#1 ansible-containerContainer sig#1 ansible-container
Container sig#1 ansible-containerNaoya Hashimoto
 
楽しくて病みつきになるゲームジャムのススメ
楽しくて病みつきになるゲームジャムのススメ楽しくて病みつきになるゲームジャムのススメ
楽しくて病みつきになるゲームジャムのススメHiroki Omae
 
HTTP/2 and Java: Current Status
HTTP/2 and Java: Current StatusHTTP/2 and Java: Current Status
HTTP/2 and Java: Current StatusSimone Bordet
 
Enabling Cloud Native Security with OAuth2 and Multi-Tenant UAA
Enabling Cloud Native Security with OAuth2 and Multi-Tenant UAA Enabling Cloud Native Security with OAuth2 and Multi-Tenant UAA
Enabling Cloud Native Security with OAuth2 and Multi-Tenant UAA Will Tran
 
Jersey Coders New Term Introduction
Jersey Coders New Term IntroductionJersey Coders New Term Introduction
Jersey Coders New Term IntroductionAlex Theedom
 
Java EE revisits design patterns
Java EE revisits design patternsJava EE revisits design patterns
Java EE revisits design patternsAlex Theedom
 
Java 8 and 9 in Anger
Java 8 and 9 in AngerJava 8 and 9 in Anger
Java 8 and 9 in AngerTrisha Gee
 
Linux Kernel Booting Process (1) - For NLKB
Linux Kernel Booting Process (1) - For NLKBLinux Kernel Booting Process (1) - For NLKB
Linux Kernel Booting Process (1) - For NLKBshimosawa
 

Viewers also liked (20)

2015 JavaOne EJB/CDI Alignment
2015 JavaOne EJB/CDI Alignment2015 JavaOne EJB/CDI Alignment
2015 JavaOne EJB/CDI Alignment
 
What's next for Java API for WebSocket (JSR 356)
What's next for Java API for WebSocket (JSR 356)What's next for Java API for WebSocket (JSR 356)
What's next for Java API for WebSocket (JSR 356)
 
Reactive Java EE - Let Me Count the Ways!
Reactive Java EE - Let Me Count the Ways!Reactive Java EE - Let Me Count the Ways!
Reactive Java EE - Let Me Count the Ways!
 
HTTP/2 Comes to Java - What Servlet 4.0 Means to You
HTTP/2 Comes to Java - What Servlet 4.0 Means to YouHTTP/2 Comes to Java - What Servlet 4.0 Means to You
HTTP/2 Comes to Java - What Servlet 4.0 Means to You
 
HTTP/2 Comes to Java
HTTP/2 Comes to JavaHTTP/2 Comes to Java
HTTP/2 Comes to Java
 
Java EE 8: What Servlet 4 and HTTP2 Mean
Java EE 8: What Servlet 4 and HTTP2 MeanJava EE 8: What Servlet 4 and HTTP2 Mean
Java EE 8: What Servlet 4 and HTTP2 Mean
 
Introducing Apache Unomi - JavaOne 2015 Session
Introducing Apache Unomi - JavaOne 2015 SessionIntroducing Apache Unomi - JavaOne 2015 Session
Introducing Apache Unomi - JavaOne 2015 Session
 
Java EE 7 (Lyon JUG & Alpes JUG - March 2014)
Java EE 7 (Lyon JUG & Alpes JUG  - March 2014)Java EE 7 (Lyon JUG & Alpes JUG  - March 2014)
Java EE 7 (Lyon JUG & Alpes JUG - March 2014)
 
Project Avatar (Lyon JUG & Alpes JUG - March 2014)
Project Avatar (Lyon JUG & Alpes JUG  - March 2014)Project Avatar (Lyon JUG & Alpes JUG  - March 2014)
Project Avatar (Lyon JUG & Alpes JUG - March 2014)
 
State of Securing Restful APIs s12gx2015
State of Securing Restful APIs s12gx2015State of Securing Restful APIs s12gx2015
State of Securing Restful APIs s12gx2015
 
Container sig#1 ansible-container
Container sig#1 ansible-containerContainer sig#1 ansible-container
Container sig#1 ansible-container
 
jDays Sweden 2016
jDays Sweden 2016jDays Sweden 2016
jDays Sweden 2016
 
楽しくて病みつきになるゲームジャムのススメ
楽しくて病みつきになるゲームジャムのススメ楽しくて病みつきになるゲームジャムのススメ
楽しくて病みつきになるゲームジャムのススメ
 
HTTP/2 and Java: Current Status
HTTP/2 and Java: Current StatusHTTP/2 and Java: Current Status
HTTP/2 and Java: Current Status
 
Enabling Cloud Native Security with OAuth2 and Multi-Tenant UAA
Enabling Cloud Native Security with OAuth2 and Multi-Tenant UAA Enabling Cloud Native Security with OAuth2 and Multi-Tenant UAA
Enabling Cloud Native Security with OAuth2 and Multi-Tenant UAA
 
スペクトル分布(白熱電球、蛍光灯、LED照明)
スペクトル分布(白熱電球、蛍光灯、LED照明)スペクトル分布(白熱電球、蛍光灯、LED照明)
スペクトル分布(白熱電球、蛍光灯、LED照明)
 
Jersey Coders New Term Introduction
Jersey Coders New Term IntroductionJersey Coders New Term Introduction
Jersey Coders New Term Introduction
 
Java EE revisits design patterns
Java EE revisits design patternsJava EE revisits design patterns
Java EE revisits design patterns
 
Java 8 and 9 in Anger
Java 8 and 9 in AngerJava 8 and 9 in Anger
Java 8 and 9 in Anger
 
Linux Kernel Booting Process (1) - For NLKB
Linux Kernel Booting Process (1) - For NLKBLinux Kernel Booting Process (1) - For NLKB
Linux Kernel Booting Process (1) - For NLKB
 

Similar to Servlet 4.0 at GeekOut 2015

Oracle REST Data Services
Oracle REST Data ServicesOracle REST Data Services
Oracle REST Data ServicesChris Muir
 
HTTP/2 Comes to Java: Servlet 4.0 and what it means for the Java/Jakarta EE e...
HTTP/2 Comes to Java: Servlet 4.0 and what it means for the Java/Jakarta EE e...HTTP/2 Comes to Java: Servlet 4.0 and what it means for the Java/Jakarta EE e...
HTTP/2 Comes to Java: Servlet 4.0 and what it means for the Java/Jakarta EE e...Edward Burns
 
How to add stuff to MySQL
How to add stuff to MySQLHow to add stuff to MySQL
How to add stuff to MySQLGeorgi Kodinov
 
Servlet 4.0 Adopt-a-JSR 10 Minute Infodeck
Servlet 4.0 Adopt-a-JSR 10 Minute InfodeckServlet 4.0 Adopt-a-JSR 10 Minute Infodeck
Servlet 4.0 Adopt-a-JSR 10 Minute InfodeckEdward Burns
 
WebRTC with Java
WebRTC with JavaWebRTC with Java
WebRTC with Javaamithap07
 
Meetup Tech Talk on Web Performance
Meetup Tech Talk on Web PerformanceMeetup Tech Talk on Web Performance
Meetup Tech Talk on Web PerformanceJean Tunis
 
Web technology-guide
Web technology-guideWeb technology-guide
Web technology-guideSrihari
 
Explore Advanced CA Release Automation Configuration Topics
Explore Advanced CA Release Automation Configuration TopicsExplore Advanced CA Release Automation Configuration Topics
Explore Advanced CA Release Automation Configuration TopicsCA Technologies
 
Next generation web protocols
Next generation web protocolsNext generation web protocols
Next generation web protocolsDaniel Austin
 
OOW15 - Installation, Cloning, and Configuration of Oracle E-Business Suite 12.2
OOW15 - Installation, Cloning, and Configuration of Oracle E-Business Suite 12.2OOW15 - Installation, Cloning, and Configuration of Oracle E-Business Suite 12.2
OOW15 - Installation, Cloning, and Configuration of Oracle E-Business Suite 12.2vasuballa
 
Oracle REST Data Services Best Practices/ Overview
Oracle REST Data Services Best Practices/ OverviewOracle REST Data Services Best Practices/ Overview
Oracle REST Data Services Best Practices/ OverviewKris Rice
 
(ZDM) Zero Downtime DB Migration to Oracle Cloud
(ZDM) Zero Downtime DB Migration to Oracle Cloud(ZDM) Zero Downtime DB Migration to Oracle Cloud
(ZDM) Zero Downtime DB Migration to Oracle CloudRuggero Citton
 
Hit Refresh with Oracle GoldenGate Microservices
Hit Refresh with Oracle GoldenGate MicroservicesHit Refresh with Oracle GoldenGate Microservices
Hit Refresh with Oracle GoldenGate MicroservicesBobby Curtis
 
Oracle goldegate microservice
Oracle goldegate microserviceOracle goldegate microservice
Oracle goldegate microserviceMojtaba Khandan
 
WebRTC Customer Experience Optimizations - Kranky Geek Presentation
WebRTC Customer Experience Optimizations  - Kranky Geek PresentationWebRTC Customer Experience Optimizations  - Kranky Geek Presentation
WebRTC Customer Experience Optimizations - Kranky Geek Presentationamithap07
 
WebRTC standards update - November 2014
WebRTC standards update - November 2014WebRTC standards update - November 2014
WebRTC standards update - November 2014Victor Pascual Ávila
 
APIs, STOP Polling, lets go Streaming
APIs, STOP Polling, lets go StreamingAPIs, STOP Polling, lets go Streaming
APIs, STOP Polling, lets go StreamingPhil Wilkins
 

Similar to Servlet 4.0 at GeekOut 2015 (20)

HTTP/2 Comes to Java
HTTP/2 Comes to JavaHTTP/2 Comes to Java
HTTP/2 Comes to Java
 
Oracle REST Data Services
Oracle REST Data ServicesOracle REST Data Services
Oracle REST Data Services
 
HTTP/2 Comes to Java: Servlet 4.0 and what it means for the Java/Jakarta EE e...
HTTP/2 Comes to Java: Servlet 4.0 and what it means for the Java/Jakarta EE e...HTTP/2 Comes to Java: Servlet 4.0 and what it means for the Java/Jakarta EE e...
HTTP/2 Comes to Java: Servlet 4.0 and what it means for the Java/Jakarta EE e...
 
How to add stuff to MySQL
How to add stuff to MySQLHow to add stuff to MySQL
How to add stuff to MySQL
 
Servlet 4.0 Adopt-a-JSR 10 Minute Infodeck
Servlet 4.0 Adopt-a-JSR 10 Minute InfodeckServlet 4.0 Adopt-a-JSR 10 Minute Infodeck
Servlet 4.0 Adopt-a-JSR 10 Minute Infodeck
 
WebRTC with Java
WebRTC with JavaWebRTC with Java
WebRTC with Java
 
Meetup Tech Talk on Web Performance
Meetup Tech Talk on Web PerformanceMeetup Tech Talk on Web Performance
Meetup Tech Talk on Web Performance
 
Web technology-guide
Web technology-guideWeb technology-guide
Web technology-guide
 
Explore Advanced CA Release Automation Configuration Topics
Explore Advanced CA Release Automation Configuration TopicsExplore Advanced CA Release Automation Configuration Topics
Explore Advanced CA Release Automation Configuration Topics
 
JavaCro'15 - HTTP2 Comes to Java! - David Delabassee
JavaCro'15 - HTTP2 Comes to Java! - David DelabasseeJavaCro'15 - HTTP2 Comes to Java! - David Delabassee
JavaCro'15 - HTTP2 Comes to Java! - David Delabassee
 
Next generation web protocols
Next generation web protocolsNext generation web protocols
Next generation web protocols
 
OOW15 - Installation, Cloning, and Configuration of Oracle E-Business Suite 12.2
OOW15 - Installation, Cloning, and Configuration of Oracle E-Business Suite 12.2OOW15 - Installation, Cloning, and Configuration of Oracle E-Business Suite 12.2
OOW15 - Installation, Cloning, and Configuration of Oracle E-Business Suite 12.2
 
Oracle REST Data Services Best Practices/ Overview
Oracle REST Data Services Best Practices/ OverviewOracle REST Data Services Best Practices/ Overview
Oracle REST Data Services Best Practices/ Overview
 
Ebr the key_to_online_application_upgrade at amis25
Ebr the key_to_online_application_upgrade at amis25Ebr the key_to_online_application_upgrade at amis25
Ebr the key_to_online_application_upgrade at amis25
 
(ZDM) Zero Downtime DB Migration to Oracle Cloud
(ZDM) Zero Downtime DB Migration to Oracle Cloud(ZDM) Zero Downtime DB Migration to Oracle Cloud
(ZDM) Zero Downtime DB Migration to Oracle Cloud
 
Hit Refresh with Oracle GoldenGate Microservices
Hit Refresh with Oracle GoldenGate MicroservicesHit Refresh with Oracle GoldenGate Microservices
Hit Refresh with Oracle GoldenGate Microservices
 
Oracle goldegate microservice
Oracle goldegate microserviceOracle goldegate microservice
Oracle goldegate microservice
 
WebRTC Customer Experience Optimizations - Kranky Geek Presentation
WebRTC Customer Experience Optimizations  - Kranky Geek PresentationWebRTC Customer Experience Optimizations  - Kranky Geek Presentation
WebRTC Customer Experience Optimizations - Kranky Geek Presentation
 
WebRTC standards update - November 2014
WebRTC standards update - November 2014WebRTC standards update - November 2014
WebRTC standards update - November 2014
 
APIs, STOP Polling, lets go Streaming
APIs, STOP Polling, lets go StreamingAPIs, STOP Polling, lets go Streaming
APIs, STOP Polling, lets go Streaming
 

More from Edward Burns

Developer Career Masterplan
Developer Career MasterplanDeveloper Career Masterplan
Developer Career MasterplanEdward Burns
 
Jakarta EE 11 Status Update​
Jakarta EE 11 Status Update​Jakarta EE 11 Status Update​
Jakarta EE 11 Status Update​Edward Burns
 
Sponsored Session: Please touch that dial!
Sponsored Session: Please touch that dial!Sponsored Session: Please touch that dial!
Sponsored Session: Please touch that dial!Edward Burns
 
How modernizing enterprise applications gives you a competitive advantage
How modernizing enterprise applications gives you a competitive advantageHow modernizing enterprise applications gives you a competitive advantage
How modernizing enterprise applications gives you a competitive advantageEdward Burns
 
Wie Azure Jakarta EE Nutzt
Wie Azure Jakarta EE NutztWie Azure Jakarta EE Nutzt
Wie Azure Jakarta EE NutztEdward Burns
 
Practical lessons from customers performing digital transformation with Azure
Practical lessons from customers performing digital transformation with AzurePractical lessons from customers performing digital transformation with Azure
Practical lessons from customers performing digital transformation with AzureEdward Burns
 
wls-azure-devnexus-2022.pdf
wls-azure-devnexus-2022.pdfwls-azure-devnexus-2022.pdf
wls-azure-devnexus-2022.pdfEdward Burns
 
Jakarta EE und Microprofile sind bei Azure zu Hause
Jakarta EE und Microprofile sind bei Azure zu HauseJakarta EE und Microprofile sind bei Azure zu Hause
Jakarta EE und Microprofile sind bei Azure zu HauseEdward Burns
 
Java on Your Terms with Azure
Java on Your Terms with AzureJava on Your Terms with Azure
Java on Your Terms with AzureEdward Burns
 
Wars I’ve Seen From Java EE to Spring and more, Azure has you covered
Wars I’ve SeenFrom Java EE to Spring and more, Azure has you coveredWars I’ve SeenFrom Java EE to Spring and more, Azure has you covered
Wars I’ve Seen From Java EE to Spring and more, Azure has you coveredEdward Burns
 
Programming Language Platform Growth: Table Stakes or Deal Makes?
Programming Language Platform Growth: Table Stakes or Deal Makes?Programming Language Platform Growth: Table Stakes or Deal Makes?
Programming Language Platform Growth: Table Stakes or Deal Makes?Edward Burns
 
Programming Language Platform Growth: Table Stakes or Deal Makes?
Programming Language Platform Growth: Table Stakes or Deal Makes?Programming Language Platform Growth: Table Stakes or Deal Makes?
Programming Language Platform Growth: Table Stakes or Deal Makes?Edward Burns
 
Building a Serverless State Service for the Cloud
Building a Serverless State Service for the CloudBuilding a Serverless State Service for the Cloud
Building a Serverless State Service for the CloudEdward Burns
 
JSF 2.3 Adopt-a-JSR 10 Minute Infodeck
JSF 2.3 Adopt-a-JSR 10 Minute InfodeckJSF 2.3 Adopt-a-JSR 10 Minute Infodeck
JSF 2.3 Adopt-a-JSR 10 Minute InfodeckEdward Burns
 
JavaOne 2014 Java EE 8 Booth Slides
JavaOne 2014 Java EE 8 Booth SlidesJavaOne 2014 Java EE 8 Booth Slides
JavaOne 2014 Java EE 8 Booth SlidesEdward Burns
 
Best Practices for JSF, Gameduell 2013
Best Practices for JSF, Gameduell 2013Best Practices for JSF, Gameduell 2013
Best Practices for JSF, Gameduell 2013Edward Burns
 
Ed presents JSF 2.2 at a 2013 Gameduell Tech talk
Ed presents JSF 2.2 at a 2013 Gameduell Tech talkEd presents JSF 2.2 at a 2013 Gameduell Tech talk
Ed presents JSF 2.2 at a 2013 Gameduell Tech talkEdward Burns
 
jsf2-composite-components
jsf2-composite-componentsjsf2-composite-components
jsf2-composite-componentsEdward Burns
 
Kids computer-programming
Kids computer-programmingKids computer-programming
Kids computer-programmingEdward Burns
 

More from Edward Burns (20)

Developer Career Masterplan
Developer Career MasterplanDeveloper Career Masterplan
Developer Career Masterplan
 
Jakarta EE 11 Status Update​
Jakarta EE 11 Status Update​Jakarta EE 11 Status Update​
Jakarta EE 11 Status Update​
 
Sponsored Session: Please touch that dial!
Sponsored Session: Please touch that dial!Sponsored Session: Please touch that dial!
Sponsored Session: Please touch that dial!
 
How modernizing enterprise applications gives you a competitive advantage
How modernizing enterprise applications gives you a competitive advantageHow modernizing enterprise applications gives you a competitive advantage
How modernizing enterprise applications gives you a competitive advantage
 
Wie Azure Jakarta EE Nutzt
Wie Azure Jakarta EE NutztWie Azure Jakarta EE Nutzt
Wie Azure Jakarta EE Nutzt
 
Practical lessons from customers performing digital transformation with Azure
Practical lessons from customers performing digital transformation with AzurePractical lessons from customers performing digital transformation with Azure
Practical lessons from customers performing digital transformation with Azure
 
wls-azure-devnexus-2022.pdf
wls-azure-devnexus-2022.pdfwls-azure-devnexus-2022.pdf
wls-azure-devnexus-2022.pdf
 
Jakarta EE und Microprofile sind bei Azure zu Hause
Jakarta EE und Microprofile sind bei Azure zu HauseJakarta EE und Microprofile sind bei Azure zu Hause
Jakarta EE und Microprofile sind bei Azure zu Hause
 
Java on Your Terms with Azure
Java on Your Terms with AzureJava on Your Terms with Azure
Java on Your Terms with Azure
 
Wars I’ve Seen From Java EE to Spring and more, Azure has you covered
Wars I’ve SeenFrom Java EE to Spring and more, Azure has you coveredWars I’ve SeenFrom Java EE to Spring and more, Azure has you covered
Wars I’ve Seen From Java EE to Spring and more, Azure has you covered
 
Programming Language Platform Growth: Table Stakes or Deal Makes?
Programming Language Platform Growth: Table Stakes or Deal Makes?Programming Language Platform Growth: Table Stakes or Deal Makes?
Programming Language Platform Growth: Table Stakes or Deal Makes?
 
Programming Language Platform Growth: Table Stakes or Deal Makes?
Programming Language Platform Growth: Table Stakes or Deal Makes?Programming Language Platform Growth: Table Stakes or Deal Makes?
Programming Language Platform Growth: Table Stakes or Deal Makes?
 
Building a Serverless State Service for the Cloud
Building a Serverless State Service for the CloudBuilding a Serverless State Service for the Cloud
Building a Serverless State Service for the Cloud
 
JSF 2.3 Adopt-a-JSR 10 Minute Infodeck
JSF 2.3 Adopt-a-JSR 10 Minute InfodeckJSF 2.3 Adopt-a-JSR 10 Minute Infodeck
JSF 2.3 Adopt-a-JSR 10 Minute Infodeck
 
JavaOne 2014 Java EE 8 Booth Slides
JavaOne 2014 Java EE 8 Booth SlidesJavaOne 2014 Java EE 8 Booth Slides
JavaOne 2014 Java EE 8 Booth Slides
 
Best Practices for JSF, Gameduell 2013
Best Practices for JSF, Gameduell 2013Best Practices for JSF, Gameduell 2013
Best Practices for JSF, Gameduell 2013
 
Ed presents JSF 2.2 at a 2013 Gameduell Tech talk
Ed presents JSF 2.2 at a 2013 Gameduell Tech talkEd presents JSF 2.2 at a 2013 Gameduell Tech talk
Ed presents JSF 2.2 at a 2013 Gameduell Tech talk
 
jsf2-composite-components
jsf2-composite-componentsjsf2-composite-components
jsf2-composite-components
 
JSF 2.2
JSF 2.2JSF 2.2
JSF 2.2
 
Kids computer-programming
Kids computer-programmingKids computer-programming
Kids computer-programming
 

Recently uploaded

Global Identity Enrolment and Verification Pro Solution - Cizo Technology Ser...
Global Identity Enrolment and Verification Pro Solution - Cizo Technology Ser...Global Identity Enrolment and Verification Pro Solution - Cizo Technology Ser...
Global Identity Enrolment and Verification Pro Solution - Cizo Technology Ser...Cizo Technology Services
 
How to submit a standout Adobe Champion Application
How to submit a standout Adobe Champion ApplicationHow to submit a standout Adobe Champion Application
How to submit a standout Adobe Champion ApplicationBradBedford3
 
办理学位证(UQ文凭证书)昆士兰大学毕业证成绩单原版一模一样
办理学位证(UQ文凭证书)昆士兰大学毕业证成绩单原版一模一样办理学位证(UQ文凭证书)昆士兰大学毕业证成绩单原版一模一样
办理学位证(UQ文凭证书)昆士兰大学毕业证成绩单原版一模一样umasea
 
Dealing with Cultural Dispersion — Stefano Lambiase — ICSE-SEIS 2024
Dealing with Cultural Dispersion — Stefano Lambiase — ICSE-SEIS 2024Dealing with Cultural Dispersion — Stefano Lambiase — ICSE-SEIS 2024
Dealing with Cultural Dispersion — Stefano Lambiase — ICSE-SEIS 2024StefanoLambiase
 
Open Source Summit NA 2024: Open Source Cloud Costs - OpenCost's Impact on En...
Open Source Summit NA 2024: Open Source Cloud Costs - OpenCost's Impact on En...Open Source Summit NA 2024: Open Source Cloud Costs - OpenCost's Impact on En...
Open Source Summit NA 2024: Open Source Cloud Costs - OpenCost's Impact on En...Matt Ray
 
Taming Distributed Systems: Key Insights from Wix's Large-Scale Experience - ...
Taming Distributed Systems: Key Insights from Wix's Large-Scale Experience - ...Taming Distributed Systems: Key Insights from Wix's Large-Scale Experience - ...
Taming Distributed Systems: Key Insights from Wix's Large-Scale Experience - ...Natan Silnitsky
 
CRM Contender Series: HubSpot vs. Salesforce
CRM Contender Series: HubSpot vs. SalesforceCRM Contender Series: HubSpot vs. Salesforce
CRM Contender Series: HubSpot vs. SalesforceBrainSell Technologies
 
Folding Cheat Sheet #4 - fourth in a series
Folding Cheat Sheet #4 - fourth in a seriesFolding Cheat Sheet #4 - fourth in a series
Folding Cheat Sheet #4 - fourth in a seriesPhilip Schwarz
 
GOING AOT WITH GRAALVM – DEVOXX GREECE.pdf
GOING AOT WITH GRAALVM – DEVOXX GREECE.pdfGOING AOT WITH GRAALVM – DEVOXX GREECE.pdf
GOING AOT WITH GRAALVM – DEVOXX GREECE.pdfAlina Yurenko
 
Automate your Kamailio Test Calls - Kamailio World 2024
Automate your Kamailio Test Calls - Kamailio World 2024Automate your Kamailio Test Calls - Kamailio World 2024
Automate your Kamailio Test Calls - Kamailio World 2024Andreas Granig
 
SuccessFactors 1H 2024 Release - Sneak-Peek by Deloitte Germany
SuccessFactors 1H 2024 Release - Sneak-Peek by Deloitte GermanySuccessFactors 1H 2024 Release - Sneak-Peek by Deloitte Germany
SuccessFactors 1H 2024 Release - Sneak-Peek by Deloitte GermanyChristoph Pohl
 
Balasore Best It Company|| Top 10 IT Company || Balasore Software company Odisha
Balasore Best It Company|| Top 10 IT Company || Balasore Software company OdishaBalasore Best It Company|| Top 10 IT Company || Balasore Software company Odisha
Balasore Best It Company|| Top 10 IT Company || Balasore Software company Odishasmiwainfosol
 
React Server Component in Next.js by Hanief Utama
React Server Component in Next.js by Hanief UtamaReact Server Component in Next.js by Hanief Utama
React Server Component in Next.js by Hanief UtamaHanief Utama
 
What is Advanced Excel and what are some best practices for designing and cre...
What is Advanced Excel and what are some best practices for designing and cre...What is Advanced Excel and what are some best practices for designing and cre...
What is Advanced Excel and what are some best practices for designing and cre...Technogeeks
 
Software Coding for software engineering
Software Coding for software engineeringSoftware Coding for software engineering
Software Coding for software engineeringssuserb3a23b
 
Unveiling the Future: Sylius 2.0 New Features
Unveiling the Future: Sylius 2.0 New FeaturesUnveiling the Future: Sylius 2.0 New Features
Unveiling the Future: Sylius 2.0 New FeaturesŁukasz Chruściel
 
英国UN学位证,北安普顿大学毕业证书1:1制作
英国UN学位证,北安普顿大学毕业证书1:1制作英国UN学位证,北安普顿大学毕业证书1:1制作
英国UN学位证,北安普顿大学毕业证书1:1制作qr0udbr0
 
cpct NetworkING BASICS AND NETWORK TOOL.ppt
cpct NetworkING BASICS AND NETWORK TOOL.pptcpct NetworkING BASICS AND NETWORK TOOL.ppt
cpct NetworkING BASICS AND NETWORK TOOL.pptrcbcrtm
 

Recently uploaded (20)

Global Identity Enrolment and Verification Pro Solution - Cizo Technology Ser...
Global Identity Enrolment and Verification Pro Solution - Cizo Technology Ser...Global Identity Enrolment and Verification Pro Solution - Cizo Technology Ser...
Global Identity Enrolment and Verification Pro Solution - Cizo Technology Ser...
 
How to submit a standout Adobe Champion Application
How to submit a standout Adobe Champion ApplicationHow to submit a standout Adobe Champion Application
How to submit a standout Adobe Champion Application
 
办理学位证(UQ文凭证书)昆士兰大学毕业证成绩单原版一模一样
办理学位证(UQ文凭证书)昆士兰大学毕业证成绩单原版一模一样办理学位证(UQ文凭证书)昆士兰大学毕业证成绩单原版一模一样
办理学位证(UQ文凭证书)昆士兰大学毕业证成绩单原版一模一样
 
Dealing with Cultural Dispersion — Stefano Lambiase — ICSE-SEIS 2024
Dealing with Cultural Dispersion — Stefano Lambiase — ICSE-SEIS 2024Dealing with Cultural Dispersion — Stefano Lambiase — ICSE-SEIS 2024
Dealing with Cultural Dispersion — Stefano Lambiase — ICSE-SEIS 2024
 
Open Source Summit NA 2024: Open Source Cloud Costs - OpenCost's Impact on En...
Open Source Summit NA 2024: Open Source Cloud Costs - OpenCost's Impact on En...Open Source Summit NA 2024: Open Source Cloud Costs - OpenCost's Impact on En...
Open Source Summit NA 2024: Open Source Cloud Costs - OpenCost's Impact on En...
 
Taming Distributed Systems: Key Insights from Wix's Large-Scale Experience - ...
Taming Distributed Systems: Key Insights from Wix's Large-Scale Experience - ...Taming Distributed Systems: Key Insights from Wix's Large-Scale Experience - ...
Taming Distributed Systems: Key Insights from Wix's Large-Scale Experience - ...
 
CRM Contender Series: HubSpot vs. Salesforce
CRM Contender Series: HubSpot vs. SalesforceCRM Contender Series: HubSpot vs. Salesforce
CRM Contender Series: HubSpot vs. Salesforce
 
Folding Cheat Sheet #4 - fourth in a series
Folding Cheat Sheet #4 - fourth in a seriesFolding Cheat Sheet #4 - fourth in a series
Folding Cheat Sheet #4 - fourth in a series
 
GOING AOT WITH GRAALVM – DEVOXX GREECE.pdf
GOING AOT WITH GRAALVM – DEVOXX GREECE.pdfGOING AOT WITH GRAALVM – DEVOXX GREECE.pdf
GOING AOT WITH GRAALVM – DEVOXX GREECE.pdf
 
Automate your Kamailio Test Calls - Kamailio World 2024
Automate your Kamailio Test Calls - Kamailio World 2024Automate your Kamailio Test Calls - Kamailio World 2024
Automate your Kamailio Test Calls - Kamailio World 2024
 
SuccessFactors 1H 2024 Release - Sneak-Peek by Deloitte Germany
SuccessFactors 1H 2024 Release - Sneak-Peek by Deloitte GermanySuccessFactors 1H 2024 Release - Sneak-Peek by Deloitte Germany
SuccessFactors 1H 2024 Release - Sneak-Peek by Deloitte Germany
 
Hot Sexy call girls in Patel Nagar🔝 9953056974 🔝 escort Service
Hot Sexy call girls in Patel Nagar🔝 9953056974 🔝 escort ServiceHot Sexy call girls in Patel Nagar🔝 9953056974 🔝 escort Service
Hot Sexy call girls in Patel Nagar🔝 9953056974 🔝 escort Service
 
Balasore Best It Company|| Top 10 IT Company || Balasore Software company Odisha
Balasore Best It Company|| Top 10 IT Company || Balasore Software company OdishaBalasore Best It Company|| Top 10 IT Company || Balasore Software company Odisha
Balasore Best It Company|| Top 10 IT Company || Balasore Software company Odisha
 
React Server Component in Next.js by Hanief Utama
React Server Component in Next.js by Hanief UtamaReact Server Component in Next.js by Hanief Utama
React Server Component in Next.js by Hanief Utama
 
Advantages of Odoo ERP 17 for Your Business
Advantages of Odoo ERP 17 for Your BusinessAdvantages of Odoo ERP 17 for Your Business
Advantages of Odoo ERP 17 for Your Business
 
What is Advanced Excel and what are some best practices for designing and cre...
What is Advanced Excel and what are some best practices for designing and cre...What is Advanced Excel and what are some best practices for designing and cre...
What is Advanced Excel and what are some best practices for designing and cre...
 
Software Coding for software engineering
Software Coding for software engineeringSoftware Coding for software engineering
Software Coding for software engineering
 
Unveiling the Future: Sylius 2.0 New Features
Unveiling the Future: Sylius 2.0 New FeaturesUnveiling the Future: Sylius 2.0 New Features
Unveiling the Future: Sylius 2.0 New Features
 
英国UN学位证,北安普顿大学毕业证书1:1制作
英国UN学位证,北安普顿大学毕业证书1:1制作英国UN学位证,北安普顿大学毕业证书1:1制作
英国UN学位证,北安普顿大学毕业证书1:1制作
 
cpct NetworkING BASICS AND NETWORK TOOL.ppt
cpct NetworkING BASICS AND NETWORK TOOL.pptcpct NetworkING BASICS AND NETWORK TOOL.ppt
cpct NetworkING BASICS AND NETWORK TOOL.ppt
 

Servlet 4.0 at GeekOut 2015

  • 1. HTTP/2 Comes to Java What Servlet 4.0 Means to You Ed Burns @edburns Java EE Specification Team Oracle Copyright © 2015, Oracle and/or its affiliates. All rights reserved. |
  • 2. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | Safe Harbor Statement The following is intended to outline our general product direction. It is intended for information purposes only, and may not be incorporated into any contract. It is not a commitment to deliver any material, code, or functionality, and should not be relied upon in making purchasing decisions. The development, release, and timing of any features or functionality described for Oracle’s products remains at the sole discretion of Oracle. 2
  • 3. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | Our Plan for Your Time Investment Why HTTP/2? HTTP/2 Big Features How Servlet Might Expose These Features Java SE 9 Support for HTTP/2 Summary and Current Status 1 2 3 4 5 3
  • 4. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | Our Plan for Your Time Investment Why HTTP/2? HTTP/2 Big Features How Servlet Might Expose These Features Java SE 9 Support for HTTP/2 Summary and Current Status 1 2 3 4 5 4
  • 5. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | Why HTTP/2? A Real Life Example index.html style1.css style2.css . . . script1.js script9.js pic1.jpg pic8.jpg . . . photo1.png photo2.png . . .
  • 6. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | Why HTTP/2? • Head-of-Line blocking Problems in HTTP/1.1
  • 7. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | Why HTTP/2? • HTTP Pipelining Problems in HTTP/1.1 style1.css style2.css Client Server index.html index.html style1.css style2.css script1.js . . . script2.js . . . script1.js script2.js
  • 8. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | Why HTTP/2? • Inefficient use of TCP sockets Problems in HTTP/1.1 Client ServerClient Server Client Server Client Server Client Server Client Server
  • 9. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | Why HTTP/2? • Much of what we do in web-apps is a hack to work around shortcomings in HTTP/1.1 – File concatenation and image sprites – Domain sharding – Inlined assets What is an optimization? 9
  • 10. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | File Concatenation and Image Sprites TCP Efficiency Improves with Larger Files 10
  • 11. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | File Concatenation and Image Sprites TCP Efficiency Improves with Larger Files 11 • Modern web page now consists of more than 90 resources fetched from 15 distinct hosts • Solution: – Just work around it by shoving more than one logical file into one physical file. – Seminal article: A List Apart http://alistapart.com/article/sprites – Useful tool: SpritePad http://spritepad.wearekiss.com/
  • 12. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | File Concatenation and Image Sprites TCP Efficiency Improves with Larger Files 12 .ic-AerospaceAndDefense-wht-on-gray, .ic-AerospaceAndDefense-wht-on- red, .ic-Airline-wht-on-gray, .ic-Airline-wht-on-red{ background: url(sprites.png) no-repeat; } .ic-AerospaceAndDefense-wht-on-gray{ background-position: 0 0; width: 80px; height: 80px; } .ic-AerospaceAndDefense-wht-on-red{ background-position: -81px 0; width: 80px; height: 80px; } .ic-Airline-wht-on-gray{ background-position: 0 -80px ; width: 80px; height: 80px; } .ic-Airline-wht-on-red{ background-position: -81px -79px ; width: 80px; height: 80px; }
  • 13. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | Domain Sharding Split page resources across several hosts to work around browser limits 13
  • 14. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | Inlined Assets • data URLs • <img src="data:image/gif;base64,R0lGODlhEAAOALMAAOazToeHh0tLS/7LZv/0jv b29t/f3//Ub/ /ge8WSLf/rhf/3kdbW1mxsbP//mf///yH5BAAAAAAALAAAAAAQAA4…" /> Base64 Encoding Will Never Die 14
  • 15. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | Our Plan for Your Time Investment Why HTTP/2? HTTP/2 Big Features How Servlet Might Expose These Features Java SE 9 Support for HTTP/2 Summary and Current Status 1 2 3 4 5 15
  • 16. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | HTTP/2 is really just a new transport layer underneath HTTP/1.1 – same request/response model – no new methods – no new headers – no new usage patterns from application layer – no new usage of URL spec and other lower level specs Network Programming Review 16
  • 17. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | Standing on the Shoulders 17
  • 18. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | Network Programming Review 18
  • 19. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | Network Programming Review 19
  • 20. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | Network Programming Review 20
  • 21. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | Network Programming Review 21
  • 22. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | Network Programming Review 22
  • 23. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | Network Programming Review 23
  • 24. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | Network Programming Review 24
  • 25. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | • HTTP/1.0 – Sockets are a throwaway resource – Specification says very little about how sockets are to be used – Browsers free to open many sockets to the same server Network Programming Review 25 Credit: chrisjstanley flickr The Socket Angle
  • 26. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | Network Programming Review 26 The Socket Angle • HTTP/2 – Sockets seen as a scarce resource – Specification says much about how they are to be used – Only one open per server
  • 27. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | Network Programming Review 27 The Socket Angle • It would be like if we took the existing Servlet specification
  • 28. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | Network Programming Review 28 The Socket Angle • It would be like if we took the existing Servlet specification and added a new layer underneath it
  • 29. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | Network Programming Review The Socket Angle Client ServerClient Server Client Server Client Server Client Server Client Server
  • 30. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | Network Programming Review Solution in HTTP/2 Client Server
  • 31. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | Network Programming Review • HTTP/1.0 was designed to be easy to implement with contemporary development practices of 1991 – text based protocol – leaves flow control to the TCP layer – easy to write a parser – simple socket lifecycle The Adoption Angle 31
  • 32. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | Network Programming Review • HTTP/2 is much more complicated to implement – state machine – header compression – binary framing (arguably easier than text based for parsing) The Adoption Angle 32
  • 33. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | • HTTP/2 is much more complicated to implement – No more telnet host 80 GET /somepage.html rnrn 33 Network Programming Review The Adoption Angle
  • 34. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | • HTTP/2 is much more complicated to implement – No more telnet host 80 GET /somepage.html rnrn 34 Network Programming Review The Adoption Angle
  • 35. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | • Request/Response multiplexing • Binary Framing • Stream Prioritization • Server Push • Header Compression • Upgrade from HTTP/1.1 • ALPN • 101 Switching Protocols 35 HTTP/2 Big Ticket Feature Review
  • 36. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | 36 HTTP/2 Big Ticket Feature Review
  • 37. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | HTTP/2 Request Response Multiplexing • Fully bi-directional • Enabled by defining some terms – Connection A TCP socket – Stream A “channel” within a connection – Message A logical message, such as a request or a response – Frame The smallest unit of communication in HTTP/2. 37 Lets you do more things with a single TCP connection
  • 38. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | HTTP/2 Request Response Multiplexing 38 Connections, Streams, Messages, Frames
  • 39. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | HTTP/2 Request Response Multiplexing • Once you break the communication down into frames, you can interweave the logical streams over a single TCP connection. • Yet another idea from the 1960s is new again. 39 Connections, Streams, Messages, Frames Browser ServerSingle TCP connection for HTTP 2 STREAM'4' HEADERS' STREAM'9' HEADERS' STREAM'7' DATA' STREAM'7' HEADERS' STREAM'2' HEADERS' STREAM'2' DATA'
  • 40. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | HTTP/2 Binary Framing • Solves Head-Of-Line (HOL) blocking problem • Type field can be DATA, HEADERS, PRIORITY, RST_STREAM, SETTINGS, PUSH_PROMISE, PING, GOAWAY, WINDOW_UPDATE, CONTINUATION 40 Enabled by dumping newline delimited ASCII Length (24) Type (8) Flags (8) R Stream Identifier (31) Frame Payload (0 …)
  • 41. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | HTTP/2 Header Compression • Observation: most of the headers are the same in a given stream – Host: Accept: user-agent: etc. • Why send them every time? • Have the server and the client keep tables of headers, then just send references and updates to the tables. 41 Known as HPACK
  • 42. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | HTTP/2 Binary Framing GET /index.html HTTP/1.1 Host: example.com Accept: text/html 42 Example 1 HEADERS + END_STREAM + END_HEADERS :method: GET :scheme: http :path: /index.html :authority: example.org accept: text/html
  • 43. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | HTTP/2 Binary Framing HTTP/1.1 200 OK Content-Length: 11 Content-Type: text/html Hello World 43 Example 2 HEADERS - END_STREAM + END_HEADERS :status: 200 content-length: 11 content-type: text/html DATA + END_STREAM Hello World
  • 44. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | HTTP/2 Stream Prioritization • Stream Dependency in HEADERS Frame • PRIORITY frame type • An additional 40 bytes – Stream id (31) – Weight (8): [1, 256] – Exclusive bit (1) • Only a suggestion 44 S A B C 4 12 A B CD 4 16 12 exclusive = 0 A B C D 4 12 16 exclusive = 1
  • 45. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | HTTP/2 Server Push • Eliminates the need for resource inlining. • Lets the server populate the browser’s cache in advance of the browser asking for the resource to put in the cache. • No corresponding JavaScript API, but can be combined with SSE – Server pushes stuff into the browser’s cache. – Server uses SSE to tell the browser to go fetch it (but we know it’s already in the browser’s cache). 45 E
  • 46. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | HTTP/2 Upgrade from HTTP/1.1 • Not secure – We have to use port 80 – Use existing 101 Switching Protocols from HTTP/1.1 • Secure – Application Layer Protocol Negotiation (ALPN) 46 Secure or not-secure?
  • 47. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | Criticism of HTTP/2 • HOL blocking is still a problem, just shuffled around – HOL blocking can still happen in HEADERS frames • No h2c in Firefox or Chrome – Mention the IETF RFC-7258 • Carbon footprint for all that HPACK encoding/decoding • Numerous new DoS attack vectors • HTTP/2 is orthogonal to WebSocket Everybody's a Critic 47
  • 48. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | Criticism of HTTP/2 • Poul Henning-Kamp's rant just before WGLC – http://queue.acm.org/detail.cfm?id=2716278 Everybody's a Critic 48
  • 49. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | Criticism of HTTP/2 • Poul Henning-Kamp's rant just before WGLC – http://queue.acm.org/detail.cfm?id=2716278 Everybody's a Critic 49
  • 50. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | Criticism of HTTP/2 • Poul Henning-Kamp's rant just before WGLC – http://queue.acm.org/detail.cfm?id=2716278 Everybody's a Critic 50
  • 51. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | Criticism of HTTP/2 • Poul Henning-Kamp's rant just before WGLC – http://queue.acm.org/detail.cfm?id=2716278 Everybody's a Critic 51 Credit: Michael Fritz
  • 52. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | Don't take my word for it • HTTP/2 isn't one spec, it's two specs – HTTP/2 protocol – HPACK • Built on top of many other specs 52
  • 53. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | Don't take my word for it 53
  • 54. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | Don't take my word for it 54
  • 55. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | Aside Servlet and Reactive Programming 55
  • 56. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | Reactive Programming 56 Responsive Message Driven ResilientElastic image credit: reactivemanifesto.org
  • 57. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | Servlet 4.0 and Reactive Programming • Non-blocking IO in Servlet 3.1 – ServletInputStream • #setReadListener, #isReady – ServletOutputStream • #setWriteListener, #isReady – ReadListener • #onDataAvailable, #onAllDataRead, #onError – WriteListener • #onWritePossible, #onError 57
  • 58. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | Servlet 4.0 and Reactive Programming • Asynchronous in Servlet 3.0 – ServletRequest#startAsync – AsyncContext • #addListener, #dispatch, #complete – AsyncListener • #onComplete, #onError, #onStartAsync, #onTimeout • Event-driven – Server-Sent Events 58
  • 59. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | Our Plan for Your Time Investment Why HTTP/2? HTTP/2 Big Features How Servlet Might Expose These Features Java SE 9 Support for HTTP/2 Summary and Current Status 1 2 3 4 5 59
  • 60. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | Our Plan for Your Time Investment Why HTTP/2? HTTP/2 Big Features How Servlet Might Expose These Features Java SE 9 Support for HTTP/2 Summary and Current Status 1 2 3 4 5 60
  • 61. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | • Allow server to understand client supplied stream priorities • Allow server to set priority of responses • Allow frameworks to effectively leverage server push – flexible strategies for leveraging push • Leverage ALPN Abstractions Endure 61 Servlet API is Well Positioned to Enable HTTP/2 Optimizations
  • 62. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | • Existing API is designed for One Request == One Response. • HTTP/2 destroys this assumption. • It will be challenging to do justice to the new reality of One Request == One or More Responses. • We must not simply bolt the “One or More Responses” concept onto some convenient part of the existing API. 62 Challenges in Exposing HTTP/2 Features in Servlet API Servlet 4.0 Big Ticket New Features
  • 63. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | • Request/Response multiplexing • Binary Framing • Stream Prioritization • Server Push • Header Compression • Upgrade from HTTP/1.1 – ALPN – 101 Switching Protocols 63 HTTP/2 Features Servlet 4.0 Big Ticket New Features
  • 64. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | • Request/Response multiplexing • Binary Framing • Stream Prioritization • Server Push • Header Compression • Upgrade from HTTP/1.1 – ALPN – 101 Switching Protocols 64 HTTP/2 Features Potentially Exposed in Servlet API Servlet 4.0 Big Ticket New Features
  • 65. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | • Add method HttpServletRequest and HttpServletResponse – int getStreamId() 65 Request/Response Multiplexing Servlet 4.0 Big Ticket New Features
  • 66. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | • Add a new class Priority – boolean exclusive – int streamId – int weight – Priority dependency • Add method to HttpServletRequest – Priority getPriority() • Add methods to HttpServletResponse – Priority getPriority() – void setPriority(Priority p) 66 Stream Prioritization Servlet 4.0 Big Ticket New Features
  • 67. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | • Push resource to client for a given url and headers • May add callback for completion or error of a push • Not at all a replacement for WebSocket • Really useful for frameworks that build on Servlet, such as JSF • Two implementation strategies – dispatch synthetic request – builder API 67 Server Push Servlet 4.0 Big Ticket New Features
  • 68. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | 68 Server Push via dispatch of synthetic request Servlet 4.0 Big Ticket New Features Browser Server Thread A servlet.service() GET /index.html Server discovers browser will need style.css and script.js request.dispatchPushRequest("style.css") request.dispatchPushRequest("script.js") Server Thread B servlet.service() synthetic GET /style.css synthetic GET /script.js Server Thread C servlet.service() style.css script.js index.html
  • 69. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | Server Push public class FacesServlet implements Servlet { public void service(ServletRequest req, ServletResponse resp) throws IOException, ServletException { //.. HttpServletRequest request = (HttpServletRequest) req; try { ResourceHandler handler = context.getApplication().getResourceHandler(); if (handler.isResourceRequest(context)) { handler.handleResourceRequest(context); } else { lifecycle.attachWindow(context); lifecycle.execute(context); lifecycle.render(context); } } } Example of Potential Use from JSF 69
  • 70. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | Server Push public class ExternalContextImpl extends ExternalContext { //… public String encodeResourceURL(String url) { if (null == url) { String message = MessageUtils.getExceptionMessageString (MessageUtils.NULL_PARAMETERS_ERROR_MESSAGE_ID, "url"); throw new NullPointerException(message); } Map attrs = getResourceAttrs(); ((HttpServletRequest) request).dispatchPushRequest(url, attrs); return ((HttpServletResponse) response).encodeURL(url); } //… } Example of Potential Use from JSF 70
  • 71. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | 71 Server Push via Builder API Servlet 4.0 Big Ticket New Features Browser Server Thread A servlet.service() GET /index.html Server discovers browser will need style.css and script.js request.getPushBuilder() PushBuilder 1 in Thread A setPath("/style.css") setPath("/script.js") PushBuilder 2 in Thread B style.css script.js index.html request.getPushBuilder() push() push()
  • 72. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | Our Plan for Your Time Investment Why HTTP/2? HTTP/2 Big Features How Servlet Might Expose These Features Java SE 9 Support for HTTP/2 Summary and Current Status 1 2 3 4 5 72
  • 73. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | Java SE 9 Support for HTTP/2 • JEP 110 http://openjdk.java.net/jeps/110 • Easy to use API • Covers only the most common use cases • Supports both HTTP/1.1 and 2 • Builds on Java API classes going back to Java 1.2! 73
  • 74. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | Java SE 9 Support for HTTP/2 74 HttpClientHttpClient.Builder HttpRequest.Builder HttpRequestHttpRequest
  • 75. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | Java SE 9 Support for HTTP/2 • A handful of classes – HttpClient, built by HttpClient.Builder • Holds information for creating one or more HttpRequests – HttpRequest, built by HttpRequest.Builder • one request/response interaction – HttpResponse – Body Processors • HttpRequestBodyProcessor • HttpResponseBodyProcessor Small footprint 75
  • 76. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | Java SE 9 Support for HTTP/2 • Blocking mode: one thread per request/response – send request – get response • Non-blocking mode – Using ExecutorService and CompletableFuture • Full support for HTTP/2 Server Push Small footprint 76
  • 77. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | Java SE 9 Support for HTTP/2 HttpResponse response = HttpRequest .create(new URI("http://www.foo.com")) .send(HttpRequest.noBody()); String responseBody = response.body(HttpResponse.asString()); 77
  • 78. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | Java SE 9 Support for HTTP/2 //Simple blocking -- all execution from calling thread HttpResponse r1 = HttpRequest.create(new URI("http://www.foo.com/")) .method("GET") .send(HttpRequest.noBody()); int responseCode = r1.responseCode()); String body = r1.body(HttpResponse.asString()); HttpResponse r2 = HttpRequest.create(new URI("http://www.foo.com/")) .method("GET") .send(HttpRequest.noBody()); System.out.println("Response was " + r1.responseCode()); File body = r2.body(HttpResponse.asFile("/tmp/response.txt)); // Content stored in /tmp/response.txt HttpResponse<Void> r3 = HttpRequest.create(new URI("http://www.foo.com/")) .method("POST") .send(HttpRequest.fromString("param1=1, param2=2")); Void body = r3.body(HttpResponse.ignoreBody()); // body is Void in this case 78
  • 79. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | Java SE 9 Support for HTTP/2 // Async support, fully leverages SE 8 features // Fetch three resources asynchronously. If all fetch ok // send a further request to confirm work done // Set up initial three requests String[] filenames = {"foo.txt", "bar.txt", "blah.txt"}; CompletableFuture<File> futures[] = new CompletableFuture[filenames.length]; URI base = new URI("http://foo.com/resources") URI finalResult = new URI("http://foo.com/confirm"); for (int i=0; i<filenames.length; i++) { String filename = filenames[i]; URI uri = base.resolve(filename); futures[i] = HttpRequest.create(uri) .method("GET") .sendAsync(HttpRequest.noBody()) .thenApply((HttpResponse resp) -> { return resp.body(HttpResponse.asFile("/tmp/" + filename)); }); } 79
  • 80. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | Java SE 9 Support for HTTP/2 // Set up dependent request upon completion of all of the above CompletableFuture<String>; last = CompletableFuture.allOf(futures) .thenCompose((Void v) -> { return HttpRequest.create(finalResult) .method("POST") .build() .sendAsync(HttpRequest.noBody()) .thenApply((HttpResponse resp) -> { return resp.body(HttpResponse.asString()); }); }); // when we get to this point, no blocking has occurred and the // initial requests are in progress String lastResponse = last.join(); // -- wait for all work to complete System.out.println(lastResponse); 80
  • 81. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | Java SE 9 Support for HTTP/2 • Negotiation of HTTP/2 from 1.1 – ALPN or plaintext • Server Push – Support for PUSH_PROMISE frames • HPACK parameters HTTP/2 features 81
  • 82. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | Our Plan for Your Time Investment Why HTTP/2? HTTP/2 Big Features How Servlet Might Expose These Features Java SE 9 Support for HTTP/2 Summary and Current Status 1 2 3 4 5 82
  • 83. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | Summary and Current Status • Servlet 4.0 brings HTTP/2 to Java EE – 100% compliant implementation of HTTP/2 – Expose key features to the API • Server Push • Stream Prioritization • Request/Response multiplexing 83
  • 84. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | Summary and Current Status: HTTP/2 • December 2015 Submit HTTP/2 to IESG for consideration as a Proposed Standard DONE • January 2015 Submit HTTP/2 to RFC Editor DONE • May 2015 Publish HTTP/2 as an RFC 7540/7541 DONE 84
  • 85. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | Summary and Current Status • JSR-369 formed on 22 September 2014 • Tentative Delivery Schedule, revised as of 2015-06-05! – Q3 2014: expert group formed – Q3 2015: early draft – Q4 2015: public review – Q2 2016: proposed final draft – Q1-2 2017: final release https://blogs.oracle.com/theaquarium/entry/java_ee_8_roadmap_update 85
  • 86. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | How to Get Involved • Adopt a JSR – http://glassfish.org/adoptajsr/ • The Aquarium – http://blogs.oracle.com/theaquarium/ • Java EE 8 Reference Implementation – http://glasfish.org 86
  • 87. Copyright © 2015, Oracle and/or its affiliates. All rights reserved. | Safe Harbor Statement The preceding is intended to outline our general product direction. It is intended for information purposes only, and may not be incorporated into any contract. It is not a commitment to deliver any material, code, or functionality, and should not be relied upon in making purchasing decisions. The development, release, and timing of any features or functionality described for Oracle’s products remains at the sole discretion of Oracle. 87

Editor's Notes

  1. out additional information/disclaimers required depending on your audience.
  2. Know your audience They already think they know everything about Servlet They already think they know everything about HTTP/1.1 They’ve heard about HTTP/2.0 They are looking for what’s new. They’re looking for a reason to stick with Servlet over node.js They like lots of code, they are suspicious of slideware. Show of hands questions: using Servlet 3.0, 3.1 heard something substantial about h2?
  3. This section of the talk can follow the narrative arc and foreshadowing patterns to build to the climax of how Servlet 4.0 will provide answers to these problems. The quest for better performance If HTTP/1.1 was good enough for the last 15 years, why do we need something new?
  4. 30 resources 2 styelsheets 9 java scripts 8 jpg images 2 pngs ----- Meeting Notes (3/11/15 14:24) ----- Google research used to inform design of h2 from the beginning.
  5. Given this basic reality, what sorts of problems exist in the current state of the art? The first is called Head of Line (HOL) Blocking.
  6. With HTTP/1.1 pipelineing, you can send each request in order, the server is required to respond in the same order. Lets say style1 and style2 are returned quickly, but script1 seems to take some time. Because of HOL blocking, none of the other resources can be delivered until script1 is completely delivered.
  7. Can we work around HOL blocking in HTTP/1.1? Sort of, just open up more sockets to the same server! Most browsers support 6 – 8 simultaneous sockets. We know that each socket is expensive. Particularly on servers! Well, if the protocol itself has these performance problems, what can we do at the application level to work around them?
  8. This is where the problem began. Prior to this, there was no concept of an inlined asset. Just goes to show the importance of going from "zero" to "one or more".
  9. This technique works around the HOL blocking problem by concatenating many logical resources into a single physical resource. Leverages the benefits of the TCP congestion algorithm, that the efficiency of the socket improves with larger files over time.
  10. This concept also works with css and js. And don't forget compression. That really helps as well.
  11. You play a stupid DNS trick to get more parallel access. Lets you work around the browser imposed limitation on how many parallel connections to a single host
  12. Goes back to the way it was before Mosaic came along: back to a single resource. This has numerous problems: inlined images can't be easily cached and shared across pages. unnecessary base64 encoding decoding
  13. Those are the big problems that are out there in the world.
  14. This is important because HTTP/2 is essentially a new transport layer underneath the existing HTTP/1.1 semantics + a header compression specification. Same request/response model No new HTTP methods (except for PRI but that's just for the protocol) No new headers (but new names/concepts for old headers) No new usage pattern from application level Same usage of URL spec and TCP ports
  15. Care has been taken to avoid the "not invented here" syndrome, and to re-use concepts already proven successful.
  16. Physical: electrical and physical specifications of the data connection. Token ring, ethernet, etc. Data Link: MAC addresses, node-to-node transfer, anyone remember PPP? Reliable communication. Network: This is where routing comes in. This is how datagrams can make it between nodes that are not directly connected to each other. Multicast group management lives here. Transport: This is where TCP and UDP live. Session: home of the concept of a connection being created and closed. The connection lifecycle lives here. The UNIX Socket API lives here. Presentation: This is where Transport Layer Security lives (incorrectly named, eh?). Mime is another example of a presentation layer protocol. Does anyone here do anything with layers 6 and below here?
  17. Different viewpoints on the problem of the network layer for the web. As we've already seen, sockets are seen as a throw away resource. This rule about how many parallel sockets may be opened is really a gentleman's agreement. The original Mosaic only opened one socket. When IE upped it to four, people started calling it "Internet Exploiter".
  18. Another illustration of the socket angle.
  19. what can we do at the application level to work around them?
  20. Plug ACM
  21. Plug ACM
  22. Fully bi-directional at the protocol level, no HOL blocking. Message, not just request and response, there are also control messages.
  23. Headers must precede data. ODD == client originated EVEN == server originated
  24. httpbis draft 14. Length shows how long the entire frame is. Flags are used for several purposes, one of which is to indicate that this is the end of the header, or the end of the stream. DATA is request or response body HEADERS is the request or response header RST_STREAM corresponds to an error SETTINGS allows you to send configuration data for a given stream. PUSH_PROMISE: related to server push PING if the connection is still alive. This is necessary because the impact of closing down and opening a new socket is a bigger deal. In h1, if there was a problem on a socket, just close it and open up another one. In h2, sockets are treated with more respect. GOAWAY allows graceful closing of the socket. WINDOW_UPDATE is for flow control. If the server is sending more data than the client can handle, the client can tell the server to send less. CONTINUATION when one frame is a continuation of another one.
  25. HPACK is the single biggest thing that enables the HTTP WG to refute the claim that HTTP/2 is just a rubber stamping of Google's SPDY. The designers of HTTP/2 observed that a lot of bytes of H1 are just headers. Furthermore, there is a lot of repetition. Because we have the concept of stream ID within a channel, we can now have headers that correspond to that stream ID, and therefore keep track of these header tables that correspond to that stream. This is a lot harder to implement than h1! Let’s rewind the clock to 1993. These standards were designed to be easy to implement. This fact was crucially important to the growth of the web. Remember, back then, the web was not the only game in town. There was archie, WAIS and gopher. If they came out of the gate with such a complex protocol, http would not have caught on as fast as it did. There is something to be said for simplicity of implementation. But there is also something to be said for a judicious use of complexity to increase performance where it is appropriate. The client and server have shared state! This means there is a data structure at both ends of the connection that must be kept in synch. Source of controversy. Note SPDY did not have this kind of header "compression". It just said that the regular HTTP/1.1 headers block must be compressed using a "normal" compression algorithm: zlib.
  26. httpbis draft 14. The + means "add this header to the table". The – means "remove this header from the table". :method:, :scheme: etc are "Pseudo-Header Fields". These are special header fields defined by the HTTP/2 spec. They were defined to hold information that formerly was on the request line, or for other "must have" HTTP headers, and must start and end with a ":". They must be in lower case or the request is treated as malformed, but the strings must be compared in a case-insensitive fashion.
  27. httpbis draft 14.
  28. Two ways to specify priority: in headers or in a separate frame. Make sure people understand that this is not just an integer. It's not just like, "a bigger integer means it is more important." B and C depend on A. This information is included as a header in the HEADERS frame. These numbers are weights that correspond to the priority. If A is stuck, you can't do anything on A, you would like to do the things that are lower priority, which is B and C in this case. B receives one third the resources of C. An exclusive flag allows for the insertion of a new level of dependencies. The exclusive flag causes the stream to become the sole dependency of its parent stream, causing other dependencies to become dependent on the prioritized stream.
  29. Patterns: Foreshadow use of Server Push with JSF later It's a facility to allow the server to pre-populate the browser's cache with data it knows the browser will need anyway. Here is where you mention that this is not a replacement for WebSocket. It can be used in concert with SSE
  30. HTTP RFC 7230 HTTP/1.1 messaging 7231 HTTP/1/1 semantics and content 7232 h1 conditional requests 7233 range requests 7234 Caching 7235 authentication 4648 base64 encoding 7323 TCP extensions for high performance 3986 URI spec 2046 MIME 6265 Cookies
  31. HTTP RFC 7230 HTTP/1.1 messaging 7231 HTTP/1/1 semantics and content 7232 h1 conditional requests 7233 range requests 7234 Caching 7235 authentication 4648 base64 encoding 7323 TCP extensions for high performance 3986 URI spec 2046 MIME 6265 Cookies
  32. Responsive: responds to user needs in a timely manner Resilient: can withstand outages with graceful degradation Elastic: system response is not too heavily degraded when demand is high, resource utilization is not to heavy when demand is low. Message Driven: allows the parts of the system to be loosely coupled and interact with eachother in an asynchronous manner. Servlet only concentrates on two of these concerns: responsive and message driven. The other parts are outside of the domain of Servlet.
  33. One problem with being able to proudly sport the "We Are Reactive" banner is that the instant you have to block for IO, you are no longer reactive. The main purpose of these new APIs in Servlet 3.1 is to make it so you can entirely avoid blocking if you are really careful. Uses a listener approach to solve the non-blocking IO problem. Introduced an API to query if the streams can be read from or written to without blocking.
  34. Servlet started on the path of reactivity in 3.0. SSE is where we handle the "Event Driven" concern of reactive. Mention the discussion about SSE: conclusion: no additional API needed.
  35. Use this is a segue to mention how new features at the protocol layer may or may not be exposed to higher layers in the stack. Request reliability mechanism in h2 8.1.4
  36. The features in gray are deemed too low level to expose in Servlet, an application level abstraction.
  37. ----- Meeting Notes (3/11/15 17:16) ----- page speed chrome plugibn
  38. We are not trying to obsolete Apache HTTP client. Mention how long it's been since we've done anything on the level of HttpUrlConnection in JDK.