Expand my Community achievements bar.

SOLVED

AEM 6.1 getServiceResourceResolver not works

Avatar

Level 2

Hi,

getServiceResourceResolver not work for me, I created new system user, added mappings in org.apache.sling.serviceusermapping.impl.ServiceUserMapperImpl, but getServiceResourceResolver throws LoginException.

When i specify existing system user (e.g. projects-service) in getServiceResourceResolver works, but it does not work with my system user.

Could anyone help me how to create system user that will work with my services?


User:

<?xml version="1.0" encoding="UTF-8"?>
<jcr:root xmlns:jcr="http://www.jcp.org/jcr/1.0" xmlns:rep="internal"
    jcr:primaryType="rep:SystemUser"
    jcr:uuid="98c416ab-ee61-30f2-a8d0-0c13bd39d6c0"
    rep:authorizableId="sevice-user"
    rep:principalName="sevice-user"/>

 

1 Accepted Solution

Avatar

Correct answer by
Administrator

Hi 

Please have a look at this StackOverflow post :- http://stackoverflow.com/questions/31350548/resourceresolverfactory-getserviceresourceresolver-throw...

I hope this would help you.

Thanks and Regards

Kautuk Sahni



Kautuk Sahni

View solution in original post

3 Replies

Avatar

Correct answer by
Administrator

Hi 

Please have a look at this StackOverflow post :- http://stackoverflow.com/questions/31350548/resourceresolverfactory-getserviceresourceresolver-throw...

I hope this would help you.

Thanks and Regards

Kautuk Sahni



Kautuk Sahni

Avatar

Level 2

Thank you.

found the issue, in .content.xml rep:principalName was sevice-user insted of seRvice-user