Observability¶
Use correlation headers and application logging around SDK calls, but never record bearer tokens.
var options = new OkatanaRequestOptions
{
Headers = new Dictionary<string, string>
{
["X-Correlation-ID"] = activity.TraceId.ToString(),
["X-Workload"] = "release-publisher"
}
};
var ticket = await client.Tickets.GetAsync(ticketId, options, cancellationToken);
Recommended metrics include request count by operation, latency, status class, retry count, rate-limit count, and reconciliation count for ambiguous writes. Avoid high-cardinality labels such as ticket IDs unless your telemetry backend can handle them.
When using IHttpClientFactory, standard .NET HTTP logging and delegating handlers can be used. Ensure any HTTP logging layer redacts Authorization and does not dump sensitive ticket or document bodies by default.