Skip to content

[meta] Continue bulk operations if MODE_IGNORE_ERROR and skip entries that fail validation#1780

Open
markx-arista wants to merge 1 commit intosonic-net:masterfrom
markx-arista:fix-meta-layer-bulk-operations
Open

[meta] Continue bulk operations if MODE_IGNORE_ERROR and skip entries that fail validation#1780
markx-arista wants to merge 1 commit intosonic-net:masterfrom
markx-arista:fix-meta-layer-bulk-operations

Conversation

@markx-arista
Copy link

@markx-arista markx-arista commented Feb 25, 2026

PR1613 was proposed to ignore errors during bulk operations if SAI_BULK_OP_ERROR_MODE_IGNORE_ERROR is set. But it was reverted as it caused regression in test_duplicate_route.py because validation errors are ignored and some SAI can successfully add duplicated route. Later, createObject will be called on already existed entries in meta_generic_validation_post_create, and throws a fatal runtime_error exception.
This fix removes entries that fail validation checks before passing to SAI during bulk operations with SAI_BULK_OP_ERROR_MODE_IGNORE_ERROR, and populates object_statuses with validation results for those entries.

@markx-arista
Copy link
Author

@prsunny, FYI.

@markx-arista markx-arista changed the title Fix Meta layer bulk operations [Meta] Continue bulk operations if MODE_IGNORE_ERROR and skip entries that fail validation Feb 25, 2026
@markx-arista markx-arista changed the title [Meta] Continue bulk operations if MODE_IGNORE_ERROR and skip entries that fail validation [meta] Continue bulk operations if MODE_IGNORE_ERROR and skip entries that fail validation Feb 25, 2026
@mssonicbld
Copy link
Collaborator

/azp run

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@prsunny prsunny requested a review from Ndancejic February 25, 2026 23:33
@markx-arista markx-arista force-pushed the fix-meta-layer-bulk-operations branch from 81b42ed to 7eaa7b3 Compare February 25, 2026 23:36
@mssonicbld
Copy link
Collaborator

/azp run

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@markx-arista markx-arista force-pushed the fix-meta-layer-bulk-operations branch from 7eaa7b3 to 5e131e8 Compare February 25, 2026 23:53
@mssonicbld
Copy link
Collaborator

/azp run

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

PR1613 was proposed to ignore errors during bulk operations if
SAI_BULK_OP_ERROR_MODE_IGNORE_ERROR is set. But it was reverted as it
caused regression in test_duplicate_route.py because validation errors
are ignored and some SAI can successfully add duplicated route. Later,
createObject will be called on already existed entries in
meta_generic_validation_post_create, and throws a fatal runtime_error
exception.
This fix removes entries that fail validation checks before passing to
SAI during bulk operations with SAI_BULK_OP_ERROR_MODE_IGNORE_ERROR, and
populates object_statuses with validation results for those entries.

Signed-off-by: markxiao <markxiao@arista.com>
@markx-arista markx-arista force-pushed the fix-meta-layer-bulk-operations branch from 5e131e8 to b1def83 Compare February 26, 2026 02:10
@mssonicbld
Copy link
Collaborator

/azp run

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants