-
Notifications
You must be signed in to change notification settings - Fork 136
Open
Labels
bugSomething isn't workingSomething isn't working
Description
Description
Summary
The GCP plugin parses relationship-shaped fields in compute resources but does not consistently materialize them as graph edges. Two confirmed gaps are:
GcpAddress.usersdoes not create aninstance -> addressedge.GcpInstance.disks[].sourcedoes not create aninstance -> diskedge.
This leaves graph traversal incomplete and causes selectors or reports that depend on graph edges to miss real GCP relationships.
Impact
- Attached disks can appear disconnected from the instances that use them.
- Reserved or attached addresses can appear unlinked from the instances that consume them.
- Traversal-based queries underreport valid compute relationships.
Affected Files And Changes
plugins/gcp/fix_plugin_gcp/resources/compute.py- Add
gcp_instancetoGcpAddresspredecessor metadata. - Update
GcpAddress.connect_in_graph()to convertusersinto instance-to-address edges. - Update
GcpInstance.connect_in_graph()to convert attached disksourcelinks into instance-to-disk edges.
- Add
plugins/gcp/test/test_compute.py- Add regression coverage for address user linkage.
- Add regression coverage for attached disk linkage.
Expected Behavior
GcpAddress.usersshould create a graph edge from the referenced instance to the address.GcpInstance.disks[].sourceshould create a graph edge from the instance to each referenced disk.- Duplicate relationship reports should still resolve cleanly at the graph layer.
Version
v4.3.0
Environment
Docker
Steps to Reproduce
- Collect inventory
- Query for disks attached to an instance: search for is(gcp_disk) with (any, <-- is(gcp_instance))
- Observe that no results are returned when cloud environment has instances with disks attached.
Logs
Additional Context
No response
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working