Repository navigation
Add build-time catalog validation for existing interface templates - #8456
Open
somethingwithproof wants to merge 4 commits into
Open
somethingwithproof wants to merge 4 commits into
somethingwithproof wants to merge 4 commits into
Conversation
somethingwithproof
requested review from
cigamit
and removed request for
a team
October 22, 2026 21:44
3 tasks done
github-actions
Bot
force-pushed
the
feature/interface-catalog-foundation
branch
4 times, most recently
from
October 27, 2026 20:46
1a5ba19 to
ade0d70
Compare
somethingwithproof
force-pushed
the
feature/interface-catalog-foundation
branch
2 times, most recently
from
November 9, 2026 05:24
9ac5cc0 to
87ea49a
Compare
github-actions
Bot
force-pushed
the
feature/interface-catalog-foundation
branch
4 times, most recently
from
November 11, 2026 21:10
bfc2d11 to
a22360b
Compare
github-actions
Bot
force-pushed
the
feature/interface-catalog-foundation
branch
4 times, most recently
from
November 17, 2026 08:49
81baba6 to
d386f61
Compare
TheWitness
requested changes
Nov 17, 2026
TheWitness
left a comment
Member
There was a problem hiding this comment.
This requires a design review and agreement by the team.
github-actions
Bot
force-pushed
the
feature/interface-catalog-foundation
branch
from
November 17, 2026 20:48
d386f61 to
983d7a2
Compare
Member
Author
Understood. I'll hold this until the team has looked at the approach. The open questions are:
It changes no runtime files, only build-time validation. I'm happy to move the discussion to #7354, and to cut this down or close it depending on what the team prefers. |
github-actions
Bot
force-pushed
the
feature/interface-catalog-foundation
branch
8 times, most recently
from
November 25, 2026 20:50
8d348e4 to
076130a
Compare
Signed-off-by: Thomas Vincent <thomasvincent@gmail.com>
Signed-off-by: Thomas Vincent <thomasvincent@gmail.com>
Signed-off-by: Thomas Vincent <thomasvincent@gmail.com>
…ters The binding check only proved that each declared field fed its RRD item somewhere, so a regenerated package that also bound a field to the other direction, or bound one RRD item twice in a graph, still passed. Require each declared field to be bound exactly once and only to its own RRD item. The width check accepted any ifXTable column as 64-bit, but the multicast and broadcast packet columns there are Counter32. Pin the four IF-MIB octet counter OIDs by direction and width instead. Document how to update the pinned fingerprints after a template package or query regeneration. Signed-off-by: Thomas Vincent <thomasvincent@gmail.com>
github-actions
Bot
force-pushed
the
feature/interface-catalog-foundation
branch
from
November 26, 2026 08:51
076130a to
25ae181
Compare
|
This branch has not been deployed
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.



This change adds automatic build-time checks for Cacti 1.3’s existing interface templates. A catalog and schema describe the shipped fields, identities and dependencies, and tests compare them with the existing query and signed package while preserving their output. This prepares a safer foundation for template maintenance; it does not add new vendor templates or monitoring metrics.
Why
The #7354 audit found 12 of the 30 bundled template packages at risk of drift and 2 likely stale. Aruba OSCX also ships 32-bit traffic graphs on 10G ports, which wrap within seconds at line rate. Fixing these means editing or replacing shipped templates. Today nothing checks that an edit is safe, and the mistakes are silent:
ifInOctetsinstead ofifHCInOctetsstill graphs, but wraps and under-reports on fast links.This PR adds those checks for the interface family, which nearly every Cacti install uses. It doesn't change its output. Later template fixes from #7354 can then be checked the same way before they ship.
What changes
Add a build-time catalog and strict schema for the existing IF-MIB/IF-X-MIB interface family on develop (Cacti 1.3). The renderer reproduces all 42 shipped query fields byte for byte. Explicit native query/data/graph hashes, 66 dependency references and traffic-counter contracts are checked against the existing signed package.
The standalone query and package-embedded query already differ upstream, so their fingerprints are preserved independently. The tool does not rewrite or re-sign either artifact.
Related to #7354.
Verification
PHP fixtures were verified at
9304e7543and the Python suite ata49d2ac0f, using Python 3.12.12, PHP 8.5.12, RRDtool 1.11.0 and a disposable MariaDB 13.0.2 schema:The native tests use the actual query importer and SQL helpers, canonical tables, repeated imports, administrator-added suggested values, and temporary RRD updates covering counter precision, wraps, resets and outages. Mutation tests reject unrelated existing graphs and invalid metric bindings. Native CI is registered for MariaDB 10.11/MySQL 8.4 at PHP 8.3. See the revision-specific check snapshot below.
Known upstream CI failure: the Deepness multiselect palette assertion also fails on the unchanged develop base
a9c73cfc4(base run, PR run). This PR changes neither the theme files nor those browser tests. See the revision-specific check snapshot below.Compatibility and limits
Runtime behavior, database schemas, installer interfaces and PHP/Spine protocols remain unchanged. Existing query XML, signed packages and runtime source have no diff. This PR targets Cacti 1.3 only.
The fixture uses controlled dependency IDs and does not establish full installed graph creation, an installer/upgrade rehearsal or hardware validation. Existing COUNTER reset/wrap ambiguity is preserved and documented.
Revision and checks
Description scope: target
develop, 12 changed files, heada49d2ac0f. Checked 2026-10-23 03:06:04 UTC.GitHub check snapshot: 44 passed, 1 failed, 2 skipped. Checks needing attention:
chromium. Local test figures and earlier CI runs above are recorded evidence for their stated revisions and environments; they do not assert that every check passes at this head.