Description of problem: Platform issue for https://issues.jboss.org/browse/GTNPORTAL-2072 Version-Release number of selected component (if applicable): How reproducible: Always Steps to Reproduce: 1) Login and go to Group -> Administration -> Site Export/Import. (If this is not a fresh install, add the Export/Import gadget to a page on the portal). 2) Expand the sites and portal nodes in the tree nav on the left. Select the site classic, hit the export button, and save the zip file to local filesystem. 4) Hit the import link and upload zip file previously exported. Check the overwrite existing data checkbox, and hit the import button. 5) Navigate back to the home page. Click Edit Page, you should see errors and similar stacktrace in server logs. Actual results: 'Unknown Error' popup and ERROR in the log: Caused by: org.exoplatform.portal.config.NoSuchDataException: Can not find 1c42bec77f0000011076449207f5d085 at org.exoplatform.portal.pom.config.POMSession.findCustomizationById(POMSession.java:214) at org.exoplatform.portal.pom.config.tasks.PreferencesTask$Load.run(PreferencesTask.java:91) at org.exoplatform.portal.pom.config.POMSession.execute(POMSession.java:405) Expected results: UI cache should be cleared automatically, and no error should be presented to the user Additional info:
Trong Tran <trongtt> made a comment on jira GTNPORTAL-2072 Could you review it, Nick ?
Trong Tran <trongtt> made a comment on jira GTNPORTAL-2072 Could you review the PR, Nick ?
Nick Scavelli <nscavell> made a comment on jira GTNPORTAL-2072 Currently reviewing. Looks like I'm not getting any errors, which is good. But I can also see that my page is not updated anymore. I believe it was able to update the page, even though an exception was thrown. For example if I export the classic site, add a portlet to the homepage, import the exported site (with overwrite), I believe I was able to see that the portlet I added to be removed. If I got to edit that page, it then gets removed. I would say it's a step further, going to investigate if we can get better.
Nick Scavelli <nscavell> made a comment on jira GTNPORTAL-2072 [~phuong_vu] I missed your one comment, yea let's handle the cache in POMSessionManager too. I think this is the main usecase actually. When data is saved through backend services, and not the UI, the UI should be able to see non stale data. I think this what the customer is actually after in https://bugzilla.redhat.com/show_bug.cgi?id=1038029
Nick Scavelli <nscavell> made a comment on jira GTNPORTAL-2072 I'm not getting the exception, so I think this is good. Will open another to see if we can handle the stale cache in POMSessionManager. I think this PR is good to go.
Proposed solution is to manually clear the POMSessionManager cache. If there's stale data, then the user will see a display message that they need to refresh the browser. After refreshing they should see the new content. In light of this change I am also adding the ability to clear the POMSessionManager cache for import, so users don't need to log out, and rather refresh to see new changes. Martin will this suffice with the customer ?
I'm closing this - please reopen if this resolution is not enough. However at the moment it is rather hard for us to go any further than that.
The upstream PR was merged to master but there conflicts when cherry-picking the master PR to 3.6.x. I do not feel self-confident enough to resolve them. Nick, could you please have a look (read: prepare a new PR against 3.6.x branch)? It is this commit in master: ba5f44ceb39c5d212039c8e97cf7c8064ffb5f10
Peter Palaga <ppalaga> made a comment on jira GTNPORTAL-2072 Keeping open as it was fixed in 3.7.0 only but the fix for 3.6.x is still pending.
Fixed in both 3.7.0 and 3.6.x now.