Class EnterpriseOMRSRepositoryConnector

  • All Implemented Interfaces:
    AuditLoggingComponent, OMRSMetadataCollectionManager, org.odpi.openmetadata.repositoryservices.enterprise.connectormanager.OMRSConnectorConsumer

    public class EnterpriseOMRSRepositoryConnector
    extends OMRSRepositoryConnector
    implements org.odpi.openmetadata.repositoryservices.enterprise.connectormanager.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.

    • Method Detail

      • setLocalMetadataCollectionId

        public void setLocalMetadataCollectionId​(java.lang.String localMetadataCollectionId)
        Set the unique id of the metadata collection that is collocated with the Enterprise Metadata Collection
        Parameters:
        localMetadataCollectionId - String unique Id
      • setCallingServiceName

        public void setCallingServiceName​(java.lang.String callingServiceName)
        Set up the name of the access service using this connector.
        Parameters:
        callingServiceName - string name
      • requestRefreshOfEntity

        public void requestRefreshOfEntity​(org.odpi.openmetadata.repositoryservices.connectors.stores.metadatacollectionstore.properties.instances.EntityDetail entity)
        Request the refresh of this instance.
        Parameters:
        entity - retrieved instance
      • requestRefreshOfRelationship

        public void requestRefreshOfRelationship​(org.odpi.openmetadata.repositoryservices.connectors.stores.metadatacollectionstore.properties.instances.Relationship relationship)
        Request the refresh of this instance.
        Parameters:
        relationship - retrieved instance
      • setLocalConnector

        public void setLocalConnector​(java.lang.String metadataCollectionId,
                                      LocalOMRSRepositoryConnector localConnector)
        Save the connector to the local repository. This is passed from the OMRSConnectorManager.
        Specified by:
        setLocalConnector in interface org.odpi.openmetadata.repositoryservices.enterprise.connectormanager.OMRSConnectorConsumer
        Parameters:
        metadataCollectionId - Unique identifier for the metadata collection.
        localConnector - OMRSRepositoryConnector object for the local repository.
      • addRemoteConnector

        public void addRemoteConnector​(java.lang.String metadataCollectionId,
                                       OMRSRepositoryConnector remoteConnector)
        Pass the connector to one of the remote repositories in the metadata repository cohort.
        Specified by:
        addRemoteConnector in interface org.odpi.openmetadata.repositoryservices.enterprise.connectormanager.OMRSConnectorConsumer
        Parameters:
        metadataCollectionId - Unique identifier for the metadata collection.
        remoteConnector - OMRSRepositoryConnector object providing access to the remote repository.
      • removeRemoteConnector

        public void removeRemoteConnector​(java.lang.String metadataCollectionId)
        Pass the metadata collection id for a repository that has just left the metadata repository cohort.
        Specified by:
        removeRemoteConnector in interface org.odpi.openmetadata.repositoryservices.enterprise.connectormanager.OMRSConnectorConsumer
        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 interface org.odpi.openmetadata.repositoryservices.enterprise.connectormanager.OMRSConnectorConsumer