Skip to content

quiche seems unable to send requests with long urls #2118

Duplicate

Description

@icing

I added tests in curl using GET on long urls, running all HTTP versions and backends. The tests add n * 'x' as query string to a url with n in [1k, 16k, 32k, 54k]. (see curl/curl#18129).

All QUIC backends except quiche work, giving the server 4xx response for the URL being too long. quiche is unable to start the stream. This happens in curl_quiche.c:1025:

  stream3_id = quiche_h3_send_request(ctx->h3c, ctx->qconn, nva, nheader,
                                      stream->send_closed);
  if(stream3_id < 0) {
    if(QUICHE_H3_ERR_STREAM_BLOCKED == stream3_id) {
      /* quiche seems to report this error if the connection window is
       * exhausted. Which happens frequently and intermittent. */
      CURL_TRC_CF(data, cf, "[%"FMT_PRIu64"] blocked", stream->id);
      stream->quic_flow_blocked = TRUE;
      result = CURLE_AGAIN;
      goto out;
    }
    ...

So, we are getting QUICHE_H3_ERR_STREAM_BLOCKED and interpret this as a temporary failure, as the description say "retry later". Are we wrong or is there an error code missing for a permanent failure here?

Note: this happens not only the first request of a connection, but also when sending a successful other request with response first.

Please advise.

Version used: quiche v0.24.4

Activity

  1. LPardue commented on Aug 1, 2025

    @LPardue
    Contributor

    I think this is a different manifestation of your prior #1573 issue. Basically, the stream write is probably blocked on send capacity arising from cwnd, because we write HEADERS atomically (rather than stream them out). That's something we want to change but has sadly not been a priority to get to yet.

    Early in a connection, your cwnd will be small and not have a chance to grow. As a client that only sends "small" requests the growth might even be very slow.

    As a workaround, you can play with the newish set_send_capacity_factor() https://docs.quic.tech/quiche/struct.Config.html#method.set_send_capacity_factor. This changes quiche internal to allow you to buffer more into it

    As another workaround, you can also consider fiddling with the initial cwnd size if you enjoy footguns. See https://docs.quic.tech/quiche/struct.Config.html#method.set_initial_congestion_window_packets

  2. added
    type: bugfix
    area: h3
    on Nov 24, 2026
  3. ghedo commented on Nov 25, 2026

    @ghedo
    Member

    Closing as a duplicate of #1573, as discussed above. HEADERS are written atomically, so a header block larger than the available send capacity stays blocked.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    area: h3type: bugfix

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions