From 896862892133263e6f9fa4d028b846d535b023c1 Mon Sep 17 00:00:00 2001 From: Shadab Khan Date: Mon, 26 Dec 2022 20:17:25 +0530 Subject: [PATCH 1/4] feat(bridge): add faucet link to announcement --- .../src/components/HeaderAnnouncement.svelte | 17 ++++------------- 1 file changed, 4 insertions(+), 13 deletions(-) diff --git a/packages/bridge-ui/src/components/HeaderAnnouncement.svelte b/packages/bridge-ui/src/components/HeaderAnnouncement.svelte index c3c2729babd..2e5b886412f 100644 --- a/packages/bridge-ui/src/components/HeaderAnnouncement.svelte +++ b/packages/bridge-ui/src/components/HeaderAnnouncement.svelte @@ -3,19 +3,10 @@

Hello! At Taiko, we develop in open-source, so this URL, and others, - are publicly available. However, it is not ready to be used. We will - make an announcement when our public testnet is ready! - - - Follow @taikoxyz on Twitter - - - + >Receive some tokens for bridging with our faucet.

From d38f09543a42e7a98054040ccd2cad161bc09d39 Mon Sep 17 00:00:00 2001 From: Jeffery Walsh Date: Mon, 26 Dec 2022 12:57:00 -0800 Subject: [PATCH 2/4] faucet url --- .../bridge-ui/src/components/HeaderAnnouncement.svelte | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/packages/bridge-ui/src/components/HeaderAnnouncement.svelte b/packages/bridge-ui/src/components/HeaderAnnouncement.svelte index 2e5b886412f..7d33b683214 100644 --- a/packages/bridge-ui/src/components/HeaderAnnouncement.svelte +++ b/packages/bridge-ui/src/components/HeaderAnnouncement.svelte @@ -4,9 +4,10 @@

Receive some tokens for bridging with our faucet. + href="https://taiko.xyz/docs/alpha-1-testnet/request-eth-from-faucet" + class="font-bold text-white underline">faucet.

From c12d207b82a8a6e7d5cd566851499f51ac8fdd47 Mon Sep 17 00:00:00 2001 From: Jeffery Walsh Date: Mon, 26 Dec 2022 21:58:52 -0800 Subject: [PATCH 3/4] .default.env defaults, basic readme --- .../src/components/Transaction.svelte | 2 +- .../src/components/form/ProcessingFee.svelte | 5 ++-- packages/relayer/.default.env | 29 +++++++++---------- packages/relayer/README.md | 6 ++++ 4 files changed, 24 insertions(+), 18 deletions(-) diff --git a/packages/bridge-ui/src/components/Transaction.svelte b/packages/bridge-ui/src/components/Transaction.svelte index e40029a24db..fe82e40f19a 100644 --- a/packages/bridge-ui/src/components/Transaction.svelte +++ b/packages/bridge-ui/src/components/Transaction.svelte @@ -133,7 +133,7 @@ {#if !processable} - Pending {fromChain.id === CHAIN_TKO.id ? '(2-3hrs)': ''}... + Pending {:else if !transaction.receipt && transaction.status === MessageStatus.New}
  • - Custom: You can set a custom fee if you want to pay - less (and wait). + Custom:You can set a custom fee for the relayer to + incentivize them to prioritize your request. A lower fee may result in + longer processing time.
  • None: You can select no fee if you want to come back diff --git a/packages/relayer/.default.env b/packages/relayer/.default.env index 7445d2e4e49..4406ea05ee2 100644 --- a/packages/relayer/.default.env +++ b/packages/relayer/.default.env @@ -1,22 +1,21 @@ -HTTP_PORT=4102 -PROMETHEUS_HTTP_PORT=6060 +HTTP_PORT=4101 +PROMETHEUS_HTTP_PORT=6061 MYSQL_USER=root MYSQL_PASSWORD=root MYSQL_DATABASE=relayer MYSQL_HOST=localhost:3306 +MYSQL_MAX_IDLE_CONNS=50 +MYSQL_MAX_OPEN_CONNS=3000 +MYSQL_CONN_MAX_LIFETIME_IN_MS=100000 RELAYER_ECDSA_KEY= -L1_BRIDGE_ADDRESS=0xB12d6112D64B213880Fa53F815aF1F29c91CaCe9 -L2_BRIDGE_ADDRESS=0xA53a0f12879Aba509A24D2e5C959a36cdD18F9d0 -L1_TAIKO_ADDRESS=0x9b557777Be33A8A2fE6aF93E017A0d139B439E5D -L2_TAIKO_ADDRESS=0x80EDBd3f3618b348526F0970AEAFA52b6f204449 -L1_RPC_URL=ws://34.132.67.34:8546 -L2_RPC_URL=ws://ws.a1.testnet.taiko.xyz -BLOCK_BATCH_SIZE=2 -MYSQL_MAX_IDLE_CONNS= -MYSQL_MAX_OPEN_CONNS= -MYSQL_CONN_MAX_LIFETIME_IN_MS= -NUM_GOROUTINES=20 -SUBSCRIPTION_BACKOFF_IN_SECONDS=3 -CONFIRMATIONS_BEFORE_PROCESSING=15 +L1_BRIDGE_ADDRESS=0x3612E284D763f42f5E4CB72B1602b23DAEC3cA60 +L2_BRIDGE_ADDRESS=0x0000777700000000000000000000000000000004 +L1_TAIKO_ADDRESS=0x7B3AF414448ba906f02a1CA307C56c4ADFF27ce7 +L2_TAIKO_ADDRESS=0x0000777700000000000000000000000000000001 +L1_RPC_URL=wss://l1ws.a1.taiko.xyz +L2_RPC_URL=wss://l2ws.a1.taiko.xyz +CONFIRMATIONS_BEFORE_PROCESSING=13 CORS_ORIGINS=* +NUM_GOROUTINES=1000 +BLOCK_BATCH_SIZE=100 HEADER_SYNC_INTERVAL_IN_SECONDS=60 \ No newline at end of file diff --git a/packages/relayer/README.md b/packages/relayer/README.md index f12149044b5..b12f5bfe8fe 100644 --- a/packages/relayer/README.md +++ b/packages/relayer/README.md @@ -5,6 +5,12 @@ A relayer for the Bridge to watch and sync event between Layer 1 and Taiko Layer 2. +## Running the app + +run `cp .default.env .env`, and add your own private key as `RELAYER_ECDSA_KEY` in `.env`. You need to be running a MySQL instance, and replace all the `MYSQL_` env vars with yours. + +Run `go run cmd/main.go --help` to see a list of possible configuration flags, or `go run cmd/main.go` to run with defaults, which will process messages from L1 to L2, and from L2 to L1, and start indexing blocks from 0. + ## Project structure ### bin From 3e81c570ca3b0d5fb4c2d72f1fe514dec62538eb Mon Sep 17 00:00:00 2001 From: Jeffery Walsh Date: Mon, 26 Dec 2022 21:59:20 -0800 Subject: [PATCH 4/4] sensible defaults --- packages/relayer/.default.env | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/relayer/.default.env b/packages/relayer/.default.env index 4406ea05ee2..5097c633e8f 100644 --- a/packages/relayer/.default.env +++ b/packages/relayer/.default.env @@ -16,6 +16,6 @@ L1_RPC_URL=wss://l1ws.a1.taiko.xyz L2_RPC_URL=wss://l2ws.a1.taiko.xyz CONFIRMATIONS_BEFORE_PROCESSING=13 CORS_ORIGINS=* -NUM_GOROUTINES=1000 -BLOCK_BATCH_SIZE=100 +NUM_GOROUTINES=100 +BLOCK_BATCH_SIZE=10 HEADER_SYNC_INTERVAL_IN_SECONDS=60 \ No newline at end of file