We are pleased to announce that Better Commit Policy for Bitbucket 3.0.1 is available at Atlassian Marketplace!
More efficient computation of the "is existing" property for Bitbucket commits
Better Commit Policy for Bitbucket 3.0.0 introduced a new mechanism to detect existing commits (commits that are pushed or merged to a repo, but already existing on another branch in the same repository). It helps to avoid re-verifying existing commits, not because of performance, but because the issues referenced by the existing commits may already be in another stage in their lifecycle (like in another status) at their second push, which could lead to sub-optimal development workflows and policies.
As for implementation, unlike other Bitbucket commit verification apps, we did not use the "commit indexer" mechanism built to Bitbucket, because that is not reliable enough for this purpose. Instead, we used a lower level approach relying purely on Git. If it affected you, then your developers may have complained about unexpectedly slow pushes.
Although the original implementation of the "is existing" computation logic is working correctly, it did not scale to repositories with several hundred branches or with tens of thousands of commits.
In the new app version, we implemented a better approach that is two orders of magnitude (100x) faster even in huge repositories! For instance, the verification of a large push to a mega-repo now completes in less than a second instead of 2 minutes.
- To take advantage of the improvement, the required Git version (that you use on the Bitbucket server) is 2.11.0 or newer. (But, older Git versions are still supported!)
Upgrading from 3.0.0
Upgrade the app JAR as usual, through the Universal Plugin Manager. That's it.