Class EnterpriseOMRSRepositoryConnector
java.lang.Object
org.odpi.openmetadata.frameworks.connectors.Connector
org.odpi.openmetadata.frameworks.connectors.ConnectorBase
org.odpi.openmetadata.repositoryservices.connectors.stores.metadatacollectionstore.repositoryconnector.OMRSRepositoryConnector
org.odpi.openmetadata.repositoryservices.enterprise.repositoryconnector.EnterpriseOMRSRepositoryConnector
- All Implemented Interfaces:
AuditLoggingComponent
,SecureConnectorExtension
,VirtualConnectorExtension
,OMRSMetadataCollectionManager
,OMRSConnectorConsumer
public class EnterpriseOMRSRepositoryConnector
extends OMRSRepositoryConnector
implements OMRSConnectorConsumer
EnterpriseOMRSRepositoryConnector supports federating calls to multiple metadata repositories. As a result,
its OMRSMetadataInstanceStore (EnterpriseOMRSMetadataCollection) returns metadata from all repositories in the
connected open metadata repository cohort(s).
An instance of the EnterpriseOMRSRepositoryConnector is created by each Open Metadata Access Service (OMAS) using the OCF ConnectorBroker. They use its metadata collection to retrieve and send the metadata they need.
Each EnterpriseOMRSRepositoryConnector instance needs to maintain an up to date list of OMRS Connectors to all the repositories in the connected open metadata repository cohort(s). It does by registering as an OMRSConnectorConsumer with the OMRSConnectorManager to be notified when connectors to new open metadata repositories are available.
-
Nested Class Summary
Nested classes/interfaces inherited from class org.odpi.openmetadata.frameworks.connectors.ConnectorBase
ConnectorBase.ProtectedConnection
-
Field Summary
Fields inherited from class org.odpi.openmetadata.repositoryservices.connectors.stores.metadatacollectionstore.repositoryconnector.OMRSRepositoryConnector
auditLog, maxPageSize, metadataCollection, metadataCollectionId, metadataCollectionName, organizationName, repositoryHelper, repositoryName, repositoryValidator, serverName, serverType, serverUserId
Fields inherited from class org.odpi.openmetadata.frameworks.connectors.ConnectorBase
connectedAssetProperties, connectionBean, connectionProperties, connectorInstanceId, embeddedConnectors, messageFormatter, secretsStoreConnectorMap
-
Method Summary
Modifier and TypeMethodDescriptionvoid
addRemoteConnector
(String metadataCollectionId, OMRSRepositoryConnector remoteConnector) Pass the connector to one of the remote repositories in the metadata repository cohort.void
Free up any resources held since the connector is no longer needed.void
The OMRS is about to shut down.void
removeRemoteConnector
(String metadataCollectionId) Pass the metadata collection id for a repository that has just left the metadata repository cohort.void
requestRefreshOfEntity
(EntityDetail entity) Request the refresh of this instance.void
requestRefreshOfRelationship
(Relationship relationship) Request the refresh of this instance.void
setCallingServiceName
(String callingServiceName) Set up the name of the access service using this connector.void
setLocalConnector
(String metadataCollectionId, LocalOMRSRepositoryConnector localConnector) Save the connector to the local repository.void
setLocalMetadataCollectionId
(String localMetadataCollectionId) Set the unique id of the metadata collection that is collocated with the Enterprise Metadata Collectionvoid
setMetadataCollectionId
(String metadataCollectionId) Set up the unique id for this metadata collection.void
start()
Indicates that the connector is completely configured and can begin processing.Methods inherited from class org.odpi.openmetadata.repositoryservices.connectors.stores.metadatacollectionstore.repositoryconnector.OMRSRepositoryConnector
getConnectorComponentDescription, getMaxPageSize, getMetadataCollection, getMetadataCollectionId, getMetadataCollectionName, getOrganizationName, getRepositoryHelper, getRepositoryName, getRepositoryValidator, getServerName, getServerType, getServerUserId, setAuditLog, setMaxPageSize, setMetadataCollectionName, setOrganizationName, setRepositoryHelper, setRepositoryName, setRepositoryValidator, setServerName, setServerType, setServerUserId, validateRepositoryIsActive
Methods inherited from class org.odpi.openmetadata.frameworks.connectors.ConnectorBase
combineConfigurationProperties, disconnectConnectors, equals, getArrayConfigurationProperty, getAssetTypeName, getBooleanConfigurationProperty, getConnectedAssetProperties, getConnection, getConnectorInstanceId, getDateConfigurationProperty, getIntConfigurationProperty, getLongConfigurationProperty, getNetworkAddresses, getStringConfigurationProperty, getSuppliedPlaceholderProperties, hashCode, initialize, initializeConnectedAssetProperties, initializeEmbeddedConnectors, initializeSecretsStoreConnector, isActive, logExceptionRecord, logRecord, logRecord, throwMissingConfigurationProperty, throwMissingResource, throwNoAsset, throwWrongTypeOfAsset, throwWrongTypeOfResource, throwWrongTypeOfRootSchema, toString
Methods inherited from class org.odpi.openmetadata.frameworks.connectors.Connector
clearStatisticProperty, clearStatisticTimestamp, getConnectorStatistics, getStatisticCounter, getStatisticProperty, getStatisticTimestamp, incrementStatisticCounter, initializeStatisticCounter, setStatisticProperty, setStatisticTimestamp
-
Method Details
-
setMetadataCollectionId
Set up the unique id for this metadata collection.- Specified by:
setMetadataCollectionId
in interfaceOMRSMetadataCollectionManager
- Overrides:
setMetadataCollectionId
in classOMRSRepositoryConnector
- Parameters:
metadataCollectionId
- String unique Id
-
setLocalMetadataCollectionId
Set the unique id of the metadata collection that is collocated with the Enterprise Metadata Collection- Parameters:
localMetadataCollectionId
- String unique Id
-
setCallingServiceName
Set up the name of the access service using this connector.- Parameters:
callingServiceName
- string name
-
start
Indicates that the connector is completely configured and can begin processing.- Overrides:
start
in classConnectorBase
- Throws:
ConnectorCheckedException
- there is a problem within the connector.
-
disconnect
Free up any resources held since the connector is no longer needed.- Overrides:
disconnect
in classConnectorBase
- Throws:
ConnectorCheckedException
- there is a problem disconnecting the connector.
-
requestRefreshOfEntity
Request the refresh of this instance.- Parameters:
entity
- retrieved instance
-
requestRefreshOfRelationship
Request the refresh of this instance.- Parameters:
relationship
- retrieved instance
-
setLocalConnector
public void setLocalConnector(String metadataCollectionId, LocalOMRSRepositoryConnector localConnector) Save the connector to the local repository. This is passed from the OMRSConnectorManager.- Specified by:
setLocalConnector
in interfaceOMRSConnectorConsumer
- Parameters:
metadataCollectionId
- Unique identifier for the metadata collection.localConnector
- OMRSRepositoryConnector object for the local repository.
-
addRemoteConnector
public void addRemoteConnector(String metadataCollectionId, OMRSRepositoryConnector remoteConnector) Pass the connector to one of the remote repositories in the metadata repository cohort.- Specified by:
addRemoteConnector
in interfaceOMRSConnectorConsumer
- Parameters:
metadataCollectionId
- Unique identifier for the metadata collection.remoteConnector
- OMRSRepositoryConnector object providing access to the remote repository.
-
removeRemoteConnector
Pass the metadata collection id for a repository that has just left the metadata repository cohort.- Specified by:
removeRemoteConnector
in interfaceOMRSConnectorConsumer
- Parameters:
metadataCollectionId
- identifier of the metadata collection that is no longer available.
-
disconnectAllConnectors
public void disconnectAllConnectors()The OMRS is about to shut down. Call disconnect() on all registered remote connectors and stop calling them. There is no need to disconnect the local connector - that is handled by the EnterpriseConnectorManager- Specified by:
disconnectAllConnectors
in interfaceOMRSConnectorConsumer
-