Skip to content

Test cases failed: TestSlidingWindowMetric_GetIntervalSumWithTime #533

@sczyh30

Description

@sczyh30

Issue Description

Type: bug report

Describe what happened

CI message: https://github.com/alibaba/sentinel-golang/actions/runs/5245310227/jobs/9473217587

2023-06-12T15:34:14.9150364Z {"timestamp":"2023-06-12 15:34:11.11120","caller":"bucket_leap_array.go:117","logLevel":"ERROR","msg":"Failed to get current bucket in BucketLeapArray.currentBucketWithTime()","now":1678416554500}
2023-06-12T15:34:14.9150566Z Provided time timeMillis=1678416554500 is already behind old.BucketStart=1686584064500.
2023-06-12T15:34:14.9150859Z github.com/alibaba/sentinel-golang/core/stat/base.(*LeapArray).currentBucketOfTime
2023-06-12T15:34:14.9151173Z 	/home/runner/work/sentinel-golang/sentinel-golang/core/stat/base/leap_array.go:226
2023-06-12T15:34:14.9151489Z github.com/alibaba/sentinel-golang/core/stat/base.(*BucketLeapArray).currentBucketWithTime
2023-06-12T15:34:14.9151818Z 	/home/runner/work/sentinel-golang/sentinel-golang/core/stat/base/bucket_leap_array.go:115
2023-06-12T15:34:14.9152117Z github.com/alibaba/sentinel-golang/core/stat/base.(*BucketLeapArray).addCountWithTime
2023-06-12T15:34:14.9152450Z 	/home/runner/work/sentinel-golang/sentinel-golang/core/stat/base/bucket_leap_array.go:95
2023-06-12T15:34:14.9152812Z github.com/alibaba/sentinel-golang/core/stat/base.TestSlidingWindowMetric_GetIntervalSumWithTime.func1
2023-06-12T15:34:14.9153225Z 	/home/runner/work/sentinel-golang/sentinel-golang/core/stat/base/sliding_window_metric_test.go:175
2023-06-12T15:34:14.9153304Z testing.tRunner
2023-06-12T15:34:14.9153494Z 	/opt/hostedtoolcache/go/1.19.9/x64/src/testing/testing.go:1446
2023-06-12T15:34:14.9153585Z runtime.goexit
2023-06-12T15:34:14.9153764Z 	/opt/hostedtoolcache/go/1.19.9/x64/src/runtime/asm_amd64.s:1594
2023-06-12T15:34:14.9154099Z     sliding_window_metric_test.go:179: SlidingWindowMetric.getSumWithTime() = 0, want 2000
2023-06-12T15:34:14.9154368Z --- FAIL: TestSlidingWindowMetric_GetIntervalSumWithTime (0.28s)
2023-06-12T15:34:14.9154718Z     --- FAIL: TestSlidingWindowMetric_GetIntervalSumWithTime/#00 (0.28s

Metadata

Metadata

Assignees

Labels

kind/bugSomething isn't working

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions