Skip to content

Commit 424c4fe

Browse files
committed
http: Add priority to common http headers
The standard `Priority` header is defined in RFC 9218. This is added as part of the precusor to quic/http3 work. Signed-off-by: James M Snell <jasnell@gmail.com>
1 parent da8f618 commit 424c4fe

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed

src/node_http_common.h

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,8 @@ class Environment;
7878
V(ORIGIN, "origin") \
7979
V(PURPOSE, "purpose") \
8080
V(TIMING_ALLOW_ORIGIN, "timing-allow-origin") \
81-
V(X_FORWARDED_FOR, "x-forwarded-for")
81+
V(X_FORWARDED_FOR, "x-forwarded-for") \
82+
V(PRIORITY, "priority")
8283

8384
#define HTTP_ADDITIONAL_HEADERS(V) \
8485
V(ACCEPT_CHARSET, "accept-charset") \

test/parallel/test-http2-binding.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -180,6 +180,7 @@ const expectedHeaderNames = {
180180
HTTP2_HEADER_PURPOSE: 'purpose',
181181
HTTP2_HEADER_TIMING_ALLOW_ORIGIN: 'timing-allow-origin',
182182
HTTP2_HEADER_X_FORWARDED_FOR: 'x-forwarded-for',
183+
HTTP2_PRIORITY: 'priority',
183184
};
184185

185186
const expectedNGConstants = {

0 commit comments

Comments
 (0)