Skip to content

Docs(Clients): Document transaction abort reason categories#761

Open
rahst12 wants to merge 1 commit into
dgraph-io:mainfrom
rahst12:txn-abort-reason-surface-phase-1
Open

Docs(Clients): Document transaction abort reason categories#761
rahst12 wants to merge 1 commit into
dgraph-io:mainfrom
rahst12:txn-abort-reason-surface-phase-1

Conversation

@rahst12

@rahst12 rahst12 commented Jun 17, 2026

Copy link
Copy Markdown

Description

Documents the new transaction abort reason categories that Dgraph reports to clients,
across the shared concept page and each client page.

When a commit aborts, the server now encodes why as a "<code>: <detail>" prefix on the
gRPC ABORTED status (and the HTTP error message), with <code> being one of conflict,
stale-startts, or predicate-move. This PR explains that format and the per-language
API:

  • clients/index.md — new "Abort reasons" subsection: the three categories, the
    message format, and graceful degradation to UNKNOWN against older servers.
  • clients/java.md — "Handling aborted transactions" using
    TxnConflictException.getReason() / AbortReason.
  • clients/python.md — parallel section for pydgraph.AbortedError.reason /
    pydgraph.AbortReason.
  • clients/raw-http.md — updated abort response example plus a table of the codes.

All four pages cross-link via the shared #abort-reasons anchor. Content is additive and
descriptive only.

Related PRs

Unreleased feature

⚠️ This documents behavior that has not shipped yet. Please hold merge until the
corresponding server and client releases are out.

@rahst12 rahst12 requested a review from rderbier as a code owner June 17, 2026 06:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

1 participant