Skip to content

Add docs for HTTP/2 WebSockets #209

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Nov 3, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions supporting-http2.html.md.erb
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,12 @@ For more information, see [Starting HTTP/2 with Prior Knowledge](https://datatra
Layer 7 load balancers terminate the incoming HTTP connection and initiate new HTTP connections to their back ends.
For end-to-end HTTP/2 support, Layer 7 load balancers must have HTTP/2 enabled for both ingress and egress HTTP connections.

Gorouter and many Layer 7 load balancers do not support WebSockets over HTTP/2 ([RFC 8441](https://datatracker.ietf.org/doc/html/rfc8441)).
WebSockets are used by <%= vars.app_runtime_abbr %> for streaming logs and metrics, in addition to apps that serve WebSocket traffic.
Because of this, load balancers should be configured to forward WebSocket traffic over HTTP/1.1.
Alternatively, you may use a Layer 4 load balancer for WebSockets traffic.
For more information, see <a href='../adminguide/supporting-websockets.html'>Supporting WebSockets</a>.

For example, the HAProxy BOSH release contains the canonical example of how to set up HTTP/2 load balancing for <%= vars.app_runtime_abbr %>.
See the [BOSH release for HAProxy](https://github.com/cloudfoundry-incubator/haproxy-boshrelease) on GitHub.

Expand Down
4 changes: 4 additions & 0 deletions supporting-websockets.html.md.erb
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,10 @@ To form a WebSocket connection, the client sends an HTTP request that contains a
These requests return a 503 error and a <code>X-Cf-Routererror
route_service_unsupported</code> header.</p>

<p class="note"><strong>Note:</strong> Gorouter does not support WebSockets over HTTP/2 (<a href='https://datatracker.ietf.org/doc/html/rfc8441'>RFC 8441</a>).
Your load balancer should always send WebSocket requests to Gorouter over HTTP/1.1.
For more information, see <a href='../adminguide/supporting-http2.html#load-balancer'>Configuring HTTP/2 Support </a>.</p>

## <a id='modify'></a> Set Your Loggregator Port

<% if vars.platform_code == 'CF' %>
Expand Down