Skip to content
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

[dash] Implement PL and route group API #3048

Merged
merged 81 commits into from
Sep 6, 2024
Merged
Changes from 1 commit
Commits
Show all changes
81 commits
Select commit Hold shift + click to select a range
c905608
[dash] Implement PL API
theasianpianist Feb 14, 2024
3ab9137
fix parameter use
theasianpianist Feb 14, 2024
0179272
[dash] Implement PL API
theasianpianist Feb 14, 2024
8bd8a0e
fix parameter use
theasianpianist Feb 14, 2024
ad81039
fix routing_type parsing
theasianpianist Feb 14, 2024
e1be81c
Merge branch 'dash-pl' of github.com:theasianpianist/sonic-swss into …
theasianpianist Feb 14, 2024
1a7685d
Set routing type table in dash_vnet test
theasianpianist Feb 14, 2024
11e374e
add VS test for PL
theasianpianist Feb 14, 2024
37e347f
Make ROUTING_TYPE_TABLE optional
theasianpianist Feb 15, 2024
134fd99
Set SAI PL attribute based on ROUTING_TYPE
theasianpianist Feb 15, 2024
0c26e58
Update DASH orchs to use route groups
theasianpianist Aug 7, 2024
9d8d664
Merge branch 'master' of github.com:sonic-net/sonic-swss into dash-pl
theasianpianist Aug 7, 2024
47a497e
refactor tests
theasianpianist Aug 10, 2024
d8252ee
use newest sairedis build
theasianpianist Aug 10, 2024
49789b1
improve naming
theasianpianist Aug 10, 2024
8cc622e
pin sairedis artifacts for route group changes
theasianpianist Aug 12, 2024
8df9224
update DASH vnet tests for route group changes
theasianpianist Aug 13, 2024
d84bb1b
Merge branch 'master' of github.com:sonic-net/sonic-swss into dash-pl
theasianpianist Aug 13, 2024
e5eccb6
update bulker for route group changes
theasianpianist Aug 13, 2024
cf41eed
update PL dip/sip mask
theasianpianist Aug 13, 2024
aa2f1e7
fix PL test config
theasianpianist Aug 14, 2024
933c24b
fix ipaddr to ipprefix for sai attribute
theasianpianist Aug 14, 2024
4342d40
fix build
theasianpianist Aug 15, 2024
16fbe6d
Update import file path
theasianpianist Aug 15, 2024
2cee9c3
Fix action type enum usage
theasianpianist Aug 15, 2024
913fd27
fix test config naming
theasianpianist Aug 15, 2024
d4877a8
fix test errors
theasianpianist Aug 15, 2024
c45f56c
Update test_dash_pl.py
theasianpianist Aug 15, 2024
0e76c05
Deprecate VnetMapping::action_type
theasianpianist Aug 16, 2024
bfb3c52
fix function call
theasianpianist Aug 16, 2024
abdfa7e
oops
theasianpianist Aug 16, 2024
ebf3f7d
Fix dash_db function name
theasianpianist Aug 16, 2024
9da66f2
Check route group creation
theasianpianist Aug 16, 2024
3b0926a
Fix route group guid type
theasianpianist Aug 16, 2024
2004f9f
oops
theasianpianist Aug 16, 2024
5a3dbcc
subscribe to new DASH APPL_DB tables
theasianpianist Aug 16, 2024
ea70423
fix eni route creation
theasianpianist Aug 16, 2024
1744962
fix tests
theasianpianist Aug 18, 2024
e6bcb53
fix inconsistent SAI attr names
theasianpianist Aug 19, 2024
3de2db2
fix outbound_ca_to_pa overlay IP and mask
theasianpianist Aug 19, 2024
3ca5e96
update tests for outbound_ca_to_pa overlay SIP and DIP changes
theasianpianist Aug 19, 2024
0ba041a
add dash_route_table override underlay_sip for PL
theasianpianist Aug 19, 2024
f0e7f8c
fix SAI attribute constants
theasianpianist Aug 26, 2024
e26658d
remove unrelated file
theasianpianist Aug 26, 2024
ae761f8
fix DASH test configs and formatting
theasianpianist Aug 26, 2024
c8156a1
remove tests for deprecated attributes
theasianpianist Aug 27, 2024
26e2a22
poll continuously for asic DB changes
theasianpianist Aug 27, 2024
a770e87
cleanup imports
theasianpianist Aug 27, 2024
62888f9
remove deprecated yield_fixture use
theasianpianist Aug 27, 2024
d3a8291
remove unneeded return
theasianpianist Aug 27, 2024
cd2f848
Access route group OID through getter
theasianpianist Aug 28, 2024
8c83788
track route group bindings and make bound route groups immutable
theasianpianist Aug 28, 2024
0b0d443
remove old code
theasianpianist Aug 28, 2024
e5a65c0
remove unused utils
theasianpianist Aug 28, 2024
29f83c0
fix route group bind check
theasianpianist Aug 28, 2024
d8232f4
fix route group ref counter
theasianpianist Aug 28, 2024
0bbe94c
fix test object creation order
theasianpianist Aug 28, 2024
35f3c54
restrict route table routing_types
theasianpianist Aug 29, 2024
d467e48
Use VNET routing type for PL routes
theasianpianist Aug 29, 2024
2ce30f0
fix log format
theasianpianist Aug 29, 2024
226bf8a
move all dash VS tests to single folder
theasianpianist Aug 29, 2024
dd0cdf2
Make route underlay_sip independent of routing_type
theasianpianist Aug 29, 2024
58b6e18
add ASIC_DB check helper
theasianpianist Aug 29, 2024
6b35f64
formatting fix
theasianpianist Aug 29, 2024
6923d1b
restructure PL tests
theasianpianist Aug 30, 2024
ca712cc
unbind old route group from ENI
theasianpianist Aug 30, 2024
52b6013
retry route group deletion if bound
theasianpianist Sep 3, 2024
07408d6
setup/teardown per test case
theasianpianist Sep 3, 2024
e097983
add __init__.py for utils folder
theasianpianist Sep 4, 2024
e86e56d
Merge branch 'master' of github.com:sonic-net/sonic-swss into dash-pl
theasianpianist Sep 4, 2024
cf34994
fix test package
theasianpianist Sep 4, 2024
8ff6bb8
Test ENI route group rebinding
theasianpianist Sep 4, 2024
0d4859a
refactor orchagent mock base class
theasianpianist Sep 4, 2024
3c33ac1
add dashorch UT
theasianpianist Sep 4, 2024
ae68c5a
add more route group tests
theasianpianist Sep 4, 2024
8b3a3d6
fix build
theasianpianist Sep 4, 2024
6fcb7af
Update mock_orch_test.h
theasianpianist Sep 4, 2024
9060640
fix test override error
theasianpianist Sep 5, 2024
a7e3ae5
define mock_orch_test base fns
theasianpianist Sep 5, 2024
3665aab
restrict route removal from bound groups
theasianpianist Sep 5, 2024
f4af126
add more tests
theasianpianist Sep 5, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
unbind old route group from ENI
Signed-off-by: Lawrence Lee <lawlee@microsoft.com>
theasianpianist committed Aug 30, 2024
commit ca712cc69ae0c22d580c1b55aa27bb341cd442c2
7 changes: 7 additions & 0 deletions orchagent/dash/dashorch.cpp
Original file line number Diff line number Diff line change
@@ -718,10 +718,12 @@ bool DashOrch::setEniRoute(const std::string& eni, const dash::eni_route::EniRou
return false;
}

std::string old_group_id;
if (eni_route_entries_.find(eni) != eni_route_entries_.end())
{
if (eni_route_entries_[eni].group_id() != entry.group_id())
{
old_group_id = eni_route_entries_[eni].group_id();
SWSS_LOG_INFO("Updating route entry from %s to %s for ENI %s", eni_route_entries_[eni].group_id().c_str(), entry.group_id().c_str(), eni.c_str());
}
else
@@ -750,6 +752,11 @@ bool DashOrch::setEniRoute(const std::string& eni, const dash::eni_route::EniRou
eni_route_entries_[eni] = entry;
dash_route_orch->bindRouteGroup(entry.group_id());

if (!old_group_id.empty())
{
dash_route_orch->unbindRouteGroup(old_group_id);
}

SWSS_LOG_NOTICE("Updated ENI route group for %s to route group %s", eni.c_str(), entry.group_id().c_str());
return true;
}