org.apache.sling.api.resource.LoginException: Cannot derive user name for bundle xxx.xxx.xxx [] and sub service | Community
Skip to main content
VeenaVikraman
New Participant
November 1, 2017
Solved

org.apache.sling.api.resource.LoginException: Cannot derive user name for bundle xxx.xxx.xxx [] and sub service

  • November 1, 2017
  • 7 replies
  • 6384 views

Hi All

     I have an exact same problem as mentioned here org.apache.sling.api.resource.LoginException: Cannot derive user name for bundle com.mycompany.core [472] and sub servic…  . So for this long time I used to go directly to the Felix console and add the Service User details in the Apache Sling Service User Mapper

So the problem I face is :- I am trying to create a config node for org.apache.sling.serviceusermapping.impl.ServiceUserMapperImpl in my project . All the values are reflecting fine in the config when I check . But still it throws me the above error.

     But if I go directly to the felix and add the value directly as I used to before , it just works perfect. Have someone face the same issue before ?

Why I cannot go and edit directly in felix console ? - > So the CSE who does our deployments won't be making any changes in the felix console directly. Anything we need to deploy should be deployed as config nodes. And for some reason , even though the config values are reflecting in the felix console, it always throw me the above error.

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
Best answer by VeenaVikraman

I am not able to replicate this now . I did a restart of the server and seems like my config values are getting picked  

7 replies

CT1012
New Participant
December 12, 2017

Can you please give us more info on this

- Will it automatically create system user or we need to do it form the same old crx/explorer ?? Is system user=principal name?

-The ACE's added, will they automatically take care of permissions so that we no need to change anything from user admin?

Please add anything you want to inform on this

TIA

smacdonald2008
New Participant
November 1, 2017

I am glad its picking up the values. I have not seen that before.

VeenaVikraman
VeenaVikramanAuthorAccepted solution
New Participant
November 1, 2017

I am not able to replicate this now . I did a restart of the server and seems like my config values are getting picked  

VeenaVikraman
New Participant
November 1, 2017

Ya scott. I am trying to draft this down neatly to give you all more insight on my issue. I need to get a sample code setup as I cannot share the one which I am currently working on.

smacdonald2008
New Participant
November 1, 2017

Can you show code where error is thrown?

VeenaVikraman
New Participant
November 1, 2017

edubey​ But my issue is different here. I am trying to set the Apache Sling Service User Mapper Configuration as a config value in my project.

edubey
New Participant
November 1, 2017

CSE is right, as part of the deployment, its always good have config present in deployment package rather making changes in Felix console which eventually gets stored in /apps/system/config.

I would recommend using Ensure Service User from ACS Commons, it takes care of service user deployment with code package

Ensure Service User

Thanks