fn
fn copied to clipboard
add user-agent versions to headers of various things
if we send out versions of fdks, sdks and cli then we can track usage of these things over time from metrics, allowing us to deprecate older things easily in the future.
- fdk can send this back in the response, and fn can strip this and add a metric for it.
Fn-Fdk-Version: fdk-<lang> / X.Y.Z
- sdk can send this in the headers when making a request, fn can add a metric for this.
User-Agent: sdk-<lang> / X.Y.Z
- cli can send this in the headers when making a request, fn can add a metric for this (possible overlap with sdk, we may omit, but it may also be interesting to track cli versions separately to track usage separately from the sdk).
User-Agent: cli / X.Y.Z
it may be the case that swagger is already doing 2), and as follows, 3), 1) is definitely not something we are doing and it is not the case that we are tracking metrics for any of these.
fdk:
- https://github.com/fnproject/docs/pull/70
- https://github.com/fnproject/fdk-go/pull/54