Skip to content

Commit

Permalink
Merge pull request #330 from aloubyansky/concurrent-linked-deque-errors
Browse files Browse the repository at this point in the history
Use ConcurrentLinkedDeque to collect errors when inspecting dependencies
  • Loading branch information
aloubyansky authored Mar 28, 2024
2 parents aa139de + 9e064e9 commit 0b25d69
Showing 1 changed file with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@
package io.quarkus.domino.inspect;

import java.util.ArrayList;
import java.util.Deque;
import java.util.Formatter;
import java.util.List;
import java.util.concurrent.ConcurrentLinkedDeque;
import java.util.concurrent.atomic.AtomicInteger;
import org.eclipse.aether.artifact.Artifact;

abstract class DependencyTreeVisitSchedulerBase<E> implements DependencyTreeVisitScheduler {

private static final String FORMAT_BASE = "[%s/%s %.1f%%] ";

protected final List<DependencyTreeError> errors = new ArrayList<>();
protected final Deque<DependencyTreeError> errors = new ConcurrentLinkedDeque<>();
protected final DependencyTreeVisitContext<E> ctx;
protected final AtomicInteger counter = new AtomicInteger();
protected final int rootsTotal;
Expand All @@ -23,7 +23,7 @@ abstract class DependencyTreeVisitSchedulerBase<E> implements DependencyTreeVisi
}

@Override
public List<DependencyTreeError> getResolutionFailures() {
public Deque<DependencyTreeError> getResolutionFailures() {
return errors;
}

Expand Down

0 comments on commit 0b25d69

Please sign in to comment.