Interesting New Feature in CQ 5.3

So I’m on-site with a client in Phoenix, and I was directed to perform a “test-upgrade” to their CQ 5.2.1 code, to see how smooth the upgrade to 5.3 would be. It was a pretty good experience all-in-all, but I thought I would share a couple minor hiccups with the audience, just in case they may save some of you some time and frustration later.

  1. If you have custom templates built (which for sure most of you do, unless you are starting from scratch in 5.3), don’t forget to add the “allowedPaths” property to the template folder (NOT the jcr:content node) via the CRX Explorer…otherwise your template will not appear in the “New Page” dialog in the WCM. This property should be of type “String []” and you can add as many values as you want…the values should be regular expressions and a typical value (that allows the template to be placed anywhere below “/content/”) would be “/content(/.*)?”.
  2. Note that the method for configuring the Sling Resource Resolver has changed. If you do have custom mappings defined under “/system/console/configMgr/” the upgrade process will automatically try to create the new configuration for you, but it will fail to add a key property with its default values. So what you need to do is the following:
    1. Go into the CRX Explorer, navigate to “/apps/sling/config/”
    2. under that node you should see a node called “org.apache.sling.jcr.resource.internal.JcrResourceResolverFactoryImpl”. If you click on that node, you should see a property called “resource.resolver.mapping” which should contain your custom mapping values from your 5.2.1 install.
    3. Add a new property to this node called “resource.resolver.searchpath” the property should be of type “String []”.
    4. Add the following values to this property IN ORDER: “/apps”, “/libs”, “/apps/foundation/components/primary” and “/libs/foundation/components/primary”.

The above steps should fix the following issues:

  1. Not seeing your custom templates in the “New Page” dialog, despite your code being installed in the instance.
  2. Getting either a 403 Forbidden, a 404 Not Found, or a “This page is not redirecting properly” error, when trying to load a content page which you KNOW already exists in the WCM.

Cheers!

Leave a Reply

You must be logged in to post a comment.