Issue
- Jenkins is failing while creating the DXP cloud build and the following errors are observed:
ERROR: org.jenkinsci.plugins.github_branch_source.ApiRateLimitChecker$RateLimitCheckerAdapter checkRateLimit
ERROR: LocalChecker for rate limit was not set for this thread. Configured using system settings.
Environment
- Liferay DXP 7.4
Resolution
ERROR: org.jenkinsci.plugins.github_branch_source.ApiRateLimitChecker$RateLimitCheckerAdapter checkRateLimit
The above error suggests that the build limit has been reached, preventing further API calls.
ERROR: LocalChecker for rate limit was not set for this thread. Configured using system settings.
As per the above, the pipeline execution wasn't configured. It's currently relying on the system-wide settings.
To resolve the above errors, we would suggest avoiding triggering builds on all branches as a workaround. This will help you save disk space and prevent unnecessary builds from running, which in turn will prevent you from exceeding your daily quota limit.
Please set the following environment variables in your infrastructure environment:
LCP_CI_SCM_BRANCH_FILTER_INCLUDE
LCP_CI_SCM_BRANCH_FILTER_EXCLUDE
Below is more information regarding the above environmental variables:
LCP_CI_SCM_BRANCH_FILTER_INCLUDE - specify those branches which you WANT to trigger build
LCP_CI_SCM_BRANCH_FILTER_EXCLUDE - specify those branches which you DON'T WANT to trigger build
For example, if you want the develop and master branches to be included in the autoscan and exclude the branches that start with PR, you would have to configure it as follows:
LCP_CI_SCM_BRANCH_FILTER_INCLUDE="master develop"
LCP_CI_SCM_BRANCH_FILTER_EXCLUDE="PR-*"