RFR: forge: add search method

Robin Westberg rwestberg at openjdk.java.net
Tue Sep 29 12:46:06 UTC 2020


On Tue, 29 Sep 2020 12:32:27 GMT, Erik Helin <ehelin at openjdk.org> wrote:

> Hi all,
> 
> please review this patch that adds the `Forge.search` method to allow searching for a commit with a particular hash on
> a forge.
> Thanks,
> Erik

Looks good, a bit worried that auto-pagination of thousands of commits will take a while though.. :)

forge/src/main/java/org/openjdk/skara/forge/gitlab/GitLabHost.java line 246:

> 244:                                   .collect(Collectors.toList());
> 245:             for (var project : projects) {
> 246:                 var c = request.get("projects/" + project + "/repository/commits/" + hex)

Could we use this endpoint instead? https://docs.gitlab.com/ce/api/commits.html#get-a-single-commit

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

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


More information about the skara-dev mailing list