|
19 | 19 | - [Building binaries](#agent-building-binaries) |
20 | 20 | - [Usage](#agent-usage) |
21 | 21 | - [OpenCensus Collector](#opencensus-collector) |
| 22 | + - [Global Tags](#global-tags) |
| 23 | + - [Intelligent Sampling](#tail-sampling) |
22 | 24 | - [Usage](#collector-usage) |
23 | 25 |
|
24 | 26 | ## Introduction |
@@ -167,23 +169,6 @@ exporters: |
167 | 169 | endpoint: "http://127.0.0.1:9411/api/v2/spans" |
168 | 170 | ``` |
169 | 171 |
|
170 | | -### <a name="config-global"></a> Global |
171 | | -
|
172 | | -The collector also takes some global configurations that modify its behavior for all receivers / exporters. One of the configurations |
173 | | -available is to add Attributes or Tags to all spans passing through this collector. These additional tags can be configured to either overwrite |
174 | | -attributes if they already exists on the span, or respect the original values. An example of this is provided below. |
175 | | -```yaml |
176 | | -global: |
177 | | - attributes: |
178 | | - overwrite: true |
179 | | - values: |
180 | | - # values are key value pairs where the value can be an int, float, bool, or string |
181 | | - some_string: "hello world" |
182 | | - some_int: 1234 |
183 | | - some_float: 3.14159 |
184 | | - some_bool: false |
185 | | -``` |
186 | | -
|
187 | 172 | ### <a name="config-diagnostics"></a>Diagnostics |
188 | 173 |
|
189 | 174 | zPages is provided for monitoring. Today, the OpenCensus Agent is configured with zPages running by default on port ``55679``. |
@@ -307,6 +292,56 @@ The collector also serves as a control plane for agents/clients by supplying |
307 | 292 | them updated configuration (e.g. trace sampling policies), and reporting |
308 | 293 | agent/client health information/inventory metadata to downstream exporters. |
309 | 294 |
|
| 295 | +### <a name="global-tags"></a> Global Tags |
| 296 | + |
| 297 | +The collector also takes some global configurations that modify its behavior for all receivers / exporters. One of the configurations |
| 298 | +available is to add Attributes or Tags to all spans passing through this collector. These additional tags can be configured to either overwrite |
| 299 | +attributes if they already exists on the span, or respect the original values. An example of this is provided below. |
| 300 | +```yaml |
| 301 | +global: |
| 302 | + attributes: |
| 303 | + overwrite: true |
| 304 | + values: |
| 305 | + # values are key value pairs where the value can be an int, float, bool, or string |
| 306 | + some_string: "hello world" |
| 307 | + some_int: 1234 |
| 308 | + some_float: 3.14159 |
| 309 | + some_bool: false |
| 310 | +``` |
| 311 | + |
| 312 | +### <a name="tail-sampling"></a>Intelligent Sampling |
| 313 | + |
| 314 | +```yaml |
| 315 | +sampling: |
| 316 | + mode: tail |
| 317 | + # amount of time from seeing the first span in a trace until making the sampling decision |
| 318 | + decision-wait: 10s |
| 319 | + # maximum number of traces kept in the memory |
| 320 | + num-traces: 10000 |
| 321 | + policies: |
| 322 | + # user-defined policy name |
| 323 | + my-string-tag-filter: |
| 324 | + # exporters the policy applies to |
| 325 | + exporters: |
| 326 | + - jaeger |
| 327 | + - omnition |
| 328 | + policy: string-tag-filter |
| 329 | + configuration: |
| 330 | + tag: tag1 |
| 331 | + values: |
| 332 | + - value1 |
| 333 | + - value2 |
| 334 | + my-numeric-tag-filter: |
| 335 | + exporters: |
| 336 | + - jaeger |
| 337 | + - omnition |
| 338 | + policy: numeric-tag-filter |
| 339 | + configuration: |
| 340 | + tag: tag1 |
| 341 | + min-value: 0 |
| 342 | + max-value: 100 |
| 343 | +``` |
| 344 | + |
310 | 345 | ### <a name="collector-usage"></a>Usage |
311 | 346 |
|
312 | 347 | > It is recommended that you use the latest [release](https://github.com/census-instrumentation/opencensus-service/releases). |
@@ -364,7 +399,7 @@ receivers: |
364 | 399 | queued-exporters: |
365 | 400 | jaeger-sender-test: # A friendly name for the exporter |
366 | 401 | # num-workers is the number of queue workers that will be dequeuing batches and sending them out (default is 10) |
367 | | - num-workers: 2 |
| 402 | + num-workers: 2 |
368 | 403 |
|
369 | 404 | # queue-size is the maximum number of batches allowed in the queue at a given time (default is 5000) |
370 | 405 | queue-size: 100 |
|
0 commit comments