System user AEM 6.4

Avatar

Avatar

AdobeID24

Avatar

AdobeID24

AdobeID24

18-10-2019

//this all for creating session from resource resolver factory
   Map<String, Object> usermap = new HashMap<String, Object>();
   usermap.put(ResourceResolverFactory.SUBSERVICE, "customreporting");
   ResourceResolver resourceResolver = null;
  try {

// resourceResolver = resourceResolverFactory.getResourceResolver(usermap);
resourceResolver = resourceResolverFactory.getServiceResourceResolver(usermap);
   logger.info("Resolved user: " + resourceResolver.getUserID());
   } catch (LoginException e) {

  e.printStackTrace();
   }

this code is not working ...

Mapping configuration is also correct.

in path /apps/system/config/***********

# Configuration created by Apache Sling JCR Installer

service.ranking=I"0"

user.mapping=["AEMMaven13.core:customreporting\=customreportinguser"]

user customreportinguser having all the permission.

Please let me know what can be the issue .

Accepted Solutions (1)

Accepted Solutions (1)

Avatar

Avatar

Ankur_Khare

MVP

Avatar

Ankur_Khare

MVP

Ankur_Khare
MVP

19-10-2019

You can also check whether this servlet is not being included in multiple bundles http://localhost:4502/system/console/components and search for your servlet.

Answers (5)

Answers (5)

Avatar

Avatar

AdobeID24

Avatar

AdobeID24

AdobeID24

19-10-2019

Thanks folks it got resolved .

Problem may be with user permisiion I restarted the server and it worked

Avatar

Avatar

Ankur_Khare

MVP

Avatar

Ankur_Khare

MVP

Ankur_Khare
MVP

19-10-2019

This is not an error it's a warning.

If you are getting  500 error that means you are able to hit the servlet and you are getting 500 error at some specific line can you let us know that specific code.

Avatar

Avatar

AdobeID24

Avatar

AdobeID24

AdobeID24

19-10-2019

during accessing it is showing me internal 500 server error .

logs in error.logs file

19.10.2019 01:32:47.885 *WARN* [0:0:0:0:0:0:0:1 [*********************] GET /bin/commentexcelreporting HTTP/1.1] com.day.cq.wcm.core.impl.components.ComponentCacheImpl Requested Path /bin/commentexcelreporting.servlet is not in available search paths

Avatar

Avatar

Ankur_Khare

MVP

Avatar

Ankur_Khare

MVP

Ankur_Khare
MVP

19-10-2019

What's the error?

Avatar

Avatar

AdobeID24

Avatar

AdobeID24

AdobeID24

19-10-2019

Entry from manifest.mf file :

Bundle-Name: AEMMaven13 - Core

Bundle-SymbolicName: AEMMaven13.core

Bundle-Version: 1.0.0.SNAPSHOT

I used bundle symbolic name for mapping

Mapping in User mapper service amendment clicking on plus sign

AEMMaven13.core:customreporting=customreportinguser