Details
-
Type:
Story
-
Status:
Ready for QA
-
Priority:
Major
-
Resolution: Unresolved
-
Affects Version/s: None
-
Fix Version/s: 6.2.0 CE M5
-
Component/s: WCM, WCM > Site and Page Templates
-
Labels:None
-
Similar Issues:Show 4 results
LPS-26881UndeclaredThrowableException when using site template and propagation enabled LPS-24098Site template propagation is not working when a portlet is moved LPS-25504Custom site page based on page template can be accidentally deleted when propagating changes from a site template LPS-27831Avoid propagating changes to all Sites just because I am a member of them when I change the Site Template
Description
The process to propagate changes from site or page templates has a mechanism to detect recurring problems and avoid trying to perform the propagation again and again in that situation.
But there is no way currently for the site administrator to detect and fix the situation, where merge of a page / site template was skipped, because it failed too many times previously.
The goal of this Story is to provide a UI that shows an indication of current merge fails for given layout / layout set and ideally possibility of request an propagation (resetting the internal count of failures to 0).
-
- Site Settings mockup.bmml
- 10/Jan/13 10:26 AM
- 6 kB
- Josef Šustáček
-
- Site Template mockup.bmml
- 10/Jan/13 10:33 AM
- 5 kB
- Josef Šustáček
-
Hide
- templates-breaker-portlet-6.2.0.1.war
- 24/Jan/13 4:13 PM
- 34 kB
- Josef Šustáček
-
- WEB-INF/.../TemplatesBreakerPortlet.class 9 kB
- WEB-INF/classes/.../Language.properties 0.6 kB
- WEB-INF/lib/portal-compat-client.jar 11 kB
- WEB-INF/liferay-display.xml 0.2 kB
- WEB-INF/liferay-plugin-package.properties 0.4 kB
- WEB-INF/liferay-portlet.xml 0.9 kB
- WEB-INF/portlet.xml 1 kB
- WEB-INF/src/.../TemplatesBreakerPortlet.java 9 kB
- WEB-INF/src/content/Language.properties 0.6 kB
- WEB-INF/tld/aui.tld 90 kB
- WEB-INF/tld/liferay-portlet-ext.tld 13 kB
- WEB-INF/tld/liferay-portlet.tld 4 kB
- WEB-INF/tld/liferay-security.tld 3 kB
- WEB-INF/tld/liferay-theme.tld 2 kB
- WEB-INF/tld/liferay-ui.tld 89 kB
- WEB-INF/tld/liferay-util.tld 3 kB
- css/.sass-cache/main.css 0.0 kB
- css/main.css 0.0 kB
- html/view.jsp 5 kB
- icon.png 0.5 kB
- js/main.js 0.0 kB
-
- page_template_1_before.png
- 140 kB
- 07/Jan/13 2:17 PM
-
- page_template_2_after.png
- 144 kB
- 07/Jan/13 2:17 PM
-
- site_template_1_before.png
- 146 kB
- 07/Jan/13 2:17 PM
-
- site_template_2_after.png
- 147 kB
- 07/Jan/13 2:17 PM
-
- site_template_3_after_failed.png
- 148 kB
- 07/Jan/13 2:17 PM
-
- Site Settings mockup.png
- 41 kB
- 10/Jan/13 10:26 AM
-
- Site Template mockup.png
- 31 kB
- 10/Jan/13 10:33 AM
Issue Links
- causes
-
LPS-33828
Adding a Page Template or a Site Template in Control Panel creates an exception
-
Activity
Hi Juan,
sure, I'll complete the steps a send to you i na while.
Thanks,
Josef
To test the displaying and Reset button, you have to fail some merges from site template. I'm sure there are many ways, this is what I've used for site templates testing:
(1) start Tomcat bundle
(2) create site based on template
(3) change page (e.g move portlet)
(4) reload the page in browser
(5) merge changes from template using button under Dockbar
(6) go to <tomcat>/temp/layou_set_prototype/, edit <uuid>.lar/manifest.xml (e.g. add some odd locale like '<header available-locales="bbb,ar_SA,...')
(7) change page (e.g move portlet)
(8) reload the page in browser
(9) merge changes from template using button under Dockbar – since template wasn't changes since #5, altered LAR will be used and its import will fail on LocaleException
(10) go to Site Template / <template> / Edit and you will see the Merge Failure Count risen and eventually (after its >= 3) warning box with Reset button will appear.
I haven't figured out an easy manual test scenario for Page Template failures, during testing I've used altered LayoutImporter class, always throwing my custom exception when page was about to me merged.
Hey Josef,
I agree with the issue you mention. My only concern is that putting this in the form for the site the way you've done it will make it confusing for people creating or editing the site and not visible enough for those who care about the problem.
One alternative I just thought of (so it might not be the best one either) is to show an smaller warning message next to the checkbox and text that says that the propagation is enabled. The text could just say "Disabled temporarily". This text would then be a link to a pop-up or an area that appears underneath which says something like "The propagation has been disabled temporarily after __ errors". Regarding the button to reset, I think it might be better to offer a button to force the propagation at that point in such a way so that we can show some more info about the error to the user.
What do you think?
Jorge
Hi Jorge,
I agree that the described, smaller message is Site Settings makes sense. I've created a mock to show how I understand it.
I've been thinking where to place the UI, whether to site administration itself, or the template administration. Both locations make sense to me, but template one a little bit more.
(1) Instead of just forced propagation, I'd reset the counter and then invoke a regular merge using com.liferay.portlet.sites.util.SitesUtil.mergeLayoutSetProtypeLayouts() resp. com.liferay.portlet.sites.util.SitesUtil.mergeLayoutProtypeLayout(). Those methods have so much code around the actual merge (timestamps, fail counter, locking etc.) The the code in those methods would need to be refactored and new method created, which would do just the merge and throw exception in case of any error. Then we would propagate this exception to the user (site admin, who invoked Reset & Merge).
(2) In case of Site Template, when site was changed, template is not applied any more, but Site Settings portlet does not indicate this (in comparison to Dockbar on the site, where you see the message of stopped propagation). Should the new warning message and Reset & Merge somehow reflect this (not being avaialble, or only with confirmation)?
(3) Should I change the UI in Site Templates portlet and Page Templates portlets to be the same, smaller, as in Site Settings? I can imagine the counter being hidden, till the threshold is met. Then small warning saying "Propagation Disabled Temporarily" will show up, being a link to similar pop-up as in Site Settings. The forced merge here may be a little problematic, since there may be many sites linking the template. Should the template be pushed to all linked sites? I'd prefer to leave just the counter Reset here, then the template will be merged lazily. Also as said in #2, some site my be linked but changed, making the link inactive, so forced push of template should be up to the site admin, not the template admin.
Thanks for your thoughts,
Josef
Shows new Proposed UI in Site Settings portlet, as suggested by Jorge.
Hey Josef,
I think the mockups look very good. Please go ahead and implement it. Feel free to send me the pr for review once you are done.
Hi Josef:
could you please:
1) Launch and fix ant format-source
2) rebase and resend
3) list the steps to reproduce this so that QA can test
4) Add two screenshots (before/after) so that PM can review
Thanks a lot,
Juan