[meta] Skip validation for mandatory deprecated attributes in Meta.#1871
[meta] Skip validation for mandatory deprecated attributes in Meta.#1871kcudnik merged 1 commit intosonic-net:masterfrom
Conversation
|
/azp run |
|
Azure Pipelines successfully started running 1 pipeline(s). |
db0907c to
9804bcd
Compare
|
/azp run |
|
Azure Pipelines successfully started running 1 pipeline(s). |
|
@ksravani-hcl @sreeiyer-1 Please fix the verification part in the description notes, there is no Bazel env here. |
|
@kcudnik can you please approve this PR? |
|
in description you said that if attribute is depreacated then LOG will be added, but no log message exists in this PR, also was this discussed further ? did all vendors agreed to skip this or all depreacated attributes from specifisc SAI version ? |
Corrected the log. This is discussed only internally but the change is applicable only to SAI_TUNNEL_TERM_TABLE_ENTRY_ATTR_VR_ID in saitunnel.h (https://github.com/opencomputeproject/SAI/blob/c72635e6ca35371ba0bd82d36a5b2c500c021e16/inc/saitunnel.h#L995) which is the only attribute in the SAI/inc that is both mandatory and deprecated. |
|
i would add warning line or at least NOTICE in this case taht any attribute as depreacated, as i sspect not all vendors will initially support that right away |
9804bcd to
ab7886e
Compare
|
/azp run |
|
Azure Pipelines successfully started running 1 pipeline(s). |
ab7886e to
e147f69
Compare
|
/azp run |
|
Azure Pipelines successfully started running 1 pipeline(s). |
Signed-off-by: SRAVANI KANASANI <kanasanis@google.com>
e147f69 to
c26e1e5
Compare
|
/azp run |
|
Azure Pipelines successfully started running 1 pipeline(s). |
|
@kcudnik |
What i did:
Updated the generic object creation validation logic in Meta.cpp to check the isdeprecated flag of SAI attributes. If an attribute is marked as both mandatory and deprecated, skips the requirement check instead of potentially failing the operation.
Why i did:
In SAI, some legacy attributes are marked as mandatory for backward compatibility but are simultaneously deprecated in favor of newer mechanisms. Enforcing mandatory checks on deprecated attributes can cause unnecessary validation failures in orchestration agents that have already migrated to modern attributes, hindering smooth transitions and system stability.
How i did:
Verified the persistence mechanism through the local build and UT.