Annotations and labels
  • 04 Jan 2022
  • 4 Minutes to read
  • PDF

Annotations and labels

  • PDF

Article Summary

The topic describes the various annotations that are available for traceable-agent


Traceable module extension (tme)

The following tables describe labels and annotations for namespace and pod. 

Namespace

The following table describes annotations and labels for the namespace.

Label

LabelDescription
traceableai-inject-tmeSet this value to enabled for the namespace where you want to inject Traceable module extension

 Annotations

AnnotationDescription
tme.traceable.ai/defaultInject

This annotation defines the default injection behavior on pods in a namespace, that is, whether you want to inject or do not want to inject. 

  • Value set to true - When you set the value to true, then by default injection is enabled. If you do not want injection at the pod level, set agent.traceable.ai/inject: false. 
  • Value set to false - When you set the value to false, then by default injection is disabled. In this case, if you want injection at the pod level, set agent.traceable.ai/inject: true

When this annotation is not set, the default behavior is similar to when the value is set to false.

Pod

Labels

There are no labels for the pod for Traceable platform agent.

Annotations

AnnotationsDescription
tme.traceable.ai/injectSet the value to true to enable injection and false to disable injection. The default behavior, when this annotation is not specified, depends on the behavior of the namespace. See, tme.traceable.ai/defaultInject annotation in the namespace section above.
tme.traceable.ai/portDefines the port to be used for tme sidecar GRPC endpoint. The default value is 5441.
tme.traceable.ai/restPortDefines the port to be used for tme REST endpoint. The default value is 5442.
tme.traceable.ai/blockingThe annotation is used to define request blocking in the injected tme. Set the value to true to enable blocking and false to disable blocking. The default behavior is to enable blocking.

Mirroring

The following tables describe labels and annotations for namespace and pod. 

Label

LabelDescription
traceableai-inject-tmeSet this value to enabled for the target namespace.

Namespace

Annotations

AnnotationDescription
mirror.traceable.ai/defaultInject

This annotation defines the default injection behavior on pods in a namespace, that is, whether you want to inject or do not want to inject. 

  • Value set to true - When you set the value to true, then by default injection is enabled. If you do not want injection at the pod level, set the pod annotation mirror.traceable.ai/inject: false
  • Value set to false - When you set the value to false, then by default injection is disabled. In this case, if you want injection at the pod level, set the pod annotation mirror.traceable.ai/inject: true

When this annotation is not set, the default behavior is similar to when the value is set to false.

Pod

The following table describes annotations and labels for the pod.

Labels

There are no labels for the pod for mirroring.

Annotations

AnnotationDescription
mirror.traceable.ai/injectSet the value to true to enable injection of the Traceable Mirroring Module(tmm) along with the Traceable Module Extension(tme) and false to disable injection. 
The default behavior, when this annotation is not specified, depends on the behavior of the namespace. See, mirror.traceable.ai/defaultInject annotation in the namespace section above.
Note
Other annotations prefixed with tme.traceable.ai also work alongside.

Proxy

The following tables describe labels and annotations for namespace and pod.

Namespace

The following table describes annotations and labels for the namespace.

Label

LabelDescription
traceableai-inject-proxySet the value of this label to enabled for the namespace where you want to inject proxy.

 Annotation

AnnotationDescription
proxy.traceable.ai/defaultInject

This annotation defines the default injection behavior on pods in a namespace, that is, whether you want to inject or do not want to inject. 

  • Value set to true - When you set the value to true, then by default injection is enabled. If you do not want injection at the pod level, set proxy.traceable.ai/inject: false. 
  • Value set to false - When you set the value to false, then by default injection is disabled. In this case, if you want injection at the pod level, set proxy.traceable.ai/inject: true

When this annotation is not set, the default behavior is similar to when the value is set to true.

Pod

The following table describes annotations and labels for the pod.

Labels

There are no labels for the pod for Proxy.

Annotation

AnnotationDescription
proxy.traceable.ai/inboundPortmapsThe annotation is used to define the port mapping between service and Envoy. For example, 8080:80819090:9091
proxy.traceable.ai/injectSet the value to true to enable injection and false to disable injection. The default behavior, when this annotation is not specified, depends on the behavior of the namespace. See, proxy.traceable.ai/defaultInject annotation above.
proxy.traceable.ai/blockingThe annotation is used to define request blocking in the injected proxy. Set the value to true to enable blocking and false to disable blocking. The default behavior is to enable blocking.
proxy.traceable.ai/ignoreMatcherA JSON array formatted string used to configure URLs to ignore. Used for --ignore-url-regex proxy argument. For example, [{"url_path":"\/login"},{"url_path":"\/logout"}].

Java agent

The following tables describe labels and annotations for namespace and pod. 

Namespace

The following table describes annotations and labels for the namespace.

Label

LabelDescription
traceableai-inject-javaSet the value to enabled for the namespace where you would like to inject the Java agent.

Annotation

AnnotationDescription
java.traceable.ai/defaultInject

This annotation defines the default injection behavior on pods in a namespace, that is, whether you want to inject or do not want to inject. 

  • Value set to true - When you set the value to true, then by default injection is enabled. If you do not want injection at the pod level, set java.traceable.ai/inject: false
  • Value set to false - When you set the value to false, then by default injection is disabled. In this case, if you want injection at the pod level, set java.traceable.ai/inject: true

When this annotation is not set, the default behavior is similar to when the value is set to false.

Pod

The following table describes annotations and labels for the pod.

Labels

There are no labels for the pod for Java agent.

Annotation

AnnotationDescription
java.traceable.ai/injectSet the value to true to enable injection and false to disable injection. The default behavior, when this annotation is not specified, depends on the behavior of the namespace. See, java.traceable.ai/defaultInject annotation above.
java.traceable.ai/configmapDefines the configmap that contains the Java agent configuration. The default value when this annotation is not specified is an empty string.
java.traceable.ai/configmapNamespaceDefines the namespace that contains the configmap defined above. The default value when this annotation is not specified is an empty string.
java.traceable.ai/blockingThe annotation is used to define request blocking in the injected Java agent. Set the value to true to enable blocking and false to disable blocking. The default behavior is to enable blocking.

Was this article helpful?