Your achievements

Level 1

0% to

Level 2

Tip /
Sign in

Sign in to Community

to gain points, level up, and earn exciting badges like the new
BedrockMission!

Learn More

View all

Sign in to view all badges

Resource Mapping in AEM 6.4 Just Not Working

Avatar

Avatar
Validate 1
Level 1
timr69563937
Level 1

Likes

0 likes

Total Posts

14 posts

Correct Reply

1 solution
Top badges earned
Validate 1
Ignite 1
Give Back 3
Give Back
Affirm 1
View profile

Avatar
Validate 1
Level 1
timr69563937
Level 1

Likes

0 likes

Total Posts

14 posts

Correct Reply

1 solution
Top badges earned
Validate 1
Ignite 1
Give Back 3
Give Back
Affirm 1
View profile
timr69563937
Level 1

21-09-2018

I am trying to use resource mapping to handle roots for multiple domains in our AEM 6.4 platform, and it's just not working. It seems like they're just ignored.

For example....

https://domain123.com/content/site123/us/en/ (works)

https://domain123.com/ (mapped to path above, throws 404)

So the domain is getting through the dispatcher to the AEM publish instances, but the mapping never kicks in. The only thing I see in the access_log is for the domain root showing a 404 response. Am I missing something? Is there some checkbox to enable something hidden in some configuration dialog somewhere?

Tim

Replies

Avatar

Avatar
Coach
MVP
Arun_Patidar
MVP

Likes

1,279 likes

Total Posts

3,156 posts

Correct Reply

889 solutions
Top badges earned
Coach
Contributor 2
Ignite 10
Give Back 700
Boost 1000
View profile

Avatar
Coach
MVP
Arun_Patidar
MVP

Likes

1,279 likes

Total Posts

3,156 posts

Correct Reply

889 solutions
Top badges earned
Coach
Contributor 2
Ignite 10
Give Back 700
Boost 1000
View profile
Arun_Patidar
MVP

23-09-2018

Hi,

Can you share mapping configuration with node structure?

For more info how to create mappings you can check Creating Mapping Definitions in AEM section in below article:

Resource Mapping

Avatar

Avatar
Validate 1
Level 1
timr69563937
Level 1

Likes

0 likes

Total Posts

14 posts

Correct Reply

1 solution
Top badges earned
Validate 1
Ignite 1
Give Back 3
Give Back
Affirm 1
View profile

Avatar
Validate 1
Level 1
timr69563937
Level 1

Likes

0 likes

Total Posts

14 posts

Correct Reply

1 solution
Top badges earned
Validate 1
Ignite 1
Give Back 3
Give Back
Affirm 1
View profile
timr69563937
Level 1

24-09-2018

Well, I have tried many different variations. Let's look at this one for now. I am trying to use the default AMS URL, because our custom dev domain is internal-only DNS.

So this is the target that should come up when you hit the root....

Claims

This is the root, which should map to the above location but gets a 404....

https://aig-dev64.adobecqms.net/

Here is the mapping in CRXDE....

resource-mapper.png

Avatar

Avatar
Validate 25
Level 10
smacdonald2008
Level 10

Likes

1,406 likes

Total Posts

12,671 posts

Correct Reply

2,278 solutions
Top badges earned
Validate 25
Validate 10
Validate 1
Give back 900
Give back 600
View profile

Avatar
Validate 25
Level 10
smacdonald2008
Level 10

Likes

1,406 likes

Total Posts

12,671 posts

Correct Reply

2,278 solutions
Top badges earned
Validate 25
Validate 10
Validate 1
Give back 900
Give back 600
View profile
smacdonald2008
Level 10

24-09-2018

This node looks like it contains all information documented here:

Configuring an Internal Redirect to /content

To create the mapping that prefixes any request to http://localhost:4503/ with /content:

  1. Using CRXDE navigate to /etc/map/http.
  2. Create a new node:
    • Type sling:Mapping
      This node type is intended for such mappings, though its use is not mandatory.
    • Name localhost_any
  3. Click Save All.
  4. Add the following properties to this node:
    • Name sling:match
      • Type String
      • Value localhost.4503/
    • Name sling:internalRedirect
      • Type String
      • Value /content/
  5. Click Save All.

I see the correct node type and the correct node structure. 

I have asked a few internal ppl to look here.

Avatar

Avatar
Validate 25
Level 10
smacdonald2008
Level 10

Likes

1,406 likes

Total Posts

12,671 posts

Correct Reply

2,278 solutions
Top badges earned
Validate 25
Validate 10
Validate 1
Give back 900
Give back 600
View profile

Avatar
Validate 25
Level 10
smacdonald2008
Level 10

Likes

1,406 likes

Total Posts

12,671 posts

Correct Reply

2,278 solutions
Top badges earned
Validate 25
Validate 10
Validate 1
Give back 900
Give back 600
View profile
smacdonald2008
Level 10

24-09-2018

Check request log file to see if there are more details.

Avatar

Avatar
Validate 1
Level 1
timr69563937
Level 1

Likes

0 likes

Total Posts

14 posts

Correct Reply

1 solution
Top badges earned
Validate 1
Ignite 1
Give Back 3
Give Back
Affirm 1
View profile

Avatar
Validate 1
Level 1
timr69563937
Level 1

Likes

0 likes

Total Posts

14 posts

Correct Reply

1 solution
Top badges earned
Validate 1
Ignite 1
Give Back 3
Give Back
Affirm 1
View profile
timr69563937
Level 1

24-09-2018

All I see in the request log is the 404 for the root....

10.4.0.29 - - [24/Sep/2018:07:58:22 -0700] "GET / HTTP/1.1" 404 198 "-" "Mozilla/5.0 (Windows NT 6.1; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/68.0.3440.106 Safari/537.36"

Avatar

Avatar
Give Back 5
Level 4
aneeta45259594
Level 4

Likes

46 likes

Total Posts

67 posts

Correct Reply

27 solutions
Top badges earned
Give Back 5
Give Back 3
Give Back 10
Give Back
Boost 5
View profile

Avatar
Give Back 5
Level 4
aneeta45259594
Level 4

Likes

46 likes

Total Posts

67 posts

Correct Reply

27 solutions
Top badges earned
Give Back 5
Give Back 3
Give Back 10
Give Back
Boost 5
View profile
aneeta45259594
Level 4

24-09-2018

Hello timr69563937

One main observation here is that you have a http mapping and you're hitting a https URL. Clearly the HTTPS is getting terminated at the Load Balancer but AEM doesn't know about it. Therefore, AEM tries to map it exactly and as it doesn't find a https mapping for https://aig-dev64.adobecqms.net/ , it errors out with a 404.

You need to do two things

1) Create an https mapping instead. Basically, in your /etc/map, create a https folder with the same set of mappings as http

2) Go to https://host:port/system/console/configMgr/org.apache.felix.http and Enable the setting Enable Proxy/Load Balancer Connection.

See AEM redirecting user back to http if accessed through SSL terminated Load Balancer for more information.

Best Regards,

Aneet Arora

Avatar

Avatar
Validate 25
Level 10
smacdonald2008
Level 10

Likes

1,406 likes

Total Posts

12,671 posts

Correct Reply

2,278 solutions
Top badges earned
Validate 25
Validate 10
Validate 1
Give back 900
Give back 600
View profile

Avatar
Validate 25
Level 10
smacdonald2008
Level 10

Likes

1,406 likes

Total Posts

12,671 posts

Correct Reply

2,278 solutions
Top badges earned
Validate 25
Validate 10
Validate 1
Give back 900
Give back 600
View profile
smacdonald2008
Level 10

24-09-2018

Excellent response!

Avatar

Avatar
Validate 1
Level 1
timr69563937
Level 1

Likes

0 likes

Total Posts

14 posts

Correct Reply

1 solution
Top badges earned
Validate 1
Ignite 1
Give Back 3
Give Back
Affirm 1
View profile

Avatar
Validate 1
Level 1
timr69563937
Level 1

Likes

0 likes

Total Posts

14 posts

Correct Reply

1 solution
Top badges earned
Validate 1
Ignite 1
Give Back 3
Give Back
Affirm 1
View profile
timr69563937
Level 1

24-09-2018

Thanks, but this doesn't seem to make any difference. Tried with both http and https nodes and with just the https node. I see the same behavior.

Avatar

Avatar
Coach
MVP
Arun_Patidar
MVP

Likes

1,279 likes

Total Posts

3,156 posts

Correct Reply

889 solutions
Top badges earned
Coach
Contributor 2
Ignite 10
Give Back 700
Boost 1000
View profile

Avatar
Coach
MVP
Arun_Patidar
MVP

Likes

1,279 likes

Total Posts

3,156 posts

Correct Reply

889 solutions
Top badges earned
Coach
Contributor 2
Ignite 10
Give Back 700
Boost 1000
View profile
Arun_Patidar
MVP

25-09-2018

Hi,

Root Level Mappings apply to the request at large including the scheme, host, port and uri path. To accomplish this a path is constructed from the request lik this {scheme}/{host}.{port}/{uri_path}.

Try to change sling:Match property value with host.port (aig-dev64.adobecqms.net.4503) then try.

Note : You can try with AEM Publish/Author ports.