go-graphite / carbon-clickhouse

Graphite metrics receiver with ClickHouse as storage
MIT License
187 stars 47 forks source link

Missing tag data with after slash separator #135

Open evdevk opened 8 months ago

evdevk commented 8 months ago

Starting from carbon-clickhouse-0.11.2-1 and above (carbon-clickhouse-0.11.1-1 working ok) there was some strange bug with uploading metrics.

If I set tag value as symbol/single_symbol - carbon-clickhouse lose single_symbol. If I set tag value as symbol/multiple_symbols - all ok.

Working ok example (check port_name):

metric_name;contur=prod&interval=30s;port_name=0/22 123 1703255195
metric_name;contur=prod&interval=30s;port_name=0/x1 123 1703255195
metric_name;contur=prod&interval=30s;port_name=0/.x 123 1703255195

Tag1 result list: port_name=0/22 port_name=0/x1 port_name=0/.x

Bug example (check port_name):

metric_name;contur=prod&interval=30s;port_name=0/1 123 1703255195
metric_name;contur=prod&interval=30s;port_name=0/x 123 1703255195
metric_name;contur=prod&interval=30s;port_name=0/. 123 1703255195

Tag1 result list: port_name=0/ port_name=0/ port_name=0/

msaf1980 commented 4 months ago

@evdevk Can You test against master ? It's may be #116

evdevk commented 4 months ago

@evdevk Can You test against master ? It's may be #116 Looks like not fixed.

1) I've clone master branch 2) gownload go1.18 3) make (binary have 0.11.7) and replace carbon-clickhouse binary 4) push same 3 metrics from example above and got port_name=0/

evdevk commented 16 hours ago

Here is the code which produces the described error

If you remove "-1" from line - all ok.