• Evan Richard's avatar
    op-service, op-batcher, op-proposer: Active sequencer follow mode (#8585) · c04cefe0
    Evan Richard authored
    * op-service: Add ActiveL2EndpointProvider.
    
    * Fix bug in initialization, and handle case where no ethUrls are provided.
    
    * Split active L2 provider into active rollup and active L2 provider.
    
    * Re-duplicate some code until tests are passing.
    
    * op-proposer: Add ability to enable active provider.
    
    * op-batcher: Add ability to enable active provider.
    
    * Add an empty test skeleton.
    
    * Add an empty test skeleton.
    
    * op-service: add, but do not yet use, RollupClientInterface and EthClientInterface.
    
    * op-service: update mocks and interfaces for endpoint provider testing.
    
    * op-service - WIP on Active L2 Providers: unit tests pass, design and impl contains TODOs.
    
    * op-service: restore design in Active Endpoint Providers that only keeps one client open at a time.
    
    * op-service: when dialing a new sequencer, close() the old connection.
    
    * op-service: obey coderabbit suggestion around safer handling of p.currentIndex in Active L2 Providers.
    
    * op-service, op-batcher, op-proposer: address review comments in PR#8585.
    
    * op-service: Active L2 Provider - add test case for a sequencer returning an error.
    
    * op-service: Active L2/Rollup Providers: improve unit testing and logging.
    
    * op-service, op-batcher: address review comments in 8585 regarding first-startup behavior and testing.
    
    * op-service: address review comments through adding more tests, and moving "nil client" behavior from client getter to constructor.
    
    * op-service: minor error message change in active endpoint providers.
    
    * Update op-service/dial/active_l2_provider.go
    Co-authored-by: default avatarcoderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
    
    * op-service: obey linter in rabbit-provided error message change.
    
    * Update op-service/dial/active_l2_provider.go
    Co-authored-by: default avatarSebastian Stammler <seb@oplabs.co>
    
    * op-service active L2 provider tests: assertAllExpectations after most tests.
    
    * op-service: more elegantly handle startup in active l2 providers, and improve testing.
    
    * Change remaining longDurationTests to be able to use ept.assertAllExpectations.
    
    * use new error errSeqUnset.
    
    * Add test for scenario where many sequencers are inactive, and only the last is active.
    
    * Readability change: move the on-creation initialization to its own function.
    
    * Move extra one-time dial to constructor.
    
    * Update op-service/dial/active_rollup_provider.go
    Co-authored-by: default avatarcoderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
    
    * Add nil check to active l2 provider.
    
    * Update op-service/dial/active_rollup_provider.go
    Co-authored-by: default avatarSebastian Stammler <seb@oplabs.co>
    
    * Address review comment: change many-inactive tests to many-undialable tests.
    
    * Add test that reproduces internal state corruption.
    
    * op-service: Improve active seq provider
    
    - Preserve the invariant that the index and current rollup/eth
      client match.
    - Dial at the start of the loop instead of at the end.
    
    * Fix some tests.
    
    * Move usage of ExpectClose to MaybeClose, we don't want to enforce a particular close behavior in these tests.
    
    * add a missing call to assertAllExpectations.
    
    * Test even the case where the active providers are managing a list of 1 element.
    
    * Revert experimental hunk in active_l2_provider.
    
    ---------
    Co-authored-by: default avatarcoderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
    Co-authored-by: default avatarSebastian Stammler <seb@oplabs.co>
    c04cefe0
mock_rollup_client.go 1.99 KB