use of org.apereo.portal.groups.CompositeEntityIdentifier in project uPortal by Jasig.
the class JpaAggregatedGroupLookupDao method getGroupMapping.
@OpenEntityManager(unitName = BaseAggrEventsJpaDao.PERSISTENCE_UNIT_NAME)
@Override
public AggregatedGroupMapping getGroupMapping(final String portalGroupKey) {
final IEntityGroup group = compositeGroupService.findGroup(portalGroupKey);
if (group == null) {
if (warnedGroupKeys.add(portalGroupKey)) {
logger.warn("No group found for key {}, no aggregate group mapping will be done and the group key will be ignored.", portalGroupKey);
}
final CompositeEntityIdentifier compositeEntityIdentifier = new CompositeEntityIdentifier(portalGroupKey, IEntityGroup.class);
final String serviceName = compositeEntityIdentifier.getServiceName().toString();
final String groupKey = compositeEntityIdentifier.getLocalKey();
return this.getGroupMapping(serviceName, groupKey);
}
final String groupService = group.getServiceName().toString();
final String groupName = group.getName();
return this.getGroupMapping(groupService, groupName);
}
Aggregations