Skip to content

Commit

Permalink
chore: remove unused metrics
Browse files Browse the repository at this point in the history
  • Loading branch information
twoeths committed Aug 17, 2023
1 parent d705074 commit f1c5043
Show file tree
Hide file tree
Showing 5 changed files with 3 additions and 13 deletions.
2 changes: 0 additions & 2 deletions packages/beacon-node/src/chain/validation/attestation.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import {toHexString} from "@chainsafe/ssz";
import bls from "@chainsafe/bls";
import {phase0, Epoch, Root, Slot, RootHex, ssz} from "@lodestar/types";
import {ProtoBlock} from "@lodestar/fork-choice";
import {ATTESTATION_SUBNET_COUNT, SLOTS_PER_EPOCH, ForkName, ForkSeq} from "@lodestar/params";
Expand All @@ -22,7 +21,6 @@ import {
import {AttestationDataCacheEntry} from "../seenCache/seenAttestationData.js";
import {sszDeserializeAttestation} from "../../network/gossip/topic.js";
import {Result, wrapError} from "../../util/wrapError.js";
import {MIN_SIGNATURE_SETS_TO_BATCH_VERIFY} from "../../network/processor/gossipQueues/index.js";

export type BatchResult = {
results: Result<AttestationValidationResult>[];
Expand Down
8 changes: 0 additions & 8 deletions packages/beacon-node/src/metrics/metrics/lodestar.ts
Original file line number Diff line number Diff line change
Expand Up @@ -580,18 +580,10 @@ export function createLodestarMetrics(
help: "Number of attestations verified in batch",
buckets: [1, 2, 4, 8, 16, 32, 64, 128],
}),
attestationBatchCount: register.gauge({
name: "lodestar_gossip_attestation_verified_in_batch_count",
help: "Count of attestations verified in batch",
}),
attestationNonBatchCount: register.gauge({
name: "lodestar_gossip_attestation_verified_non_batch_count",
help: "Count of attestations NOT verified in batch",
}),
totalBatch: register.gauge({
name: "lodestar_gossip_attestation_total_batch_count",
help: "Total number of attestation batches",
}),
},

// Gossip block
Expand Down
4 changes: 1 addition & 3 deletions packages/beacon-node/src/network/processor/gossipHandlers.ts
Original file line number Diff line number Diff line change
Expand Up @@ -395,9 +395,7 @@ export function getGossipHandlers(modules: ValidatorFnsModules, options: GossipH
}

if (batchableBls) {
metrics?.gossipAttestation.totalBatch.inc();
metrics?.gossipAttestation.attestationBatchCount.inc(attestationCount);
metrics?.gossipAttestation.attestationBatchHistogram.observe(gossipHandlerParams.length);
metrics?.gossipAttestation.attestationBatchHistogram.observe(attestationCount);
} else {
metrics?.gossipAttestation.attestationNonBatchCount.inc(attestationCount);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,7 @@ describe.skip("verify+import blocks - range sync perf test", () => {
suggestedFeeRecipient: defaultValidatorOptions.suggestedFeeRecipient,
skipCreateStateCacheIfAvailable: true,
archiveStateEpochFrequency: 1024,
minSameMessageSignatureSetsToBatch: 32,
},
{
config: state.config,
Expand Down
1 change: 1 addition & 0 deletions packages/beacon-node/test/utils/network.ts
Original file line number Diff line number Diff line change
Expand Up @@ -82,6 +82,7 @@ export async function getNetworkForTest(
disableArchiveOnCheckpoint: true,
disableLightClientServerOnImportBlockHead: true,
disablePrepareNextSlot: true,
minSameMessageSignatureSetsToBatch: 32,
},
{
config: beaconConfig,
Expand Down

0 comments on commit f1c5043

Please sign in to comment.