Skip to content
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

deadlineExceeded (UnableToParseFrame(file: "NIOHTTP2/HTTP2ChannelHandler.swift", line: 490)) #1962

Open
furuyan opened this issue Jul 3, 2024 · 3 comments
Labels

Comments

@furuyan
Copy link

furuyan commented Jul 3, 2024

What are you trying to achieve?

I want to get data using UnaryCall.But it returns this error.
deadlineExceeded (UnableToParseFrame(file: "NIOHTTP2/HTTP2ChannelHandler.swift", line: 490))
This error is occured in HTTP2FrameDecoder.process(maxFrameSize:, maxHeaderListSize:) Line: 91
It's because the header.length is too large, but I have no idea why.

I used Charles, but could not find the target network log.

    func getData() async throws {
        let group = MultiThreadedEventLoopGroup(numberOfThreads: 1)
        let channel = try GRPCChannelPool.with(
            target: .host("myhost.com", port: 443),
            transportSecurity: .tls(.makeClientDefault(for: .best)),
            eventLoopGroup: group
        )

        let client = MyClient(channel: channel)

        let request = SomeRequest.with {
            $0.condition = "hoge"
        }

        try await client.hogeData(request)
    }

Environment
Apple Swift version 5.9.2

    dependencies: [
        .package(url: "https://github.com/apple/swift-protobuf", from: "1.25.2"),
        .package(url: "https://github.com/grpc/grpc-swift.git", from: "1.23.0"),

What have you tried so far?

It works fine in grpcurl.
grpcurl ’ -d ‘{ “param”: “hoge”, }’ myhost.com:443 hoge/Data

@glbrntt
Copy link
Collaborator

glbrntt commented Jul 3, 2024

This appears to be a protocol violation: the error indicates that the server is sending a headers frame which is larger than the client allows.

Do you own the server here too?

@furuyan
Copy link
Author

furuyan commented Jul 3, 2024

Yes, i own the server.

@glbrntt
Copy link
Collaborator

glbrntt commented Jul 3, 2024

Is it possible for you to reproduce this locally then, ideally without TLS, so that we can get a packet capture?

I'd like to be able to understand why we're hitting this error: either the server is sending a frame which is too large or there's a bug in our http/2 code.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants