Class AuditableDiscoveryService
java.lang.Object
org.odpi.openmetadata.frameworks.connectors.Connector
org.odpi.openmetadata.frameworks.connectors.ConnectorBase
org.odpi.openmetadata.frameworks.discovery.DiscoveryService
org.odpi.openmetadata.adapters.connectors.discoveryservices.AuditableDiscoveryService
- All Implemented Interfaces:
AuditLoggingComponent
,SecureConnectorExtension
,VirtualConnectorExtension
,OpenDiscoveryService
- Direct Known Subclasses:
CSVDiscoveryService
,DuplicateSuspectDiscoveryService
AuditableDiscoveryService is a base class for discovery services that wish to use the audit log.
-
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.discovery.DiscoveryService
auditLog, discoveryContext, discoveryServiceName, embeddedConnectors
Fields inherited from class org.odpi.openmetadata.frameworks.connectors.ConnectorBase
connectedAssetProperties, connectionBean, connectionProperties, connectorInstanceId, secretsStoreConnectorMap
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected String
getAssetTypeName
(AssetUniverse asset, String methodName) Return the type name for the asset.getNetworkAddresses
(AssetUniverse asset) Return the network address of this asset.protected void
logNoAsset
(String assetGUID, String methodName) Log that no asset has been returned to the discovery service.protected void
logWrongTypeOfAsset
(String assetGUID, String assetType, String supportedAssetType, String methodName) Log that the discovery service can not process the type of asset it has been passed.Methods inherited from class org.odpi.openmetadata.frameworks.discovery.DiscoveryService
disconnect, getConnectorComponentDescription, getDiscoveryContext, getEmbeddedDiscoveryServices, handleUnexpectedException, initializeEmbeddedConnectors, setAuditLog, setDiscoveryContext, setDiscoveryServiceName, start
Methods inherited from class org.odpi.openmetadata.frameworks.connectors.ConnectorBase
disconnectConnectors, equals, getConnectedAssetProperties, getConnection, getConnectorInstanceId, hashCode, initialize, initializeConnectedAssetProperties, initializeSecretsStoreConnector, isActive, toString
Methods inherited from class org.odpi.openmetadata.frameworks.connectors.Connector
clearStatisticProperty, clearStatisticTimestamp, getConnectorStatistics, getStatisticCounter, getStatisticProperty, getStatisticTimestamp, incrementStatisticCounter, initializeStatisticCounter, setStatisticProperty, setStatisticTimestamp
-
Constructor Details
-
AuditableDiscoveryService
public AuditableDiscoveryService()
-
-
Method Details
-
logNoAsset
Log that no asset has been returned to the discovery service. It is unable to proceed without this basic information.- Parameters:
assetGUID
- the unique identifier of the asset from the discovery contextmethodName
- calling method- Throws:
ConnectorCheckedException
- resulting exception
-
logWrongTypeOfAsset
protected void logWrongTypeOfAsset(String assetGUID, String assetType, String supportedAssetType, String methodName) throws ConnectorCheckedException Log that the discovery service can not process the type of asset it has been passed.- Parameters:
assetGUID
- identifier of the assetassetType
- type of the assetsupportedAssetType
- supported asset typesmethodName
- calling method- Throws:
ConnectorCheckedException
- resulting exception
-
getAssetTypeName
protected String getAssetTypeName(AssetUniverse asset, String methodName) throws ConnectorCheckedException Return the type name for the asset. An exception is thrown if the type name is not available.- Parameters:
asset
- asset universemethodName
- calling method- Returns:
- asset's type name
- Throws:
ConnectorCheckedException
- resulting exception
-
getNetworkAddresses
Return the network address of this asset.- Parameters:
asset
- asset to extract address from- Returns:
- the list of network addresses
-