Uploaded image for project: 'PUBLIC - Liferay Portal Community Edition'
  1. PUBLIC - Liferay Portal Community Edition
  2. LPS-93384

Remove unnecessary "synchronized" block from PortletSharedTaskExecutorImpl

    Details

    • Type: Task
    • Status: Open
    • Priority: Minor
    • Resolution: Unresolved
    • Affects Version/s: 7.1.X, Master
    • Fix Version/s: None
    • Labels:
      None

      Description

      There is a different "renderRequest" instance for each portlet on a page (per each user request thread) so we should remove the "synchronized" block from https://github.com/liferay/liferay-portal/blob/master/modules/apps/portal-search/portal-search-web/src/main/java/com/liferay/portal/search/web/internal/portlet/shared/task/PortletSharedTaskExecutorImpl.java#L50-L64 because it does not really do anything.

      The key here is the requestSharedAttribute which sets an attribute on the actual httpServletRequest instance (which is the same across thread for all portlets) and that ensures that we execute it only once, not the sync block.

        Attachments

          Activity

            People

            • Assignee:
              support-lep@liferay.com SE Support
              Reporter:
              tibor.lipusz Tibor Lipusz
              Recent user:
              André Ricardo Barreto de Oliveira
              Participants of an Issue:
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:

                Packages

                Version Package