Uploaded image for project: '[Read Only] - Hippo Site Toolkit 2'
  1. [Read Only] - Hippo Site Toolkit 2
  2. HSTTWO-4557

HstRequestContext#isCmsRequest (and setCmsRequest) have a confusing and outdated name

    XMLWordPrintable

Details

    • Improvement
    • Status: Closed
    • High
    • Resolution: Fixed
    • 13.1.0
    • 13.2.0
    • None
    • None

    Description

      A lot of code in the HST rely on whether the request is a cms request or not, for example

      if (requestContext.isCmsRequest()) {
                  hstSite = channelManagerHstSiteProvider.getHstSite(compositeHstSite.getMaster(), compositeHstSite.getBranches(), requestContext);
              } else {
                  final CustomWebsiteHstSiteProviderService customWebsiteHstSiteProviderService = HippoServiceRegistry.getService(CustomWebsiteHstSiteProviderService.class);        
      

      This is however very confusing since version 13.0.0 : For example all HST requests via the platform webapp (/cms) are NOT cms requests! They are just plain HST requests that happen to go over the /cms webapp. What 'isCmsRequest' really means is that an HST Site webapp is hit (for example /site) OVER the host of the CMS : Aka, it is a 'channel manager preview request'!! A channel mgr preview request must for example decorate Mounts to the preview mount. A request over the cms webapp, for example /cms/_rp never needs decorated mounts. Hence, we should deprecate #isCmsRequest and give it a proper name since it is so confusing now and results in bugs because the behavior is different than people expect from the name

      Before 13.0.0, there was no confusion since the /cms webapp did not contain the HST

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              aschrijvers Ard Schrijvers
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: