Skip to content

failnext v0.6.0

Latest

Choose a tag to compare

@yermakovsa yermakovsa released this 25 Sep 15:50
· 1 commit to main since this release
9c02b3c

First release under the failnext name.

This release is a larger redesign of rcpx, with a simpler focus: ordered failover across a small set of HTTP or RPC providers.

failnext is now protocol-neutral. It no longer parses JSON-RPC or tries to decide which operations are safe to repeat. Instead, the application controls when failover is allowed, which providers are eligible, and whether a particular provider should be tried first.

For go-ethereum applications, this makes it possible to keep the routing policy close to the code that understands the operation: allow reads to fail over, keep sensitive writes on one provider, skip RPCs the application considers lagging or degraded, and prefer the provider that handled an earlier operation for a follow-up request.

The module path has changed from github.com/yermakovsa/rcpx to:

github.com/yermakovsa/failnext

The API has changed significantly from rcpx, so upgrading is not just a package rename.

Changes

  • Rename rcpx to failnext
  • Make the transport protocol-neutral
  • Add explicit per-request failover allow and deny controls
  • Add application-controlled endpoint eligibility
  • Add preferred-endpoint routing for related requests
  • Rework cooldown around provider failures
  • Add structured events for attempts, skips, replay failures, and final results
  • Add FailoverError with per-endpoint attempt information
  • Improve response fallback and request replay behavior
  • Rewrite the README around practical RPC failover use cases
  • Add production-oriented package and go-ethereum examples

See the README and examples for the new API and migration patterns.