Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

Post Function works only on one instance

Dominik Henka February 17, 2022

Hi. I have a custom post function that triggers when I close an issue. However this post function works only on my test instance and not on my production jira. It's seems it doesn't even trigger. Configuration on both jira instances are the same. Other custom post functions triggers and works fine. So maybe after all I'm missing some configuration or could it be other problem I fail to see?

1 answer

1 accepted

0 votes
Answer accepted
Dave Bosman [Realdolmen]
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
February 17, 2022

Hi @Dominik Henka 

Most likely you are missing some configuration. 

However without more details it is hard to say what the root cause is. 

Regards

Dave

Dominik Henka February 17, 2022

For both my test and production instances post function is in same workflow, same transition, same project and same issue type. Code used is also the same. There is no problem with any permissions as well. Is there any other configuration I can check?

Dave Bosman [Realdolmen]
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
February 17, 2022

Hi @Dominik Henka 

Is it really the same? You could have properties in 1 of the environments that forbid something. 

Also check your permission scheme.

What is the post function that you want to perform? And if it belongs to a plugin, what plugin is it? 

Regards

Dave

Dominik Henka February 17, 2022

What properties do you mean? 
Permission scheme is ok. I checked it once again. It's same on both instances.

Plugin is custom, wrote fully by us.

Dave Bosman [Realdolmen]
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
February 17, 2022

Hi @Dominik Henka 

So i repeat, what is the post function supposed to do? 

Regards

Dave

Dominik Henka February 17, 2022

When subtask is closed(fromStatus -> closed) it should populate text from one of the fields in subtask(description field) to main issue to the "description" field 

Dave Bosman [Realdolmen]
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
February 17, 2022

Hi @Dominik Henka 

So this is a step by step troubleshooting 

First, you need to check if the user that performs the action can edit the main issue. And with user i mean depending on how you wrote the plugin it can be the user that triggered the issue, but it also could be that it is a user specific to the plugin.

For example, if you want Jira automation to perform actions in a project you need to add "Project Role (atlassian-addons-project-access)" to your permission scheme (and security scheme if you have it set up.) 

If it is this specific user, the user also needs to be able to see the source issue (in case you have a security scheme set up)

Once you know what user is performing this action you can use the permission helper to see what is missing. 

But to be honest, you wrote a plugin with functionality that already exists out of the box in Jira, you can find it in your project -> "project settings" -> "automation". There you can simply create an automation rule that handles that. So out of personal curiosity, do you have any specific reason for choosing this solution? 

Regards

Dave

Dave Bosman [Realdolmen]
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
February 17, 2022

So i forgot to answer a part.

About the properties: If you edit your workflow and select a status, on the right side you have a link "Properties". If properties are added this could be the reason 

Examples of those properties can be found here

Dominik Henka February 17, 2022

Answering your question. The most important part is we as a company want to have full control over our customizations. Also for us limit of 500 executions would be over in few days.

For your suggested solutions I will test it and give you answer tomorrow. 

Dominik Henka February 18, 2022

Hi. So your suggested solutions didn't worked. With our team we decided to rewrite this method so we can end this here.

But thank you for your help.

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events