Class OpenMetadataTopicConsumerBase
java.lang.Object
org.odpi.openmetadata.frameworks.connectors.Connector
org.odpi.openmetadata.frameworks.connectors.ConnectorBase
org.odpi.openmetadata.repositoryservices.connectors.openmetadatatopic.OpenMetadataTopicConsumerBase
- All Implemented Interfaces:
AuditLoggingComponent
,SecureConnectorExtension
,VirtualConnectorExtension
- Direct Known Subclasses:
OpenMetadataTopicListenerConnectorBase
,OpenMetadataTopicSenderConnectorBase
public class OpenMetadataTopicConsumerBase
extends ConnectorBase
implements VirtualConnectorExtension, AuditLoggingComponent
OpenMetadataTopicConnectorBase is a base class to topic connectors that only send
events on the embedded event bus connector
-
Nested Class Summary
Nested classes/interfaces inherited from class org.odpi.openmetadata.frameworks.connectors.ConnectorBase
ConnectorBase.ProtectedConnection
-
Field Summary
Modifier and TypeFieldDescriptionprotected AuditLog
protected String
protected List<OpenMetadataTopicConnector>
Fields inherited from class org.odpi.openmetadata.frameworks.connectors.ConnectorBase
connectedAssetProperties, connectionBean, connectionProperties, connectorInstanceId, messageFormatter, secretsStoreConnectorMap
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
Free up any resources held since the connector is no longer needed.Return the component description that is used by this connector in the audit log.void
initializeEmbeddedConnectors
(List<Connector> embeddedConnectors) Set up the list of connectors that this virtual connector will use to support its interface.void
setAuditLog
(AuditLog auditLog) Receive an audit log object that can be used to record audit log messages.void
start()
Indicates that the connector is completely configured and can begin processing.protected void
validateEventBusConnectors
(String methodName) Validates that there is at least one event bus connector receiving events.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, 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
-
Field Details
-
embeddedConnectors
-
eventBusConnectors
-
connectionName
-
auditLog
-
-
Constructor Details
-
OpenMetadataTopicConsumerBase
public OpenMetadataTopicConsumerBase()
-
-
Method Details
-
initializeEmbeddedConnectors
Set up the list of connectors that this virtual connector will use to support its interface. The connectors are initialized waiting to start. When start() is called on the virtual connector, it needs to pass start() to each of the embedded connectors. Similarly for disconnect().- Specified by:
initializeEmbeddedConnectors
in interfaceVirtualConnectorExtension
- Overrides:
initializeEmbeddedConnectors
in classConnectorBase
- Parameters:
embeddedConnectors
- list of connectors
-
setAuditLog
Receive an audit log object that can be used to record audit log messages. The caller has initialized it with the correct component description and log destinations.- Specified by:
setAuditLog
in interfaceAuditLoggingComponent
- Parameters:
auditLog
- audit log object
-
getConnectorComponentDescription
Return the component description that is used by this connector in the audit log.- Specified by:
getConnectorComponentDescription
in interfaceAuditLoggingComponent
- Returns:
- id, name, description, wiki page URL.
-
validateEventBusConnectors
Validates that there is at least one event bus connector receiving events.- Parameters:
methodName
- calling method- Throws:
ConnectorCheckedException
- no event bus connectors available.
-
start
Indicates that the connector is completely configured and can begin processing. OMRSTopicConnector needs to pass on the start() to its embedded connectors.- 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 within the connector.
-