Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Refactor the api/metrics push controller; add CheckpointSet synchronization #737

Merged
merged 10 commits into from
May 19, 2020

Conversation

jmacd
Copy link
Contributor

@jmacd jmacd commented May 18, 2020

From reviewing #735, it's not clear that the synchronization of the *simple.Integrator map was correct, that it's possible for a reader-writer panic in the underlying map.

The push controller directly refers to the *simple.Integrator, and push options are added for setting Stateful and Period. The default push interval changes to 10s (from the pain of #735).

Prometheus changes the result of NewExportPipeline to *Exporter from http.Handler. Adds a test for Prometheus statefulness and refactors existing mock clock code.

This is preparatory for removing the push controller from the Prometheus exporter, adding a pull controller instead.

@jmacd jmacd added the area:metrics Part of OpenTelemetry Metrics label May 18, 2020
Copy link
Contributor

@MrAlias MrAlias left a comment

Choose a reason for hiding this comment

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

LGTM. Minor suggestions/nits.

sdk/metric/controller/push/push.go Show resolved Hide resolved
sdk/metric/integrator/simple/simple.go Outdated Show resolved Hide resolved
sdk/metric/integrator/simple/simple.go Outdated Show resolved Hide resolved
sdk/metric/integrator/simple/simple.go Show resolved Hide resolved
sdk/export/metric/metric.go Outdated Show resolved Hide resolved
exporters/metric/prometheus/prometheus.go Outdated Show resolved Hide resolved
exporters/metric/prometheus/prometheus_test.go Outdated Show resolved Hide resolved
exporters/metric/prometheus/prometheus_test.go Outdated Show resolved Hide resolved
exporters/metric/stdout/stdout.go Outdated Show resolved Hide resolved
@jmacd jmacd merged commit 21d094a into open-telemetry:master May 19, 2020
@jmacd jmacd deleted the jmacd/refactor_push branch May 19, 2020 01:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area:metrics Part of OpenTelemetry Metrics
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants