From cb269c5d0ef9959b0e28fe9d76b8672e063e9d0f Mon Sep 17 00:00:00 2001 From: Enrico Del Fante Date: Thu, 31 Oct 2024 13:36:54 +0100 Subject: [PATCH] improve integration test bug fix --- .../coordinator/publisher/BlockPublisherDeneb.java | 1 + .../coordinator/publisher/BlockPublisherPhase0.java | 5 ++--- .../performance/trackers/BlockPublishingPerformance.java | 4 ++-- .../trackers/BlockPublishingPerformanceImpl.java | 8 ++++---- 4 files changed, 9 insertions(+), 9 deletions(-) diff --git a/beacon/validator/src/main/java/tech/pegasys/teku/validator/coordinator/publisher/BlockPublisherDeneb.java b/beacon/validator/src/main/java/tech/pegasys/teku/validator/coordinator/publisher/BlockPublisherDeneb.java index 3512f81cf54..674ca235f29 100644 --- a/beacon/validator/src/main/java/tech/pegasys/teku/validator/coordinator/publisher/BlockPublisherDeneb.java +++ b/beacon/validator/src/main/java/tech/pegasys/teku/validator/coordinator/publisher/BlockPublisherDeneb.java @@ -67,6 +67,7 @@ void importBlobSidecars( void publishBlobSidecars( final List blobSidecars, final BlockPublishingPerformance blockPublishingPerformance) { + blockPublishingPerformance.blobSidecarsPublishingInitiated(); blobSidecarGossipChannel.publishBlobSidecars(blobSidecars).ifExceptionGetsHereRaiseABug(); } } diff --git a/beacon/validator/src/main/java/tech/pegasys/teku/validator/coordinator/publisher/BlockPublisherPhase0.java b/beacon/validator/src/main/java/tech/pegasys/teku/validator/coordinator/publisher/BlockPublisherPhase0.java index 3d832f0910e..014417b21ba 100644 --- a/beacon/validator/src/main/java/tech/pegasys/teku/validator/coordinator/publisher/BlockPublisherPhase0.java +++ b/beacon/validator/src/main/java/tech/pegasys/teku/validator/coordinator/publisher/BlockPublisherPhase0.java @@ -65,9 +65,8 @@ void importBlobSidecars( @Override SafeFuture publishBlock( final SignedBeaconBlock block, final BlockPublishingPerformance blockPublishingPerformance) { - return blockGossipChannel - .publishBlock(block) - .alwaysRun(blockPublishingPerformance::blockPublishingInitiated); + blockPublishingPerformance.blockPublishingInitiated(); + return blockGossipChannel.publishBlock(block); } @Override diff --git a/ethereum/performance-trackers/src/main/java/tech/pegasys/teku/ethereum/performance/trackers/BlockPublishingPerformance.java b/ethereum/performance-trackers/src/main/java/tech/pegasys/teku/ethereum/performance/trackers/BlockPublishingPerformance.java index fe9e468ec08..a60be63266f 100644 --- a/ethereum/performance-trackers/src/main/java/tech/pegasys/teku/ethereum/performance/trackers/BlockPublishingPerformance.java +++ b/ethereum/performance-trackers/src/main/java/tech/pegasys/teku/ethereum/performance/trackers/BlockPublishingPerformance.java @@ -29,7 +29,7 @@ public void builderGetPayload() {} public void blobSidecarsPrepared() {} @Override - public void blockAndBlobSidecarsPublishingInitiated() {} + public void blobSidecarsPublishingInitiated() {} @Override public void blockPublishingInitiated() {} @@ -38,7 +38,7 @@ public void blockPublishingInitiated() {} public void blockImportCompleted() {} }; - void blockAndBlobSidecarsPublishingInitiated(); + void blobSidecarsPublishingInitiated(); void blockPublishingInitiated(); diff --git a/ethereum/performance-trackers/src/main/java/tech/pegasys/teku/ethereum/performance/trackers/BlockPublishingPerformanceImpl.java b/ethereum/performance-trackers/src/main/java/tech/pegasys/teku/ethereum/performance/trackers/BlockPublishingPerformanceImpl.java index 9772817cfef..e5ae3e6d647 100644 --- a/ethereum/performance-trackers/src/main/java/tech/pegasys/teku/ethereum/performance/trackers/BlockPublishingPerformanceImpl.java +++ b/ethereum/performance-trackers/src/main/java/tech/pegasys/teku/ethereum/performance/trackers/BlockPublishingPerformanceImpl.java @@ -67,13 +67,13 @@ public void blobSidecarsPrepared() { } @Override - public void blockAndBlobSidecarsPublishingInitiated() { - performanceTracker.addEvent("block_and_blob_sidecars_publishing_initiated"); + public void blockPublishingInitiated() { + performanceTracker.addEvent("block_publishing_initiated"); } @Override - public void blockPublishingInitiated() { - performanceTracker.addEvent("block_publishing_initiated"); + public void blobSidecarsPublishingInitiated() { + performanceTracker.addEvent("blob_sidecars_publishing_initiated"); } @Override