Skip to content

Google Cloud Spanner Query-Level Metrics#24565

Open
amw-zero wants to merge 7 commits into
masterfrom
alex.weisberger/dbmon-6844-spanner-integration
Open

Google Cloud Spanner Query-Level Metrics#24565
amw-zero wants to merge 7 commits into
masterfrom
alex.weisberger/dbmon-6844-spanner-integration

Conversation

@amw-zero

@amw-zero amw-zero commented Jul 15, 2026

Copy link
Copy Markdown
Contributor

What does this PR do?

This introduces a new integration: cloud_spanner. This integration adds query-level metrics for Spanner databases by connecting to the DB and querying tables in the SPANNER_SYS schema.

This integration should be seen as experimental until otherwise communicated.

Motivation

Today, Datadog collects various metrics for Spanner databases, but it does it via the GCP API. This limits what data is available. For example, query metrics are aggregated across all queries, and a per-query breakdown is not supported.

Query-Level Metrics are a staple of Database Monitoring, so we can support a Database Monitoring experience for Spanner by collecting and sending them.

Review checklist (to be filled by reviewers)

  • Feature or bugfix MUST have appropriate tests (unit, integration, e2e)
  • Add qa/required if this PR needs QA validation, or qa/skip-qa if it does not. Exactly one of the two is required.
  • If you need to backport this PR to another branch, you can add the backport/<branch-name> label to the PR and it will automatically open a backport PR once this one is merged

amw-zero and others added 3 commits July 14, 2026 17:59
- Add metadata.csv with 10 spanner.queries.* metrics
- Add assets/service_checks.json (empty)
- Add assets/configuration/spec.yaml with full config schema
- Generate conf.yaml.example and config_models/ via ddev
- Update manifest.json: add app_uuid, owner, fix metrics prefix to spanner.*
- Update pyproject.toml Development Status from Alpha to Beta
- Add README.md with beta notice, setup instructions, and tile sections
- Fix ruff formatting across all Python files in the integration

Environment: Datadog workspace

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@datadog-datadog-prod-us1

datadog-datadog-prod-us1 Bot commented Jul 15, 2026

Copy link
Copy Markdown
Contributor

Pipelines

Fix all issues with BitsAI

⚠️ Warnings

🚦 5 Pipeline jobs failed

PR | test / test (linux, ubuntu-22.04, cloud_spanner, Cloud Spanner (py3.13), py3.13) / Cloud Spanner (py3.13)-py3.13   View in Datadog   GitHub Actions

PR | test / test-minimum-base-package (linux, ubuntu-22.04, cloud_spanner, Cloud Spanner (py3.13), py3.13) / minimum-base-package-Cloud Spanner (py3.13)-py3.13   View in Datadog   GitHub Actions

Validate repository | Run Validations / Validate   View in Datadog   GitHub Actions

View all 5 failed jobs.

Useful? React with 👍 / 👎

This comment will be updated automatically if new data arrives.
🔗 Commit SHA: cfc3510 | Docs | Datadog PR Page | Give us feedback!

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: b10a86a46b

ℹ️ About Codex in GitHub

Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".

Comment thread cloud_spanner/datadog_checks/cloud_spanner/queries.py Outdated
Comment thread cloud_spanner/datadog_checks/cloud_spanner/check.py
@amw-zero amw-zero added the qa/skip-qa Automatically skip this PR for the next QA label Jul 15, 2026
@amw-zero amw-zero changed the title Alex.weisberger/dbmon 6844 spanner integration Google Cloud Spanner Query-Level Metrics Jul 15, 2026
@drichards-87 drichards-87 added the editorial review Waiting on a more in-depth review from a docs team editor label Jul 15, 2026
@drichards-87

Copy link
Copy Markdown
Contributor

Created DOCS-15122 for the editorial review.

@dd-octo-sts

dd-octo-sts Bot commented Jul 15, 2026

Copy link
Copy Markdown
Contributor

Validation Report

Validation Description Status
ci Validate CI configuration and code coverage settings
dep Verify dependency pins are consistent and Agent-compatible
labeler Validate PR labeler config matches integration directories
license-headers Validate Python files have proper license headers
version Validate version consistency between package and changelog

Run ddev validate all changed --fix to attempt to auto-fix supported validations.

Passed validations (16)
Validation Description Status
agent-reqs Verify check versions match the Agent requirements file
codeowners Validate every integration has a CODEOWNERS entry
config Validate default configuration files against spec.yaml
http Validate integrations use the HTTP wrapper correctly
imports Validate check imports do not use deprecated modules
integration-style Validate check code style conventions
jmx-metrics Validate JMX metrics definition files and config
legacy-signature Validate no integration uses the legacy Agent check signature
licenses Validate third-party license attribution list
metadata Validate metadata.csv metric definitions
models Validate configuration data models match spec.yaml
openmetrics Validate OpenMetrics integrations disable the metric limit
package Validate Python package metadata and naming
qa-label Validate the pull request declares whether it needs QA for the next Agent release
readmes Validate README files have required sections
saved-views Validate saved view JSON file structure and fields

View full run

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants