PersistedOperationException

Abstract base for every structured failure raised by IPersistedOperationStore.UpsertAsync. Inherits InvalidOperationException so legacy callers that catch InvalidOperationException still see them.

All subclasses expose a stable Code string that matches the code field on the GraphQL mutation errors[] payload.

SubclassCodeWhen
PersistedOperationParseExceptionPARSE_FAILEDDocument failed Utf8GraphQLParser.Parse.
PersistedOperationValidationExceptionSCHEMA_VALIDATION_FAILEDDocument parsed but failed HotChocolate validation.
ShapeDiffViolationExceptionSHAPE_DIFF_VIOLATIONEdit changes the response shape of an existing id.

PersistedOperationParseException

PropertyTypeNotes
CodestringAlways "PARSE_FAILED".
Lineint?1-based line number when the parser exposed one.
Columnint?1-based column number when the parser exposed one.
OriginalMessagestringThe parser's original message, preserved without prefixing.

PersistedOperationValidationException

PropertyTypeNotes
CodestringAlways "SCHEMA_VALIDATION_FAILED".
FailuresIReadOnlyList<ValidationFailure>One entry per HotChocolate validation error. Construction throws ArgumentException for an empty list (a validation exception with no failures is meaningless).

ValidationFailure is a record with:

FieldTypeNotes
MessagestringValidator-provided message.
LocationsIReadOnlyList<ValidationFailureLocation>Empty when not available.
PathIReadOnlyList<object>Response-path components leading to the failure. Empty when not applicable.

ShapeDiffViolationException

PropertyTypeNotes
CodestringAlways "SHAPE_DIFF_VIOLATION".
IdstringThe id whose shape would change.
OldFingerprintstringFingerprint stored on the existing row.
NewFingerprintstringFingerprint computed from the proposed new document.

Pass UpsertOptions { BypassShapeDiff = true } (or bypassShapeDiff: true on the GraphQL mutation) when the change is verified safe for shipped clients.