Class MSSQLDatabaseStatsExtractor
java.lang.Object
org.odpi.openmetadata.frameworks.auditlog.AuditLoggingBase
org.odpi.openmetadata.adapters.connectors.mssql.survey.MSSQLDatabaseStatsExtractor
MSSQLDatabaseStatsExtractor gathers the same measurements as the PostgreSQL equivalent
(org.odpi.openmetadata.adapters.connectors.postgres.survey.PostgresDatabaseStatsExtractor) but sources
them from Microsoft SQL Server's system catalog views and DMVs (sys.databases, sys.tables, sys.views,
sys.columns, sys.dm_db_partition_stats, sys.dm_db_index_operational_stats, sys.dm_db_stats_histogram)
instead of pg_catalog. All of these sources are metadata/statistics only - no user data is read.
The connections passed to it are expected to be in auto-commit mode, so that every query is its own short transaction. Each schema is surveyed with its own set of queries, and a query that fails is logged and skipped, so one inaccessible schema, missing permission or dropped table leaves a gap in the results rather than ending the survey.
The connections passed to it are expected to be in auto-commit mode, so that every query is its own short transaction. Each schema is surveyed with its own set of queries, and a query that fails is logged and skipped, so one inaccessible schema, missing permission or dropped table leaves a gap in the results rather than ending the survey.
-
Field Summary
Fields inherited from class org.odpi.openmetadata.frameworks.auditlog.AuditLoggingBase
auditLog -
Constructor Summary
ConstructorsConstructorDescriptionMSSQLDatabaseStatsExtractor(List<String> validDatabases, List<String> excludedSchemas, List<String> includedSchemas, SurveyActionServiceConnector surveyActionServiceConnector, AuditLog auditLog, String surveyActionServiceName) Constructor sets up the list of databases to process, the schemas within them to survey, and the connection to the database.MSSQLDatabaseStatsExtractor(List<String> validDatabases, SurveyActionServiceConnector surveyActionServiceConnector) Constructor sets up the list of databases to process and the connection to the database. -
Method Summary
Methods inherited from class org.odpi.openmetadata.frameworks.auditlog.AuditLoggingBase
logExceptionRecord, logExceptionRecord, logRecord, logRecord
-
Constructor Details
-
MSSQLDatabaseStatsExtractor
public MSSQLDatabaseStatsExtractor(List<String> validDatabases, SurveyActionServiceConnector surveyActionServiceConnector) Constructor sets up the list of databases to process and the connection to the database. Every schema in those databases is surveyed.- Parameters:
validDatabases- list of database namessurveyActionServiceConnector- calling connector
-
MSSQLDatabaseStatsExtractor
public MSSQLDatabaseStatsExtractor(List<String> validDatabases, List<String> excludedSchemas, List<String> includedSchemas, SurveyActionServiceConnector surveyActionServiceConnector, AuditLog auditLog, String surveyActionServiceName) Constructor sets up the list of databases to process, the schemas within them to survey, and the connection to the database.- Parameters:
validDatabases- list of database namesexcludedSchemas- schemas to leave out (null means none are excluded)includedSchemas- the only schemas to survey (null means all that are not excluded); takes precedence over excludedSchemassurveyActionServiceConnector- calling connectorauditLog- logging destination for queries that fail (may be null)surveyActionServiceName- name of the calling survey action service, for the audit log
-