* @throws RepositoryException If a general error occurs while creating the
* session
*/
public final Session loginService(String subServiceName, String workspace) throws LoginException,
RepositoryException {
final ServiceUserMapper serviceUserMapper = this.getSlingRepositoryManager().getServiceUserMapper();
final String userName = (serviceUserMapper != null) ? serviceUserMapper.getServiceUserID(this.usingBundle,
subServiceName) : null;
if (userName == null) {
throw new LoginException("Cannot derive user name for bundle " + usingBundle + " and sub service "
+ subServiceName);
}