Conversation
…bels
Relationship labels like RESOURCE repeat across 425+ schemas, making
the metric `relationship.resource.loaded` useless for distinguishing
what was loaded. Include source and target node labels in the metric
name: `relationship.{src}.{rel}.{tgt}.loaded`.
Addresses post-merge feedback from heryxpc on PR #2331.
Co-Authored-By: Claude Opus 4.6 <[email protected]>
Signed-off-by: Jeremy Chapeau <[email protected]>
kunaals
approved these changes
Feb 13, 2026
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.
Type of change
Summary
Relationship labels like
RESOURCErepeat across 425+ schemas (e.g.EC2Instance->AWSAccount,S3Bucket->AWSAccount,AzureSubnet->AzureSubscription), making the current metricrelationship.resource.loadeduseless for distinguishing what was actually loaded.This changes the
load_matchlinks()metric to include source and target node labels:Before:
relationship.{rel_label}.loaded(e.g.relationship.resource.loaded)After:
relationship.{src}.{rel}.{tgt}.loaded(e.g.relationship.ec2instance.resource.awsaccount.loaded)The log message is also improved to show the full relationship pattern:
Loaded 42 (EC2Instance)-[RESOURCE]->(AWSAccount) relationships.Related issues or links
Breaking changes
Metric names change from
relationship.{rel_label}.loadedtorelationship.{src}.{rel}.{tgt}.loaded. Any dashboards or alerts referencing the old metric names will need updating.How was this tested?
Unit tests updated and passing (
make test_unit). Pre-commit hooks pass cleanly.Checklist
General
make lint).Proof of functionality
Notes for reviewers
The
source_node_labelonCartographyRelSchemais optional (can beNone), butload_matchlinks()is specifically for matchlink schemas where it should always be set. A fallback to"unknown"is included as a safety measure.