Skip to content

Undesirable caching of REST API branches requests

The lately introduced caching of REST API branches requests might be undesirable under some circumstances. In our case this feature breaks our Jenkins pipeline triggers, because Jenkins GitLab branch source plugin can no longer reliably detect latest commits. It uses GitLab REST API to fetch the latest commits for all project branches and thus can not detect any changes if cached branch info is returned.

I think there should be a REST API argument to disable caching for specific requests. Also it should be stated in the API documentation that those requests are cached and might not reflect the current state of the repository.