feat: monitor Snapshot Policy Compliance#3857
Merged
rahulguptajss merged 12 commits intomainfrom Aug 25, 2025
Merged
Conversation
Contributor
There was a problem hiding this comment.
Pull Request Overview
This PR adds snapshot policy compliance monitoring by introducing a SnapshotViolation plugin that identifies snapshots not created by snapshot policies. The feature helps administrators monitor and track snapshot governance by highlighting volumes with non-policy snapshots.
- Adds SnapshotViolation plugin for both REST and ZAPI collectors to monitor snapshot policy compliance
- Updates Grafana data protection dashboard with new violation panels and metrics
- Includes comprehensive test configuration updates and documentation for new violation metrics
Reviewed Changes
Copilot reviewed 15 out of 15 changed files in this pull request and generated 5 comments.
Show a summary per file
| File | Description |
|---|---|
| pkg/api/ontapi/zapi/client.go | Adds streaming API call method to support batch processing of large datasets |
| cmd/collectors/zapi/plugins/snapshotviolation/snapshotviolation.go | Implements ZAPI-based snapshot violation detection plugin |
| cmd/collectors/rest/plugins/snapshotviolation/snapshotviolation.go | Implements REST-based snapshot violation detection plugin |
| cmd/collectors/plugins/snapshotviolation/snapshotviolation.go | Provides shared violation detection logic between REST/ZAPI implementations |
| grafana/dashboards/cmode/data_protection.json | Adds new dashboard panels for displaying snapshot policy violations |
| conf/zapi/cdot/9.8.0/snapshotpolicy.yaml | Updates ZAPI template to include prefix field and violation plugin configuration |
| conf/rest/9.12.0/snapshotpolicy.yaml | Updates REST template to include violation plugin configuration |
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
# Conflicts: # cmd/collectors/zapi/collector/zapi.go # docs/ontap-metrics.md
cgrinds
reviewed
Aug 25, 2025
cgrinds
previously approved these changes
Aug 25, 2025
cgrinds
approved these changes
Aug 25, 2025
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.