As a jira admin, I need to edit a workflow to edit the post function . I added a post function to send transition to webhook. It is not working as expected. Kindly help me.
Usually the problem with webhooks not functioning as expected as a post function is the order in which that webhook is set to fire. By default when you add a webhook to a post function it places it in the #1 position. This means that the web hook can fire even before Jira attempts to reindex that issue for the specific status change that was also triggered by the transition. This can cause problems because it's a sort of race-condition where the webhook is being told to go now, but Jira hasn't actually updated the issue yet, change the status, updated the index, or fired the actual event that this webhook could be using as a configuration setting.
So first thing to try, move the 'fire a webhook' post function event to the very bottom of the post functions in that transition, and publish the changes to the workflow. Then see if this works as expected or not.
If that doesn't help, please let me know the following:
Hi,
We are working as suggested. We will get back to you after checking with user.
Thanks
Hi Andrew,
We also face same issue, I have reoredered the webhook in bottom of post function but still nothing is happening.
1. JIRA Version : 7.1.0
@Vasanta Kumaar I can see in your webhook you have a JQL filter of
Project=WAYN and project ="CH Backlog"
I can tell you that if these are two different projects, then your JQL query will always return 0 Jira issues. In turn this could prevent this webhook from ever working. That specific query is only return Jira issues that can match both projects. Since no issue can actually be in more than one project at a time, there are no Jira issues that can possibly match both elements at the same time.
Instead if you only want match against issues in either project try a query such as
project in (WAYN,"CH Backlog")
Or perhaps remove the JQL entirely. You can control which projects use the specific workflow so that method would probably be preferred here so that this webhook is only fired for projects that use this specific workflow in question.
I hope that helps.
Andy
hi Andy,
Having same problem ie webhook dosent work. Made changes as suggested:
1. Sent webhook post function at the very bottom.
2. No JQL is present
Could you help here please?
Many thanks in advance!
Regards
Sabyasachi
I don't see a clear problem from the screenshots you posted. Did you publish the workflow after you made these changes to the post functions? If not, it would explain why this is not behaving as expected. Screenshots appear to be cropped so I can't see the upper part of the page that would better indicate if this is still a draft workflow or an active workflow.
Hi Andy,
Yeap, the workflow is published after the post function addition in the transition and its active, missed the upper part earlier. Adding now.
Is there any way to dig further and check if the webhook is getting called successfully? I really cant see any in JIRA UI where a webhook calls are registered.
Hi @Saby
Not sure I know the cause here, but I did run across this bug that affects Jira server versions running on top of Java 11 versions, see JRASERVER-70780. No idea if that describes your environment or not.
If this doesn't apply, please let me know your specific version of Jira. Perhaps there is some other explanation for why this is not working as expected.
It looks like you're new here. Sign in or register to get started.