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

Can not use unstaged segments to create experiences in the staging environment



      When staging is activated in a site, segments are unstaged by default. This way, the segments are the same for both the live and the staging environments.

      In this setup, there is a strange behavior, which can be reproduced as follows:

      1. Create a site
      2. Create 2 segments seg1 and seg2 in the site
      3. Create a content page cp1 in the site
      4. Add a text fragment to cp1, write "default" in it. Publish cp1
      5. Create a new experience for cp1. Name it exp1 and select seg1 for the Audience field
      6. In the text fragment, write "segment 1". Publish cp1
      7. Checkpoint: you can switch default and exp1 experiences, cp1 reflects the differences
      8. Enable staging in that site. (Note: ensure "Segments" checkbox remains unchecked, that's the default)
      9. Go to staging site. Visit cp1.
      10. Create a new experience for cp1
      11. Go to the Audience drop down, click on it to select the audience

       Observed: only seg1 is available for selection

       Expected: both seg1 and seg2 are available, or, if seg1 is already part of an existing experience for cp1, only seg2 is available.

      As a result, It is not possible to create new experiences based off on "unused" segments when working in the staging environment.

      If we assume that site authors are interested in previewing all the experiences for a content page in the staging environment before publishing it to live, the reported behavior shall be considered a bug. This is even more clear if one considers that content pages can not be edited in the live environment, which implies that, in practise, it's not possible to use segments which were not part of the initial publication process. Finally, segments are being duplicated in both groups (staging & live), which goes against the settings used to activate staging.

      Possible explanation: system looks for the segments using the stagingGroupId even if segments are not staged. In the staging activation process, existing experiences were transferred to the staging environment, making a copy of seg1 in that environment (I've checked this in the DB). This should not happen as segments are not staged 

      In case of this being the expected behavior, then we shall remove the option of selecting "Segments" in the staging configuration as their participation in the staging process would be mandatory, very much as content pages and experiences are.





            • Assignee:
              daniel.sanz Daniel Sanz
              daniel.sanz Daniel Sanz
              Participants of an Issue:
              Recent user:
              Jason Pince
            • Votes:
              0 Vote for this issue
              0 Start watching this issue


              • Created:
                Days since last comment:
                35 weeks, 4 days ago


                Version Package
                7.3.0 CE GA1