Skip to content

Phase 1: StorageRW contention contract + key distribution #36

@bdchatham

Description

@bdchatham

Part of #33. Depends on the Distribution primitive. The headline contention knob.

Problem

Hot-key contention exists only as the binary ERC20Conflict (hardcoded counter++, 100%-or-nothing). You can't study "how Sei degrades as contention rises" with an on/off switch.

Approach

  • StorageRW contract: read/write/rmw a slot whose index is drawn (via keyDist) from a keyspace of size recordcount. Read/write/rmw proportions = a weighted scenario mix (reuse generator/weighted.go).
  • Contention becomes a continuum: huge keyspace + uniform ≈ 0% → single slot ≈ 100%, dialed by (recordcount, θ).
  • Deprecate, don't delete ERC20Conflict — keep it parseable/runnable so existing profiles work.
  • Version the contract StorageRWv1 + pin the ABI (on-chain layout is forward-only on persistent chains).

Acceptance criteria

  • Sweeping (recordcount, θ) produces a measurable contention gradient end-to-end.
  • ERC20Conflict still runs (marked deprecated).

Design: https://github.com/sei-protocol/platform/blob/main/docs/designs/sei-load-workload-modeler.md

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions