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

The start time must be before the end time for the non-gauge metric #266

@zargarpur

Description

@zargarpur

What version of the Exporter are you using?

contrib.go.opencensus.io/exporter/stackdriver => contrib.go.opencensus.io/exporter/stackdriver v0.12.9-0.20191108183826-59d068f8d8ff

What version of OpenCensus are you using?

go.opencensus.io => go.opencensus.io v0.22.1

What version of Go are you using?

go version go1.14.2 linux/amd64

What did you do?

We have that count metric here https://github.com/google/knative-gcp/blob/d0a452483985c0f1d775efa2ea54fddaed2ed107/pkg/metrics/ingress_reporter.go#L59

Invoked here https://github.com/google/knative-gcp/blob/d0a452483985c0f1d775efa2ea54fddaed2ed107/pkg/metrics/ingress_reporter.go#L103

And we're seeing this error occasionally in our E2E tests that prevents our metrics from being uploaded

default-brokercell-ingress-594cd99c77-57gk6 ingress 2020/06/12 20:48:48 Failed to export to Stackdriver: rpc error: code = InvalidArgument desc = Field timeSeries[1].points[0].interval.start_time had an invalid value of "2020-06-12T13:48:47.794571-07:00": The start time must be before the end time (2020-06-12T13:48:47.794571-07:00) for the non-gauge metric 'knative.dev/internal/eventing/broker/event_count'.

If possible, provide a recipe for reproducing the error.
We have a continuous E2E test runs that occasionally run into this issue which is exercising the code path above https://testgrid.knative.dev/knative-gcp#continuous&include-filter-by-regex=TestGCPBrokerMetrics

What did you expect to see?

Metrics consistently uploaded to Stackdriver without this error

What did you see instead?

This error message

default-brokercell-ingress-594cd99c77-57gk6 ingress 2020/06/12 20:48:48 Failed to export to Stackdriver: rpc error: code = InvalidArgument desc = Field timeSeries[1].points[0].interval.start_time had an invalid value of "2020-06-12T13:48:47.794571-07:00": The start time must be before the end time (2020-06-12T13:48:47.794571-07:00) for the non-gauge metric 'knative.dev/internal/eventing/broker/event_count'.

Additional context

Add any other context about the problem here.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions