skywalking icon indicating copy to clipboard operation
skywalking copied to clipboard

[BanyanDB] Support float64 in the streaming process

Open hanahmily opened this issue 3 years ago • 4 comments

Search before asking

  • [X] I had searched in the issues and found no similar feature requirement.

Description

This is a follow-up task after https://github.com/apache/skywalking-banyandb/pull/240

The server side should handle 64-bit float data more than 64-bit integers.

Use case

No response

Related issues

No response

Are you willing to submit a PR?

  • [ ] Yes I am willing to submit a PR!

Code of Conduct

hanahmily avatar Jan 14 '23 01:01 hanahmily

@lujiajing1126 Could you provide more details about this task? We have potential contributors who are interested in it.

hanahmily avatar Apr 03 '23 06:04 hanahmily

Currently, the TopN calculus is only for int64 fields since we've hard-coded int64 in most places. I could provide some examples but still may miss some corner cases,

  1. In TopN schema, FieldType_FIELD_TYPE_INT is used: https://github.com/apache/skywalking-banyandb/blob/d1426ecbbf5ccda47e38103666fc2c6ef19fd58b/banyand/measure/measure_topn.go#L71
  2. In TopN result writing: https://github.com/apache/skywalking-banyandb/blob/d1426ecbbf5ccda47e38103666fc2c6ef19fd58b/banyand/measure/measure_topn.go#L208
  3. In the streaming operators, int64 is assumed: https://github.com/apache/skywalking-banyandb/blob/d1426ecbbf5ccda47e38103666fc2c6ef19fd58b/banyand/measure/measure_topn.go#L159 and https://github.com/apache/skywalking- banyandb/blob/d1426ecbbf5ccda47e38103666fc2c6ef19fd58b/banyand/measure/measure_topn.go#L490
  4. In the post aggregation: https://github.com/apache/skywalking-banyandb/blob/d1426ecbbf5ccda47e38103666fc2c6ef19fd58b/banyand/query/processor_topn.go#L242
  5. In the TopN Aggregator: https://github.com/apache/skywalking-banyandb/blob/d1426ecbbf5ccda47e38103666fc2c6ef19fd58b/pkg/flow/streaming/topn.go#L58

At least the aforementioned places must be refactored to support float64.

@lujiajing1126 Could you provide more details about this task? We have potential contributors who are interested in it.

Any other useful info I have to add here? @hanahmily

lujiajing1126 avatar Apr 03 '23 06:04 lujiajing1126

@hanahmily I would like to contribute.

DevPJ9 avatar Apr 03 '23 14:04 DevPJ9

@DevPJ9 Any update?

hanahmily avatar Jun 07 '23 03:06 hanahmily