本文へ移動
← すべてのコース
コース · perp の構築

Step 1. Consensus — cargo init から single-validator devnet 構築

Hyperliquid 型の L1 コンセンサス層を一から作る。本番品質の Reth(EVM)と Malachite(BFT)を 1 つの Rust workspace にまとめ、ブロックを end-to-end で生成する。リファレンス実装(psyto/openhl)をもとに手を動かして学ぶ。openhl 構築コース群の 1 つ。

perp 取引所を作る · EVM / Reth — OpenHL を順に · 全 6 コース中 1 番目次のコース: Step 2. CLOB — マッチングエンジンの追加とステートマシンの統合 →

コースを始める →エキスパート約 11 時間16 レッスン

Orientation

  1. OpenHL を自作する(cargo init → single-validator devnet)20 分

Foundations

  1. レッスン1 — Workspace + Reth + Malachite45 分

Contract types

  1. レッスン2 — openhl-types の共通 contract type30 分
  2. レッスン3 — ConsensusBridge trait30 分

EL test double

  1. レッスン4 — InMemoryEvmBridge — trait の最初の impl40 分
  2. レッスン5 — real alloy 型を使う RethEvmBridge40 分

CL types

  1. レッスン6 — OpenHlContext と Malachite の 10 sub-type50 分
  2. レッスン7 — OpenHlSigningProvider と canonical encoding40 分
  3. レッスン8 — OpenHlCodec — エンジンが要求する codec スロット35 分
  4. レッスン9 — OpenHlNode と初の start_engine 呼び出し55 分

Engine integration

  1. レッスン10 — run_engine_app と actor pipeline 経由の最初のブロック55 分

Live Reth

  1. レッスン11 — workspace で live Reth EthereumNode を boot する40 分
  2. レッスン12 — LiveRethEvmBridge が real chain から parent を読む50 分
  3. レッスン13 — validate_payload が Reth の EthBeaconConsensus を走らせる55 分
  4. レッスン14 — commit が Reth の Engine API forkchoice を駆動する50 分

Capstone

  1. レッスン15 — 作ったもの、まだ stub のもの、次に行く先25 分