Skip to content

Expose the underlying Backoff rng source to support DST #788

Description

@AdamGS

Is your feature request related to a problem or challenge? Please describe what you are trying to do.

I'm using object-store as the IO layer for some deterministic simulation testing work. I'm trying to control all sources of randomness, and one of the things I've realized is that there's no way to seed Backoff and BackoffStrategy, so I have to disable retries completely, but I would actually love to use them.

Describe the solution you'd like

Through RetryConfig -> RetryContext, provide an optional way to seed the RNG inside of Backoff.

Describe alternatives you've considered
The alternatives I can think of are:

  1. Fork and patch object-store (Like madsim does).
  2. LD_PRELOAD something, which seems more fragile.

Happy to do the work to figure it out, I just want to get a sense as to how the maintainers feel about it.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions