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

AEM Pattern detector issues

Avatar

Avatar
Give Back
Level 1
sonalid49327489
Level 1

Like

1 like

Total Posts

11 posts

Correct Reply

0 solutions
Top badges earned
Give Back
Boost 1
View profile

Avatar
Give Back
Level 1
sonalid49327489
Level 1

Like

1 like

Total Posts

11 posts

Correct Reply

0 solutions
Top badges earned
Give Back
Boost 1
View profile
sonalid49327489
Level 1

24-06-2020

Hi,

 

We are currently upgrading aem 6.3 to 6.5 version. We are clearing the issues mentioned in pattern detector.

 

But errors related to overlay components in pattern detector are not updating even after solving them. The component functionality is working fine as per requirement but imcompatible errors are still showing in pattern detector.

Below is the error pattern

 

/apps/cq/gui/components/common/wcm/clientlibs/wcm by overlaying (shadowing) the JCR path at /libs/cq/gui/components/common/wcm/clientlibs/wcm might be incompatible after update and might need some adaption.

 

Can someone please help me understand why the js errors are showing up even after solving them.

 

Accepted Solutions (1)

Accepted Solutions (1)

Avatar

Avatar
Validate 1
MVP
Theo_Pendle
MVP

Likes

238 likes

Total Posts

251 posts

Correct Reply

105 solutions
Top badges earned
Validate 1
Ignite 5
Ignite 3
Ignite 10
Ignite 1
View profile

Avatar
Validate 1
MVP
Theo_Pendle
MVP

Likes

238 likes

Total Posts

251 posts

Correct Reply

105 solutions
Top badges earned
Validate 1
Ignite 5
Ignite 3
Ignite 10
Ignite 1
View profile
Theo_Pendle
MVP

24-06-2020

Hello @sonalid49327489,

Both @berliant and @vanegi are correct in a way. This pattern detector issue is not meant to be understood as "Your whole AEM instance will commit suicide if you overlay /libs/cq/gui/components/common/wcm/clientlibs/wcm" but more like "Watch out, things have changed in /libs/cq/gui/components/common/wcm/clientlibs/wcm and your overlay may cause a conflict or some errors" 😉

Here is a comparison between /libs/cq/gui/components/common/wcm/clientlibs/wcm in 6.3 vs 6.5:

Selection_049.png

 If we look more closely at just one file, eg: copy.js, we see that things have changed a lot!

Selection_050.png

So for example, if your overlay in 6.3 was a copy of copy.js, but you added one line at the end that's a small change in behvaiour. If you carry that overlay into 6.5 though, you now have dozens of changes!

What you should do is examine the diff between the 6.3 and 6.5 versions of every overlay you've made and patch them. In some cases you may find that if your overlay was made as a fix, you might not even need it anymore 🙂

If you have a lot of overlays and it's causing trouble, that's too bad... but going forward perhaps you'd like to read my article on best practices to minimise the impact of patching overlays on AEM upgrades #shamelessplug 😉

Hope that helps!

Answers (2)

Answers (2)

Avatar

Avatar
Give Back 50
Employee
berliant
Employee

Likes

207 likes

Total Posts

315 posts

Correct Reply

98 solutions
Top badges earned
Give Back 50
Give Back 5
Give Back 3
Give Back 25
Give Back 10
View profile

Avatar
Give Back 50
Employee
berliant
Employee

Likes

207 likes

Total Posts

315 posts

Correct Reply

98 solutions
Top badges earned
Give Back 50
Give Back 5
Give Back 3
Give Back 25
Give Back 10
View profile
berliant
Employee

24-06-2020

I think it means that you should not overlay wcm clientlibs, which might cause some unexpected effect on OOTB UI, but specify cq.common.wcm within your custom libs as dependencies.

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

24-06-2020

This seems to be false positive warnings which can be safely ignored. Currently Pattern Detector reports suspicions (warnings) with different codes and an internal ticket [CQ-4284004] has already been filed with R&D to introduce priority/importance level for each suspicion (detected pattern). The priority/importance would help (even for the same metapattern problem code) to highlight which concrete potential issues are more important to fix in the first place and would also help to lower the levels of false positives (those ideally should be scored the lowest so in the end they are analyzed if there is a time for that).