Add spec for attribute name and value (#138)

This commit is contained in:
Hong Zhang 2017-05-09 14:35:01 -07:00 committed by Douglas Reid
parent f90b9a4908
commit 5cf5ef0867
1 changed files with 18 additions and 7 deletions

View File

@ -13,10 +13,11 @@ The page describes Istio attributes, what they are and how they are used.
## Background
Istio uses *attributes* to control the runtime behavior of services running in the mesh. Attributes are named and typed pieces of metadata
describing ingress and egress traffic and the environment this traffic occurs in. An Istio attribute carries a specific piece
Istio uses *attributes* to control the runtime behavior of services running in the service mesh.
Attributes are named and typed pieces of metadata describing ingress and egress traffic and the
environment this traffic occurs in. An Istio attribute carries a specific piece
of information such as the error code of an API request, the latency of an API request, or the
original IP address of a TCP connection. Here are a few examples of attributes:
original IP address of a TCP connection. For example:
request.path: xyz/abc
request.size: 234
@ -24,13 +25,23 @@ original IP address of a TCP connection. Here are a few examples of attributes:
source.ip: 192.168.0.1
target.service: example
A given Istio deployment has a fixed vocabulary of attributes that it understands. The specific vocabulary is
determined by the set of attribute producers being used in the deployment. The primary attribute producer in Istio
is Envoy, although specialized Mixer adapters and services can also introduce attributes.
## Attribute Vocabulary
A given Istio deployment has a fixed vocabulary of attributes that it understands.
The specific vocabulary is determined by the set of attribute producers being used
in the deployment. The primary attribute producer in Istio is Envoy, although
specialized Mixer adapters and services can also generate attributes.
The common baseline set of attributes available in most Istio deployments is defined
[here]({{home}}/docs/reference/api/mixer/attribute-vocabulary.html).
[here]({{home}}/docs/reference/api/mixer/attribute-vocabulary.html).
## Attribute Names
Istio attributes use Java-like fully qualified identiers as attribute names. The
allowed characters are `[_.a-z0-9]`. The character `"."` is used as namespace
separator. For example, `request.size` and `source.ip`.
## Attribute Types
Istio attributes are strongly typed. The supported attribute types are defined by
[ValueType](https://github.com/istio/api/blob/master/mixer/v1/config/descriptor/value_type.proto).