Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
43 changes: 43 additions & 0 deletions annotation/annotations.gen.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

66 changes: 66 additions & 0 deletions annotation/annotations.pb.html

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

29 changes: 29 additions & 0 deletions annotation/annotations.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -191,6 +191,35 @@ annotations:
resources:
- Pod

- name: sidecar.istio.io/statsFlushInterval
featureStatus: Alpha
description: Specifies the flush interval for push-based stat sinks, e.g. OTLP. Default interval is `5s`.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

qq: if this is only for push-based stats sinks, what about prometheus (pull based)?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Flush interval doesn't matter for prometheus. However, eviction piggy backs on flush timer, and eviction works for prometheus.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't get it. if it doesn't matter, but we evict when we flush, then it does matter...? And if the default is 5s, isn't that going to break prometheus?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Envoy always runs a stats flush timer, regardless of prometheus. During that timer, server stats are published (e.g. memory allocations, etc), and some other work is done, e.g. eviction.

Prometheus endpoint can snip stats are any point through, in between flushes.

So flush impacts prometheus only indirectly, e.g. by updating/removing some metrics.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe more concretely... I send 1 request to foo.com. I get an istio_request_total metric for it.

When, with prometheus, will this metric stop showing up in /stats/prometheus with/without this annotation set?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For flush annotation: it will show up immediately and stay forever.
For eviction annotation: same, but it will disappear after 2*eviction interval unless the metric gets another hit.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks! Sorry I was being a bit dense, github UI was hiding part of the PR

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@howardjohn @keithmattix can we move this forward?

deprecated: false
hidden: false
resources:
- Pod

- name: sidecar.istio.io/statsEvictionInterval
featureStatus: Alpha
description: Specifies the expiration interval for the Istio standard
metrics. This gets rounded to a multiple of the flush interval. A time
series is expected to be evicted after 2 iterations of this interval from
the last measurement.
deprecated: false
hidden: false
resources:
- Pod

- name: sidecar.istio.io/statsHistogramBins
featureStatus: Alpha
description: Specifies the bin size per time series for the Istio standard
metrics histograms. Reducing this value from the default `100` decreases
overall memory usage for sparse and/or high cardinality histograms.
deprecated: false
hidden: false
resources:
- Pod

- name: sidecar.istio.io/userVolume
featureStatus: Alpha
description: Specifies one or more user volumes (as a JSON array) to be added to
Expand Down