[
https://issues.apache.org/jira/browse/KAFKA-20404?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=18081820#comment-18081820
]
Canxuan Wang commented on KAFKA-20404:
--------------------------------------
I'd like to work on this. Plan: walk through each class in spotbugs-exclude.xml
that was bulk-added for the new atomicity warning patterns, classify each as
(a) genuine false positive (add a more targeted suppression with rationale), or
(b) real concurrency issue (fix). Will keep changes incremental per class to
ease review.
> Investigate/Fix bulk-excluded SpotBugs atomicity warnings
> ----------------------------------------------------------
>
> Key: KAFKA-20404
> URL: https://issues.apache.org/jira/browse/KAFKA-20404
> Project: Kafka
> Issue Type: Improvement
> Components: streams
> Reporter: Muralidhar Basani
> Priority: Major
> Labels: concurrency, spotbugs
>
> When SpotBugs was upgraded, several streams classes were bulk-excluded for
> three new atomicity warning patterns.
> For ex: StreamThread class is added to exclusion list.
> [https://github.com/apache/kafka/blob/1bf7d6032b9b4171f510dc9a1c7e0243410e27f5/gradle/spotbugs-exclude.xml#L636]
> Check for Field lastCommitMs
> [https://github.com/apache/kafka/blob/1bf7d6032b9b4171f510dc9a1c7e0243410e27f5/streams/src/main/java/org/apache/kafka/streams/processor/internals/DefaultStateUpdater.java#L819]
>
> Each class needs individual investigation to determine whether the warning is
> a false positive or a real concurrency bug.
> Atomicity warnings to consider :
> AT_NONATOMIC_OPERATIONS_ON_SHARED_VARIABLE
> AT_NONATOMIC_64BIT_PRIMITIVE
> AT_STALE_THREAD_WRITE_OF_PRIMITIVE
--
This message was sent by Atlassian Jira
(v8.20.10#820010)