Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature/bb post webhooks #694

Merged
45 commits merged into from
Apr 1, 2021
Merged

Feature/bb post webhooks #694

45 commits merged into from
Apr 1, 2021

Conversation

nleach999
Copy link
Contributor

@nleach999 nleach999 commented Mar 31, 2021

Description

Implementation of BitBucket Server third party webhook plugin Post Web Hooks resolves #651. Embedded wiki files have been updated to reflect the change. As part of the implementation, this fixes #650 to avoid additional scans by handling the MERGED event.

As part of the customer's deployment, they needed to have the ability to use multiple instances of BitBucket server to test the configuration and workflow before using in their production instance. As such, this resolves #674 with changes that allow for multiple BitBucket servers. The implementation may need some work given when looking at the multi-SCM feature, it was written to accommodate GitHub/GitLab type configurations where there is a URL for the SCM and a URL for the API. Since BitBucket uses one URL for the SCM and an additional "api-path" configuration, the "optional-instances" clause is configured differently to make multi-SCM with BBS work.

UPDATE: Also resolves #699 out of necessity for deployment.

Testing

Multi-SCM testing was done with a BB Server as the primary instance, a BB Server and BB Cloud as secondary instances. Issue #675 will remain open until testing is performed with BB Cloud as the primary SCM with one or more BB Servers as secondary.

Currently it is deployed and functional at a customer site with their production BB Server as the primary and their sandbox BB Server as the secondary.

The Post Web Hook plugin was also tested locally using BB Server and is in the customer's environment. Locally I validated that Post Web Hook events and BB Server native events were handled with no changes from the handling of the BB Server native events.

Post Web Hook global events are configured in the customer's sandbox and is being used in combination with config-as-code to provide override configurations on a per-repository basis. Per-repository Post Web Hook events were tested in my local setup. The customer has native BB Server events coming from their production instance, so CxFlow is handling both without issue.

Tested issue #699 with both Jira Data Center and Jira Cloud.

Checklist

  • I have added documentation for new/changed functionality in this PR (if applicable).
  • All active GitHub checks for tests, formatting, and security are passing
  • The correct base branch is being used

@ghost ghost requested a review from AvivCx April 1, 2021 04:14
@ghost
Copy link

ghost commented Apr 1, 2021

Hi @nleach999 , to run the full pipeline for the PR, the source branch needs to be created from the same repo (cxflow) and the branch name should start with 'pr-'.

@nleach999
Copy link
Contributor Author

@MithileshPawar I don't have permissions to create a branch under checkmarx-ltd repos. You'll probably have to do what Ken did for my last PR that originated from my repo by re-targeting this PR and merging it to a branch that meets the naming criteria.

@ghost ghost changed the base branch from develop to pr-nathan-bitbucket-post-webhooks April 1, 2021 15:02
@ghost
Copy link

ghost commented Apr 1, 2021

Hi, @nleach999, looks like there are some conflicts. Can you try to rebase your branch (nleach999:feature/bb_post_webhooks) with the new base branch (pr-nathan-bitbucket-post-webhooks) ?

@nleach999
Copy link
Contributor Author

@MithileshPawar done, currently shows no conflicts.

@ghost ghost self-requested a review April 1, 2021 15:36
@ghost ghost merged commit 4cbddaf into checkmarx-ltd:pr-nathan-bitbucket-post-webhooks Apr 1, 2021
AvivCx pushed a commit that referenced this pull request Apr 10, 2021
Feature/bb post webhooks (#694) (#700)
This pull request was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants