Expand my Community achievements bar.

Don’t miss the AEM Skill Exchange in SF on Nov 14—hear from industry leaders, learn best practices, and enhance your AEM strategy with practical tips.
SOLVED

Component specific Clientlibs under apps not loading

Avatar

Level 2

Hi,

We are upgrading our application from AEM 6.0 to AEM 6.2.

I have installed CFP 13.

I see that Component specific Clientlibs under apps not loading .

I am  embedding the Component specific Clientlib  /apps/bootstrap/components/bootstrap-nav-megamenu/clientlibs/js/bootstrap-nav-megamenu.min.js in /etc/designs/bootstrap/bootstrap-design/components/bootstrap-megamenu and referencing the clientlib under designs by its category .

I see below error

01.05.2018 13:17:30.163 *ERROR* [10.99.27.202 [1525144650152] GET /etc/designs/bootstrap/bootstrap-design/components/bootstrap-megamenu.js HTTP/1.1] com.adobe.granite.ui.clientlibs.impl.HtmlLibraryServlet Cannot create library for /etc/designs/bootstrap/bootstrap-design/components/bootstrap-megamenu.js

java.io.IOException: Error while sending cached library: javax.jcr.PathNotFoundException: /apps/bootstrap/components/bootstrap-nav-megamenu/clientlibs/js/bootstrap-nav-megamenu.min.js/jcr:content/jcr:data

As a work around i have given the clientlibs-service user permission to /apps folder and rebuild the client library.

By doing this i am able to load the client libs under apps folder.

Can some one help me with whats missing and  why the clientlibs under /apps not loading straight away.

1 Accepted Solution

Avatar

Correct answer by
Level 2

I was able to find the root cause of the issue.

The system user "clientlibs-service" should be having the permission to /apps, /etc and /libs folder by default.

clientlibs-service is a service user for HTML client library service.

I believe there was a package which was overwriting this permission. Hence access to  /apps folder was removed and was unable to embed the clientlibs under /apps folder,

View solution in original post

4 Replies

Avatar

Administrator

This could be the reason for your problem:- Re: Unable to apply component-level CSS.



Kautuk Sahni

Avatar

Level 2

The same code base works fine in AEM

6.0 but when deployed on AEM 6.2  I see the issue with component specific libraries not loading . What’s changed with AEM 6.2

Avatar

Level 10

When you build an AEM Maven 10 Archetype for 6.2 - notice that clientlibs are placed under etc and they are being pulled in. See this article -- Scott's Digital Community: Creating your first AEM 6.2 Project using Adobe Maven Archetype 10

Follow that article and you will see that CSS is being pulled into the AEM site defined under /etc.

Avatar

Correct answer by
Level 2

I was able to find the root cause of the issue.

The system user "clientlibs-service" should be having the permission to /apps, /etc and /libs folder by default.

clientlibs-service is a service user for HTML client library service.

I believe there was a package which was overwriting this permission. Hence access to  /apps folder was removed and was unable to embed the clientlibs under /apps folder,