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

HstLinkResolver.resolveAllCanonicals() should not log warning when no links can be created

    XMLWordPrintable

Details

    • Bug
    • Status: Closed
    • Normal
    • Resolution: Fixed
    • None
    • 2.24.00
    • None
    • None

    Description

      The method HstLinkResolver.resolveAllCanonicals() logs a warning when no canonical links can be created. However, returning an empty list is a valid state and should not cause a warning.

      For example, the documents 'comments' and 'reviews' in GoGreen do not have a dedicated sitemap item. When such a document is viewed in the CMS, the 'View' menu performs a REST call to get the canonical links for all channels. That call uses HstLinkResolver.resolveAllCanonicals(), which then logs a warning. As a result, a warning is logged whenever a 'comment' document is viewed in the CMS.

      Steps to reproduce:
      1. log in to the GoGreen CMS
      2. open a comment document in the folder 'Hippo Go Green -> Comments -> News -> solar-power-the-skys-the-limit'

      Expected behavior: no warning is logged
      Actual behavior: the following warning is logged:

      WARN [org.hippoecm.hst.core.linking.DefaultHstLinkCreator$HstLinkResolver.resolveAllCanonicals():662] Cannot create a link for node with path '/content/documents/hippogogreen/comments/news/solar-power-the-skys-the-limit/Comment on solar-power-the-skys-the-limit 2010-07-30 12.53.10.447'. Return empty list for canonicalLinks.

      Attachments

        Activity

          People

            jsheriff Junaidh Kadhar Sheriff
            mdenburger Mathijs den Burger (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: