You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cassandra.apache.org by "Yifan Cai (Jira)" <ji...@apache.org> on 2025/09/29 16:41:00 UTC
[jira] [Commented] (CASSSIDECAR-349) Thread race issue when adding excluded metric in FilteringMetricRegistry
[ https://issues.apache.org/jira/browse/CASSSIDECAR-349?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=18023583#comment-18023583 ]
Yifan Cai commented on CASSSIDECAR-349:
---------------------------------------
+1
> Thread race issue when adding excluded metric in FilteringMetricRegistry
> ------------------------------------------------------------------------
>
> Key: CASSSIDECAR-349
> URL: https://issues.apache.org/jira/browse/CASSSIDECAR-349
> Project: Sidecar for Apache Cassandra
> Issue Type: Bug
> Components: Observability
> Reporter: Francisco Guerrero
> Assignee: Francisco Guerrero
> Priority: Major
> Time Spent: 20m
> Remaining Estimate: 0h
>
> In CASSSIDECAR-347, an issue was introduced where two threads can race. A modification to the {{excludedMetrics}} in the {{org.apache.cassandra.sidecar.metrics.FilteringMetricRegistry#addExcludedMetricIfNotExists}} can race with a call to {{org.apache.cassandra.sidecar.metrics.FilteringMetricRegistry#getMetrics}} when the {{allMetrics}} is nulled out in {{addExcludedMetricIfNotExists}} but the metric is not yet added to the {{excludedMetrics}} map, and the other thread in {{getMetrics}} is computing a new value of {{allMetrics}} without the new metric that has not yet been added to {{allMetrics}}
--
This message was sent by Atlassian Jira
(v8.20.10#820010)
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@cassandra.apache.org
For additional commands, e-mail: commits-help@cassandra.apache.org