Update field in linked issues is not triggering a reindex?
Seems like the "Write field on linked issues or subtasks" is not triggering a reindex on the target issues.
I've discovered this while changing a field value that should have triggered a change in the SLA goal of the target issue.
If on the same post function we trigger transition on the target issue then the indexing works fine. But this is not something we want always to enforce.
Any ideas?
Cheers, Aggelos
Comments (10)
-
repo owner -
reporter Attaching the post function at the source issue.
-
repo owner The way to know whether an issue has been reindexed or not, is to check whether a JSD query returns the issue based on updated values.
In your particular case, after executing the transition with the 3 post-functions, you should execute JQL queries asking for issues with the new values you have give to fields Due Date, Priority and Responsible. If issues have not been reindexed, JQL queries consider the old value for those fields, instead of the new one.
Can you please do some checking with JQL queries?
I have detected recently a problem on SLA refresh (look at last comments) caused by JSD. I think that what you are observing might be caused by a problem with JSD, and not with the plugin.
Here there is an interesting article about problems with SLA calculation.
-
reporter I've already tried the JQL and I'm getting the correct results. It definitely seems to be a JSD (SLA calculation) issue. I'll try to go through the related issues you mentioned and get back to you.
-
reporter The only workaround I've found so far is to add a recursive workflow transition (all-2-all) on the target workflow and trigger it in cases where we were using only "Write field..." post-functions that didn't trigger other transitions on the target issues. It seems that SLA recalculation is triggered only by JSD event listeners catching events of the target issue. I suppose that "Write field ...' post-functions aren't triggering events or not? Otherwise it doesn't makes sense.
-
repo owner That post-function is effectively not triggering an "Issue Updated" event. Please, try the following beta version, and let me know whether it solves the problem: 2.2.12_beta_15.
-
reporter Beta's looking good. Removed the workaround and the SLA is immediately recalculated as it supposed to. So what's the story behind this change, you now trigger an event on the target issue?
-
repo owner The new version is triggering an "Issue Updated" event each time a field is updated. I don't know yet whether it will be the definitive solution, because I haven't yet investigated possible problems when many fields are updated on a same issue, because it will triggering more than one event on a same issue.
-
repo owner - changed status to resolved
Fixed in just released version 2.2.12.
-
reporter Working great! Thanks Fidel.
- Log in to comment
Post-function "Write field on linked issues or subtasks" always triggers 2 reindexations on target issue with 1.5 and 5 seconds delay.
You can check up your JIRA's log file in order to verify that the reindexations has been carried out, as expected. You should previously set logging level for package com.fca.jira.plugins.workflowToolbox to DEBUG. You can do it at Administration > Logging and profiling > Configure logging level for another package.
Can you please attach a screenshot showing post-function's tab of the transition where you are executing the post-function?