driver/database.py
def collect_db_level_observation_for_on_prem(config: DriverConfig) -> DBLevelObservation:
    """
    Get the db level observation data for the target cloud database. It may have multiple sources,
    e.g., runtime knobs/metrics data from the database, metrics from cloudwatch, etc.

    Args:
        config: driver configuration for cloud deployment.
    Returns:
        DB level observation data from the target database.
    Raises:
        DriverConfigException: invalid database configuration.
        DbCollectorException: database type is not supported.
        MysqlCollectorException: unable to connect to MySQL database or get version.
        PostgresCollectorException: unable to connect to Postgres database or get version.
    """
    observation = collect_db_level_data_from_database(config._asdict())
    metrics_from_sources = collect_data_from_metric_sources(config._asdict())
    observation["metrics_data"]["global"].update(metrics_from_sources)
    return observation

    Get the db level observation data for the target cloud database. It may have multiple sources,
    e.g., runtime knobs/metrics data from the database, metrics from cloudwatch, etc.

    Args:
        config: driver configuration for cloud deployment.
    Returns:
        DB level observation data from the target database.
    Raises:
        DriverConfigException: invalid database configuration.
        DbCollectorException: database type is not supported.
        MysqlCollectorException: unable to connect to MySQL database or get version.
        PostgresCollectorException: unable to connect to Postgres database or get version.
    
Get the db level observation data for the target cloud database. It may have multiple sources,
e.g., runtime knobs/metrics data from the database, metrics from cloudwatch, etc.
Get the db level observation data for the target cloud database . It may have multiple sources e . g . runtime knobs / metrics data from the database metrics from cloudwatch etc .
def collect_db_level_observation_for_on_prem(config: DriverConfig) -> DBLevelObservation:
    observation = collect_db_level_data_from_database(config._asdict())
    metrics_from_sources = collect_data_from_metric_sources(config._asdict())
    observation["metrics_data"]["global"].update(metrics_from_sources)
    return observation
def collect_db_level_observation_for_on_prem ( config : DriverConfig ) -> DBLevelObservation : observation = collect_db_level_data_from_database ( config . _asdict ( ) ) metrics_from_sources = collect_data_from_metric_sources ( config . _asdict ( ) ) observation [ "metrics_data" ] [ "global" ] . update ( metrics_from_sources ) return observation
Get the db level observation data for the target cloud database.
Get the db level observation data for the target cloud database .
"""
    Get the db level observation data for the target cloud database. It may have multiple sources,
    e.g., runtime knobs/metrics data from the database, metrics from cloudwatch, etc.

    Args:
        config: driver configuration for cloud deployment.
    Returns:
        DB level observation data from the target database.
    Raises:
        DriverConfigException: invalid database configuration.
        DbCollectorException: database type is not supported.
        MysqlCollectorException: unable to connect to MySQL database or get version.
        PostgresCollectorException: unable to connect to Postgres database or get version.
    """
DB level observation data from the target database.
DB level observation data from the target database .
invalid database configuration.
invalid database configuration .
DriverConfigException
database type is not supported.
database type is not supported .
DbCollectorException
unable to connect to MySQL database or get version.
unable to connect to MySQL database or get version .
MysqlCollectorException
unable to connect to Postgres database or get version.
unable to connect to Postgres database or get version .
PostgresCollectorException
config
DriverConfig
driver configuration for cloud deployment.
driver configuration for cloud deployment .