Expand my Community achievements bar.

SOLVED

Troubleshooting resource mapping

Avatar

Level 4

Hi,

We have a template page (let's call it templateA) where we have built pages with.  Let's say we have pages pageA and pageB.  The constructed page pageA works correctly.  All links (for eg. /content/global/en_us/index/solutions/index.html) are resource mapped correctly (eg /solutions/index.html).  However, the constructed page pageB works incorrectly.  All links do not get resource mapped.  We are trying to find out why this is happening.  We have tailed the logs and we did not find any errors that would indicate failure in the resource mapping.  We went to system/console/jcrresolver and paths are getting mapped.  We looked at the browser's developer console and there have been no errors.  Any advice on where else to look?

Thank You.

1 Accepted Solution

Avatar

Correct answer by
Employee

One other thing to look at is that if your HTML is really messy (broken/mismatched tags), then the HTML parser AEM uses while doing the link rewriting may fail. They way you could identify this is that if some of the links at the top of the page are rewritten, but at some point mid-way through the page the rewriting stops. Unfortunately, the parser doesn't log anything in these cases, mostly because it doesn't know that something has gone wrong.

I've run into this maybe twice in the last four years and have heard of one or two other cases where it happened.

View solution in original post

3 Replies

Avatar

Level 10

Voon Siong wrote...

Hi,

We have a template page (let's call it templateA) where we have built pages with.  Let's say we have pages pageA and pageB.  The constructed page pageA works correctly.  All links (for eg. /content/global/en_us/index/solutions/index.html) are resource mapped correctly (eg /solutions/index.html).  However, the constructed page pageB works incorrectly.  All links do not get resource mapped.  We are trying to find out why this is happening.  We have tailed the logs and we did not find any errors that would indicate failure in the resource mapping.  We went to system/console/jcrresolver and paths are getting mapped.  We looked at the browser's developer console and there have been no errors.  Any advice on where else to look?

Thank You.

 


Below are some commonly encountered

1)     You have mapping done at /etc/http/...  only for few host/ip and not all

2)      There might be custom extra configuration logic built in component to skip link checker

3)       If 5.6.1 make sure to install security fix has it includes some fixes related to resolver.

4)       Logs should give indication why it is skipping. Make sure logger set to right package.

Avatar

Correct answer by
Employee

One other thing to look at is that if your HTML is really messy (broken/mismatched tags), then the HTML parser AEM uses while doing the link rewriting may fail. They way you could identify this is that if some of the links at the top of the page are rewritten, but at some point mid-way through the page the rewriting stops. Unfortunately, the parser doesn't log anything in these cases, mostly because it doesn't know that something has gone wrong.

I've run into this maybe twice in the last four years and have heard of one or two other cases where it happened.

Avatar

Level 4

Thank You Justin.  We removed the component with text content and the page rendered links correctly.  We are asking the content author to review the text/html they are putting in to make sure they are all well formed.