-
Notifications
You must be signed in to change notification settings - Fork 157
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
OTG Test - RT-1.4: BGP Graceful Restart #1509
base: main
Are you sure you want to change the base?
Conversation
…profiles into otg-rt1.4
-updated README -updated the OTG configuration -added gnoi commands
Pull Request Test Coverage Report for Build 12184701459Details
💛 - Coveralls |
-corrected the direction of traffic for 1.4.7 -- 1.4.10
@sachendras could you please review the corrections I've made to the README file. I'm assuming we would want to run 1.4.5 for both IBGP and EBGP. Also for tests 1.4.7 through 1.4.10 when testing EBGP I'm assuming the direction of traffic is ATE port2 - ATE Port1 (EBGP routes). In this case the notification will be sent from DUT port1 |
} | ||
|
||
func TestBGPPGracefulRestart(t *testing.T) { | ||
cases := []struct { |
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.
Move these cases before the RT-1.4.1 test so that they are defined closer to where they are used.
|
||
srcBgp := srcDev.Bgp().SetRouterId(srcIpv4.Address()) | ||
srcBgp4Peer := srcBgp.Ipv4Interfaces().Add().SetIpv4Name(srcIpv4.Name()).Peers().Add().SetName(ateSrc.Name + ".BGP4.peer") | ||
srcBgp4Peer.Advanced().SetKeepAliveInterval(keepaliveTimer).SetHoldTimeInterval(3 * keepaliveTimer) |
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.
Maybe a comment is worth it here explaining the relationship between the keep alive/hold time values? I think it's implied in the README, but will make it easier to understand the code.
// ate.OTG().StartProtocols(t) | ||
t.Log("Pushing config to ATE and starting protocols...") | ||
|
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.
Comment/commented out code can both be dropped.
pgGrV4.Enabled = ygot.Bool(true) | ||
pgGrV4.RestartTime = ygot.Uint16(grRestartTime) | ||
pgGrV4.StaleRoutesTime = ygot.Uint16(grStaleRouteTime) | ||
// pg.PeerAs = ygot.Uint32(ateAS) |
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.
Can be removed?
pgGrV6.Enabled = ygot.Bool(true) | ||
pgGrV6.RestartTime = ygot.Uint16(grRestartTime) | ||
pgGrV6.StaleRoutesTime = ygot.Uint16(grStaleRouteTime) | ||
// pgv6.PeerAs = ygot.Uint32(ateAS) |
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.
Can be removed?
pgGrV4.RestartTime = ygot.Uint16(grRestartTime) | ||
pgGrV4.StaleRoutesTime = ygot.Uint16(grStaleRouteTime) |
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.
These (RestartTime and StaleRoutesTime) are indicated in the README as set at the 'global' level. (I believe the existing ATE test does do that.) Might also imply changes in checkBgpGRConfig
?
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.
If we do wind up sending traffic from both ATE interfaces, do we want to rename config in general to reflect IBGP vs. EBGP instead? (Eg. srcEth -> iBGPEth maybe).
t.Log("Configure/update Network Instance") | ||
fptest.ConfigureDefaultNetworkInstance(t, dut) | ||
|
||
if deviations.ExplicitPortSpeed(dut) { |
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.
This deviation can be removed
vendor: NOKIA | ||
} | ||
deviations: { | ||
explicit_port_speed: true |
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.
Can be removed, please.
OTG Test conversion of RT-1.4: BGP Graceful Restart
Resolves #580
The ACL sections were replaced by the "Initiate graceful restart" in the case of DUT helper and "gnoi restart pid" in case of DUT restart initiator