Skip to content

Sampling more streams to measure error rate correctly #5195

Description

@masaori335

"Closing a H2 connection with high stream error rate" is added by 693b3cb.
The close event could be triggered when the first stream got error regardless value of proxy.config.http2.stream_error_rate_threshold. Because the error rate bacomes 1. We should wait for more streams to measure stream error rate correctly.

} else if (this->connection_state.get_stream_error_rate() >
Http2::stream_error_rate_threshold) { // For a case many stream errors happened

double
get_stream_error_rate() const
{
int total = get_stream_requests();
if (total > 0) {
return (double)stream_error_count / (double)total;
} else {
return 0;
}
}

Activity

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

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions