Class OMFOutTopicClientConnector
java.lang.Object
org.odpi.openmetadata.frameworks.connectors.Connector
org.odpi.openmetadata.frameworks.connectors.ConnectorBase
org.odpi.openmetadata.repositoryservices.connectors.openmetadatatopic.OpenMetadataTopicConsumerBase
org.odpi.openmetadata.repositoryservices.connectors.openmetadatatopic.OpenMetadataTopicListenerConnectorBase
org.odpi.openmetadata.frameworkservices.omf.connectors.outtopic.OMFOutTopicClientConnector
- All Implemented Interfaces:
AuditLoggingComponent,SecureConnectorExtension,VirtualConnectorExtension,OpenMetadataEventInterface,OpenMetadataTopicListener
public class OMFOutTopicClientConnector
extends OpenMetadataTopicListenerConnectorBase
implements OpenMetadataEventInterface
OMFOutTopicClientConnector is the java base class implementation of
the client side connector that receives events from the Open Metadata Store's OutTopic.
-
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.openmetadatatopic.OpenMetadataTopicConsumerBase
connectionName, embeddedConnectors, eventBusConnectorsFields inherited from class org.odpi.openmetadata.frameworks.connectors.ConnectorBase
auditLog, connectionBean, connectorInstanceId, messageFormatter, secretsStoreConnectorMap -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidprocessEvent(String event) Pass an event received from the topic to each registered listener.voidregisterListener(String userId, OpenMetadataEventListener listener) Register a listener object that will be passed each of the events published by the Open Metadata Store.Methods inherited from class org.odpi.openmetadata.repositoryservices.connectors.openmetadatatopic.OpenMetadataTopicListenerConnectorBase
disconnect, getEventBean, initializeEmbeddedConnectorsMethods inherited from class org.odpi.openmetadata.repositoryservices.connectors.openmetadatatopic.OpenMetadataTopicConsumerBase
getConnectorComponentDescription, setAuditLog, start, validateEventBusConnectorsMethods inherited from class org.odpi.openmetadata.frameworks.connectors.ConnectorBase
combineConfigurationProperties, disconnectConnectors, equals, fromCamelToCanonicalCase, fromCanonicalToCamelCase, fromCanonicalToKebabCase, fromCanonicalToSnakeCase, fromKebabToCanonicalCase, fromSnakeToCanonicalCase, getArrayConfigurationProperty, getArrayConfigurationProperty, getArrayConfigurationProperty, getArrayValue, getBooleanConfigurationProperty, getConnection, getConnectorInstanceId, getDateConfigurationProperty, getIntConfigurationProperty, getLongConfigurationProperty, getSecretsCollectionName, getSecretsLocation, getSecretsProvider, getStringConfigurationProperty, getStringConfigurationProperty, getSuppliedPlaceholderProperties, hashCode, initialize, initializeSecretsStoreConnector, isActive, logExceptionRecord, logExceptionRecord, logRecord, logRecord, throwMissingConfigurationProperty, throwMissingElement, throwMissingEndpointAddress, throwMissingResource, throwNoAsset, throwWrongTypeOfAsset, throwWrongTypeOfResource, throwWrongTypeOfRootSchema, toStringMethods inherited from class org.odpi.openmetadata.frameworks.connectors.Connector
clearStatisticProperty, clearStatisticTimestamp, getConnectorStatistics, getStatisticCounter, getStatisticProperty, getStatisticTimestamp, incrementStatisticCounter, initializeStatisticCounter, refreshStatistics, setStatisticProperty, setStatisticTimestamp
-
Constructor Details
-
OMFOutTopicClientConnector
public OMFOutTopicClientConnector()
-
-
Method Details
-
registerListener
public void registerListener(String userId, OpenMetadataEventListener listener) throws InvalidParameterException Register a listener object that will be passed each of the events published by the Open Metadata Store.- Specified by:
registerListenerin interfaceOpenMetadataEventInterface- Parameters:
userId- calling userlistener- listener object- Throws:
InvalidParameterException- one of the parameters is null or invalid.
-
processEvent
Pass an event received from the topic to each registered listener.
This method is deliberately not synchronized. A listener may call into its server, and if that code holds a lock of its own while disconnecting this connector - which needs this connector's lock - the two threads deadlock. That is what happened when an engine host shut down while an engine action event was being delivered. The events from a topic arrive on a single listener thread, so they are still delivered one at a time and in order.- Specified by:
processEventin interfaceOpenMetadataTopicListener- Specified by:
processEventin classOpenMetadataTopicListenerConnectorBase- Parameters:
event- inbound event
-