Repository navigation
Replies: 1 comment
|
I went through the same code and your reading holds for what the Go runtime records. What Encore Cloud does after it receives the events isn't in this repo. Verified in source (v1.58.6):
Can't see from the repo: whether Encore Cloud's ingestion still applies Partial workaround: since v1.58.8 (#2616), every endpoint, raw ones included, redacts On (3): the Go runtime already honours per-endpoint sampling rates from its runtime config (traceprovider.go#L35-L92), but I can't tell whether Encore Cloud lets you set them. |
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
We run a Go app on Encore 1.58.6, deployed on Encore Cloud. Two of its endpoints are raw. The Go docs (Defining APIs, "Sensitive data") say that for a raw endpoint, adding
sensitiveto the//encore:apiannotation redacts the whole request and response payload, all headers included. That's exactly what we need, since the request'sCookieheader holds a session.Reading the source at
v1.58.6, we couldn't find where the Go runtime applies the flag:Endpoint.Sensitive, and it reaches the app's metadata (meta.proto#L131-L133: "none of the request/response payload will be traced").ScrubRequestPathsandScrubRequestHeadersfrom the request and response types alone (endpointgen.go#L76-L81, #L118-L121). A raw endpoint has neither type.ScrubRequestHeaders(trace2/events.go#L222, #L1052-L1064).request_span_startandrequest_span_endskip the headers, path parameters and payload of an endpoint marked sensitive (endpoint.rs#L767, protocol.rs#L211, #L250-L261). That arrived with Add Sensitive Redaction For TypeScript #1894.Our questions:
Cookieheader of a request to a raw endpoint markedsensitivekept out of the traces Encore Cloud stores?This comes from reading the source, not from a test on Encore Cloud, so we may have missed where the platform handles it.
All reactions