Tenant-specific vanity URLs with AEM

AEM is capable of managing thousands of domains with one instance. But one common pain point is that vanity URLs are not tenant-specific but global for all domains. This is caused by the underlying Sling framework that manages sling:vanityPath without context.

This talk will present solutions on how to manage vanity URLs with multiple domains in a seamless way for the editors.

Henry Kuijpers

There is an in-memory cache in the Dispatcher, which contains all the vanity paths that are requested from AEM (/vanity_urls) - How will this cache still function, if all your vanity paths have /content/something in front of it?

Henry Kuijpers

That answer was not correct: The vanitys still work, but the Dispatcher will not find a match for the URL in its in-memory list of known vanity paths.

Alexander

What is the difference from ACS Commons Redirect Manager? Is it only the prefix handling?

Barry

when a page moves the entries in the redirect manager are not updated, with a vanity path its tightly coupled to the page

Henry Kuijpers

What if your request comes in in AEM as "domain.com/vanity", instead of "domain.com/content/something/vanity"? Then this will not work?

RolandGruber

Yes, AEM resolves vanity paths before Sling Mappings. Therefore, prefixes must be added in dispatcher already.

apelluru

Does this tool will help editors to prevent the duplicates? E.g. vanity URL is already defined somewhere in site tree, but editor is trying to add in different location

(see answer in talk video)

Henry Kuijpers

What's the difference between this and the "Vanity Path Rewrite Mapper"? https://adobe-consulting-services.github.io/acs-aem-commons/features/vanity-path-rewrite-mapper/ ? (Which we also can't use in our case,s ince we don't have /content/something/ prepended to our path.

RolandGruber

The ACS approach is a bit different. Actually, it removes the prefix on publish. It also does not support the editors for multidomain.

Would you be able to make this work with cross-domain vanity URLs? e.g. request on www.site.com/jobs that is actually handled by www.site.us/en-us/careers/jobs
(see answer in talk video)

Vugar Aghayev

How you make sure that the prefixes are unique as the editors can add the same prefix in another market? Can’t we use the site structure somehow automatically derive the prefix for a given market?

(see answer in talk video)