Skip to content
This repository has been archived by the owner on Oct 3, 2023. It is now read-only.

Exporter.Flush does not flush #232

Closed
filipzyzniewski-fexco opened this issue Oct 30, 2019 · 1 comment
Closed

Exporter.Flush does not flush #232

filipzyzniewski-fexco opened this issue Oct 30, 2019 · 1 comment
Labels
bug Something isn't working

Comments

@filipzyzniewski-fexco
Copy link

Please answer these questions before submitting a bug report.

What version of the Exporter are you using?

9366d36, v0.12.7

What version of OpenCensus are you using?

opencensus-go-exporter-stackdriver $ go list -m go.opencensus.io
go.opencensus.io v0.22.1
opencensus-go-exporter-stackdriver $

What version of Go are you using?

$ go version
go version go1.13.3 darwin/amd64
$

What did you do?

filipzyzniewski-fexco@1c06b10 :

opencensus-go-exporter-stackdriver $ go run examples/stats/main.go
2019/10/30 18:39:51 Flushing explictly
2019/10/30 18:39:51 Wait longer than the reporting duration...
2019/10/30 18:40:52 entering statsExporter.uploadMetrics
2019/10/30 18:41:51 Done waiting
opencensus-go-exporter-stackdriver $

What did you expect to see?

"entering statsExporter.uploadMetrics" message shortly after the "Flushing explictly" message

What did you see instead?

"entering statsExporter.uploadMetrics" message after the reporting interval has passed

Additional context

Perhaps this is WAI - if so, could godoc of https://godoc.org/contrib.go.opencensus.io/exporter/stackdriver#Exporter.Flush explicitly state that it won't upload metrics?

Also - please note how I had to bump up the sleep up from 1 minute at filipzyzniewski-fexco@1c06b10#diff-6f40325426fabdac95ad42f50bf87ba1R79 - otherwise the stats example never tried to upload the metrics, as it returned before the upload kicked in - please see timestamps above:
2019/10/30 18:39:51 Wait longer than the reporting duration...
2019/10/30 18:40:52 entering statsExporter.uploadMetrics
there is an additional second of delay before upload kicks in - perhaps the example should be updated?

@filipzyzniewski-fexco filipzyzniewski-fexco added the bug Something isn't working label Oct 30, 2019
@filipzyzniewski-fexco
Copy link
Author

Actually, it's a duplicate of #43

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant