Expand my Community achievements bar.

Dive into Adobe Summit 2024! Explore curated list of AEM sessions & labs, register, connect with experts, ask questions, engage, and share insights. Don't miss the excitement.
SOLVED

AEM Dispatcher not resolving vanity urls

Avatar

Level 2

Hi there,

I'm trying to set up our dispatcher to resolve the vanity urls we have set up in our publisher.  However, after following the configuration guide, when I try to hit a vanity url, I'm getting a 404 error rather than the page itself.

Here's a snippet from our dispatcher.any configuration:

Here's what I see in the dispatcher.log when I try to hit my vanity url:

It looks like it's trying to get to the /home vanity url after the filter rejects it, but nothing ever shows up.  When I look at the access.log on the publisher, I don't see any requests for the vanityUrls.html from the dispatcher.

Any help you could provide would be much appreciated!

Thanks!

1 Accepted Solution

Avatar

Correct answer by
Level 2

I believe this is now fixed. It turns out the documentation on the dispatch configuration (Configuring Dispatcher - docs.adobe.com ) has a typo in the first example configuration, where it lists the entry as "/vanity-urls".  However, later on in the vanity urls section (https://docs.adobe.com/content/docs/en/dispatcher/disp-config.html#Enabling Access to Vanity URLs - /vanity_urls), it's listed as "/vanity_urls".  The proper configuration is indeed with the underscore and not the hyphen (i.e. /vanity_urls). 

View solution in original post

5 Replies

Avatar

Employee

Few things to check :

- Bypass the dispatcher and see if the vanity urls work or not ? If they do, issue lies on the webserver configuration

- Hit the vanity url via the dispatcher and check if any rewrite rules are changing the url before it actually goes to the dispatcher

- Quick test would be switch off the mod_rewrite and see if the vanity urls work or not ?

Avatar

Level 2

- I'm able to access the vanity urls if I bypass the dispatcher and go straight to the Publisher.  I know it has something to do with the webserver config but just trying to see what it could be.

- how would I switch off the mod_rewrite to do the quick test? Based on the dispatcher log, it seems like it's trying to go to my vanity url (/home) even after the filter, so it seems like it's checking the vanity urls file.  However, like I said, the access.log on the publisher never shows the dispatcher getting the vanityUrls.html from it.

Avatar

Level 2

Looking at the dispatcher log, I'm seeing that the vanity-urls entry in the dispatcher.any file is not being recognized.

That would explain why it's not making the call to the publisher.  Any reason you can think of as to why this warning is showing?

Avatar

Administrator

Jörg Hoh Any hey here?

~kautuk



Kautuk Sahni

Avatar

Correct answer by
Level 2

I believe this is now fixed. It turns out the documentation on the dispatch configuration (Configuring Dispatcher - docs.adobe.com ) has a typo in the first example configuration, where it lists the entry as "/vanity-urls".  However, later on in the vanity urls section (https://docs.adobe.com/content/docs/en/dispatcher/disp-config.html#Enabling Access to Vanity URLs - /vanity_urls), it's listed as "/vanity_urls".  The proper configuration is indeed with the underscore and not the hyphen (i.e. /vanity_urls).