<p>I use &quot;multibranch with Bitbucket Source&quot; plugin and I have a situation where I need to prevent feature branch from notifying bitbucket, else it influences PR gates and other things.</p>
<p>It looks like I need to filter with more advanced conditions than the one that the organization configuration provides. I have tried the trait stop notification plugin, but can't get it to work and tried to disable notifications when status is not built, but that didn't work either.
Also all kind of attempts to break/cancel via the API before it happens, but I was unable to. Any remedy?</p>

CC BY-SA 4.0
2023-05-12T09:48:47.070Z
hi! I'm not sure I understand the problem - do you want to prevent the mainline branch pipeline from being notified of events corresponding to commits on other branches? This sounds like you need to set conditions on the pipelines...
Bruce Becker
CC BY-SA 4.0
2023-05-12T21:34:51.773Z
Hi, basically the use case is that currently I want feature/bugfix branches to not send notifications to bitbucket *only for certain repos* and develop/release/hotfix for example to do it (where I tried based on conditions within the libraries pipelines to decide if notification will be send or not depending on repo name for example, but I failed to prevent it). The idea behind it that the structure of the Bitbucket project is layered in a way that if I want to enable feature/bugfix branch auto-discovy/auto-build on commit only for certain repos in the same time I can only do it for all.
anVzdGFub3RoZXJodW1hbg
CC BY-SA 4.0
2023-05-12T21:41:53.157Z
What I mean above is that normally one should be able to filter what to be auto-build or not form the project. However the services are different and the organization level filters kind of do global decisions. For example I have regular java services starting with service-* so I would want all of them to be auto-build/disc on develop/release/hotfix, but not on hotfix/bugfix (as I don't have support for it yet). But there is a service with another named pattern services-* for example that should have same conditions as above + auto-build on feature/bugfix. I can only allow for all or deny.
anVzdGFub3RoZXJodW1hbg
CC BY-SA 4.0
2023-05-12T21:44:38.173Z
From here the struggle becomes since all are enabled to be auto-build I want the dummy ones that don't have proper support to not send any notifications in order to not impact the PR gate process (as a build from this before PR one is complete might give greenlight or fail merge before the PR build take effect in Bitbucket). I found absolutely no working way to manipulate the notifications even from the organization level, notification were sent no matter what I did.
anVzdGFub3RoZXJodW1hbg
<jenkins><bitbucket>
Prevent "[Bitbucket] Notifying commit build result" happening during Jenkins pipeline
anVzdGFub3RoZXJodW1hbg
# Prevent "[Bitbucket] Notifying commit build result" happening during Jenkins pipeline

(Asked by: username_0 on 2023-04-05)

I use "multibranch with Bitbucket Source" plugin and I have a situation where I need to prevent feature branch from notifying bitbucket, else it influences PR gates and other things.

It looks like I need to filter with more advanced conditions than the one that the organization configuration provides. I have tried the trait stop notification plugin, but can't get it to work and tried to disable notifications when status is not built, but that didn't work either.
Also all kind of attempts to break/cancel via the API before it happens, but I was unable to. Any remedy?

**Tags:** jenkins, bitbucket

> **Comments:**
> **username_1**: hi! I'm not sure I understand the problem - do you want to prevent the mainline branch pipeline from being notified of events corresponding to commits on other branches? This sounds like you need to set conditions on the pipelines...  
> **username_0**: Hi, basically the use case is that currently I want feature/bugfix branches to not send notifications to bitbucket *only for certain repos* and develop/release/hotfix for example to do it (where I tried based on conditions within the libraries pipelines to decide if notification will be send or not depending on repo name for example, but I failed to prevent it). The idea behind it that the structure of the Bitbucket project is layered in a way that if I want to enable feature/bugfix branch auto-discovy/auto-build on commit only for certain repos in the same time I can only do it for all.  
> **username_0**: What I mean above is that normally one should be able to filter what to be auto-build or not form the project. However the services are different and the organization level filters kind of do global decisions. For example I have regular java services starting with service-* so I would want all of them to be auto-build/disc on develop/release/hotfix, but not on hotfix/bugfix (as I don't have support for it yet). But there is a service with another named pattern services-* for example that should have same conditions as above + auto-build on feature/bugfix. I can only allow for all or deny.  
> **username_0**: From here the struggle becomes since all are enabled to be auto-build I want the dummy ones that don't have proper support to not send any notifications in order to not impact the PR gate process (as a build from this before PR one is complete might give greenlight or fail merge before the PR build take effect in Bitbucket). I found absolutely no working way to manipulate the notifications even from the organization level, notification were sent no matter what I did.  

---

## 0 answers

