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

Sling mapping issue in Production Publish 2

Avatar

Avatar
Level 1
sivaramr5911311
Level 1

Likes

0 likes

Total Posts

2 posts

Correct Reply

0 solutions
View profile

Avatar
Level 1
sivaramr5911311
Level 1

Likes

0 likes

Total Posts

2 posts

Correct Reply

0 solutions
View profile
sivaramr5911311
Level 1

14-07-2020

There was an issue with short url mapping in Production Publish 2 instance for one of our site where we had the mapping under /etc/map/https/www.xyz.com. The short URL was resolving in Prod publish 1 instance whereas it was not resolving in Publish 2.

Due to this, when the pages are accessed pages from the site, 404 page not found was coming up occasionally (whenever the request hits dispatcher 2 which points to publish 2). We tried the following steps to resolve the issue. Package /etc/map/https/www.xyz.com and /etc/map/http/www.xyz.com from Publish 1 and installed it in Publish 2 – Issue was not resolved. We restarted the following 2 bundles – The issue was resolved. Apache Sling JCR Resource Resolver org.apache.sling.jcr.resource Apache Sling Resource Resolver org.apache.sling.resourceresolver The issue was resolved but we are unable to determine the root cause of this issue. So that we could prevent this kind of issue from occurring again in production environment.

Any idea what could have caused this issue?

Accepted Solutions (1)

Accepted Solutions (1)

Avatar

Avatar
Boost 250
MVP
ChitraMadan
MVP

Likes

271 likes

Total Posts

165 posts

Correct Reply

67 solutions
Top badges earned
Boost 250
Establish
Ignite 1
Give Back 5
Give Back 3
View profile

Avatar
Boost 250
MVP
ChitraMadan
MVP

Likes

271 likes

Total Posts

165 posts

Correct Reply

67 solutions
Top badges earned
Boost 250
Establish
Ignite 1
Give Back 5
Give Back 3
View profile
ChitraMadan
MVP

14-07-2020

Hi @sivaramr5911311 ,

 

I have faced this issue quite often, whenever we make a change in sling mappings, we mostly have to restart the bundle, as you mentioned.

 

One of the reason I could relate is mentioned in this article -  

https://sling.apache.org/documentation/the-sling-engine/mappings-for-resource-resolution.html#rebuil...

 

Although, it mentions that Sling automatically builds the filter, but looks like when we do a restart of the bundle, this filter gets build again.

Answers (2)

Answers (2)

Avatar

Avatar
Level 1
Hamid1350
Level 1

Likes

0 likes

Total Posts

1 post

Correct Reply

0 solutions
View profile

Avatar
Level 1
Hamid1350
Level 1

Likes

0 likes

Total Posts

1 post

Correct Reply

0 solutions
View profile
Hamid1350
Level 1

14-07-2020

Do you have any rewrite rules defined at httpd server level ?

Avatar

Avatar
Give Back 5
Employee
vanegi
Employee

Likes

392 likes

Total Posts

378 posts

Correct Reply

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

Avatar
Give Back 5
Employee
vanegi
Employee

Likes

392 likes

Total Posts

378 posts

Correct Reply

148 solutions
Top badges earned
Give Back 5
Give Back 3
Give Back 10
Give Back
Boost 50
View profile
vanegi
Employee

14-07-2020

Please confirm if you have log in as an admin via CRXDE and then do the same request again to validate this. Also check if the mapping is actually applied by AEM:

 

- Go to http://<host>:<port>/system/console/jcrresolver

- Under "Mapping Map Entries", check if the entries are appearing there.

 

You can also setup a DEBUG logger on "org.apache.sling.resourceresolver" to check how the resolution is happening and which resource resolver settings are being applied.