-
Type:
Bug
-
Status: Closed
-
Resolution: Fixed
-
Affects Version/s: 7.0.0 DXP GA1, 7.0.X, Master
-
Fix Version/s: 7.0.0 DXP FP36, 7.0.0 DXP SP7, 7.0.5 CE GA6, 7.0.X, 7.1.0 M1, 7.1.X, Master
-
Component/s: Calendar
-
Branch Version/s:7.0.x
-
Backported to Branch:Committed
-
Fix Priority:3
-
Git Pull Request:
After portlet removal, Calendar is not destroying a javascript poller code that requests current time to server once per minute
The code that request the time to server was added in LPS-65412
This issue is also reproduced in case of having SPA enabled and moving from a page with a calendar to other page without any calendar. The requests that get current time from server will be executed without having calendar and a warning trace will be written to liferay log
Steps to reproduce
- Create a new page
- Install Calendar in new page
- Open it in "Day" or "Week" view
- Stay in the new page and open browser "Developer tools" => "Network" tab
- Wait two or three minutes
- You will view a request to following URL once a minute
/c/portal/layout?p_l_id={PLID}&p_p_cacheability=cacheLevelPage&p_p_id=com_liferay_calendar_web_portlet_CalendarPortlet_INSTANCE_xxxxxxxxxxxx&p_p_lifecycle=2&p_p_resource_id=currentTime
- That requests are also written in tomcat log file localhost_access_log.2017-xx-xx.txt
- Remove Calendar from page
- Wait two or three minutes
- Open browser "Developer tools" => "Network" tab and check again the requests to /c/portal/layout
- Expected behavior: No requests to /c/portal/layout are done after removing Calendar portlet. No warnings are written to liferay log
- Wrong behavior: Requests to /c/portal/layout are done after removing Calendar portlet and they return error "400 bad request". A warning is written to liferay log for each request
2017-12-16 07:54:05.054 WARN [http-nio-9080-exec-5][SecurityPortletContainerWrapper:408] Reject serveResource for /c/portal/layout on com_liferay_calendar_web_portlet_CalendarPortlet_INSTANCE_IRFANkP9ogmH
- Expected behavior: No requests to /c/portal/layout are done after removing Calendar portlet. No warnings are written to liferay log
- You can also check the requests in localhost_access_log.2017-xx-xx.txt file