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

Collector fails to send payload over HTTP2 with the {:exceeds_window_size, :request, 65536} error #3

Closed
arkgil opened this issue Jun 3, 2022 · 9 comments

Comments

@arkgil
Copy link

arkgil commented Jun 3, 2022

Hi there 👋

At the end of the test suite, the collector fails with the following stacktrace:

** (CaseClauseError) no case clause matching: {:error, %Mint.HTTP2{buffer: <<0, 0, 4, 8, 0, 0, 0, 0, 0, 127, 255, 0, 0>>, client_settings: %{enable_push: true, max_concurrent_streams: 100, max_frame_size: 16384}, client_settings_queue: {[[]], []}, decode_table: %HPAX.Table{entries: [], length: 0, max_table_size: 4096, size: 0}, encode_table: %HPAX.Table{entries: [], length: 0, max_table_size: 4096, size: 0}, headers_being_processed: nil, hostname: "analytics-api.buildkite.com", mode: :active, next_stream_id: 3, open_client_stream_count: 0, open_server_stream_count: 0, ping_queue: {[], []}, port: 443, private: %{}, proxy_headers: [], ref_to_stream_id: %{}, scheme: "https", server_settings: %{enable_connect_protocol: false, enable_push: true, initial_window_size: 65536, max_concurrent_streams: 128, max_frame_size: 16777215, max_header_list_size: :infinity}, socket: {:sslsocket, {:gen_tcp, #Port<0.335>, :tls_connection, :undefined}, [#PID<0.3828.0>, #PID<0.3827.0>]}, state: :open, streams: %{}, transport: Mint.Core.Transport.SSL, window_size: 65535}, %Mint.HTTPError{module: Mint.HTTP2, reason: {:exceeds_window_size, :request, 65536}}}
--
  | (buildkite_test_collector 0.1.0) lib/buildkite_test_collector/http_transport.ex:18: BuildkiteTestCollector.HttpTransport.send/1
  | (buildkite_test_collector 0.1.0) lib/buildkite_test_collector/formatter.ex:104: BuildkiteTestCollector.Formatter.terminate/2
  | (stdlib 3.17) gen_server.erl:733: :gen_server.try_terminate/3
  | (stdlib 3.17) gen_server.erl:918: :gen_server.terminate/10
  | (stdlib 3.17) proc_lib.erl:226: :proc_lib.init_p_do_apply/3

This looks like the error described in elixir-tesla/tesla#394.

@jimsynz
Copy link
Collaborator

jimsynz commented Jun 3, 2022

Hi @arkgil thanks for the report.

I'll take a look at fixing this first thing in the morning. The payloads are already batched (in groups of 500) so worst case we can reduce the batch size to fix.

@arkgil
Copy link
Author

arkgil commented Jun 3, 2022

Can I somehow configure the batch size to try if it helps?

@jimsynz
Copy link
Collaborator

jimsynz commented Jun 3, 2022

Yup. You can add :batch_size to your :buildkite_test_collector configuration in test.exs eg:

import Config

config :buildkite_test_collector,
  api_key: "my redacted key",
  batch_size: 100

Hope that helps!

@arkgil
Copy link
Author

arkgil commented Jun 3, 2022

Thanks! Will try it out.

@arkgil
Copy link
Author

arkgil commented Jun 3, 2022

Alright, batch size of 100 fixes the issues 👍

@joshprice
Copy link
Collaborator

Closing this for now, we'll reduce default batch size to prevent this from occurring, and investigate ways to resolve the underlying problem too. Thanks for raising @arkgil ❤️

@ryansch
Copy link

ryansch commented Jun 24, 2022

I just hit this on 0.1.2 as well. I'll try lowering the batch size.

joshprice added a commit that referenced this issue Jun 24, 2022
This prevents the error seen in #3
@joshprice
Copy link
Collaborator

Thanks for reporting. I've updated the default to 100 (34901e4), but please let us know what value(s) worked for you.

This will be in the next release.

@arkgil
Copy link
Author

arkgil commented Jun 27, 2022

@joshprice yup, we've set the batch size to 100, not issues so far. Thanks!

jimsynz pushed a commit that referenced this issue Jul 4, 2022
This prevents the error seen in #3
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants