Repository navigation
nginx: the less strict list names four more differences, an env tag asks process.env once for each traced request, and under connection the auth check is told the connection's scheme - #69
Merged
Conversation
…sks process.env once for each traced request (222.7 MiB where 2.2.0 held 523.5), and under connection the auth check is told the connection's scheme (Part of #65) The list of the ways the nginx output is less strict than the Envoy output goes from 15 to 19 entries, each measured on nginx 1.30.6 and 1.31.8 beside Envoy 1.40.2: the admin listener answers an absolute target, an https target sent over plain HTTP is served under client_address connection, a tab at either end of a header's value reaches the service, and under forwarded an X-Forwarded-Proto that is neither http nor https is told to the auth check as it arrived. HAProxy's list gains the last one and has 11. The tracing script asked process.env with hasOwnProperty before it read an env tag's variable, in each traced request. It now reads the variable and takes it when it is a string, which is equal for every name. At 1,000 traced requests a second for 300 s, nginx 1.31.8 holds 222.7 MiB where it held 523.5 (median of three runs), and nginx 1.30.6 holds 175.7. Why that call held memory outside the script's heap is not known, and the page says so. With auth.send_request and client_address connection, the nginx output told the check the scheme of an absolute request target, so an https target sent over plain HTTP made the check read https. It now tells the check the connection's scheme, as docs/auth.md says. Under forwarded nothing changes. The battery runs env tags whose variable is set, and the scheme each proxy tells the check for an absolute target, an HTTP/2 :scheme and a client's own header. Before any container starts it counts the rows each entry is about to run and fails when docs/conformance.md gives another number.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #65
What changes
The lists
rendercounts. The ticket's three differences were measured on nginx 1.30.6 and 1.31.8 beside Envoy 1.40.2, and each holds. They are named, not corrected: the nginx output keeps nginx's own behaviour.httpstarget sent over plain HTTP is served underclient_address: connection; a tab at either end of a header's value reaches the service (any header, not onlyx-request-idandUser-Agent); and, found on the way, underforwardedanX-Forwarded-Protothat is neitherhttpnorhttpsis told to the auth check as it arrived.Memory under tracing. The cause is found and removed.
proxyfile.jsaskedprocess.envwithhasOwnPropertybefore it read anenvtag's variable, in each traced request. It now reads the variable and takes it when it is a string, which is equal in behaviour for every name a file can give.Why that call held memory outside the script's heap is not known; the page says so, and says which of its other figures were measured before this change.
The scheme the auth check is told. With
auth.send_request: trueandclient_address: connection, the nginx output told the check the scheme of an absolute request target. Measured:GET https://localhost/products/1 HTTP/1.1sent over plain HTTP was served, and the check readx-forwarded-proto: https, against whatdocs/auth.mdsays forconnection. The check is now told the connection's scheme. Underforwardednothing changes.The battery.
envtag whose variable is set, and for a set variable whose name every object inherits.connectionfile and rows for the scheme each proxy tells the check: an absolute target, an HTTP/2:scheme, a client's own header, and anX-Forwarded-Protoofftp.docs/conformance.mdgives another number. The page had gone stale by hand; it now says 11,165 rows in all.Found and not corrected here
The Envoy output tells the check
httpsfor an HTTP/2 request sent over plain HTTP with:scheme: httpsunderclient_address: connection(the service is senthttp). The battery holds that row with Envoy's own literal anddocs/auth.mdsays it plainly. It gets a ticket of its own, with HAProxy's plainconnectioncase, which no row measures yet.Checks
gofmt,go vet(also with theconformancetag),go build, and the tests of the changed packages pass; the generated pages and examples are current.For the next release's notes
Every nginx file is rendered again (its
proxyfile.jschanges). A file withauth.send_request: trueandclient_address: connectionalso gets a newnginx.conf.