netbox icon indicating copy to clipboard operation
netbox copied to clipboard

Adjust prefix depth when showing child prefixes

Open HeavenBay opened this issue 4 years ago • 6 comments

NetBox version

v3.0.8

Feature type

Change to existing functionality

Proposed functionality

Hi,

We have super-prefix 192.168.0.0/18 in Site1. And prefix 192.168.25.0/24 in Site2. When I filter prefixes by Site2 I see 192.168.25.0/24 as sub-prefix (with dot before it) but I do not see its parent parent-super-prefix from different site. I think that child prefix should not be as child in this case because I did not add super-prefix to its own Site2 netbox_issue_2 netbox_issue_1 .

Use case

For example: I filter my list of prefixes for a Site2 with Depth = 0 and I do not see this child prefix! I also do not see super-prefix from different Site1 because of Site filter. So I started thinking that my Site2 does not have 192.168. prefixes. It is terrible if you try to create summarization for routing.

Thank you.

Database changes

None

External dependencies

None

HeavenBay avatar Oct 31 '21 10:10 HeavenBay

This looks like we just need a more flexible way to indicate when a prefix should be listed in the table with or without its hierarchical depth.

Actually, we already have both the prefix and prefix_flat columns in PrefixTable. It should be sufficient to only show prefix_flat as appropriate.

jeremystretch avatar Nov 11 '21 21:11 jeremystretch

Another option, could we have it check and see if there is a "parent" view and just subtract the two depths?

DanSheps avatar Nov 15 '21 18:11 DanSheps

@DanSheps that's a clever idea. Just need to be sure we're passing sufficient context to the table under each view.

jeremystretch avatar Nov 15 '21 19:11 jeremystretch

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. NetBox is governed by a small group of core maintainers which means not all opened issues may receive direct feedback. Please see our contributing guide.

github-actions[bot] avatar Mar 07 '22 04:03 github-actions[bot]

I am going to take this up, when I have time (hopefully soon) unless someone else wants to get to it.

DanSheps avatar Mar 17 '22 03:03 DanSheps

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. NetBox is governed by a small group of core maintainers which means not all opened issues may receive direct feedback. Do not attempt to circumvent this process by "bumping" the issue; doing so will result in its immediate closure and you may be barred from participating in any future discussions. Please see our contributing guide.

github-actions[bot] avatar Sep 26 '22 04:09 github-actions[bot]

This issue has been automatically closed due to lack of activity. In an effort to reduce noise, please do not comment any further. Note that the core maintainers may elect to reopen this issue at a later date if deemed necessary.

github-actions[bot] avatar Oct 27 '22 04:10 github-actions[bot]