java.lang.Object
org.odpi.openmetadata.frameworks.connectors.ConnectorProvider
org.odpi.openmetadata.repositoryservices.localrepository.repositoryconnector.LocalOMRSConnectorProvider

public class LocalOMRSConnectorProvider extends ConnectorProvider
LocalOMRSConnectorProvider implements the connector provider for LocalOMRSRepositoryConnector. Since a server only has one LocalOMRSRepositoryConnector, this connector provider returns the singleton connector for the local repository.
  • Constructor Details

    • LocalOMRSConnectorProvider

      public LocalOMRSConnectorProvider(String localMetadataCollectionId, LocalRepositoryMode localRepositoryMode, Connection localRepositoryRemoteConnection, OMRSRepositoryEventMapperConnector realEventMapper, OMRSRepositoryEventManager outboundRepositoryEventManager, OMRSRepositoryContentManager repositoryContentManager, OMRSRepositoryEventExchangeRule saveExchangeRule, AuditLog auditLog)
      Constructor used by OMRSOperationalServices during server start-up. It provides the configuration information about the local server that is used to set up the local repository connector.
      Parameters:
      localMetadataCollectionId - metadata collection id for the local repository
      localRepositoryMode - style of operation to perform
      localRepositoryRemoteConnection - connection object for creating a remote connector to this repository.
      realEventMapper - optional event mapper for local repository
      outboundRepositoryEventManager - event manager to call for outbound events.
      repositoryContentManager - repositoryContentManager for supporting OMRS in managing TypeDefs.
      saveExchangeRule - rule to determine what events to save to the local repository.
      auditLog - logging destination
    • LocalOMRSConnectorProvider

      public LocalOMRSConnectorProvider()
      Constructor used by the OCF ConnectorBroker. This approach will result in an exception when getConnector is called because there is no localMetadataCollectionId (amongst other things).
  • Method Details

    • getConnectorTypeProperties

      public ConnectorTypeProperties getConnectorTypeProperties()
      Returns the properties about the type of connector that this Connector Provider supports.
      Specified by:
      getConnectorTypeProperties in class ConnectorProvider
      Returns:
      properties including the name of the connector type, the connector provider class and any specific connection properties that are recognized by this connector.
    • getConnectorType

      public ConnectorType getConnectorType()
      Returns the properties about the type of connector that this Connector Provider supports.
      Specified by:
      getConnectorType in class ConnectorProvider
      Returns:
      properties including the name of the connector type, the connector provider class and any specific connection properties that are recognized by this connector.
    • getConnector

      public Connector getConnector(Connection realLocalConnection) throws ConnectionCheckedException, ConnectorCheckedException
      Creates a new instance of a connector based on the information in the supplied connection.
      Specified by:
      getConnector in class ConnectorProvider
      Parameters:
      realLocalConnection - connection that should have all the properties needed by the Connector Provider to create a connector instance.
      Returns:
      Connector instance of the LocalOMRSRepositoryConnector wrapping the real local connector.
      Throws:
      ConnectionCheckedException - if there are missing or invalid properties in the connection
      ConnectorCheckedException - if there are issues instantiating or initializing the connector
    • getConnector

      public Connector getConnector(ConnectionProperties realLocalConnection) throws ConnectionCheckedException, ConnectorCheckedException
      Creates a new instance of a connector based on the information in the supplied connection.
      Specified by:
      getConnector in class ConnectorProvider
      Parameters:
      realLocalConnection - connection that should have all the properties needed by the Connector Provider to create a connector instance.
      Returns:
      Connector instance of the LocalOMRSRepositoryConnector wrapping the real local connector.
      Throws:
      ConnectionCheckedException - if there are missing or invalid properties in the connection
      ConnectorCheckedException - if there are issues instantiating or initializing the connector