Skip to content

Conversation

@niran
Copy link
Contributor

@niran niran commented Jan 26, 2026

Summary

Add support for proxyd from OP Labs to enable transparent routing of RPC methods:

  • Transaction submission methods → ingress RPC
  • Standard Ethereum RPC methods → op-geth or flashblocks-rpc

Key Features

  • Uses production-grade us-docker.pkg.dev/oplabs-tools-artifacts/images/proxyd image
  • Method-based routing via TOML configuration
  • Automatic selection of backend based on --flashblocks flag
  • Custom method routing via CLI flags

Usage

# Basic usage with ingress
builder-playground start opstack --proxyd --ingress-rpc ingress-rpc

# With flashblocks (routes base_meter* methods correctly)
builder-playground start opstack --proxyd --flashblocks --ingress-rpc ingress-rpc

# With custom method routing
builder-playground start opstack --proxyd --proxyd-ingress-methods eth_customSubmit --proxyd-standard-methods debug_customTrace

Implementation Details

Two-Backend Architecture

Ingress backend: Routes transaction submission methods

  • eth_sendRawTransaction
  • eth_sendBundle
  • eth_sendBackrunBundle
  • eth_cancelBundle
  • eth_sendUserOperation

Standard backend: Routes everything else

  • When --flashblocks disabled: op-geth
  • When --flashblocks enabled: flashblocks-rpc (handles standard methods + base_meter*)

Default Method Mappings

Includes all standard Ethereum RPC methods (eth_call, eth_blockNumber, etc.) and Base-specific methods (base_transactionStatus, base_meterBundle, etc.)

Custom Method Routing

  • --proxyd-ingress-methods: Route additional methods to ingress
  • --proxyd-standard-methods: Route additional methods to standard backend

Testing

Tested with:

  • Standard RPC methods (eth_chainId, eth_blockNumber)
  • Transaction submission (eth_sendRawTransaction)
  • Base metering methods (base_meterBundle with --flashblocks)

niran added 5 commits January 25, 2026 16:06
Add support for the proxyd component from Base's infra-routing repository, enabling transparent routing of transaction submission methods to an ingress RPC endpoint while routing all other RPC methods to the standard execution layer.

Key changes:
- Add Proxyd component that uses Base's proxyd Docker image
- Generate proxyd TOML configuration with method-based routing
- Add --proxyd and --ingress-rpc flags to OpStack recipe
- Route transaction submission methods to ingress endpoint
- Route all other methods to standard EL (op-geth or rollup-boost)
- Expose proxyd on port 8545 (mapped to dynamic host port)
- Update documentation with new flags

The proxyd configuration routes the following methods to ingress:
- eth_sendRawTransaction (standard transaction submission)
- eth_sendBundle (bundle submission)
- eth_sendBackrunBundle (backrun bundle submission)
- eth_cancelBundle (bundle cancellation)
- eth_sendUserOperation (ERC-4337 user operation submission)

All other RPC methods are routed to the standard execution layer node.
Use us-docker.pkg.dev/oplabs-tools-artifacts/images/proxyd which is the
publicly available proxyd image from OP Labs, instead of the non-existent
docker.io/base/proxyd image.
proxyd requires explicit method mappings - there is no default fallback.
Add mappings for all standard Ethereum JSON-RPC methods to route them to
the standard backend, while keeping transaction submission methods routed
to ingress:

- Transaction submission to ingress: eth_sendRawTransaction, eth_sendBundle,
  eth_sendBackrunBundle, eth_cancelBundle, eth_sendUserOperation
- All other methods to standard: eth_chainId, eth_call, eth_getBalance,
  eth_blockNumber, and all other standard Ethereum RPC methods
When --flashblocks is enabled, use flashblocks-rpc as standard backend
(handles both standard RPC methods and base_meter* methods).

Add --proxyd-ingress-methods and --proxyd-standard-methods flags for
custom method routing.
Add unit and integration tests covering:
- Proxyd TOML config generation with correct backend routing
- Flashblocks-rpc as standard backend when enabled
- Custom method routing via CLI flags
- Recipe integration with various flag combinations
- Proxyd service in manifest and output

Tests verify:
- Transaction submission methods route to ingress
- Standard Ethereum methods route to standard backend
- Base-specific methods (base_meter*) route correctly
- Custom methods can be added via flags
- Proxyd endpoint is accessible and functional

All unit tests pass without requiring INTEGRATION_TESTS=true.
@ferranbt
Copy link
Collaborator

Thank you for the contribution. Could you write the proxyd config in the component itself? This is something I am iterating on to avoid having to go through the artifacts for specific per component configurations. This is an example.

niran added 3 commits January 28, 2026 16:09
The flag was wrapping the value with http:// and :8080, causing malformed
URLs when users passed a full URL. Now mirrors --external-builder behavior.
Add comments documenting that proxyd and websocket-proxy images are
amd64-only, with instructions for building from source on other
architectures and using --override flags.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants