Releases: Azure/azure-sdk-for-rust
Releases · Azure/azure-sdk-for-rust
azure_core_test_macros@0.1.0
0.1.0 (2026-06-04)
Features Added
- Initial release.
azure_core_test@0.1.0
0.1.0 (2026-06-04)
Features Added
- Initial release.
azure_messaging_eventhubs_checkpointstore_blob@0.9.0
0.9.0 (Unreleased)
Features Added
Breaking Changes
Bugs Fixed
Other Changes
azure_messaging_eventhubs@0.15.0
0.15.0 (Unreleased)
Features Added
- The
EventProcessornow opens every partition receiver with AMQP epoch (owner level)0and surfaces broker-initiated displacement as the newEventHubsError::ConsumerDisconnectederror kind. When a secondEventProcessorinstance claims a partition this instance is currently holding, the broker disconnects this instance's receiver and the consumer'sstream_events()resolves withConsumerDisconnected. This matches the behavior ofEventProcessorClientin the .NET and Java Azure SDKs. Consumers should pattern-match onErrorKind::ConsumerDisconnectedto detect a stolen partition and re-acquire a client vianext_partition_client(). - Added
EventHubsError::ConsumerDisconnected(Option<AmqpDescribedError>)error variant.
Breaking Changes
- On the receive path, the
amqp:link:stolenAMQP condition is no longer auto-retried. A receiver displaced by a higher-or-equal-epoch attacher now surfaces the error (translated toEventHubsError::ConsumerDisconnectedbyEventReceiver::stream_events) instead of silently re-attaching. Sender, CBS, and management operations retain the historical retry-on-stolen behavior.
Bugs Fixed
- Increased
DEFAULT_PARTITION_EXPIRATION_DURATIONfrom 10 seconds to 60 seconds. The previous default was shorter thanDEFAULT_UPDATE_INTERVAL(30 seconds), so ownership records expired between load-balancing cycles. The load balancer perpetually sawcurrent=0for every consumer and continuously re-claimed partitions, causing widespread duplicate event processing.EventProcessorBuilder::buildnow rejects configurations wherepartition_expiration_duration <= update_interval. (#3851) - The
EventProcessor's load-balancer reconciliation now closes the underlying AMQP receiver for any partition that has been reassigned to another consumer, so the consumer'sstream_events()resolves and the loop can terminate. Previously a stolen partition's client could continue to attempt receives until the broker tore down the link.
Other Changes
azure_data_cosmos_driver@0.3.0
0.3.0 (2026-05-29)
Features Added
CosmosErrorcan capture a stack backtrace on construction. Capture is opt-in (off by default; on whenRUST_BACKTRACEis set or when explicit capacities are supplied) and protected against error storms by two configurable per-second limiters on the runtime builder. See the README for details. (#4442)- Introduced
CosmosErrorand the crate-wideResult<T>alias as the driver's first-class error type, always exposing the typedCosmosStatus(with predicates likeis_not_found()/is_throttled()/is_transient()), the originatingCosmosResponse(when received), and the operationDiagnosticsContext. Construction goes through the fluentCosmosErrorBuilder. (#4442) - Added
PartitionKeyDefinition::with_kind(PartitionKeyKind)andPartitionKeyDefinition::with_version(PartitionKeyVersion)consuming setters so callers can override the auto-inferred kind and the defaultV2version without resorting to private-field workarounds.PartitionKeyDefinition::new(paths)continues to auto-infer the kind from the path count. - Reshaped
PatchInstructionsAPI so thatPatchInstructions::new()creates an empty instruction set, where individual operations can be added viawith_operation(). ThePatchInstructionstype also implementsFrom<Vec<PatchOperation>>for ergonomic construction from a vector. - Refactored the driver response surface: introduced
ResponseBody(aNoPayload/Bytes(Bytes)/Items(Vec<Bytes>)enum withsingle(),items(),into_single::<T>(),into_items::<T>(), andis_empty()helpers), added typedCosmosRequestHeadersfields for query / changefeed headers (max_item_count,incremental_feed,populate_index_metrics,populate_query_metrics,enable_cross_partition_query) so callers no longer need rawcustom_headers, the pipeline now auto-emitsx-ms-documentdb-isquery: TrueandContent-Type: application/query+jsonforOperationType::Query, andCosmosStatusgainedPartialEq<StatusCode>,From<CosmosStatus> for StatusCode/u16, and aCosmosStatus::new(StatusCode)constructor. (#4401) - Added support for the
x-ms-cosmos-hub-region-processing-onlyrequest header on retries after a404 / 1002 (READ_SESSION_NOT_AVAILABLE)response on single-master data-plane Cosmos operations. The header asks the backend to route only to a region that has caught up to the requested LSN, reducing the chance of a follow-up retry hitting a region whose session is also behind. The header is scoped to single-master accounts (multi-master accounts already have a different recovery path) and to data-plane operations (metadata-pipeline operations are out of scope per the design spec). Once latched on the first 1002 within an operation, the header is emitted on every subsequent retry for that operation. (#4389) - Added local query-plan generator scaffolding under
crate::query(lexer, parser, AST, planner, and in-memory evaluator). The scaffolding is not wired into the production query path yet — production callers still issue Gateway query-plan requests viaCosmosOperation::query_plan. The__internal_testingcargo feature exposesquery::__test_only_generate_query_plan_for_pk_paths,query::__TEST_ONLY_SUPPORTED_QUERY_FEATURES, andCosmosOperation::query_planfor cross-crate gateway-comparison tests; this feature is intentionally unstable and not covered by SemVer. - Added per-partition automatic failover (PPAF) for writes on single-master accounts. On 403/3 WriteForbidden, 503 ServiceUnavailable, 429/3092 SystemResourceUnavailable, 410/1022 Gone, or 408 RequestTimeout from a region, the affected partition is failed over to the next preferred region; subsequent writes for that partition skip the failed region. (#4156)
- Added per-partition circuit breaker (PPCB) for reads (any account) and writes (multi-master accounts). Tracks failure counts per
(partition_key_range_id, region)and routes to an alternate region once the threshold (default 10 reads, 5 writes) is exceeded. A background failback loop probes the original region for recovery. (#4156) - Added
OperationOptionsfields for tuning PPCB:circuit_breaker_failure_count_for_reads,circuit_breaker_failure_count_for_writes,circuit_breaker_timeout_counter_reset_window_in_minutes,allowed_partition_unavailability_duration_in_seconds,ppcb_stale_partition_unavailability_refresh_interval_in_seconds, andper_partition_circuit_breaker_enabled(each also configurable via the correspondingAZURE_COSMOS_*environment variable). (#4156) - Added
CosmosDriverRuntimeBuilder::with_wrapping_sdk_identifier(impl Into<String>)so higher-level SDKs can prepend their own identifier (e.g.,azsdk-rust-cosmos/0.34.0) to the driver'sUser-Agentprefix. The driver only sanitizes ASCII and trims whitespace; the wrapping SDK is responsible for the full token format. When set, theUser-Agentbecomes<wrapping> azsdk-rust-cosmos-driver/<ver> <os>/<arch> rustc/<ver> [suffix]; when unset, the existing format is unchanged. (#4465) - Added
OperationType::PatchplusCosmosOperation::patch_item()and thePatchOperation/CosmosNumber/PatchDocumentmodel types. Patches are executed driver-side as a Read-Modify-Write loop via a dedicatedpatch_handlerpipeline stage; seedocs/PATCH_HANDLER_SPEC.mdfor the full contract. The handler owns the internalIf-Matchprecondition end-to-end and rejects any caller-setPreconditionon the outer PATCH operation with a clear error before issuing any sub-operation. (#4386)
Breaking Changes
- Renamed the error surface:
Error→CosmosError,ErrorBuilder→CosmosErrorBuilder. Categorization moved from aKindenum to predicates onCosmosStatus(is_not_found(),is_throttled(),is_transient(), …); error details are reached viastatus()andresponse()instead of the previous flat accessors. (#4442) - Renamed
MaxItemCounttoMaxItemCountHintto better reflect that the value is a hint to the service (which may return fewer items) rather than a strict cap. The SDK already exposed the type under the new name via ause ... as MaxItemCountHint; the rename makes the canonical name consistent across both crates. Update callers that referenceazure_data_cosmos_driver::models::MaxItemCount,CosmosRequestHeaders::max_item_counttypings, orCosmosOperation::with_max_item_countargument types accordingly. - Marked
PartitionKeyVersionandCosmosStatusas#[non_exhaustive]to allow future variants/fields to be added without further breaking changes. Callers must use..wildcard arms when matching onPartitionKeyVersion;CosmosStatusalready had private fields and is constructed viaCosmosStatus::new/with_sub_status, so the attribute is primarily a forward-compat signal. - Slimmed the cached
PartitionKeyRangeto six fields, dropping eight metadata fields the routing-map cache never reads (resource_id,self_link,etag,timestamp,rid_prefix,target_throughput,lsn,owned_archival_pk_range_ids). The struct now retains the four fields the routing layer consults (id,min_inclusive,max_exclusive,status) plusthroughput_fractionandparents, kept on the cached representation for downstream consumers that read them directly. As part of this change,PartialEqandHashno longer hashresource_id: two ranges with the sameid/min_inclusive/max_exclusiveare now equal regardless of their_rid. Internal callers never usedPartitionKeyRangeas a hash-map key, but downstream consumers that did so should review their assumptions. Service responses are unchanged on the wire — the dropped JSON fields are silently ignored by serde on deserialization. (#4393) - Changed
CosmosResponse::diagnostics()to returnArc<DiagnosticsContext>instead of&DiagnosticsContext. The returnedArcderefs transparently for read-only inspection (existing call patterns likeresponse.diagnostics().activity_id()continue to work), but bindings of the formlet d = response.diagnostics();now own a clonedArchandle rather than a borrow — letting callers retain operation diagnostics acrossinto_body(). Replaces the additiveCosmosResponse::diagnostics_arc()accessor introduced earlier in this preview cycle. - Removed
CosmosResponse::body() -> &[u8]. The previous accessor panicked on multi-item feed bodies, which is unsafe for a public API. The non-consumingbody_parts() -> &ResponseBodyaccessor has been renamed tobody(). Callers needing borrowed access should pattern-match onResponseBody::Bytes(b)/ResponseBody::Items(items); consuming callers can useinto_body().single_item::<T>()orinto_body().single(). - Replaced
EffectivePartitionKey::min()/EffectivePartitionKey::max()with associated constantsEffectivePartitionKey::MIN/EffectivePartitionKey::MAX. The inner storage also changed fromStringtoCow<'static, str>so the constants can borrow static strings without allocating. Callers should rewriteEffectivePartitionKey::min()asEffectivePartitionKey::MIN.clone()(or just&EffectivePartitionKey::MINfor comparisons). - Removed
PartitionKeyValue::undefined()(use the existingPartitionKeyValue::UNDEFINEDassociated constant instead) and replaced the test-onlyPartitionKeyValue::infinity()cons...
azure_data_cosmos@0.34.0
0.34.0 (2026-05-29)
Features Added
CosmosErrorcan capture a stack backtrace on construction. Capture is opt-in (off by default; on whenRUST_BACKTRACEis set or when explicit capacities are supplied) and protected against error storms by two configurable per-second limiters on the runtime builder. (#4442)- Introduced
azure_data_cosmos::CosmosErrorand the crate-wideazure_data_cosmos::Result<T>alias, surfacing typedCosmosStatus(with predicate accessors likeis_not_found()/is_throttled()/is_transient()), the originatingCosmosResponse, and the operationDiagnosticsContexton every failure.From<CosmosError> for azure_core::Erroris provided so callers using?againstazure_core::Errorcontinue to compose. (#4442) - Added
RoutingStrategy::PreferredRegionsto allow specifying a fixed region preference order for failover, hedging, and retry. (#4485) - Standardized every client-method options type with a public
operation: OperationOptionsfield andwith_operation_options(OperationOptions) -> Selfsetter, so any per-requestOperationOptionssetting can be configured via any options type. The following options types previously had no way to attachOperationOptionsand now do:ReadContainerOptions,ReadDatabaseOptions,ReplaceContainerOptions,CreateContainerOptions,CreateDatabaseOptions,DeleteContainerOptions,DeleteDatabaseOptions,QueryContainersOptions,QueryDatabasesOptions,ThroughputOptions,ReadFeedRangesOptions. ForCreateContainerOptions/CreateDatabaseOptions/ReplaceContainerOptions, the SDK still forcescontent_response_on_write = Enabledon the resolved options because control-plane mutations require the response body.ReadFeedRangesOptions::operationis currently inert (the underlying routing-map cache does not go through the operation pipeline) but is added for shape consistency with the other options types. (#4447) - Added
new()constructors andwith_xconsuming setters to multi-required-field model types so callers can build them declaratively without struct-literal syntax (which is now blocked by#[non_exhaustive]):VectorEmbedding::new(path, data_type, dimensions, distance_function)+with_path/with_data_type/with_dimensions/with_distance_function;ConflictResolutionPolicy::new(mode)+with_resolution_path/with_resolution_procedure;SpatialIndex::new(path)+with_type(singular pusher ontotypes);CompositeIndexProperty::new(path, order)+with_path/with_order;VectorIndex::new(path, index_type)+with_path/with_index_type. These types do not implementDefault— their constructors require values that have no meaningful default. (#4447) - Derived
DefaultonVectorEmbeddingPolicy,UniqueKeyPolicy,UniqueKey,PropertyPath, andCompositeIndex, and added singularwith_xpushers / setters:VectorEmbeddingPolicy::with_embedding,UniqueKeyPolicy::with_unique_key,UniqueKey::with_path,PropertyPath::with_path, andCompositeIndex::with_property. This matches the existingIndexingPolicy::with_included_pathstyle and lets callers build these policies declaratively without constructing intermediateVecs. (#4447) - Added
QueryFeedPage::as_feed_page()returning&FeedPage<T>, so a query page can be passed to APIs that accept the more generalFeedPagetype. Query-specific metadata (index/query metrics) remains accessible on theQueryFeedPageitself. (#4447) - Added
QueryOptions::with_populate_index_metrics(bool),with_populate_query_metrics(bool), andwith_max_item_count(MaxItemCountHint)setters. These replace the previous pattern of passing rawx-ms-cosmos-populateindexmetrics,x-ms-documentdb-populatequerymetrics, andx-ms-max-item-countvalues throughOperationOptions::with_custom_headersfor query execution.max_item_counttakes the newMaxItemCountHintenum withServerDecidesandLimit(NonZeroU32)variants, so callers don't have to traffic in the-1wire sentinel directly. (#4401) - Added
ContainerClient::patch_item()for applying JSON-Patch-style mutations to a single item. Supportsadd/set/replace/remove/increment/moveops via the newPatchInstructions/PatchOperation/CosmosNumbertypes. AddedPatchItemOptionsfor per-request configuration (max_attempts,session_token, etc.).PatchItemOptionsintentionally does not expose aPreconditionor SQL filter predicate — the driver-side PATCH handler owns the internalIf-Matchend-to-end, and predicate evaluation is out of scope for this preview. The method's rustdoc documents the non-idempotent-under-transport-failure caveat. (#4386) - Support for simple cross-partition queries with
SELECTprojections andWHEREfilters. Cross-partition queries are now done through fan-out in the client, and provide a client-generated continuation token that can be used to resume the query. SeeContainerClient::query_items()andFeedScopefor details. (#4440) - Added
QueryOptions::continuation_tokenandQueryOptions::with_continuation_token(...)for resuming queries from a continuation token. (#4440) - Added a new
FeedOptionstype that wraps the paging knobs (max_item_count,continuation_token) common to feed-style operations, so future feed APIs (change feed, read-feed, etc.) can adopt the same shape without redeclaring fields.QueryOptionsnow embeds it as apub feed: FeedOptionsfield with awith_feed_options(FeedOptions)setter. The existingQueryOptions::with_max_item_countandQueryOptions::with_continuation_tokensetters are retained as convenience functions that mutate the embeddedfeed(they're expected to be used commonly enough to warrant the shortcut). (#4447)
Breaking Changes
- All fallible public APIs now return
azure_data_cosmos::Result<T>(=Result<T, CosmosError>) instead ofazure_core::Result<T>, and the error type was renamedError→CosmosError(withCosmosErrorBuilderfor construction). Categorization moved from aKindenum to predicates onCosmosStatus(is_not_found(),is_throttled(),is_transient(), …); the underlyingazure_core::Erroris still reachable viastd::error::Error::source(). (#4442) - Moved
QueryOptions::max_item_countandQueryOptions::continuation_tokeninto the newQueryOptions::feed: FeedOptionsfield. Callers that read or assign these fields directly should switch tooptions.feed.max_item_count/options.feed.continuation_token. Thewith_max_item_count/with_continuation_tokenconvenience setters onQueryOptionscontinue to work unchanged. (#4447) ThroughputPropertiesis now#[non_exhaustive]and no longer derivesDefault. TheDefaultimpl produced a meaningless wire payload (no manual throughput and no autoscale settings, which would send an empty offer body). Callers should useThroughputProperties::manual(throughput)orThroughputProperties::autoscale(starting_maximum_throughput, increment_percent)instead. (#4447)- Marked the following public model enums and response wrappers as
#[non_exhaustive]to allow future variants/fields to be added without further breaking changes:VectorDataType,VectorDistanceFunction,ConflictResolutionMode,IndexingMode,SpatialType,CompositeIndexOrder,VectorIndexType,BatchResponse,ItemResponse,ResourceResponse<T>,ResponseBody,ResponseHeaders,PartitionKeyVersionandCosmosStatus. Callers must use..wildcard arms inmatches over these enums and cannot construct these structs via struct-literal syntax (the SDK already provides constructors / setters for the constructable types). (#4447) CosmosClientBuilder::buildnow takesAccountReferencedirectly instead ofimpl Into<AccountReference>. Callers should construct anAccountReferenceexplicitly viaAccountReference::with_credentialorAccountReference::with_authentication_keyand pass it in. (#4447)- Replaced
EffectivePartitionKey::min()/EffectivePartitionKey::max()with associated constantsEffectivePartitionKey::MIN/EffectivePartitionKey::MAX. The inner storage also changed fromStringtoCow<'static, str>so the constants can borrow static strings without allocating. Callers should rewriteEffectivePartitionKey::min()asEffectivePartitionKey::MIN.clone()(or just&EffectivePartitionKey::MINfor comparisons). (#4447) - Removed
PartitionKeyValue::undefined()(use the existingPartitionKeyValue::UNDEFINEDassociated constant instead) and replaced the test-onlyPartitionKeyValue::infinity()constructor with a publicly-availablePartitionKeyValue::INFINITYassociated constant. (#4447) - Removed
FeedRange::can_merge()andFeedRange::merge_with(). These are SDK-internal helpers used only by the session-token coalescing pipeline and are now implemented internally. ([#4447](https://git...
azure_storage_queue@1.0.0
1.0.0 (2026-05-13)
Breaking Changes
- Consolidated client constructors:
QueueClient::from_url()has been renamed tonew(), replacing the previous endpoint-plus-queue-name string overload. Each client now has a singlenew()that takes a fully-formedUrl:QueueClient::new(queue_url: Url, ...)QueueServiceClient::new(service_url: Url, ...)
- Renamed
QueueClient::endpoint()andQueueServiceClient::endpoint()tourl()for consistency with other Storage clients. QueueClient::send_message()now returnsListOfSentMessageinstead of a singleSentMessage. Access the sent message viaListOfSentMessage::items.
Bugs Fixed
QueueClient::new()andQueueServiceClient::new()now reject non-base URLs (e.g.data:,mailto:).
azure_storage_blob@1.0.0
1.0.0 (2026-05-13)
Breaking Changes
- Consolidated client constructors: the existing
from_url()constructors have been renamed tonew(), replacing the previous endpoint-plus-name string overloads. Each client now has a singlenew()that takes a fully-formedUrl:BlobClient::new(blob_url: Url, ...)BlockBlobClient::new(blob_url: Url, ...)AppendBlobClient::new(blob_url: Url, ...)PageBlobClient::new(blob_url: Url, ...)BlobContainerClient::new(container_url: Url, ...)BlobServiceClient::new(service_url: Url, ...)
BlobServiceClient::find_blobs_by_tags()is now pageable and returnsResult<Pager<FilteredBlobResponse, XmlFormat>>instead ofResult<Response<FilterBlobSegment, XmlFormat>>.BlobContainerClient::find_blobs_by_tags()is now pageable and returnsResult<Pager<FilteredBlobResponse, XmlFormat>>instead ofResult<Response<FilteredBlobResponse, XmlFormat>>.- Renamed
FilterBlobSegmenttoFilteredBlobResponse. - Renamed
FilteredBlobResponse.blobstoFilteredBlobResponse.blob_items. - Changed
FilteredBlobResponse.blob_itemsfromOption<Vec<FilterBlobItem>>toVec<FilterBlobItem>. - Renamed
ListContainersSegmentResponsetoListContainersResponse. - Removed
BlobFlatListSegmentwrapper;ListBlobsResponse.blob_itemsis nowVec<BlobItem>directly (previously accessed via.segment.blob_items). - Renamed
BlobProperties.customer_provided_key_sha256toencryption_key_sha256. - Renamed
BlobMetadata.additional_propertiestovalues. - Renamed
PageBlobClientCreateOptions::with_if_not_exists()toif_not_exists(). - Renamed
AppendBlobClientCreateOptions::with_if_not_exists()toif_not_exists(). - Renamed
BlockBlobClientUploadBlobFromUrlOptions::with_if_not_exists()toif_not_exists(). - Renamed
BlockBlobClientUploadOptions::with_if_not_exists()toif_not_exists(). - Removed the
endpoint()method from all clients. Useurl()instead. - Removed
PageBlobClient::get_page_ranges()along with thePageList,PageRange,ClearRange,PageBlobClientGetPageRangesOptions, andPageListHeaderstypes. - Removed the
azure_storage_blob::errorandazure_storage_blob::models::errormodule paths. Use the re-exportedazure_storage_blob::{Result, StorageError}instead.
Features Added
- Added
with_tags()helpers to set blob tags on create/upload options by acceptingBlobTagsorHashMap<String, String>and encoding them into thex-ms-tagsheader format:PageBlobClientCreateOptions::with_tags()AppendBlobClientCreateOptions::with_tags()BlockBlobClientUploadOptions::with_tags()BlockBlobClientUploadBlobFromUrlOptions::with_tags()BlockBlobClientCommitBlockListOptions::with_tags()
Bugs Fixed
- All client constructors (
BlobClient::new(),BlobContainerClient::new(),BlobServiceClient::new(),AppendBlobClient::new(),BlockBlobClient::new(),PageBlobClient::new()) now reject non-base URLs (e.g.data:,mailto:).
azure_security_keyvault_secrets@1.0.0
1.0.0 (2026-05-12)
Features Added
- Initial stable release.
Breaking Changes
- Vault URLs must use TLS (https).
azure_security_keyvault_keys@1.0.0
1.0.0 (2026-05-12)
Features Added
- Initial stable release.
Breaking Changes
- Vault URLs must use TLS (https).