diff --git a/.github/workflows/_build-binaries.yaml b/.github/workflows/_build-binaries.yaml index ad81e6a..21ad22e 100644 --- a/.github/workflows/_build-binaries.yaml +++ b/.github/workflows/_build-binaries.yaml @@ -5,11 +5,11 @@ name: Build Binaries on: workflow_call: inputs: - reth_version: - description: "Reth version to build" + optimism_version: + description: "Optimism version to build" required: false type: string - default: "27a8c0f5a6dfb27dea84c5751776ecabdd069646" + default: "3019251e80aa248e91743addd3e833190acb26f1" geth_version: description: "Geth version to build" required: false @@ -85,10 +85,10 @@ jobs: - name: Cache reth binary uses: actions/cache@2f8e54208210a422b2efd51efaa6bd6d7ca8920f # v3.4.3 - id: cache-reth + id: cache-optimism with: path: ~/bin/reth - key: ${{ runner.os }}-reth-${{ inputs.reth_version }} + key: ${{ runner.os }}-reth-${{ inputs.optimism_version }} - name: Build reth if: steps.cache-reth.outputs.cache-hit != 'true' @@ -96,14 +96,14 @@ jobs: unset CI mkdir -p ~/bin cd clients - RETH_VERSION=${{ inputs.reth_version }} OUTPUT_DIR=~/bin ./build-reth.sh + OPTIMISM_VERSION=${{ inputs.optimism_version }} OUTPUT_DIR=~/bin ./build-reth.sh # Rename op-reth to reth for consistency [ -f ~/bin/op-reth ] && mv ~/bin/op-reth ~/bin/reth || true - name: Upload reth artifact uses: actions/upload-artifact@6f51ac03b9356f520e9adb1b1b7802705f340c2b # v4.5.0 with: - name: reth + name: optimism path: ~/bin/reth retention-days: 1 diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 133ced7..da0f226 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -69,7 +69,7 @@ jobs: actions: write # Required for reusable workflow to upload artifacts uses: ./.github/workflows/_build-binaries.yaml with: - reth_version: 27a8c0f5a6dfb27dea84c5751776ecabdd069646 + optimism_version: 3019251e80aa248e91743addd3e833190acb26f1 geth_version: 6cbfcd5161083bcd4052edc3022d9f99c6fe40e0 builder_version: 23f42c8e78ba3abb45a8840df7037a27e196e601 base_reth_node_version: main @@ -104,7 +104,7 @@ jobs: - name: Download reth binary uses: actions/download-artifact@fa0a91b85d4f404e444e00e005971372dc801d16 # v4.1.8 with: - name: reth + name: optimism path: ${{ runner.temp }}/bin/ - name: Download geth binary diff --git a/.github/workflows/examples.yaml b/.github/workflows/examples.yaml index 1ae6fec..d4faf5d 100644 --- a/.github/workflows/examples.yaml +++ b/.github/workflows/examples.yaml @@ -16,7 +16,7 @@ jobs: actions: write # Required for reusable workflow to upload artifacts uses: ./.github/workflows/_build-binaries.yaml with: - reth_version: 27a8c0f5a6dfb27dea84c5751776ecabdd069646 + optimism_version: 3019251e80aa248e91743addd3e833190acb26f1 geth_version: 6cbfcd5161083bcd4052edc3022d9f99c6fe40e0 builder_version: 23f42c8e78ba3abb45a8840df7037a27e196e601 base_reth_node_version: main @@ -53,7 +53,7 @@ jobs: - name: Download reth binary uses: actions/download-artifact@fa0a91b85d4f404e444e00e005971372dc801d16 # v4.1.8 with: - name: reth + name: optimism path: ${{ runner.temp }}/bin/ - name: Download geth binary diff --git a/.github/workflows/public-benchmarks.yaml b/.github/workflows/public-benchmarks.yaml index 336f74d..7b8f579 100644 --- a/.github/workflows/public-benchmarks.yaml +++ b/.github/workflows/public-benchmarks.yaml @@ -16,7 +16,7 @@ jobs: actions: write # Required for reusable workflow to upload artifacts uses: ./.github/workflows/_build-binaries.yaml with: - reth_version: 27a8c0f5a6dfb27dea84c5751776ecabdd069646 + optimism_version: 3019251e80aa248e91743addd3e833190acb26f1 geth_version: 6cbfcd5161083bcd4052edc3022d9f99c6fe40e0 builder_version: 23f42c8e78ba3abb45a8840df7037a27e196e601 @@ -52,7 +52,7 @@ jobs: - name: Download reth binary uses: actions/download-artifact@fa0a91b85d4f404e444e00e005971372dc801d16 # v4.1.8 with: - name: reth + name: optimism path: ${{ runner.temp }}/bin/ - name: Download geth binary diff --git a/clients/README.md b/clients/README.md index c655070..9e24a83 100644 --- a/clients/README.md +++ b/clients/README.md @@ -73,7 +73,7 @@ Modify the `versions.env` file to change defaults for all builds: ```bash # Edit versions.env to update default versions -RETH_VERSION="v0.2.0-beta.5" +OPTIMISM_VERSION="v0.2.0-beta.5" GETH_VERSION="v1.13.0" BUILDER_VERSION="your-commit-hash" ``` @@ -83,7 +83,7 @@ Override specific builds with environment variables: ```bash # Build reth from a specific commit -RETH_REPO="https://github.com/paradigmxyz/reth/" RETH_VERSION="v0.1.0" ./build-reth.sh +OPTIMISM_REPO="https://github.com/ethereum-optimism/optimism/" OPTIMISM_VERSION="v0.1.0" ./build-reth.sh # Build geth from a fork GETH_REPO="https://github.com/your-fork/op-geth/" GETH_VERSION="your-branch" ./build-geth.sh @@ -95,8 +95,8 @@ BUILDER_VERSION="main" ./build-builder.sh ### Available Environment Variables #### For reth (build-reth.sh): -- `RETH_REPO`: Git repository URL (default: https://github.com/paradigmxyz/reth/) -- `RETH_VERSION`: Git branch, tag, or commit hash (default: main) +- `OPTIMISM_REPO`: Git repository URL (default: https://github.com/ethereum-optimism/optimism/) +- `OPTIMISM_VERSION`: Git branch, tag, or commit hash (default: develop) - `BUILD_DIR`: Directory for source code (default: ./build) - `OUTPUT_DIR`: Directory for built binaries (default: ../bin) diff --git a/clients/build-reth.sh b/clients/build-reth.sh index c8a1610..0568ac6 100755 --- a/clients/build-reth.sh +++ b/clients/build-reth.sh @@ -8,14 +8,14 @@ if [ -f "versions.env" ]; then fi # Default values -RETH_REPO="${RETH_REPO:-https://github.com/paradigmxyz/reth/}" -RETH_VERSION="${RETH_VERSION:-main}" +OPTIMISM_REPO="${OPTIMISM_REPO:-https://github.com/ethereum-optimism/optimism/}" +OPTIMISM_VERSION="${OPTIMISM_VERSION:-develop}" BUILD_DIR="${BUILD_DIR:-./build}" OUTPUT_DIR="${OUTPUT_DIR:-../bin}" -echo "Building reth binary..." -echo "Repository: $RETH_REPO" -echo "Version/Commit: $RETH_VERSION" +echo "Building op-reth binary..." +echo "Repository: $OPTIMISM_REPO" +echo "Version/Commit: $OPTIMISM_VERSION" echo "Build directory: $BUILD_DIR" echo "Output directory: $OUTPUT_DIR" @@ -24,28 +24,32 @@ mkdir -p "$BUILD_DIR" cd "$BUILD_DIR" # Clone or update repository -if [ -d "reth" ]; then - echo "Updating existing reth repository..." - cd reth +if [ -d "optimism" ]; then + echo "Updating existing optimism repository..." + cd optimism git fetch origin # ensure remote matches the repository - git remote set-url origin "$RETH_REPO" + git remote set-url origin "$OPTIMISM_REPO" git fetch origin else - echo "Cloning reth repository..." - git clone "$RETH_REPO" reth - cd reth + echo "Cloning optimism repository..." + git clone "$OPTIMISM_REPO" optimism + cd optimism fi # Checkout specified version/commit -echo "Checking out version: $RETH_VERSION" -git checkout -f "$RETH_VERSION" +echo "Checking out version: $OPTIMISM_VERSION" +git checkout -f "$OPTIMISM_VERSION" + +pushd rust # Build the binary using cargo -echo "Building reth with cargo..." +echo "Building op-reth with cargo..." # Build with performance features matching CI workflow -cargo build --features asm-keccak,jemalloc --bin op-reth --profile maxperf --manifest-path crates/optimism/bin/Cargo.toml +cargo build --features asm-keccak,jemalloc --bin op-reth --profile maxperf --manifest-path op-reth/bin/Cargo.toml + +popd # Copy binary to output directory echo "Copying binary to output directory..." @@ -58,6 +62,6 @@ else FINAL_OUTPUT_DIR="../../$OUTPUT_DIR" fi mkdir -p "$FINAL_OUTPUT_DIR" -cp target/maxperf/op-reth "$FINAL_OUTPUT_DIR/" +cp rust/target/maxperf/op-reth "$FINAL_OUTPUT_DIR/" -echo "reth binary built successfully and placed in $FINAL_OUTPUT_DIR/op-reth" +echo "op-reth binary built successfully and placed in $FINAL_OUTPUT_DIR/op-reth" diff --git a/clients/versions.env b/clients/versions.env index 5ae712c..53ed4b5 100644 --- a/clients/versions.env +++ b/clients/versions.env @@ -3,8 +3,8 @@ # Source this file in scripts to use these variables # Reth Configuration -RETH_REPO="https://github.com/paradigmxyz/reth/" -RETH_VERSION="v1.9.3" +OPTIMISM_REPO="https://github.com/ethereum-optimism/optimism/" +OPTIMISM_VERSION="3019251e80aa248e91743addd3e833190acb26f1" # Op-Geth Configuration GETH_REPO="https://github.com/ethereum-optimism/op-geth/" diff --git a/runner/clients/reth/client.go b/runner/clients/reth/client.go index b3065d1..7a4a25c 100644 --- a/runner/clients/reth/client.go +++ b/runner/clients/reth/client.go @@ -99,6 +99,7 @@ func (r *RethClient) Run(ctx context.Context, cfg *types.RuntimeConfig) error { // increase mempool size args = append(args, "--txpool.pending-max-count", "100000000") args = append(args, "--txpool.queued-max-count", "100000000") + args = append(args, "--txpool.max-account-slots", "100000000") args = append(args, "--txpool.pending-max-size", "100") args = append(args, "--txpool.queued-max-size", "100")