docs(nautobotop): add resource dependency graph#1911
Merged
Conversation
a388a10 to
75396af
Compare
cardoe
approved these changes
Apr 3, 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.
Updating the Nautobot Operator graph:
The dependency ordering between resources is critical for operators to understand. If you define a VLAN before its VLAN Group exists, the sync will fail. The graph makes this immediately visible. The mermaid fix ensures contributors can preview diagrams locally without deploying to GitHub Pages.
%%{init: {"flowchart": {"defaultRenderer": "elk", "rankSpacing": 200, "nodeSpacing": 50, "curve": "linear"}} }%% flowchart TD subgraph S1["1. Independent resources"] direction LR LOC["Locations"]:::blue TGR["Tenant Groups"]:::orange RIR["RIRs"]:::pink ROLE["Roles"]:::green CT["Cluster Types"]:::red CG["Cluster Groups"]:::red LT["Location Types"]:::grey DT["Device Types"]:::grey end subgraph S2["2. First-level dependents"] direction LR RG["Rack Groups"]:::teal VG["VLAN Groups"]:::purple TEN["Tenants"]:::amber end subgraph S3["3. Second-level dependents"] direction LR RACK["Racks"]:::teal NS["Namespaces"]:::indigo VLAN["VLANs"]:::brown CLUSTER["Clusters"]:::red end subgraph S4["4. Final network resources"] direction LR PREFIX["Prefixes"]:::grey end %% Location edges (blue) LOC --> RG LOC --> VG LOC --> RACK LOC --> NS LOC --> VLAN LOC --> CLUSTER LOC --> PREFIX %% Tenant Group edges (orange) TGR --> TEN TGR --> NS TGR --> VLAN TGR --> PREFIX %% Tenant edges (amber) TEN --> NS TEN --> VLAN TEN --> PREFIX %% Rack Group edges (teal) RG --> RACK %% VLAN Group edges (purple) VG --> VLAN VG --> PREFIX %% Role edges (green) ROLE --> VLAN ROLE --> PREFIX %% Cluster type/group edges (red) CT --> CLUSTER CG --> CLUSTER %% RIR edges (pink) RIR --> PREFIX %% Namespace edges (indigo) NS --> PREFIX %% VLAN edges (brown) VLAN --> PREFIX classDef blue fill:#DBEAFE,stroke:#0969DA,color:#0969DA,stroke-width:2px classDef orange fill:#FFF0E0,stroke:#E5570F,color:#E5570F,stroke-width:2px classDef amber fill:#FEF3C7,stroke:#D4A017,color:#92400E,stroke-width:2px classDef teal fill:#CCFBF1,stroke:#1A8870,color:#1A8870,stroke-width:2px classDef purple fill:#F3E8FF,stroke:#9333EA,color:#9333EA,stroke-width:2px classDef green fill:#DCFCE7,stroke:#16A34A,color:#16A34A,stroke-width:2px classDef red fill:#FEE2E2,stroke:#DC2626,color:#DC2626,stroke-width:2px classDef pink fill:#FCE7F3,stroke:#DB2777,color:#DB2777,stroke-width:2px classDef indigo fill:#E0E7FF,stroke:#4F46E5,color:#4F46E5,stroke-width:2px classDef brown fill:#FDE68A,stroke:#92400E,color:#92400E,stroke-width:2px classDef grey fill:#F3F4F6,stroke:#6B7280,color:#374151,stroke-width:2px linkStyle 0,1,2,3,4,5,6 stroke:#0969DA,stroke-width:2px linkStyle 7,8,9,10 stroke:#E5570F,stroke-width:2px linkStyle 11,12,13 stroke:#D4A017,stroke-width:2px linkStyle 14 stroke:#1A8870,stroke-width:2px linkStyle 15,16 stroke:#9333EA,stroke-width:2px linkStyle 17,18 stroke:#16A34A,stroke-width:2px linkStyle 19,20 stroke:#DC2626,stroke-width:2px linkStyle 21 stroke:#DB2777,stroke-width:2px linkStyle 22 stroke:#4F46E5,stroke-width:2px linkStyle 23 stroke:#92400E,stroke-width:2px