Skip to content

Commit

Permalink
avoid concurrent problem in JvmFilterHolder
Browse files Browse the repository at this point in the history
  • Loading branch information
致节 committed Apr 16, 2024
1 parent cc9e6cf commit 08463d3
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -18,17 +18,17 @@

import org.springframework.core.Ordered;

import java.util.ArrayList;
import java.util.Comparator;
import java.util.List;
import java.util.concurrent.CopyOnWriteArrayList;
import java.util.concurrent.atomic.AtomicBoolean;

/**
* @author <a href="mailto:[email protected]">Alaneuler</a>
* Created on 2020/8/18
*/
public class JvmFilterHolder {
private static final List<JvmFilter> JVM_FILTERS = new ArrayList<>();
private static final List<JvmFilter> JVM_FILTERS = new CopyOnWriteArrayList<>();
private static final AtomicBoolean filtersSorted = new AtomicBoolean(false);

private static final Comparator<Ordered> comparator = (f1, f2) -> {
Expand Down

0 comments on commit 08463d3

Please sign in to comment.