public Set<IdentityObjectRelationship> resolveRelationships(IdentityStoreInvocationContext invocationCtx, IdentityObject identity, IdentityObjectRelationshipType relationshipType, boolean parent, boolean named, String name) throws IdentityException { return defaultIdentityStore.resolveRelationships(resolveIdentityStoreInvocationContext(invocationCtx), identity, relationshipType, parent, named, name); }
public Set<IdentityObjectRelationship> resolveRelationships(IdentityStoreInvocationContext invocationCxt, IdentityObject fromIdentity, IdentityObject toIdentity, IdentityObjectRelationshipType relationshipType) throws IdentityException { Set<IdentityObjectRelationship> results = cacheSupport.getRelationshipsSearchFromCache(fromIdentity, toIdentity, relationshipType); if (results == null) { results = identityStore.resolveRelationships(invocationCxt, fromIdentity, toIdentity, relationshipType); cacheSupport.putRelationshipsSearchIntoCache(fromIdentity, toIdentity, relationshipType, results); } return results; }
public Set<IdentityObjectRelationship> resolveRelationships(IdentityStoreInvocationContext invocationCtx, IdentityObject identity, IdentityObjectRelationshipType relationshipType, boolean parent, boolean named, String name) throws IdentityException { Set<IdentityObjectRelationship> results = cacheSupport.getRelationshipsSearchFromCache(identity, relationshipType, parent, named, name); if (results == null) { results = identityStore.resolveRelationships(invocationCtx, identity, relationshipType, parent, named, name); cacheSupport.putRelationshipSearchIntoCache(identity, relationshipType, parent, named, name, results); } return results; }
public Set<IdentityObjectRelationship> resolveRelationships(IdentityStoreInvocationContext ctx, IdentityObject identity, IdentityObjectRelationshipType relationshipType, boolean parent, boolean named, String name) throws IdentityException { Set<IdentityObjectRelationship> relationships = new HashSet<IdentityObjectRelationship>(); // For any IdentityStore that supports named relationships... for (IdentityStore identityStore : configuredIdentityStores) { if (!identityStore.getSupportedFeatures().getSupportedRelationshipTypes().contains(relationshipType.getName())) { continue; } if (!named || (named && identityStore.getSupportedFeatures().isNamedRelationshipsSupported())) { IdentityStoreInvocationContext storeCtx = resolveInvocationContext(identityStore, ctx); relationships.addAll(identityStore.resolveRelationships(storeCtx, identity, relationshipType, parent, named, name)); } } return relationships; }
public Set<IdentityObjectRelationship> resolveRelationships(IdentityStoreInvocationContext invocationCxt, IdentityObject fromIdentity, IdentityObject toIdentity, IdentityObjectRelationshipType relationshipType) throws IdentityException { IdentityStore fromStore = resolveIdentityStore(fromIdentity); IdentityStore toStore = resolveIdentityStore(toIdentity); IdentityStoreInvocationContext toTargetCtx = resolveInvocationContext(toStore, invocationCxt); IdentityStoreInvocationContext defaultTargetCtx = resolveInvocationContext(defaultIdentityStore, invocationCxt); if (fromStore == toStore && (!RoleManagerImpl.ROLE.getName().equals(relationshipType.getName()) || fromStore.getSupportedFeatures().isNamedRelationshipsSupported())) { return fromStore.resolveRelationships(toTargetCtx, fromIdentity, toIdentity, relationshipType); } if (!hasIdentityObject(defaultTargetCtx, defaultIdentityStore, fromIdentity)) { defaultIdentityStore.createIdentityObject(defaultTargetCtx, fromIdentity.getName(), fromIdentity.getIdentityType()); } if (!hasIdentityObject(defaultTargetCtx, defaultIdentityStore, toIdentity)) { defaultIdentityStore.createIdentityObject(defaultTargetCtx, toIdentity.getName(), toIdentity.getIdentityType()); } return defaultIdentityStore.resolveRelationships(defaultTargetCtx, fromIdentity, toIdentity, relationshipType); }