Skip to content

feat: Add Datadog schema hooks - #701

Open
lannuttia wants to merge 3 commits into
python-jsonschema:mainfrom
lannuttia:feat/add-datadog-support
Open

feat: Add Datadog schema hooks#701
lannuttia wants to merge 3 commits into
python-jsonschema:mainfrom
lannuttia:feat/add-datadog-support

Conversation

@lannuttia

@lannuttia lannuttia commented Aug 5, 2026

Copy link
Copy Markdown

Add Datadog schema hooks from https://github.com/DataDog/schema.

Closes #702.

This PR adds three new pre-commit hooks for validating Datadog configuration files:

  • check-datadog-continuous-testing - Validates Datadog Continuous Testing configuration files
  • check-datadog-service-definition - Validates Datadog Service Definition files
  • check-datadog-software-catalog - Validates Datadog Software Catalog entity files

All schemas are sourced from the official DataDog/schema repository on GitHub.

- Add check-datadog-continuous-testing hook for datadog-ci.(json|yml|yaml)
- Add check-datadog-service-definition hook for service.datadog.(json|yml|yaml)
- Add check-datadog-software-catalog hook for entity.datadog.(json|yml|yaml)

All three schemas are from DataDog/schema repository under Apache 2.0 license.
Schemas support remote $ref dependencies which are resolved automatically.

@sirosen sirosen left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

This seems like a perfectly good addition; can we add a bit of testing to make sure that the hooks are, and stay, in good working order?

You can see some tests for hook patterns here, and there's a suite of tests here which automatically check schemas against examples in tests/example-files/hooks/.

I also had a minor note for the changelog.

Comment thread CHANGELOG.rst
``check-datadog-service-definition``, and ``check-datadog-software-catalog``.
Thanks :user:`lannuttia`! (:issue:`702`, :pr:`701`)

.. vendor-insert-here

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Minor, but let's put this note down below this comment; the vendoring script uses the comment to insert the Update vendored schemas: ... entries.

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

New vendored schemas: Datadog

2 participants