netty/netty — pull request #2403 by dragonsinth (2014-04-16 22:47:40+00:00)
Title: HTTP2 server should not send preface string

Motivation:

See: https://github.com/netty/netty/issues/2402
See: https://tools.ietf.org/html/draft-ietf-httpbis-http2-10#section-3.5

Only the client should send the preface string, the server should not.

"The server connection header consists of just a SETTINGS frame (Section 6.5)
that MUST be the first frame the server sends in the HTTP/2 connection."

Modifications:

Split out Http2PrefaceWriter and Http2PrefaceReader from Http2FrameEncoder
and Http2FrameDecoder. The new channel handlers are added to the pipeline
separately and remove themselves after the preface is written/read.

Result:

HTTP2 client sends preface, server does not, in compliance with spec.