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

Performance improvements in the Content Performance Panel

Description

    Performance improvement strategies

    CPP = Content Performance Panel

    Task 1 - Launch initial request on top bar button hover event, as we do in Page Audit panel

    Currently we are waiting for the component mounted event to request the data, causing a small visible delay.

    We can improve this experience by requesting the data on top-bar button hover event, as we do in Page Audit panel

    Task 2 - Avoid re-fetching unneeded data

    If a user visits any traffic channel details, ie. Referral, and then goes back to the main page of the CPP using the provided go-back button, 3 unneeded request are executed. The main component data should be already available in client side and the reload of this main view should happen with no delay for the user.

    Task 3 - Ungroup requests for Traffic Sources

    Currently, our trafficSources endpoint return all the payload in a single request:

    [
      {
        "name": "direct",
        "share": "100.0",
        "title": "Direct",
        "value": 11,
        "helpMessage": "This is the number of page views generated by people arriving directly to your page."
      },
      {
        "referringPages": [
          {
            "trafficAmount": 80,
            "url": "http://clara.com"
          },
          {
            "trafficAmount": 15,
            "url": "http://clara2.com"
          },
          {
            "trafficAmount": 5,
            "url": "http://clara3.com"
          }
        ],
        "referringDomains": [
          {
            "trafficAmount": 94,
            "url": "http://beltran2.com"
          },
          {
            "trafficAmount": 53,
            "url": "http://beltran3.com"
          },
          {
            "trafficAmount": 35,
            "url": "http://beltran1.com"
          }
        ],
        "name": "referral",
        "share": "40.0",
        "title": "Referral",
        "value": 100,
        "helpMessage": "This is the number of page views generated by people coming to your page from other sites which are not search engine pages or social sites."
      },
      {
        "name": "social",
        "share": "40.0",
        "title": "Social",
        "referringSocialMedia": [
          {
            "name": "twitter",
            "trafficAmount": 96,
            "title": "Twitter"
          },
          {
            "name": "facebook",
            "trafficAmount": 36,
            "title": "Facebook"
          },
          {
            "name": "instagram",
            "trafficAmount": 11,
            "title": "Instagram"
          }
        ],
        "value": 100,
        "helpMessage": "This is the number of page views generated by people coming to your page from social sites."
      },
      {
        "countryKeywords": [
          {
            "keywords": [
              {
                "searchVolume": 100,
                "position": 0,
                "keyword": "españa",
                "traffic": 200
              }
            ],
            "countryCode": "es",
            "countryName": "Spain"
          },
          {
            "keywords": [
              {
                "searchVolume": 100,
                "position": 0,
                "keyword": "englang",
                "traffic": 200
              }
            ],
            "countryCode": "en",
            "countryName": "EN"
          },
          {
            "keywords": [
              {
                "searchVolume": 100,
                "position": 0,
                "keyword": "french",
                "traffic": 200
              }
            ],
            "countryCode": "fr",
            "countryName": "France"
          }
        ],
        "name": "paid",
        "share": "40.0",
        "title": "Paid",
        "value": 100,
        "helpMessage": "This is the number of page views generated by people that find your page through Google AdWords."
      },
      {
        "countryKeywords": [
          {
            "keywords": [
              {
                "searchVolume": 100,
                "position": 0,
                "keyword": "españa",
                "traffic": 200
              }
            ],
            "countryCode": "es",
            "countryName": "Spain"
          },
          {
            "keywords": [
              {
                "searchVolume": 100,
                "position": 0,
                "keyword": "englang",
                "traffic": 200
              }
            ],
            "countryCode": "en",
            "countryName": "EN"
          },
          {
            "keywords": [
              {
                "searchVolume": 100,
                "position": 0,
                "keyword": "french",
                "traffic": 200
              }
            ],
            "countryCode": "fr",
            "countryName": "France"
          }
        ],
        "name": "organic",
        "share": "40.0",
        "title": "Organic",
        "value": 100,
        "helpMessage": "This is the number of page views generated by people coming from a search engine."
      }
    ]
    

    Only a tiny fraction of this info is needed to render the main view of the CPP.

    We should split this request in multiple ones, sliming down the first one with only the needed data, and requesting each traffic channel details on user's click event over the traffic channel link. 

    Task 4 - Avoid loading the Content Performance Panel portlet every time a page is loaded

    Currently every time a content page is loaded the AnalyticsReportsPortlet is loaded, so a dispatch is executed to the Portlet. This is a costly operation, so if we render the React component directly, we can save some important time 

     

    Attachments

      Issue Links

        Activity

          People

            clara.izquierdo Clara Izquierdo
            beltran.rengifo Beltran Rengifo
            Cristina Gonzalez Cristina Gonzalez
            Kiyoshi Lee Kiyoshi Lee
            Clara Izquierdo
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Packages

                Version Package
                Master