[MAGNOLIA-6527] Deletion of a hot fix configuration is not picked up Created: 01/Feb/16 Updated: 05/May/20 Resolved: 31/Jan/18 |
|
| Status: | Closed |
| Project: | Magnolia |
| Component/s: | configuration, resource-loader |
| Affects Version/s: | 5.4.14, 5.5.8, 5.6.1 |
| Fix Version/s: | 5.4.15, 5.5.9, 5.6.2 |
| Type: | Bug | Priority: | Neutral |
| Reporter: | Roman Kovařík | Assignee: | Federico Grilli |
| Resolution: | Fixed | Votes: | 2 |
| Labels: | support | ||
| Remaining Estimate: | 0d | ||
| Time Spent: | 1.75d | ||
| Original Estimate: | Not Specified | ||
| Attachments: |
|
||||||||||||||||||||||||||||
| Issue Links: |
|
||||||||||||||||||||||||||||
| Template: |
|
||||||||||||||||||||||||||||
| Acceptance criteria: |
Empty
|
||||||||||||||||||||||||||||
| Task DoD: |
[ ]*
Doc/release notes changes? Comment present?
[ ]*
Downstream builds green?
[ ]*
Solution information and context easily available?
[ ]*
Tests
[ ]*
FixVersion filled and not yet released
[ ] 
Architecture Decision Record (ADR)
|
||||||||||||||||||||||||||||
| Bug DoR: |
[ ]*
Steps to reproduce, expected, and actual results filled
[ ]*
Affected version filled
|
||||||||||||||||||||||||||||
| Release notes required: |
Yes
|
||||||||||||||||||||||||||||
| Documentation update required: |
Yes
|
||||||||||||||||||||||||||||
| Date of First Response: | |||||||||||||||||||||||||||||
| Epic Link: | deletionOfHotfix | ||||||||||||||||||||||||||||
| Sprint: | Basel 131, Basel 132 | ||||||||||||||||||||||||||||
| Story Points: | 3 | ||||||||||||||||||||||||||||
| Description |
|
To reproduce (with no active subscriber):
After some further investigation, the issue apparently affects only configuration files, not templates, as one can see in the attached screencast where we tried to reproduce the issue. In particular, after removing a hot fix, the original configuration is not reloaded at YamlConfigurationSource#loadAndRegister. That should be triggered at LayeredResourceOrigin.RelayingChangeHandler#onResourceChange starting at line#294 but the condition to trigger the onResourceChanged method is never met. |
| Comments |
| Comment by Tomáš Gregovský [ 17/Jan/18 ] |
|
probably similar to https://jira.magnolia-cms.com/projects/CLOUDHELP/issues/CLOUDHELP-62 |
| Comment by Thomas Duffey [ 18/Jan/18 ] |
|
Note the same issue happens if you have subscribers as well. Big problem, essentially means we can't use hotfixing. |
| Comment by Federico Grilli [ 25/Jan/18 ] |
|
I wasn't able to reproduce the issue on the latest releases of the three supported Magnolia versions, i.e. 5.6.1, 5.5.8 and 5.4.14. The issue was likely cured by See also attached screencast where I try to reproduce this on latest Magnolia |
| Comment by Federico Grilli [ 25/Jan/18 ] |
|
To complete what I wrote above and which is not shown in the screencast, I also tested the case with an active subscriber and the edited resource marked as deleted (so no actual deletion occurred yet). In that case too, changes in the template were gone. As usual, feel free to reopen the issue if I missed something or if the issue persists also after updating to the latest Magnolia supported release. |
| Comment by Thomas Duffey [ 25/Jan/18 ] |
|
Frederico did you try hotfixing a YAML file from a light module? This blows it up every time for us on 5.4.14. For example, just changing the template name. Also you didn't publish the deletion which is when things go bad for us. |
| Comment by Federico Grilli [ 25/Jan/18 ] |
|
tduffey thanks for the additional input. I tried publishing the deletion (not shown in the video) and apparently it worked fine. However, I haven't tried to hot fix a resource from a light module so I'm going to reopen the ticket and look into it further. |
| Comment by Thomas Duffey [ 25/Jan/18 ] |
|
Federico I also added a screencast to our related support ticket: SUPPORT-8290 |
| Comment by Thomas Duffey [ 03/Feb/18 ] |
|
Federico, just upgraded to 5.4.15 and still seeing same issue |
| Comment by Federico Grilli [ 04/Feb/18 ] |
|
Hi tduffey maybe that's because you did not publish the deletion? Caveat: in case of an active receiver/publisher, deleting the hot fix w/o publishing won't result in a resource modification, hence a rendering error will be thrown if one tries to open a page affected by the configuration file. Not nice but correct, as only publishing will trigger the JCR removed event and, as a consequence, configuration will be reloaded with the original resource. |
| Comment by Thomas Duffey [ 05/Feb/18 ] |
|
Hi Federico, you are right that the issue appears when we have not yet published the deletion. When the hotfix is marked as deletion we should still be able to preview pages using that template on author so that we can confirm the underlying YAML file has been updated to include the fix and so we can safely publish deletion of the hotfix. I tried the same steps on the demo instance running 5.6.1 and seems fine there. |
| Comment by Federico Grilli [ 05/Feb/18 ] |
|
Hmm, the issue is affecting 5.6.x too, as far as I can see on our demo instance. Regardless of whether you publish a deletion or not, a rendering error occurs, as the underlying configuration file isn't reloaded. The fix has actually been ported from 5.6.x to 5.4.x and 5.5.x. The "marked as deleted" is just a state added by Magnolia in a JCR node publication process which is not aware of the resource loading mechanism. |
| Comment by Federico Grilli [ 05/Feb/18 ] |
|
A co-worker is pointing me to this issue MAGNOLIA-6528. I'll link it to this one. |