Skip to content

Add attempt observation hook#10

Merged
yermakovsa merged 1 commit into
mainfrom
feat/attempt-observation
Jun 21, 2026
Merged

Add attempt observation hook#10
yermakovsa merged 1 commit into
mainfrom
feat/attempt-observation

Conversation

@yermakovsa

Copy link
Copy Markdown
Owner

Adds Config.OnAttempt for observing which upstreams rcpx attempts, including the upstream that handles a successful request.

The callback receives AttemptInfo with the attempt number, upstream URL, best-effort JSON-RPC method info, status code, error, and whether the attempt was final. It is called once per attempted upstream and does not affect retry, failover, cooldown, or non-idempotent safety behavior.

Includes tests for success, failover, retry policy stop, and non-idempotent blocking. Updates the README with the new hook behavior and raw upstream URL caveat.

Closes #6

@yermakovsa yermakovsa merged commit 40664ce into main Jun 21, 2026
1 check passed
@yermakovsa yermakovsa deleted the feat/attempt-observation branch June 21, 2026 06:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Expose chosen upstream for observability

1 participant