futurewei-cloud / alcor

Alcor: Cloud native SDN platform powered by Kubernetes and Istio
MIT License
32 stars 33 forks source link

[DPM] Setting VpcId for each goal state in DpmServiceImplV2 #721

Closed VanderChen closed 2 years ago

VanderChen commented 2 years ago

In our design, Message Queue uses VPC as its topic. Thus, VPC ID needs to be set for each goal state. In this documentation, we explain where VPC IDs are set. This issue is solved in PR #695

  1. processPortConfiguration
Goal State Type
Unicast GS vpcService.buildVpcStates()
Multicast GS neighborService.buildNeighborStatesL2() \& neighborService.buildNeighborStatesL3()

Since the GS building process is corresponding to each port, there is only one VPC.

  1. processNeighborConfiguration
Goal State Type
Unicast GS neighborService.buildNeighborStatesL3()
Multicast GS neighborService.buildNeighborStatesL3()

Different from the buildNeighborStatesL3() in processPortConfiguration, the method we used is buildNeighborStatesL3(NetworkConfiguration networkConfiguration, Map<String, UnicastGoalStateV2> unicastGoalStates, MulticastGoalStateV2 multicastGoalState) which generate a map for unicast goalstates.

  1. processRouterConfiguration
Goal State Type
Unicast GS subnetService.buildSubnetState()
Multicast GS subnetService.buildSubnetState()
xieus commented 2 years ago

Discuss with @VanderChen and @cj-chung. James, Please help review this PR.

cj-chung commented 2 years ago

This is a good summary about vpcId update for UnicastGoalstateV2 and MulticastGoalstateV2 in PR #695.