Skip to content

[Bug] It working like duplicate combined in Metrics (hour time  #9687

@jinho-son

Description

@jinho-son

Search before asking

  • I had searched in the issues and found no similar issues.

Apache SkyWalking Component

OAP server (apache/skywalking)

What happened

Using AvgLabeled or Other Labeled, Histogram combined Function, it working like duplicate combined when downsampling HOUR and DAY operation

What you expected to happen

Only working once combine in same timeBucket

How to reproduce

The environment occur using
enable downsampling HOUR and DAY
application.yaml

  • core.default.downsampling (HOUR, DAY)
  1. The bug occurs in MergableBufferedData accept()
  2. If buffer has same METRICS (for example, AvgLabeled, SumHistogram, (using dataTable object or else), etc), but different timeBucket
  3. When accept method run combined code
  4. It combined looks like duplicate (same metrics but other timebucket)

Detail

  1. MetricsTransWorker create toHour and toDay
  2. it create new Metrics object but share same object (such as object)
  3. run produce and consume
  4. If buffer already existed METRICS then combined
  5. then toHour METRICS run combined, toDay METRICS run combined for same DataTable

It working fine in primitive value

solve:

  1. target toHour toDay
  2. change set(DataTable) shallow copy to deep copy (It reference same DataTable)

Anything else

When combined toHour metrics and toDay metrics

Are you willing to submit PR?

  • Yes I am willing to submit a PR!

Code of Conduct

Metadata

Metadata

Assignees

No one assigned

    Labels

    backendOAP backend related.bugSomething isn't working and you are sure it's a bug!

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions