From d8b38cf2306c314bc038721887d48b09e22f8cb0 Mon Sep 17 00:00:00 2001 From: Nishant Das Date: Thu, 30 Nov 2023 18:55:18 +0800 Subject: [PATCH] Drop Transaction Count for Transaction Generator (#13228) * reduce * comment --- testing/endtoend/components/eth1/transactions.go | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/testing/endtoend/components/eth1/transactions.go b/testing/endtoend/components/eth1/transactions.go index e35b24f14..cd8527085 100644 --- a/testing/endtoend/components/eth1/transactions.go +++ b/testing/endtoend/components/eth1/transactions.go @@ -28,6 +28,8 @@ import ( "golang.org/x/sync/errgroup" ) +const txCount = 20 + var fundedAccount *keystore.Key type TransactionGenerator struct { @@ -82,7 +84,7 @@ func (t *TransactionGenerator) Start(ctx context.Context) error { return err } f := filler.NewFiller(rnd) - // Broadcast Transactions every 3 blocks + // Broadcast Transactions every slot txPeriod := time.Duration(params.BeaconConfig().SecondsPerSlot) * time.Second ticker := time.NewTicker(txPeriod) gasPrice := big.NewInt(1e11) @@ -92,7 +94,7 @@ func (t *TransactionGenerator) Start(ctx context.Context) error { return nil case <-ticker.C: backend := ethclient.NewClient(client) - err = SendTransaction(client, mineKey.PrivateKey, f, gasPrice, mineKey.Address.String(), 100, backend, false) + err = SendTransaction(client, mineKey.PrivateKey, f, gasPrice, mineKey.Address.String(), txCount, backend, false) if err != nil { return err }