-
Notifications
You must be signed in to change notification settings - Fork 661
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
Update db_migrator to support PORT_QOS_MAP|global
#2205
Update db_migrator to support PORT_QOS_MAP|global
#2205
Conversation
Signed-off-by: bingwang <wang.bing@microsoft.com>
@stephenxs, please take a final look |
scripts/db_migrator.py
Outdated
@@ -725,6 +742,8 @@ def common_migration_ops(self): | |||
self.migrate_mgmt_ports_on_s6100() | |||
else: | |||
log.log_notice("Asic Type: {}, Hwsku: {}".format(self.asic_type, self.hwsku)) | |||
|
|||
self.migrate_port_qos_map_global() |
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.
why is this in the common migration path? I thought it should be based on a version.
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.
Updated. Please take a look. Thanks
LGTM. Approved. |
Signed-off-by: bingwang <wang.bing@microsoft.com> What I did This PR is to update the db_migrator to support generation of PORT_QOS_MAP|global. After PR sonic-net/sonic-buildimage#10565, there will be two DSCP_TO_TC_MAP DSCP_TO_TC_MAP|AZURE is the default map, which is used at port level and switch level DSCP_TO_TC_MAP|AZURE_TUNNEL is used to remap the priority of tunnel traffic in dualtor deployment To address the issue, an entry PORT_QOS_MAP|global will be added into config_db "PORT_QOS_MAP": { "global": { "dscp_to_tc_map": "AZURE" } } To handle the upgrade from older image, db_migrator is updated to generate the entry. There is no way to check if PORT_QOS_MAP|global is supported, so the migration is ran on all platforms. There is check in sonic-swss to check the switch capability code, so it will not cause issue. How I did it Update db_migrator to add a common migration step. How to verify it Verified by vstest
Signed-off-by: bingwang <wang.bing@microsoft.com> What I did This PR is to update the db_migrator to support generation of PORT_QOS_MAP|global. After PR sonic-net/sonic-buildimage#10565, there will be two DSCP_TO_TC_MAP DSCP_TO_TC_MAP|AZURE is the default map, which is used at port level and switch level DSCP_TO_TC_MAP|AZURE_TUNNEL is used to remap the priority of tunnel traffic in dualtor deployment To address the issue, an entry PORT_QOS_MAP|global will be added into config_db "PORT_QOS_MAP": { "global": { "dscp_to_tc_map": "AZURE" } } To handle the upgrade from older image, db_migrator is updated to generate the entry. There is no way to check if PORT_QOS_MAP|global is supported, so the migration is ran on all platforms. There is check in sonic-swss to check the switch capability code, so it will not cause issue. How I did it Update db_migrator to add a common migration step. How to verify it Verified by vstest
Signed-off-by: bingwang wang.bing@microsoft.com
What I did
This PR is to update the
db_migrator
to support generation ofPORT_QOS_MAP|global
.After PR sonic-net/sonic-buildimage#10565, there will be two DSCP_TO_TC_MAP
To address the issue, an entry
PORT_QOS_MAP|global
will be added intoconfig_db
To handle the upgrade from older image,
db_migrator
is updated to generate the entry.There is no way to check if
PORT_QOS_MAP|global
is supported, so the migration is ran on all platforms. There is check insonic-swss
to check the switch capability code, so it will not cause issue.How I did it
Update
db_migrator
to add a common migration step.How to verify it
Verified by vstest
Previous command output (if the output of a command-line utility has changed)
New command output (if the output of a command-line utility has changed)