Skip to content

Commit 84b6b85

Browse files
Clarification on max attempts meaning (#596)
1 parent 258feec commit 84b6b85

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

packages/restate-sdk/src/context.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -171,7 +171,7 @@ export type RunOptions<T> = {
171171
serde?: Serde<T>;
172172

173173
/**
174-
* Max number of retry attempts, before giving up.
174+
* Max number of attempts (including the initial), before giving up.
175175
*
176176
* When giving up, `ctx.run` will throw a `TerminalError` wrapping the original error message.
177177
*/

packages/restate-sdk/src/types/rpc.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -759,7 +759,8 @@ export type ServiceOpts<U> = {
759759

760760
export type RetryPolicy = {
761761
/**
762-
* Max number of retry attempts. When reached, the behavior specified in {@link onMaxAttempts} will be applied.
762+
* Max number of retry attempts (including the initial).
763+
* When reached, the behavior specified in {@link onMaxAttempts} will be applied.
763764
*/
764765
maxAttempts?: number;
765766

0 commit comments

Comments
 (0)