Path: redb-route/redb.Route.Sql/Batch/BatchItemFailedException.cs
Snapshot: redb-route, development snapshot 2026-12-06. This is the development state of the public mirrors; it may differ from the published packages.
License: Apache-2.0. Repository: https://github.com/redbase-app/redb-route
Page: https://redbase.app/src/dev-2026-12-06/redb-route/redb.Route.Sql/Batch/BatchItemFailedException.cs
----
namespace redb.Route.Sql.Batch;
///
/// Internal carrier from a batch writer to the batch processor: the item at ended the batch. It never
/// leaves the connector — the processor rolls back and rethrows the provider's exception, which is the inner exception.
///
internal sealed class BatchItemFailedException(int index, Exception providerException)
: Exception($"Batch item {index} failed.", providerException)
{
/// Zero-based position of the failed item in the batch source.
public int Index { get; } = index;
}