Configure the Google Cloud Logging service to auto-update the CMDB

  • Rversion finale: Australia
  • Mis à jour 12 mars 2026
  • 1 minute de lecture
  • You can activate the Google Cloud Logging (formerly Stackdriver Logging) service to auto-update Configuration Management Database (CMDB) configuration items (CI) data whenever Google Cloud Connector or your Google account makes a life-cycle state or configuration change to a Google Cloud Platform (GCP) resource. As a result, the CI data in the CMDB is updated without having to wait for Discovery to run.

    Avant de commencer

    Role required:
    • discovery_admin for Cloud Discovery and sn_cmp.cloud_event_integration if authentication to cloud event endpoint is required. This role is required to set up an Alert Rule in the instance.
    • Google Cloud Platform administrator for configuration steps in the GCP console.
    • Logging Role for the Google Cloud Platform integration user that would allow OAuth scopes for the following

      • https://www.googleapis.com/auth/logging.admin
      • https://www.googleapis.com/auth/cloud-platform.read-only
      • https://www.googleapis.com/auth/cloud-platform
      • https://www.googleapis.com/auth/logging.read

    Pourquoi et quand exécuter cette tâche

    Discovery integrates with Google Cloud's Cloud Logging API to collect log data from resources in your Google Cloud projects. This integration enables Discovery to automatically update the CMDB based on log entries that reflect changes in your environment. The Cloud Logging service provides:
    • Centralized log collection for Google Cloud resources.
    • APIs to query and export logs for operational workflows.

    When configured, Discovery pulls the Cloud Logging API at regular intervals to detect updates and synchronize them with the CMDB.

    Procédure

    1. Log in to your Google Cloud Platform account.
      For your project, navigate to APIs & Services > Library.
    2. Enable the Cloud Logging API.
      1. In the library, search for Cloud Logging.
      2. Select the Cloud Logging API card.
      3. On the Cloud Logging API page, select Enable.
    3. To modify the schedule, navigate to System Scheduler > Scheduled Jobs and then select GCP-Events-job and then update the Repeat setting as needed.
      Google Cloud Event Scheduler form
    4. Select Update.

    Résultats

    • Once the Google Cloud Platform generates an event and Discovery receives the event information, the 'GCP-Events-job' scheduled jobs execute in the background.

    • The scheduled job passes the event payload to the Identification and Reconciliation Engine (IRE). The IRE then takes the necessary actions to modify the state of the resources based on the event.