Skip to main content

Remove-ZrItems

Deletes multiple items from the connected Clustron Zaris store in a single bulk operation. Keys that are already absent are reported as successful no-ops.

Syntax

Remove-ZrItems [-Keys] <string[]> [-ConnectionString <string>] [-StoreName <string>] [-Endpoints <string[]>] [-TimeoutSec <int>]

Description

Remove-ZrItems removes every supplied key from the connected Zaris store using a single batched DeleteManyAsync request, which is more efficient than issuing many Remove-ZrItem calls. The command emits one result object per key, in input order. The delete is idempotent: each key reports Success = true with Deleted = true whether or not it was present, along with the operation's revision and version.

-Keys accepts pipeline input, so keys can be streamed in from another command. The command runs against the active Connect-ZrStore session, or against a one-shot connection when -StoreName and -Endpoints are supplied.

Parameters

ParameterTypeRequiredDescription
-KeysString[]YesKeys identifying the items to delete. Positional (position 0). Accepts pipeline input (ValueFromPipeline and ValueFromPipelineByPropertyName). Must not be null or empty.
-ConnectionStringStringNoConnect via a Zaris connection string, e.g. zaris://host:7861/store; an alternative to -StoreName + -Endpoints for a one-shot connection. Ignored when a Connect-ZrStore session is active.
-StoreNameStringNoStore to target when using an independent (one-shot) connection instead of the active session. Requires -Endpoints.
-EndpointsString[]NoOne or more node endpoints (host:port) for an independent connection. Ignored when a Connect-ZrStore session is active.
-TimeoutSecInt32NoConnection timeout in seconds (1–120) for an independent connection. Default 5.

Examples

Delete three items in one bulk call:

Remove-ZrItems -Keys "user:1","user:2","user:3"

Delete keys streamed in from the pipeline:

"cache:1","cache:2","cache:3" | Remove-ZrItems