Skip to content

Commit

Permalink
Suppress IS2_INCONSISTENT_SYNC warning
Browse files Browse the repository at this point in the history
  • Loading branch information
rohitsinha54 committed Feb 1, 2025
1 parent 31b41b0 commit f68fe75
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@
*/
package org.apache.beam.runners.core.metrics;

import edu.umd.cs.findbugs.annotations.SuppressFBWarnings;
import java.util.Arrays;
import java.util.Objects;
import org.apache.beam.sdk.metrics.BoundedTrie;
Expand All @@ -31,6 +32,9 @@
* In that case retrieving the underlying cell and reporting directly to it avoids a step of
* indirection.
*/
@SuppressFBWarnings(
value = "IS2_INCONSISTENT_SYNC",
justification = "Some access on purpose are left unsynchronized")
public class BoundedTrieCell implements BoundedTrie, MetricCell<BoundedTrieData> {

private final DirtyState dirty = new DirtyState();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@
*/
package org.apache.beam.runners.core.metrics;

import edu.umd.cs.findbugs.annotations.SuppressFBWarnings;
import java.io.Serializable;
import java.util.ArrayList;
import java.util.Collections;
Expand Down Expand Up @@ -55,6 +56,9 @@
@SuppressWarnings({
"nullness" // TODO(https://github.com/apache/beam/issues/20497)
})
@SuppressFBWarnings(
value = "IS2_INCONSISTENT_SYNC",
justification = "Some access on purpose are left unsynchronized")
public class BoundedTrieData implements Serializable {

private static final int DEFAULT_BOUND = 100; // Default maximum size of the trie
Expand Down

0 comments on commit f68fe75

Please sign in to comment.