Documentation ¶
Index ¶
- Variables
- func AugmentWithResponse(baseCtx context.Context, responseCode int) context.Context
- func AugmentWithResponseAndRouteTag(baseCtx context.Context, responseCode int, routeTag string) context.Context
- func AugmentWithRevision(baseCtx context.Context, ns, svc, cfg, rev string) context.Context
- func PodContext(pod, container string) (context.Context, error)
- func PodRevisionContext(pod, container, ns, svc, cfg, rev string) (context.Context, error)
- func RevisionContext(ns, svc, cfg, rev string) context.Context
Constants ¶
This section is empty.
Variables ¶
var ( PodTagKey = tag.MustNewKey(metricskey.PodName) ContainerTagKey = tag.MustNewKey(metricskey.ContainerName) ResponseCodeKey = tag.MustNewKey(metricskey.LabelResponseCode) ResponseCodeClassKey = tag.MustNewKey(metricskey.LabelResponseCodeClass) RouteTagKey = tag.MustNewKey("route_tag") )
Create the tag keys that will be used to add tags to our measurements. Tag keys must conform to the restrictions described in go.opencensus.io/tag/validate.go. Currently those restrictions are: - length between 1 and 255 inclusive - characters are printable US-ASCII
Functions ¶
func AugmentWithResponse ¶ added in v0.13.0
AugmentWithResponse augments the given context with response-code specific tags.
func AugmentWithResponseAndRouteTag ¶ added in v0.17.0
func AugmentWithResponseAndRouteTag(baseCtx context.Context, responseCode int, routeTag string) context.Context
AugmentWithResponseAndRouteTag augments the given context with response-code and route-tag specific tags.
func AugmentWithRevision ¶ added in v0.13.0
AugmentWithRevision augments the given context with a knative_revision resource.
func PodContext ¶ added in v0.13.0
PodContext generate a new base metric reporting context containing the respective pod specific tags.
func PodRevisionContext ¶ added in v0.13.0
PodRevisionContext generates a new base metric reporting context containing the respective pod and revision specific tags.
func RevisionContext ¶ added in v0.13.0
RevisionContext generates a new base metric reporting context containing the respective revision specific tags.
Types ¶
This section is empty.