Class DataEngineSchemaTypeHandler
java.lang.Object
org.odpi.openmetadata.accessservices.dataengine.server.handlers.DataEngineSchemaTypeHandler
DataEngineSchemaTypeHandler manages schema types objects from the property server. It runs server-side in the
DataEngine OMAS and creates and retrieves schema type entities through the OMRSRepositoryConnector.
-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionDataEngineSchemaTypeHandler
(String serviceName, String serverName, InvalidParameterHandler invalidParameterHandler, OMRSRepositoryHelper repositoryHelper, SchemaTypeHandler<SchemaType> schemaTypeHandler, DataEngineRegistrationHandler dataEngineRegistrationHandler, DataEngineCommonHandler dataEngineCommonHandler, DataEngineSchemaAttributeHandler dataEngineSchemaAttributeHandler) Construct the handler information needed to interact with the repository services -
Method Summary
Modifier and TypeMethodDescriptionvoid
addDataFlowRelationship
(String userId, String dataSupplierQualifiedName, String dataConsumerQualifiedName, String externalSourceName, String formula, String description) Create DataFlow relationship between two entitiesfindSchemaTypeEntity
(String userId, String qualifiedName) Find out if the SchemaType object is already stored in the repository.void
removeSchemaType
(String userId, String schemaTypeGUID, String externalSourceName, DeleteSemantic deleteSemantic) Remove the schema type with the associated schema attributesupsertSchemaType
(String userId, SchemaType schemaType, String anchorGUID, String externalSourceName) Create the schema type entity, with the corresponding schema attributes and relationships if it doesn't exist or updates the existing one.
-
Field Details
-
SCHEMA_TYPE_GUID_PARAMETER_NAME
- See Also:
-
-
Constructor Details
-
DataEngineSchemaTypeHandler
public DataEngineSchemaTypeHandler(String serviceName, String serverName, InvalidParameterHandler invalidParameterHandler, OMRSRepositoryHelper repositoryHelper, SchemaTypeHandler<SchemaType> schemaTypeHandler, DataEngineRegistrationHandler dataEngineRegistrationHandler, DataEngineCommonHandler dataEngineCommonHandler, DataEngineSchemaAttributeHandler dataEngineSchemaAttributeHandler) Construct the handler information needed to interact with the repository services- Parameters:
serviceName
- name of this serviceserverName
- name of the local serverinvalidParameterHandler
- handler for managing parameter errorsrepositoryHelper
- provides utilities for manipulating the repository services objectsschemaTypeHandler
- handler for managing schema elements in the metadata repositoriesdataEngineRegistrationHandler
- provides calls for retrieving external data engine guiddataEngineCommonHandler
- provides utilities for manipulating entitiesdataEngineSchemaAttributeHandler
- provides utilities for manipulating schema attributes
-
-
Method Details
-
upsertSchemaType
public String upsertSchemaType(String userId, SchemaType schemaType, String anchorGUID, String externalSourceName) throws InvalidParameterException, PropertyServerException, UserNotAuthorizedException Create the schema type entity, with the corresponding schema attributes and relationships if it doesn't exist or updates the existing one.- Parameters:
userId
- the name of the calling userschemaType
- the schema type valuesexternalSourceName
- the unique name of the external source- Returns:
- unique identifier of the schema type in the repository
- Throws:
InvalidParameterException
- the bean properties are invalidUserNotAuthorizedException
- user not authorized to issue this requestPropertyServerException
- problem accessing the property server
-
findSchemaTypeEntity
public Optional<EntityDetail> findSchemaTypeEntity(String userId, String qualifiedName) throws UserNotAuthorizedException, PropertyServerException, InvalidParameterException Find out if the SchemaType object is already stored in the repository. It uses the fully qualified name to retrieve the entity- Parameters:
userId
- the name of the calling userqualifiedName
- the qualifiedName name of the schema type to be searched- Returns:
- optional with entity details if found, empty optional if not found
- Throws:
InvalidParameterException
- the bean properties are invalidUserNotAuthorizedException
- user not authorized to issue this requestPropertyServerException
- problem accessing the property server
-
addDataFlowRelationship
public void addDataFlowRelationship(String userId, String dataSupplierQualifiedName, String dataConsumerQualifiedName, String externalSourceName, String formula, String description) throws InvalidParameterException, UserNotAuthorizedException, PropertyServerException Create DataFlow relationship between two entities- Parameters:
userId
- the name of the calling userdataSupplierQualifiedName
- the qualified name of the data supplier entitydataConsumerQualifiedName
- the qualified name of the data consumer entityexternalSourceName
- the unique name of the external source- Throws:
InvalidParameterException
- the bean properties are invalidUserNotAuthorizedException
- user not authorized to issue this requestPropertyServerException
- problem accessing the property server
-
removeSchemaType
public void removeSchemaType(String userId, String schemaTypeGUID, String externalSourceName, DeleteSemantic deleteSemantic) throws InvalidParameterException, PropertyServerException, UserNotAuthorizedException, FunctionNotSupportedException Remove the schema type with the associated schema attributes- Parameters:
userId
- the name of the calling userschemaTypeGUID
- the unique identifier of the schema typeexternalSourceName
- the external data enginedeleteSemantic
- the delete semantic- Throws:
InvalidParameterException
- the bean properties are invalidUserNotAuthorizedException
- user not authorized to issue this requestPropertyServerException
- problem accessing the property serverFunctionNotSupportedException
- the repository does not support this call.
-