Usage of HTTP/2 PROTOCOL_ERROR and INTERNAL_ERROR

Guoye Zhang <guoye_zhang@apple.com> Tue, 03 May 2022 16:37 UTC

Return-Path: <ietf-http-wg-request+bounce-httpbisa-archive-bis2juki=lists.ie@listhub.w3.org>
X-Original-To: ietfarch-httpbisa-archive-bis2Juki@ietfa.amsl.com
Delivered-To: ietfarch-httpbisa-archive-bis2Juki@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 9FF58C157B43 for <ietfarch-httpbisa-archive-bis2Juki@ietfa.amsl.com>; Tue, 3 May 2022 09:37:57 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.452
X-Spam-Level:
X-Spam-Status: No, score=-2.452 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_INVALID=0.1, DKIM_SIGNED=0.1, HEADER_FROM_DIFFERENT_DOMAINS=0.248, MAILING_LIST_MULTI=-1, RCVD_IN_DNSWL_BLOCKED=0.001, SPF_PASS=-0.001] autolearn=ham autolearn_force=no
Authentication-Results: ietfa.amsl.com (amavisd-new); dkim=fail (2048-bit key) reason="fail (body has been altered)" header.d=apple.com
Received: from mail.ietf.org ([50.223.129.194]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id VpeCiu1yBC0b for <ietfarch-httpbisa-archive-bis2Juki@ietfa.amsl.com>; Tue, 3 May 2022 09:37:50 -0700 (PDT)
Received: from lyra.w3.org (lyra.w3.org [128.30.52.18]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-256) server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id 6F9BFC15E3E3 for <httpbisa-archive-bis2Juki@lists.ietf.org>; Tue, 3 May 2022 09:37:49 -0700 (PDT)
Received: from lists by lyra.w3.org with local (Exim 4.92) (envelope-from <ietf-http-wg-request@listhub.w3.org>) id 1nlvUz-0007W6-LP for ietf-http-wg-dist@listhub.w3.org; Tue, 03 May 2022 16:35:41 +0000
Resent-Date: Tue, 03 May 2022 16:35:41 +0000
Resent-Message-Id: <E1nlvUz-0007W6-LP@lyra.w3.org>
Received: from www-data by lyra.w3.org with local (Exim 4.92) (envelope-from <guoye_zhang@apple.com>) id 1nlvUy-0007VB-BN for ietf-http-wg@listhub.w3.org; Tue, 03 May 2022 16:35:40 +0000
Received: from titan.w3.org ([128.30.52.76]) by lyra.w3.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from <guoye_zhang@apple.com>) id 1nloni-0000hv-VK for ietf-http-wg@listhub.w3.org; Tue, 03 May 2022 09:26:34 +0000
Received: from rn-mailsvcp-ppex-lapp34.rno.apple.com ([17.179.253.43] helo=rn-mailsvcp-ppex-lapp34.apple.com) by titan.w3.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from <guoye_zhang@apple.com>) id 1nlonh-0002GU-AJ for ietf-http-wg@w3.org; Tue, 03 May 2022 09:26:34 +0000
Received: from pps.filterd (rn-mailsvcp-ppex-lapp34.rno.apple.com [127.0.0.1]) by rn-mailsvcp-ppex-lapp34.rno.apple.com (8.16.1.2/8.16.1.2) with SMTP id 2439AR6J011640 for <ietf-http-wg@w3.org>; Tue, 3 May 2022 02:26:21 -0700
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=apple.com; h=from : content-type : content-transfer-encoding : mime-version : subject : message-id : date : to; s=20180706; bh=Iq1x5ifUFviCmioOWjNfpBC3tSUz1UivEJqJ3XF+pYM=; b=jBR+jd4FygEqc8V8vPLPQ2y6zBnzuXUgvUb6NdYcl/MNbDddfRlyVgiC/dZfGfdF0ZKV BChT94f8I5J+0V66dvEGf9pSG+78nSDmGq0VOBpubNiWixBXQLUmLltB1VOSMkh+M+PE yWMoLUt013vwyJWzj3tas16Ma7+cr2jVLqttXGY4d8jkYtXiV/GIv7XriPK8ezjtaruG po/f1tfFD7ObSCpOOXZQqai760gRUxWO7gB6V1wRJYORcem7ZKgqB4ElTPCqNspB6fzu T+UfySivE6jF6G2yDW8Owf9gYDZHPs+680QkfadBRfY7NYxtYqetrjFjsvTgmkcoHI8w Jg==
Received: from ma-mailsvcp-mta-lapp03.corp.apple.com (ma-mailsvcp-mta-lapp03.corp.apple.com [10.226.18.135]) by rn-mailsvcp-ppex-lapp34.rno.apple.com with ESMTP id 3ft1c88cgf-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128 verify=NO) for <ietf-http-wg@w3.org>; Tue, 03 May 2022 02:26:21 -0700
Received: from ma-mailsvcp-mmp-lapp04.apple.com (ma-mailsvcp-mmp-lapp04.apple.com [17.32.222.17]) by ma-mailsvcp-mta-lapp03.corp.apple.com (Oracle Communications Messaging Server 8.1.0.16.20220118 64bit (built Jan 18 2022)) with ESMTPS id <0RBA00J3VVJXS750@ma-mailsvcp-mta-lapp03.corp.apple.com> for ietf-http-wg@w3.org; Tue, 03 May 2022 02:26:21 -0700 (PDT)
Received: from process_milters-daemon.ma-mailsvcp-mmp-lapp04.apple.com by ma-mailsvcp-mmp-lapp04.apple.com (Oracle Communications Messaging Server 8.1.0.16.20220118 64bit (built Jan 18 2022)) id <0RBA00I00VAMDM00@ma-mailsvcp-mmp-lapp04.apple.com> for ietf-http-wg@w3.org; Tue, 03 May 2022 02:26:21 -0700 (PDT)
X-Va-A:
X-Va-T-CD: 2a152226d9ea59fb589454d9ebfae0d8
X-Va-E-CD: b245c8232f55b2efdd83987a8464c065
X-Va-R-CD: cbf0950d9c4884284d33bcab2d3924e8
X-Va-CD: 0
X-Va-ID: 46c99050-3c8d-4df8-8818-b37209556377
X-V-A:
X-V-T-CD: 2a152226d9ea59fb589454d9ebfae0d8
X-V-E-CD: b245c8232f55b2efdd83987a8464c065
X-V-R-CD: cbf0950d9c4884284d33bcab2d3924e8
X-V-CD: 0
X-V-ID: e2187ce4-f8f5-4847-8e08-b12d9c34fb85
X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:6.0.486,18.0.858 definitions=2022-05-03_03:2022-05-02,2022-05-03 signatures=0
Received: from smtpclient.apple (unknown [17.232.202.123]) by ma-mailsvcp-mmp-lapp04.apple.com (Oracle Communications Messaging Server 8.1.0.16.20220118 64bit (built Jan 18 2022)) with ESMTPSA id <0RBA0097TVJVZL00@ma-mailsvcp-mmp-lapp04.apple.com> for ietf-http-wg@w3.org; Tue, 03 May 2022 02:26:21 -0700 (PDT)
From: Guoye Zhang <guoye_zhang@apple.com>
Content-type: multipart/signed; boundary="Apple-Mail=_C77487A3-E356-4FC0-A60C-2D1EA32817EF"; protocol="application/pkcs7-signature"; micalg="sha-256"
Content-transfer-encoding: quoted-printable
MIME-version: 1.0 (Mac OS X Mail 16.0 \(3716.0.7\))
Message-id: <C2794B39-B296-497E-A02F-FB5D56511C5F@apple.com>
Date: Tue, 03 May 2022 02:26:19 -0700
To: ietf-http-wg <ietf-http-wg@w3.org>
X-Mailer: Apple Mail (2.3716.0.7)
X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:6.0.486,18.0.858 definitions=2022-05-03_03:2022-05-02,2022-05-03 signatures=0
Received-SPF: pass client-ip=17.179.253.43; envelope-from=guoye_zhang@apple.com; helo=rn-mailsvcp-ppex-lapp34.apple.com
X-W3C-Hub-DKIM-Status: validation passed: (address=guoye_zhang@apple.com domain=apple.com), signature is good
X-W3C-Hub-Spam-Status: No, score=-4.7
X-W3C-Hub-Spam-Report: BAYES_00=-1.9, DKIMWL_WL_HIGH=-0.594, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01, W3C_AA=-1, W3C_WL=-1
X-W3C-Scan-Sig: titan.w3.org 1nlonh-0002GU-AJ 1123e0e192d7de43f7079fdb493834d8
X-caa-id: c8248d8c69
X-Original-To: ietf-http-wg@w3.org
Subject: Usage of HTTP/2 PROTOCOL_ERROR and INTERNAL_ERROR
Archived-At: <https://www.w3.org/mid/C2794B39-B296-497E-A02F-FB5D56511C5F@apple.com>
Resent-From: ietf-http-wg@w3.org
X-Mailing-List: <ietf-http-wg@w3.org> archive/latest/40018
X-Loop: ietf-http-wg@w3.org
Resent-Sender: ietf-http-wg-request@w3.org
Precedence: list
List-Id: <ietf-http-wg.w3.org>
List-Help: <https://www.w3.org/Mail/>
List-Post: <mailto:ietf-http-wg@w3.org>
List-Unsubscribe: <mailto:ietf-http-wg-request@w3.org?subject=unsubscribe>

Hi,

We maintain the HTTP client library on Apple’s platforms, and with more servers enabling HTTP/2, our error handling logic was recently brought to attention.

To my understanding, PROTOCOL_ERROR means that the other side didn’t implement the standard correctly, and INTERNAL_ERROR means something happened unexpectedly on our side (e.g. crashed). Both of the error codes should be fatal and only caused by bugs in software, so we do not attempt to retry or perform download resumption.

However, nginx is using these error codes for transfers that are too slow causing timeout, which can occur due to bad network connectivity. https://github.com/nginx/nginx/blob/master/src/http/v2/ngx_http_v2.c#L4639

My question is, should we treat PROTOCOL_ERROR and INTERNAL_ERROR as recoverable errors on the client side?

Guoye Zhang