RFR: 1191: CommitCommentWorkItem overwhelms scheduler

Kevin Rushforth kcr at openjdk.java.net
Mon Sep 27 21:21:14 UTC 2021


On Mon, 27 Sep 2021 20:35:13 GMT, Erik Joelsson <erikj at openjdk.org> wrote:

> Main goal if this patch is to fix the scheduling issue caused by CommitCommentsWorkItems::concurrentWith always returning true. To solve this a little nicer, I decided to expand on the idea I introduced a while back with PullRequest::isSame, and add the corresponding method to HostedRepository. This made implementing the ::concurrentWith methods cleaner IMO.
> 
> In addition to this, I decided to add two new gauges to the metrics collection, which would have made it much easier to discover this issue if we already had them. These gauges report the number of active and pending WorkItems we have respectively in the BotRunner, summarized per WorkItem type using labels. To achieve this as nicely as I could, I refactored the BotRunner a little bit, moving all adds and removes for the active and pending maps to specific methods.

Looks good.

-------------

Marked as reviewed by kcr (Reviewer).

PR: https://git.openjdk.java.net/skara/pull/1223


More information about the skara-dev mailing list