From 8f2f09263afcad5a8b86c650ff10730852cc7b92 Mon Sep 17 00:00:00 2001 From: Jay Herron Date: Sun, 15 Feb 2026 21:13:14 -0700 Subject: [PATCH 1/4] fix: Uses context `maxUploadSize` for WebSocket frame max --- .../WebSocket/GraphQLHandler+handleWebSocket.swift | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/Sources/GraphQLHummingbird/WebSocket/GraphQLHandler+handleWebSocket.swift b/Sources/GraphQLHummingbird/WebSocket/GraphQLHandler+handleWebSocket.swift index af4b307..4e53f50 100644 --- a/Sources/GraphQLHummingbird/WebSocket/GraphQLHandler+handleWebSocket.swift +++ b/Sources/GraphQLHummingbird/WebSocket/GraphQLHandler+handleWebSocket.swift @@ -16,8 +16,7 @@ extension GraphQLHandler where Context: WebSocketRequestContext { ) async throws { let messenger = WebSocketMessenger(outbound: outbound, logger: logger) - // TODO: Make maxSize configurable - let messageStream = inbound.messages(maxSize: 1024 * 1024).compactMap { message -> String? in + let messageStream = inbound.messages(maxSize: context.requestContext.maxUploadSize).compactMap { message -> String? in // TODO: Add binary support guard case let .text(text) = message else { return nil From ed0c3a06d8053c976a40ca56965e920f6f1354bc Mon Sep 17 00:00:00 2001 From: Jay Herron Date: Sun, 15 Feb 2026 21:14:38 -0700 Subject: [PATCH 2/4] fix!: Coder properties are marked as internal. --- Sources/GraphQLHummingbird/GraphQLConfig.swift | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/Sources/GraphQLHummingbird/GraphQLConfig.swift b/Sources/GraphQLHummingbird/GraphQLConfig.swift index 754995f..eb81518 100644 --- a/Sources/GraphQLHummingbird/GraphQLConfig.swift +++ b/Sources/GraphQLHummingbird/GraphQLConfig.swift @@ -46,11 +46,11 @@ public struct GraphQLConfig< } public struct Coders: Sendable { - public let graphQLJSONEncoder: GraphQLJSONEncoder - public let jsonDecoder: JSONDecoder - public let jsonEncoder: JSONEncoder - public let urlEncodedFormDecoder: URLEncodedFormDecoder - public let urlEncodedFormEncoder: URLEncodedFormEncoder + let graphQLJSONEncoder: GraphQLJSONEncoder + let jsonDecoder: JSONDecoder + let jsonEncoder: JSONEncoder + let urlEncodedFormDecoder: URLEncodedFormDecoder + let urlEncodedFormEncoder: URLEncodedFormEncoder public init( graphQLJSONEncoder: GraphQLJSONEncoder? = nil, From 4c3ef11358cd1eca3748a7ac105a978fe92a0b2e Mon Sep 17 00:00:00 2001 From: Jay Herron Date: Sun, 15 Feb 2026 21:18:27 -0700 Subject: [PATCH 3/4] docs: Adds config nested type docs --- Sources/GraphQLHummingbird/GraphQLConfig.swift | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/Sources/GraphQLHummingbird/GraphQLConfig.swift b/Sources/GraphQLHummingbird/GraphQLConfig.swift index eb81518..0489dc6 100644 --- a/Sources/GraphQLHummingbird/GraphQLConfig.swift +++ b/Sources/GraphQLHummingbird/GraphQLConfig.swift @@ -45,6 +45,7 @@ public struct GraphQLConfig< self.websocket = websocket } + /// A collection of encoders and decoders used by the GraphQL system public struct Coders: Sendable { let graphQLJSONEncoder: GraphQLJSONEncoder let jsonDecoder: JSONDecoder @@ -67,6 +68,7 @@ public struct GraphQLConfig< } } + /// An embeddable GraphQL IDE public struct IDE: Sendable, Equatable { /// GraphiQL: https://github.com/graphql/graphiql public static var graphiql: Self { @@ -85,6 +87,7 @@ public struct GraphQLConfig< } } + /// A GraphQL subscription implementation public struct SubscriptionProtocol: Sendable, Hashable { /// Expose GraphQL subscriptions over WebSockets public static var websocket: Self { @@ -97,6 +100,7 @@ public struct GraphQLConfig< } } + /// WebSocket configuration public struct WebSocket: Sendable { let onWebSocketInit: @Sendable (WebSocketInit, Request, Context) async throws -> WebSocketInitResult From 3a5c927e95de5b203307284e2d9d8c8010beb935 Mon Sep 17 00:00:00 2001 From: Jay Herron Date: Sun, 15 Feb 2026 21:19:01 -0700 Subject: [PATCH 4/4] docs: Removes README beta warning --- README.md | 2 -- 1 file changed, 2 deletions(-) diff --git a/README.md b/README.md index ecd362c..5aef871 100644 --- a/README.md +++ b/README.md @@ -3,8 +3,6 @@ [![](https://img.shields.io/endpoint?url=https%3A%2F%2Fswiftpackageindex.com%2Fapi%2Fpackages%2FGraphQLSwift%2Fgraphql-hummingbird%2Fbadge%3Ftype%3Dplatforms)](https://swiftpackageindex.com/GraphQLSwift/graphql-hummingbird) [![](https://img.shields.io/endpoint?url=https%3A%2F%2Fswiftpackageindex.com%2Fapi%2Fpackages%2FGraphQLSwift%2Fgraphql-hummingbird%2Fbadge%3Ftype%3Dswift-versions)](https://swiftpackageindex.com/GraphQLSwift/graphql-hummingbird) -> ***WARNING***: This package is in v0.x beta. It's API is still evolving and is subject to breaking changes in minor version bumps. - A Swift library for integrating [GraphQL](https://github.com/GraphQLSwift/GraphQL) with [Hummingbird](https://github.com/hummingbird-project/hummingbird), enabling you to easily expose GraphQL APIs in your Hummingbird applications. ## Features