acs-aem-commons icon indicating copy to clipboard operation
acs-aem-commons copied to clipboard

Feature Review :: Add dashboard to manage Sling vanity paths

Open juan-ayala opened this issue 3 years ago • 3 comments

Currently, there are 2 features that allow content authors to manage redirects

  • Redirect Manager
  • Redirect Map Manager

The first one uses a Sling filter while the second one writes Apache config files. That makes this one not compatible with AEMaaCS. These two features are good in their own ways. There is a third option with the Vanity Path Configuration.

With these page properties, redirects can be done. i.e. 301/302 or internal. They have one shortcoming. They are at the page level and AFAIK there is no global dashboard to bulk-edit them.

Before I get started on some serious research and a POC; can anyone think why a dashboard to manage these properties would be a bad idea? Or is there anything out there already that I've missed?

juan-ayala avatar Feb 25 '22 23:02 juan-ayala

Vanity paths at scale will severely degrade AEM startup.

Another concern is around the universality of sling vanities, that is tougher to combat since it's baked into sling. Meaning that each vanity path should be unique for all of AEM regardless of number of tenants, else resolution of the resource will appear random.

that said, I think a dashboard helps alleviate both of these issues as it provides visibility into the vanities which other wise requires looking at a bunch of page properties.

davidjgonzalez avatar Feb 26 '22 02:02 davidjgonzalez

The sling:vanityPath property seems to be indexed. Writing a servlet or whatever to generate dashboard data should not be a problem. Do you know of anything else in the Sling or JCR API that would let me get the vanity mappings?

juan-ayala avatar Feb 26 '22 19:02 juan-ayala

I'm not aware of any APIs to pull them - a bloom filter is populated on startup, but that's not necessarily complete.

I think just querying on it would be the way to do it, and as you note the there's an index for it it should be fine if you paginate results or filter by the path they resolve to (aka the path they're set on).

davidjgonzalez avatar Feb 26 '22 23:02 davidjgonzalez