Closed bmannix closed 5 years ago
Hard to say why this is occurring. After looking at BitbucketRepository.java:112-133, it seems like this would only occur if the comments or their content came back null (erroneously), which seems very plausible given that bitbucket was in the middle of recovering from a serious error.
There might not be an easy way to prevent this from occurring. This is only my first day of running the plugin, so maybe I am just unlucky. However if this became a common issue, one possible workaround would be some sort of timer based solution. Such that, if a bad JSON response was encountered (e.g. bitbucket was down), upon recovery no new builds would kick off for some amount (configurable?) of time. This would allow the comment system to complete recovery before we started new builds.
I encounter similar behavior with Jenkins ver. 2.46.3 and Stash Pullrequest Builder plugin ver. 1.7.0. So it seems that this issue still exists.
Guys, you might want to take a look at a stripped-down version, that supports webhooks https://github.com/ip1981/bbprb
BUILD: 1.4.1 JENKINS: 1.567
PROBLEM:
IT appears that there were some issues with bitbucket around 5:20am (EDT) today. This is reinforced by the logs@ (http://status.bitbucket.org/). The pull request plugin received some invalid responses from bitbucket, however, upon recovery the plugin appears to not recognize that it's already built the only open pull request that I have right now. This caused it to execute 2 additional and extraneous builds.
STEPS TO REPRODUCE:
EXPECTED BEHAVIOR: The plugin should have a mechanism to determine that it already has built each individual pull request and should not duplicate builds.
LOG: