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
Bedrock Mission!

Learn more

View all

Sign in to view all badges

SOLVED

How to solve org.apache.sling.engine.impl.SlingRequestProcessorImpl service: Uncaught SlingException java.lang.NullPointerException: null

Avatar

Level 2

Hi,

           When I am trying to create a page using the created editable template in my local aem instance, page is not getting created and it is throwing an error. In error.log file this error getting logged as, "org.apache.sling.engine.impl.SlingRequestProcessorImpl service: Uncaught SlingException java.lang.NullPointerException: null".  

 

02.08.2022 09:39:52.852 *ERROR* [0:0:0:0:0:0:0:1 [1659413392762] GET /mnt/overlay/wcm/core/content/sites/createpagewizard/properties.html/conf/contentservices-tsa/settings/wcm/templates/generic-page HTTP/1.1] org.apache.sling.engine.impl.SlingRequestProcessorImpl service: Uncaught SlingException
java.lang.NullPointerException: null
at org.apache.jsp.apps.support.components.cq.gui.components.common.datasources.tags.tags_jsp._jspService(tags_jsp.java:165)
at org.apache.sling.scripting.jsp.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70) [org.apache.sling.scripting.jsp:2.3.4]
at javax.servlet.http.HttpServlet.service(HttpServlet.java:725) [org.apache.felix.http.servlet-api:1.1.2]
at org.apache.sling.scripting.jsp.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:502) [org.apache.sling.scripting.jsp:2.3.4]
at org.apache.sling.scripting.jsp.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:449) [org.apache.sling.scripting.jsp:2.3.4]
at org.apache.sling.scripting.jsp.JspScriptEngineFactory.callJsp(JspScriptEngineFactory.java:342) [org.apache.sling.scripting.jsp:2.3.4]
at org.apache.sling.scripting.jsp.JspScriptEngineFactory.access$100(JspScriptEngineFactory.java:97) [org.apache.sling.scripting.jsp:2.3.4]
at org.apache.sling.scripting.jsp.JspScriptEngineFactory$JspScriptEngine.eval(JspScriptEngineFactory.java:603) [org.apache.sling.scripting.jsp:2.3.4]
at org.apache.sling.scripting.core.impl.DefaultSlingScript.call(DefaultSlingScript.java:388) [org.apache.sling.scripting.core:2.0.56]
at org.apache.sling.scripting.core.impl.DefaultSlingScript.eval(DefaultSlingScript.java:184) [org.apache.sling.scripting.core:2.0.56]
at org.apache.sling.scripting.core.impl.DefaultSlingScript.service(DefaultSlingScript.java:491) [org.apache.sling.scripting.core:2.0.56]
at org.apache.sling.engine.impl.request.RequestData.service(RequestData.java:552) [org.apache.sling.engine:2.6.18]
at org.apache.sling.engine.impl.filter.SlingComponentFilterChain.render(SlingComponentFilterChain.java:44) [org.apache.sling.engine:2.6.18]
at org.apache.sling.engine.impl.filter.AbstractSlingFilterChain.doFilter(AbstractSlingFilterChain.java:82) [org.apache.sling.engine:2.6.18]
at com.day.cq.wcm.core.impl.WCMDeveloperModeFilter.doFilter(WCMDeveloperModeFilter.java:119) [com.day.cq.wcm.cq-wcm-core:5.12.90]
at org.apache.sling.engine.impl.filter.AbstractSlingFilterChain.doFilter(AbstractSlingFilterChain.java:72) [org.apache.sling.engine:2.6.18]
at com.adobe.granite.csrf.impl.CSRFFilter.doFilter(CSRFFilter.java:217) [com.adobe.granite.csrf:1.0.20]

 

Can anyone please guide me how to solve this error.

 

Thanks & Regards,

Lavanya.

1 Accepted Solution

Avatar

Correct answer by
Community Advisor

It looks like /conf/contentservices-tsa/settings/wcm/templates/generic-page is your project specific editable template.

Could you please try to access this specific template via Tools---> General---> Templates and see if you face any issue while accessing.

 

  • Are you facing any issue with existing pages , those were created with /conf/contentservices-tsa/settings/wcm/templates/generic-page template?
  • Are you facing any issue with any other templates while creating the pages?

View solution in original post

2 Replies

Avatar

Correct answer by
Community Advisor

It looks like /conf/contentservices-tsa/settings/wcm/templates/generic-page is your project specific editable template.

Could you please try to access this specific template via Tools---> General---> Templates and see if you face any issue while accessing.

 

  • Are you facing any issue with existing pages , those were created with /conf/contentservices-tsa/settings/wcm/templates/generic-page template?
  • Are you facing any issue with any other templates while creating the pages?

Avatar

Employee Advisor

The exception is actually quite self-explanatory.

 

* You have a NullPointerException in the code.

* The code is at the java class org.apache.jsp.apps.support.components.cq.gui.components.common.datasources.tags.tags_jsp._jspService(tags_jsp.java:165)

* which is created from the JSP at /apps/support/components/cq/gui/components/common/datasources/tags.jsp

* in the compiled java class the NPE happens at line 165

 

Now you need to go to /system/console/fsclassloader, search for that class name, select "view source" and lookup line 165. And then match it to the JSP and fix the NPE there.