Pull Requests Build Feature fails with BitBucket Cloud due to API rate limit exceeded
Failed to retrieve pull request information; Exception: java.io.IOException: Pull request information retrieval failure due to HTTP error, status code 429: Unknown Status Code
We have multiple build configurations using this feature against different repos in our bitbucket cloud account. It seems it doesn't understand how to deal with api rate limit messages, or manage multiple jobs that use the build feature. We do use an app password specific to this build feature, all of our other vcs interaction uses a private key and ssh.
we are on 2020.2.3, Pull Requests Plugin 86002
I see there were similar issues with GitHub a few years ago... I believe support was just added for Bitbucket Cloud as we weren't using it until recently.
Please sign in to leave a comment.
Hello!
Indeed, Pull Requests plugin does not handle API rate limit for BitBucket Cloud right now - I have created a bug on the matter (https://youtrack.jetbrains.com/issue/TW-71221). Please mind, though, that the fix would only prettify the error in logs - as the request limit for repository data is at 1000 requests per hour, you may still have to use separate accounts to ensure the stability.
As per my check with the development team, there will be some changes in how Pull Requests feature polls repositories in 2021.1. Current logic is complex and it may be non-trivial to predict the amount of requests for any given repository; with the new release, you may expect 12 requests per hour per repository, and a request per any reported change in pull request state (e.g. a new PR opened or an existing one changed).
If possible, could I ask you to enable debug-general logging preset in Administration | Diagnostics | Troubleshooting and, when the issue reproduces, share the teamcity-server.log files covering the issue via https://uploads.jetbrains.com/?