Google Cloud Platform (GCP) AlloyDB for PostgreSQL discovery using patterns

  • Release version: Xanadu
  • Updated July 3, 2025
  • 3 minutes to read
  • Summarize
    Summarized using AI
    This content was generated using new OpenAI-powered functionality. Results are provided on an as is basis and are not guaranteed to be accurate or complete.

    Summary of Google Cloud Platform (GCP) AlloyDB for PostgreSQL discovery using patterns

    This documentation describes how ServiceNow's Discovery and Service Mapping Patterns use the Google Cloud Platform (GCP) AlloyDB for PostgreSQL pattern to discover AlloyDB for PostgreSQL resources during horizontal discovery. This enables automated population of your CMDB with detailed AlloyDB resource data, facilitating accurate asset and dependency tracking within your cloud environment.

    Show full answer Show less

    To successfully use this pattern, customers must ensure they meet GCP discovery prerequisites and may need to update to the latest Discovery and Service Mapping Patterns application from the ServiceNow Store.

    Key Features

    • Resource Discovery: Automatically discovers AlloyDB for PostgreSQL components such as Cloud Service Accounts, Availability Zones, Google Datacenters, Cloud Database Clusters, and Cloud Databases.
    • Comprehensive CMDB Population: Discovers and populates key attributes for each resource type, including project identifiers, datacenter details, cluster statuses, database operational status, CPU counts, IP addresses, and replication types.
    • Dependency Mapping: Establishes relationships among discovered CIs, such as which databases are hosted on which datacenters, cluster membership, replication links, and availability zone containment, enabling visualization of resource dependencies on the Dependency Views map.
    • Tag Collection: Gathers resource tags and records them in the Key Value [cmdbkeyvalue] table, associating tags with both Cloud Databases and Cloud Database Clusters for enhanced filtering and categorization.

    What Customers Can Expect

    • Accurate and up-to-date discovery of AlloyDB for PostgreSQL instances and clusters within their GCP environment.
    • Populated CMDB entries with detailed attributes to support operational insight, compliance, and auditing.
    • Visualized dependency maps illustrating relationships between databases, clusters, datacenters, and availability zones to assist in impact analysis and service mapping.
    • Tag information integrated into the CMDB to enable better resource management and reporting.
    • Improved visibility into the status and configuration of AlloyDB resources, supporting efficient cloud infrastructure management.

    Discovery and Service Mapping Patterns uses the Google Cloud Platform (GCP) - AlloyDB for PostgreSQL pattern to discover AlloyDB for PostgreSQL during horizontal discovery. Discovering some of these resources may require updating to the latest version of the Discovery and Service Mapping Patterns application from the ServiceNow Store.

    Pattern-based discovery and mapping requirements

    Verify the GCP discovery prerequisites section in Google Cloud Platform (GCP) Cloud components discovery using Patterns.

    Data collected by Discovery during horizontal discovery

    Discovery populates the data in the CMDB when running the Google Cloud Platform (GCP) - AlloyDB for PostgreSQL pattern.

    Table 1. Cloud Service Account [cmdb_ci_cloud_service_account]
    Field Description
    Account Id [account_id] Name of the project used for the discovery.
    Object ID [object_id] Name of the project used for the discovery.
    Datacenter Type [datacenter_type] Datacenter type: Google Datacenter [cmdb_ci_google_datacenter].
    Table 2. Availability Zone [cmdb_ci_availability_zone]
    Field Description
    Name [name] Name of the availability zone.
    Description [short_description] Description of the availability zone.
    State [state] State of the Availability Zone. Possible values are Available or Terminated.
    Table 3. Google Datacenter [cmdb_ci_google_datacenter]
    Field Description
    Name [name] Datacenter or region name.
    Region [region] Datacenter or region name.
    Object ID [object_id] Unique identifier allocated by GCP for this resource.
    Description [short_description] Datacenter or region description.
    Table 4. Cloud DataBase Cluster [cmdb_ci_cloud_db_cluster]
    Field Description
    Cluster ID [cluster_id] The GCP system-generated unique identifier (UID) of the resource.
    Name [name] Name of the cluster resource.
    Automated Backups [automated_backup] Determines whether automated backups are enabled.

    Possible values are Enabled or Disabled.

    Install Status [install_status] Install status of the cluster. Default value is Installed.
    Operational status [operational_status] Operational status of the cluster. Default value is Operational.
    Cluster Status [cluster_status] Current state of this cluster.​

    For example: READY or STOPPED.

    Cluster Version [cluster_version] Optional field that displays the database engine's major version.
    Cluster Type [cluster_type] Type of cluster.

    Possible values are AlloyDB – Primary cluster or AlloyDB – Secondary cluster.

    Table 5. Cloud DataBase [cmdb_ci_cloud_database]
    Field Description
    Object ID [object_id] The GCP system-generated UID of the resource.
    Name [name] Name of the instance resource.
    Install Status [install_status] Install status of the database. Default value is Installed.
    Operational status [operational_status] Operational status of the database. Default value is Operational.
    State [state] State of the database.

    Possible values are Available or Terminated.

    CPU Count [cpu_count] Number of central processing units (CPUs) in the virtual machine (VM) instance.
    Type [type] Type of database: AlloyDB – PostgreSQL.
    Replication Type [replication_type] Type of the instance specified at creation time.

    For example: Primary instance, Read pool instance, or Secondary instance.

    IP Address [ip_address] IP address for the Instance, which is the endpoint for an end-user application.

    On the Dependency Views map, you can view all discovered AlloyDB for PostgreSQL resources in your organization and the relationships between them.

    Figure 1. AlloyDB for PostgreSQL instance dependency view
    AlloyDB for PostgreSQL instance CIs and connections on a Dependency View map
    Figure 2. AlloyDB for PostgreSQL Cluster dependency view
    AlloyDB for PostgreSQL Cluster CIs and connections on a Dependency View map

    CI relationships

    Discovery creates these relationships to support the AlloyDB for PostgreSQL discovery.

    CI Relationship CI
    Availability Zone [cmdb_ci_availability_zone] Contains::Contained by Cloud DataBase [cmdb_ci_cloud_database]
    Cloud DataBase [cmdb_ci_cloud_database] Hosted on::Hosts Google Datacenter [cmdb_ci_google_datacenter]
    Cloud DataBase Cluster [cmdb_ci_cloud_db_cluster] Cluster of::Cluster Cloud DataBase [cmdb_ci_cloud_database]
    Cloud DataBase Cluster [cmdb_ci_cloud_db_cluster] Hosted on::Hosts Google Datacenter [cmdb_ci_google_datacenter]
    Cloud DataBase Cluster [cmdb_ci_cloud_db_cluster] Replicates::Replicated by Cloud DataBase Cluster [cmdb_ci_cloud_db_cluster]
    Key Value [cmdb_key_value] References Cloud DataBase [cmdb_ci_cloud_database]
    Key Value [cmdb_key_value] References Cloud DataBase Cluster [cmdb_ci_cloud_db_cluster]

    Tag discovery

    The Google Cloud Platform (GCP) - AlloyDB for PostgreSQL pattern collects tags and populates them in two entries in the Key Value [cmdb_key_value] table. One entry references the Cloud DataBase table, the other entry references the Cloud DataBase Cluster table.

    Table 6. Key Value [cmdb_key_value]
    Field Description
    Key [key] Tag key.
    Value [value] Tag value.
    Configuration item [configuration_item] References the Cloud DataBase [cmdb_ci_cloud_database] table
    Configuration item [configuration_item] References the Cloud DataBase Cluster [cmdb_ci_cloud_db_cluster] table