-
Notifications
You must be signed in to change notification settings - Fork 913
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Network Connectivity Center module #1219
Conversation
Sync branch
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good stuff @juliodiez !
My comments are all meant to propose to modify this into a single NCC spoke (RA) module. I think it would make the module much simpler and useful (btw, we would need exactly that in the new networking stage of FAST).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hey @juliodiez, overall I like the idea of this PR but I'm wondering if this makes more sense as a blueprint.
Consider that:
- The NCC hub resource itself is rather simple, most of the complexity is actually on the Cloud Router.
- In other modules where a CR is required, we always give the option to reuse an existing one. Would that make sense here?
With that in mind, of you remove the CR creation/management from this module, then it becomes a very thin layer around the two NCC resources.
wdyt?
@LucaPrete I don't see good reasons to do that. The module would be simpler, sure, but also for sure it wouldn't be more useful to be able to create one spoke only instead of multiple. |
@juliodiez what if we'll need to add different spokes to the hub? Also, I'd honestly prefer to call 1 ncc-ra-spoke module per spoke from outside and iterate with a for_each to create more, then having one huge module with multiple spokes...but hey, personal preference @juliocc I think it makes sense to have a module for this. We talked about this for a long time in the new net stage of FAST. It will cleanup the code quite a lot |
|
@juliodiez can we add a blueprint that shows how to use the module, and why? |
@ludoo Sure, I will create one. I would ask if having a blueprint is not independent of the module, but I presume you also doubt whether this should be a module. I see NCC as a design resource with elements quite coupled without benefit by breaking them apart, let's see if a blueprint adds to this argument. |
Exactly. We won't know if the design is the best one until we actually use the module. So while the module will undoubtedly change a few times throughout its life, we should start with a good fit with at least one use case. I know this is a bit of a PITA, but it would be my preferred way of bringing this in. :) |
@juliodiez apologies I wrote my comment quickly in between call and might have been misunderstood. My doubt is how to integrate this with other types of spokes, without making this module becoming a "huge monster" :) Ideally, in a blueprint (or in the stage02) I'd like to see something like
In the future things like
and so on... ...I think the blueprint will end up being at this stage the same of the readme :) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Besides the minor comments, it looks great @juliodiez !
Waiting for it to be merged so we can use it right away in stage-2 :)
These IP values are optional, if you don't specify a value Google will try to find a free IP address. But this is a bad idea because setting them to 'null' forces a replacement even without any changes to make.
All comments addressed, PTAL. |
Can you resolve them?
in the VPN module we use ranges as keys. The idea is that values are then marked optional in the type. I agree it's counterintituive and am ok changing to names as keys but if you want to do that, we need to do it for every module. :) |
"values are then marked optional in the type" -> I don't get it. In both cases, vpn or my module, the type is map(string) and the semantics are in the assignment, kind of:
vs
|
(btw, I've always thought that who opens a comment should resolve it :) |
true :) maybe in the CR advertisement? I'm pretty sure that was the rationale; regardless, we should have all modules use the same interface |
Niet :) once you address resolve, burden is on you not on the reviewer |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Besides last minor comments on the outputs lgtm!
Ofc I'll abide by the rules and resolve, but don't agree ;) (e.g. random ref.) |
Good! Just send a PR after this one to invert the type anywhere we're using ranges. Tests should make it pretty easy to spot issues. |
No, no. I changed semantics and left as the rest of code (IP range = key). I meant I don't agree with who should resolve a comment |
let me put it this way: as a reviewer, I trust you to do the right thing once a comment has been sent :) |
Creation and management of NCC-based hub-and-spoke architectures.