This is an automated email from the ASF dual-hosted git repository.
kturner pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/accumulo.git
The following commit(s) were added to refs/heads/main by this push:
new e9e8de3855 fixes bug in CompactionJobPriorityQueue (#4946)
e9e8de3855 is described below
commit e9e8de38551e2807947a6e8f8bbe3d8367527bc8
Author: Keith Turner <[email protected]>
AuthorDate: Fri Oct 4 13:33:16 2024 -0400
fixes bug in CompactionJobPriorityQueue (#4946)
CompactionJobPriorityQueue.getAsync was not doing clean up of internal
data strucs when it removed a job from the queue. Changed it call an
existing method that does this cleanup.
---
.../accumulo/manager/compaction/queue/CompactionJobPriorityQueue.java | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git
a/server/manager/src/main/java/org/apache/accumulo/manager/compaction/queue/CompactionJobPriorityQueue.java
b/server/manager/src/main/java/org/apache/accumulo/manager/compaction/queue/CompactionJobPriorityQueue.java
index 2e868360df..9e2ddbc96a 100644
---
a/server/manager/src/main/java/org/apache/accumulo/manager/compaction/queue/CompactionJobPriorityQueue.java
+++
b/server/manager/src/main/java/org/apache/accumulo/manager/compaction/queue/CompactionJobPriorityQueue.java
@@ -245,9 +245,9 @@ public class CompactionJobPriorityQueue {
}
public synchronized CompletableFuture<CompactionJobQueues.MetaJob>
getAsync() {
- var job = jobQueue.pollFirstEntry();
+ var job = poll();
if (job != null) {
- return CompletableFuture.completedFuture(job.getValue());
+ return CompletableFuture.completedFuture(job);
}
// There is currently nothing in the queue, so create an uncompleted
future and queue it up to