声明式管道通过通知程序插件多次将构建状态发送到Bitbucket云

问题描述

环境- Jenkins 版本2.164.3 ,Windows Server 2012,Bitbucket Build Status Notifier 版本1.4.1,JDK 1.8.0_121 ,Chrome浏览器。 问题是- 我们在声明性管道中使用动态共享库,并使用 bitbucketStatusNotify()函数将管道的进度发送回Bitbucket云。每当触发管道时,它都会发送三次相同的消息-

已完成将xxxxxxxxxxxxxxxx提交到BitBucket的构建状态INPROGRESS! 将提交xxxxxxxxxxxxxxxx的构建状态INPROGRESS发送到BitBucket已完成! 将提交xxxxxxxxxxxxxxxx的构建状态为INPROGRESS发送到BitBucket已完成!

对于成功和失败的消息也是如此。

我们的Jenkins文件如下所示-

@Library('common-jenkins-shared-library') _

library identifier: 'project-specific-shared-library@master',changelog:false,retriever: modernSCM(
[$class: 'GitSCMSource',remote: 'URL',credentialsId: 'credntials'])

callMyPipeline()

//in some other groovy file
function callMyPipeline(){
    pipeline{......}
}

管道使用以下脚本通知bitbucket-

bitbucketStatusNotify(buildState: 'INPROGRESS',commitId: 'xxxxxxxxxxxx',repoSlug: 'yyyyyy')

正在寻求帮助。

解决方法

暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!

如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。

小编邮箱:dio#foxmail.com (将#修改为@)