Class FindRelationshipsByPropertyValueExecutor
java.lang.Object
org.odpi.openmetadata.repositoryservices.enterprise.repositoryconnector.executors.RepositoryExecutorBase
org.odpi.openmetadata.repositoryservices.enterprise.repositoryconnector.executors.FindRelationshipsByPropertyValueExecutor
- All Implemented Interfaces:
CloneableRepositoryExecutor
,RepositoryExecutor
FindRelationshipsByPropertyValueExecutor is the executor for the findRelationshipsByPropertyValue request.
This request can be issued in parallel - the call to each request potentially running in a different thread.
-
Field Summary
Fields inherited from class org.odpi.openmetadata.repositoryservices.enterprise.repositoryconnector.executors.RepositoryExecutorBase
methodName, userId
-
Constructor Summary
ConstructorsConstructorDescriptionFindRelationshipsByPropertyValueExecutor
(String userId, String relationshipTypeGUID, String searchCriteria, int fromRelationshipElement, List<InstanceStatus> limitResultsByStatus, Date asOfTime, String sequencingProperty, SequencingOrder sequencingOrder, int pageSize, String localMetadataCollectionId, AuditLog auditLog, OMRSRepositoryValidator repositoryValidator, String methodName) Create the executor. -
Method Summary
Modifier and TypeMethodDescriptiongetClone()
Return a clone of this executor with the same command parameters and accumulator instance.getResults
(EnterpriseOMRSRepositoryConnector repositoryConnector) Return the results of the combined requests.boolean
issueRequestToRepository
(String metadataCollectionId, OMRSMetadataCollection metadataCollection) Perform the required action for the supplied repository.Methods inherited from class org.odpi.openmetadata.repositoryservices.enterprise.repositoryconnector.executors.RepositoryExecutorBase
getMethodName
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.odpi.openmetadata.repositoryservices.enterprise.repositoryconnector.executors.RepositoryExecutor
augmentResultFromRepository, getResultsForAugmentation
-
Constructor Details
-
FindRelationshipsByPropertyValueExecutor
public FindRelationshipsByPropertyValueExecutor(String userId, String relationshipTypeGUID, String searchCriteria, int fromRelationshipElement, List<InstanceStatus> limitResultsByStatus, Date asOfTime, String sequencingProperty, SequencingOrder sequencingOrder, int pageSize, String localMetadataCollectionId, AuditLog auditLog, OMRSRepositoryValidator repositoryValidator, String methodName) Create the executor. The parameters provide the parameters for issuing the requests and combining the results.- Parameters:
userId
- unique identifier for requesting user.relationshipTypeGUID
- GUID of the type of entity to search for. Null means all types will be searched (could be slow so not recommended).searchCriteria
- String expression contained in any of the property values within the entities of the supplied type.fromRelationshipElement
- Element number of the results to skip to when building the results list to return. Zero means begin at the start of the results. This is used to retrieve the results over a number of pages.limitResultsByStatus
- By default, relationships in all statuses are returned. However, it is possible to specify a list of statuses (eg ACTIVE) to restrict the results to. Null means all status values.asOfTime
- Requests a historical query of the relationships for the entity. Null means return the present values.sequencingProperty
- String name of the property that is to be used to sequence the results. Null means do not sequence on a property name (see SequencingOrder).sequencingOrder
- Enum defining how the results should be ordered.pageSize
- the maximum number of result relationships that can be returned on this request. Zero means unrestricted return results size.localMetadataCollectionId
- unique identifier for the local repository - may be null if no local repositoryauditLog
- logging destinationrepositoryValidator
- validator for resulting relationshipsmethodName
- calling method
-
-
Method Details
-
getClone
Return a clone of this executor with the same command parameters and accumulator instance. This is used when setting up the parallel execution of the work. Each clone executes the calls to a single open metadata repository.- Returns:
- clone of this executor
-
issueRequestToRepository
public boolean issueRequestToRepository(String metadataCollectionId, OMRSMetadataCollection metadataCollection) Perform the required action for the supplied repository.- Specified by:
issueRequestToRepository
in interfaceRepositoryExecutor
- Specified by:
issueRequestToRepository
in classRepositoryExecutorBase
- Parameters:
metadataCollectionId
- unique identifier for the metadata collection for the repositorymetadataCollection
- metadata collection object for the repository- Returns:
- boolean true means that the required results have been achieved
-
getResults
public List<Relationship> getResults(EnterpriseOMRSRepositoryConnector repositoryConnector) throws InvalidParameterException, TypeErrorException, RepositoryErrorException, PropertyErrorException, PagingErrorException, FunctionNotSupportedException, UserNotAuthorizedException Return the results of the combined requests.- Parameters:
repositoryConnector
- enterprise connector- Returns:
- a list of relationships. Null means no matching relationships.
- Throws:
InvalidParameterException
- one of the parameters is invalid or null.TypeErrorException
- the type guid passed on the request is not known by the metadata collection.RepositoryErrorException
- there is a problem communicating with the metadata repository where the metadata collection is stored.PropertyErrorException
- the properties specified are not valid for any of the requested types of relationships.PagingErrorException
- the paging/sequencing parameters are set up incorrectly.FunctionNotSupportedException
- the repository does not support the asOfTime parameter.UserNotAuthorizedException
- the userId is not permitted to perform this operation.
-