Class BitolDocumentPublisherIntegrationConnector
java.lang.Object
org.odpi.openmetadata.frameworks.connectors.Connector
org.odpi.openmetadata.frameworks.connectors.ConnectorBase
org.odpi.openmetadata.frameworks.integration.connectors.IntegrationConnectorBase
org.odpi.openmetadata.frameworks.integration.connectors.DynamicIntegrationConnectorBase
org.odpi.openmetadata.adapters.connectors.integration.bitol.BitolDocumentPublisherIntegrationConnector
- All Implemented Interfaces:
AuditLoggingComponent,SecureConnectorExtension,VirtualConnectorExtension,CatalogTargetFactory,IntegrationConnector,OpenMetadataEventListener
public class BitolDocumentPublisherIntegrationConnector
extends DynamicIntegrationConnectorBase
implements OpenMetadataEventListener
BitolDocumentPublisherIntegrationConnector is the outbound side of Egeria's Bitol support. It generates an Open Data
Product Standard (ODPS) document for each digital product, and an Open Data Contract Standard (ODCS) document for each
data sharing agreement, and publishes them to the Bitol listeners registered in the same integration daemon (for
example the file store connector, which writes them to a directory ready to commit to git).
Documents are generated on each refresh: for every product that is a member of a DigitalProductCatalog catalog target (together with the agreements referenced by the product's ports), and for each digital product or agreement that an event has reported a change to since the last refresh. Each element is generated at most once per refresh, however many events arrived for it and however many products share it. Generating a document takes thousands of reads, and a product receives many events in a burst - create, update, classify, reclassify - so generating on every event left the connector hours behind its events on a busy repository. Each process that the lineage shows assembling a product's data becomes an input port of the product; a process with no data contract gets a sparsely populated draft one, catalogued and published with the product so that it can be filled out later.
A document is only published when its content differs from the last document generated for the same element, so a cataloguer running in the same daemon does not cause an endless exchange of identical documents.
Documents are generated on each refresh: for every product that is a member of a DigitalProductCatalog catalog target (together with the agreements referenced by the product's ports), and for each digital product or agreement that an event has reported a change to since the last refresh. Each element is generated at most once per refresh, however many events arrived for it and however many products share it. Generating a document takes thousands of reads, and a product receives many events in a burst - create, update, classify, reclassify - so generating on every event left the connector hours behind its events on a busy repository. Each process that the lineage shows assembling a product's data becomes an input port of the product; a process with no data contract gets a sparsely populated draft one, catalogued and published with the product so that it can be filled out later.
A document is only published when its content differs from the last document generated for the same element, so a cataloguer running in the same daemon does not cause an endless exchange of identical documents.
-
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.frameworks.integration.connectors.IntegrationConnectorBase
catalogTargetsManager, connectorName, integrationContext, propertyHelperFields inherited from class org.odpi.openmetadata.frameworks.connectors.ConnectorBase
auditLog, connectionBean, connectorInstanceId, embeddedConnectors, messageFormatter, secretsStoreConnectorMap -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiongetNewRequestedCatalogTargetSkeleton(CatalogTarget retrievedCatalogTarget, CatalogTargetContext catalogTargetContext, Connector connectorToTarget) Create a new catalog target processor.voidProcess an event from the open metadata server.voidrefresh()Generate the documents for the catalog targets' products, and then for the products and agreements that events have reported changes to and that the catalog targets did not cover.voidstart()Indicates that the connector is completely configured and can begin processing.Methods inherited from class org.odpi.openmetadata.frameworks.integration.connectors.IntegrationConnectorBase
disconnect, engage, getConnectorComponentDescription, getNetworkAddress, passEventToCatalogTargets, refreshCatalogTargets, setAuditLog, setConnectorName, setContextMethods 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, initializeEmbeddedConnectors, 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, setStatisticTimestampMethods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface org.odpi.openmetadata.frameworks.connectors.VirtualConnectorExtension
initializeEmbeddedConnectors
-
Constructor Details
-
BitolDocumentPublisherIntegrationConnector
public BitolDocumentPublisherIntegrationConnector()Default constructor
-
-
Method Details
-
start
Indicates that the connector is completely configured and can begin processing.- Specified by:
startin interfaceIntegrationConnector- Overrides:
startin classIntegrationConnectorBase- Throws:
ConnectorCheckedException- there is a problem within the connector.UserNotAuthorizedException- the connector was disconnected before/during start
-
refresh
Generate the documents for the catalog targets' products, and then for the products and agreements that events have reported changes to and that the catalog targets did not cover.- Specified by:
refreshin interfaceIntegrationConnector- Overrides:
refreshin classDynamicIntegrationConnectorBase- Throws:
ConnectorCheckedException- there is a problem with the connector.UserNotAuthorizedException- the connector was disconnected before/during the refresh
-
processEvent
Process an event from the open metadata server. A change to a digital product or data sharing agreement is noted, and its document is regenerated and published by the next refresh.- Specified by:
processEventin interfaceOpenMetadataEventListener- Overrides:
processEventin classDynamicIntegrationConnectorBase- Parameters:
event- event object
-
getNewRequestedCatalogTargetSkeleton
public RequestedCatalogTarget getNewRequestedCatalogTargetSkeleton(CatalogTarget retrievedCatalogTarget, CatalogTargetContext catalogTargetContext, Connector connectorToTarget) throws ConnectorCheckedException, UserNotAuthorizedException Create a new catalog target processor. DigitalProductCatalog catalog targets have every member product (and the contracts they reference) regenerated on each refresh; other catalog targets are ignored.- Specified by:
getNewRequestedCatalogTargetSkeletonin interfaceCatalogTargetFactory- Specified by:
getNewRequestedCatalogTargetSkeletonin classDynamicIntegrationConnectorBase- Parameters:
retrievedCatalogTarget- the catalog target information retrieved from the open metadata repositorycatalogTargetContext- specialized integration context for this catalog targetconnectorToTarget- connector to access the target resource- Returns:
- new processor based on the catalog target information
- Throws:
ConnectorCheckedException- problem setting up the processorUserNotAuthorizedException- the connector was disconnected before/during start
-