@Override
    public WebSocketUpgradeResult upgrade(ServiceRequestContext ctx, HttpRequest req) throws Exception {
        final HttpMethod method = ctx.method();
        switch (method) {
            case GET:
                return upgradeHttp1(ctx, req);
            case CONNECT:
                return upgradeHttp2(ctx, req);
            default:
                final HttpResponse httpResponse =
                        failOrFallback(ctx, req, () -> HttpResponse.of(HttpStatus.METHOD_NOT_ALLOWED));
                return WebSocketUpgradeResult.ofFailure(httpResponse);
        }
    }
An {@link HttpService} that supports <a href="https://datatracker.ietf.org/doc/html/rfc6455">
The WebSocket Protocol</a>.
This service has a few different default values for {@link ServiceConfig} from a normal {@link HttpService}
because of the nature of WebSocket. See {@link WebSocketServiceBuilder} for more information.
core/src/main/java/com/linecorp/armeria/internal/server/websocket/DefaultWebSocketService.java