[MGNLHOOK-249] Exception when publishing asset deletion Created: 19/Oct/22  Updated: 18/Nov/22  Resolved: 11/Nov/22

Status: Closed
Project: Magnolia Webhooks
Component/s: None
Affects Version/s: 1.0.0
Fix Version/s: 2.0.0, 1.0.1

Type: Bug Priority: Neutral
Reporter: Christopher Zimmermann Assignee: Milan Divilek
Resolution: Fixed Votes: 1
Labels: None
Σ Remaining Estimate: Not Specified Remaining Estimate: Not Specified
Σ Time Spent: Not Specified Time Spent: Not Specified
Σ Original Estimate: Not Specified Original Estimate: Not Specified

Issue Links:
dependency
depends upon PUBLISHING-164 Set information about node into conte... Closed
documentation
to be documented by DOCU-2609 Set information about node into conte... Closed
Sub-Tasks:
Key
Summary
Type
Status
Assignee
MGNLHOOK-283 Implementation Sub-task Completed Milan Divilek  
MGNLHOOK-284 review Sub-task Completed Robert Šiška  
MGNLHOOK-285 preintQA Sub-task Completed Javier Benito  
MGNLHOOK-286 QA Sub-task Completed Javier Benito  
MGNLHOOK-293 Port to master Sub-task Completed Milan Divilek  
Team: DeveloperX
Documentation update required:
Yes
Date of First Response:
Epic Link: Webhooks Maintenance (Phase 2)
Sprint: DevX 23
Story Points: 5

 Description   

 

From Partner:
Have I screwed something up or does the Webhooks module produce errors in admin when publishing a deletion?
I have a webhook on PUBLISH for assets and when I delete an asset and then click "publish deletion" I get an error and the underlying stacktrace suggests Magnolia's webhook stuff is trying to kick in
 
(Can't getJCRNode() for a deleted node)



 Comments   
Comment by Thomas Duffey [ 01/Nov/22 ]

Hi team, I seem to have mitigated this but am not sure which thing did it:

  1. Originally we had the webhook command in both the default publication command chain and also the versioned command chain. The latter calls on the former and this was causing the webhook to be triggered twice.
  2. We updated our webhook definition to use 
    setAsynchronous(false);
Comment by Milan Divilek [ 02/Nov/22 ]

tduffey Hi Thomas, I was able to reproduce the issue locally. It's caused by publication command chain. Publish command first deletes node (which is marked for deletion) and webhook command then tries to get it, but it doesn't exist in that moment because it was already removed by publish command.

We are working on fix

Generated at Mon Feb 12 10:02:27 CET 2024 using Jira 9.4.2#940002-sha1:46d1a51de284217efdcb32434eab47a99af2938b.