@lodestar/beacon-node 1.41.0-dev.9fa839a030 → 1.41.0-dev.aeab9f930d
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/api/impl/api.js.map +1 -1
- package/lib/api/impl/beacon/blocks/index.d.ts +1 -1
- package/lib/api/impl/beacon/blocks/index.d.ts.map +1 -1
- package/lib/api/impl/beacon/blocks/index.js +123 -4
- package/lib/api/impl/beacon/blocks/index.js.map +1 -1
- package/lib/api/impl/beacon/blocks/utils.js.map +1 -1
- package/lib/api/impl/beacon/index.js.map +1 -1
- package/lib/api/impl/beacon/pool/index.d.ts +1 -1
- package/lib/api/impl/beacon/pool/index.d.ts.map +1 -1
- package/lib/api/impl/beacon/pool/index.js.map +1 -1
- package/lib/api/impl/beacon/rewards/index.d.ts +1 -1
- package/lib/api/impl/beacon/rewards/index.d.ts.map +1 -1
- package/lib/api/impl/beacon/rewards/index.js.map +1 -1
- package/lib/api/impl/beacon/state/index.d.ts +1 -1
- package/lib/api/impl/beacon/state/index.d.ts.map +1 -1
- package/lib/api/impl/beacon/state/index.js +8 -8
- package/lib/api/impl/beacon/state/index.js.map +1 -1
- package/lib/api/impl/beacon/state/utils.d.ts +3 -4
- package/lib/api/impl/beacon/state/utils.d.ts.map +1 -1
- package/lib/api/impl/beacon/state/utils.js +5 -24
- package/lib/api/impl/beacon/state/utils.js.map +1 -1
- package/lib/api/impl/config/constants.js.map +1 -1
- package/lib/api/impl/config/index.js.map +1 -1
- package/lib/api/impl/debug/index.d.ts +1 -1
- package/lib/api/impl/debug/index.d.ts.map +1 -1
- package/lib/api/impl/debug/index.js +6 -2
- package/lib/api/impl/debug/index.js.map +1 -1
- package/lib/api/impl/errors.d.ts.map +1 -1
- package/lib/api/impl/errors.js.map +1 -1
- package/lib/api/impl/events/index.d.ts +1 -1
- package/lib/api/impl/events/index.d.ts.map +1 -1
- package/lib/api/impl/events/index.js.map +1 -1
- package/lib/api/impl/lightclient/index.d.ts +1 -1
- package/lib/api/impl/lightclient/index.d.ts.map +1 -1
- package/lib/api/impl/lightclient/index.js +19 -2
- package/lib/api/impl/lightclient/index.js.map +1 -1
- package/lib/api/impl/lodestar/index.d.ts +1 -1
- package/lib/api/impl/lodestar/index.d.ts.map +1 -1
- package/lib/api/impl/lodestar/index.js.map +1 -1
- package/lib/api/impl/node/index.js.map +1 -1
- package/lib/api/impl/node/utils.d.ts +1 -1
- package/lib/api/impl/node/utils.d.ts.map +1 -1
- package/lib/api/impl/node/utils.js.map +1 -1
- package/lib/api/impl/proof/index.js.map +1 -1
- package/lib/api/impl/utils.js.map +1 -1
- package/lib/api/impl/validator/index.d.ts.map +1 -1
- package/lib/api/impl/validator/index.js +134 -18
- package/lib/api/impl/validator/index.js.map +1 -1
- package/lib/api/impl/validator/utils.d.ts +1 -1
- package/lib/api/impl/validator/utils.d.ts.map +1 -1
- package/lib/api/impl/validator/utils.js.map +1 -1
- package/lib/api/rest/activeSockets.d.ts.map +1 -1
- package/lib/api/rest/activeSockets.js.map +1 -1
- package/lib/api/rest/base.d.ts.map +1 -1
- package/lib/api/rest/base.js.map +1 -1
- package/lib/api/rest/index.d.ts.map +1 -1
- package/lib/api/rest/index.js.map +1 -1
- package/lib/api/rest/swaggerUI.js.map +1 -1
- package/lib/bun-wrappers/prometheus-gc-stats.js.map +1 -1
- package/lib/chain/ColumnReconstructionTracker.d.ts.map +1 -1
- package/lib/chain/ColumnReconstructionTracker.js.map +1 -1
- package/lib/chain/GetBlobsTracker.d.ts.map +1 -1
- package/lib/chain/GetBlobsTracker.js.map +1 -1
- package/lib/chain/archiveStore/archiveStore.d.ts +1 -0
- package/lib/chain/archiveStore/archiveStore.d.ts.map +1 -1
- package/lib/chain/archiveStore/archiveStore.js +11 -1
- package/lib/chain/archiveStore/archiveStore.js.map +1 -1
- package/lib/chain/archiveStore/historicalState/getHistoricalState.d.ts +5 -6
- package/lib/chain/archiveStore/historicalState/getHistoricalState.d.ts.map +1 -1
- package/lib/chain/archiveStore/historicalState/getHistoricalState.js +9 -10
- package/lib/chain/archiveStore/historicalState/getHistoricalState.js.map +1 -1
- package/lib/chain/archiveStore/historicalState/historicalStateRegen.d.ts.map +1 -1
- package/lib/chain/archiveStore/historicalState/historicalStateRegen.js.map +1 -1
- package/lib/chain/archiveStore/historicalState/metrics.js.map +1 -1
- package/lib/chain/archiveStore/historicalState/types.js +2 -1
- package/lib/chain/archiveStore/historicalState/types.js.map +1 -1
- package/lib/chain/archiveStore/historicalState/worker.js +3 -3
- package/lib/chain/archiveStore/historicalState/worker.js.map +1 -1
- package/lib/chain/archiveStore/interface.js +2 -1
- package/lib/chain/archiveStore/interface.js.map +1 -1
- package/lib/chain/archiveStore/strategies/frequencyStateArchiveStrategy.d.ts +1 -1
- package/lib/chain/archiveStore/strategies/frequencyStateArchiveStrategy.d.ts.map +1 -1
- package/lib/chain/archiveStore/strategies/frequencyStateArchiveStrategy.js +2 -1
- package/lib/chain/archiveStore/strategies/frequencyStateArchiveStrategy.js.map +1 -1
- package/lib/chain/archiveStore/utils/archiveBlocks.d.ts +3 -8
- package/lib/chain/archiveStore/utils/archiveBlocks.d.ts.map +1 -1
- package/lib/chain/archiveStore/utils/archiveBlocks.js +1 -1
- package/lib/chain/archiveStore/utils/archiveBlocks.js.map +1 -1
- package/lib/chain/archiveStore/utils/archivePayloads.d.ts +7 -0
- package/lib/chain/archiveStore/utils/archivePayloads.d.ts.map +1 -0
- package/lib/chain/archiveStore/utils/archivePayloads.js +10 -0
- package/lib/chain/archiveStore/utils/archivePayloads.js.map +1 -0
- package/lib/chain/archiveStore/utils/pruneHistory.js.map +1 -1
- package/lib/chain/archiveStore/utils/updateBackfillRange.js +1 -1
- package/lib/chain/archiveStore/utils/updateBackfillRange.js.map +1 -1
- package/lib/chain/balancesCache.d.ts.map +1 -1
- package/lib/chain/balancesCache.js.map +1 -1
- package/lib/chain/beaconProposerCache.d.ts.map +1 -1
- package/lib/chain/beaconProposerCache.js.map +1 -1
- package/lib/chain/blocks/blockInput/blockInput.d.ts +25 -2
- package/lib/chain/blocks/blockInput/blockInput.d.ts.map +1 -1
- package/lib/chain/blocks/blockInput/blockInput.js +71 -0
- package/lib/chain/blocks/blockInput/blockInput.js.map +1 -1
- package/lib/chain/blocks/blockInput/errors.js +2 -1
- package/lib/chain/blocks/blockInput/errors.js.map +1 -1
- package/lib/chain/blocks/blockInput/types.d.ts +18 -1
- package/lib/chain/blocks/blockInput/types.d.ts.map +1 -1
- package/lib/chain/blocks/blockInput/types.js +5 -2
- package/lib/chain/blocks/blockInput/types.js.map +1 -1
- package/lib/chain/blocks/blockInput/utils.js.map +1 -1
- package/lib/chain/blocks/importBlock.d.ts.map +1 -1
- package/lib/chain/blocks/importBlock.js +27 -6
- package/lib/chain/blocks/importBlock.js.map +1 -1
- package/lib/chain/blocks/index.d.ts.map +1 -1
- package/lib/chain/blocks/index.js +2 -1
- package/lib/chain/blocks/index.js.map +1 -1
- package/lib/chain/blocks/types.js +6 -3
- package/lib/chain/blocks/types.js.map +1 -1
- package/lib/chain/blocks/utils/chainSegment.js.map +1 -1
- package/lib/chain/blocks/utils/checkpoint.js.map +1 -1
- package/lib/chain/blocks/verifyBlock.js.map +1 -1
- package/lib/chain/blocks/verifyBlocksDataAvailability.d.ts.map +1 -1
- package/lib/chain/blocks/verifyBlocksDataAvailability.js +3 -0
- package/lib/chain/blocks/verifyBlocksDataAvailability.js.map +1 -1
- package/lib/chain/blocks/verifyBlocksExecutionPayloads.d.ts +4 -0
- package/lib/chain/blocks/verifyBlocksExecutionPayloads.d.ts.map +1 -1
- package/lib/chain/blocks/verifyBlocksExecutionPayloads.js +5 -1
- package/lib/chain/blocks/verifyBlocksExecutionPayloads.js.map +1 -1
- package/lib/chain/blocks/verifyBlocksSanityChecks.d.ts.map +1 -1
- package/lib/chain/blocks/verifyBlocksSanityChecks.js +4 -1
- package/lib/chain/blocks/verifyBlocksSanityChecks.js.map +1 -1
- package/lib/chain/blocks/verifyBlocksSignatures.js.map +1 -1
- package/lib/chain/blocks/verifyBlocksStateTransitionOnly.js.map +1 -1
- package/lib/chain/blocks/writeBlockInputToDb.d.ts +12 -3
- package/lib/chain/blocks/writeBlockInputToDb.d.ts.map +1 -1
- package/lib/chain/blocks/writeBlockInputToDb.js +92 -95
- package/lib/chain/blocks/writeBlockInputToDb.js.map +1 -1
- package/lib/chain/bls/maybeBatch.js.map +1 -1
- package/lib/chain/bls/multithread/index.d.ts +3 -3
- package/lib/chain/bls/multithread/index.d.ts.map +1 -1
- package/lib/chain/bls/multithread/index.js +5 -5
- package/lib/chain/bls/multithread/index.js.map +1 -1
- package/lib/chain/bls/multithread/jobItem.d.ts +2 -2
- package/lib/chain/bls/multithread/jobItem.d.ts.map +1 -1
- package/lib/chain/bls/multithread/jobItem.js +4 -3
- package/lib/chain/bls/multithread/jobItem.js.map +1 -1
- package/lib/chain/bls/multithread/types.js +2 -1
- package/lib/chain/bls/multithread/types.js.map +1 -1
- package/lib/chain/bls/multithread/utils.js.map +1 -1
- package/lib/chain/bls/multithread/worker.js.map +1 -1
- package/lib/chain/bls/singleThread.d.ts +4 -4
- package/lib/chain/bls/singleThread.d.ts.map +1 -1
- package/lib/chain/bls/singleThread.js +4 -4
- package/lib/chain/bls/singleThread.js.map +1 -1
- package/lib/chain/bls/utils.d.ts +2 -2
- package/lib/chain/bls/utils.d.ts.map +1 -1
- package/lib/chain/bls/utils.js +7 -4
- package/lib/chain/bls/utils.js.map +1 -1
- package/lib/chain/chain.d.ts +9 -12
- package/lib/chain/chain.d.ts.map +1 -1
- package/lib/chain/chain.js +45 -28
- package/lib/chain/chain.js.map +1 -1
- package/lib/chain/emitter.d.ts +6 -8
- package/lib/chain/emitter.d.ts.map +1 -1
- package/lib/chain/emitter.js +2 -1
- package/lib/chain/emitter.js.map +1 -1
- package/lib/chain/errors/attestationError.d.ts.map +1 -1
- package/lib/chain/errors/attestationError.js +2 -1
- package/lib/chain/errors/attestationError.js.map +1 -1
- package/lib/chain/errors/attesterSlashingError.js +2 -1
- package/lib/chain/errors/attesterSlashingError.js.map +1 -1
- package/lib/chain/errors/blobSidecarError.js +2 -1
- package/lib/chain/errors/blobSidecarError.js.map +1 -1
- package/lib/chain/errors/blockError.d.ts.map +1 -1
- package/lib/chain/errors/blockError.js +2 -1
- package/lib/chain/errors/blockError.js.map +1 -1
- package/lib/chain/errors/blsToExecutionChangeError.js +2 -1
- package/lib/chain/errors/blsToExecutionChangeError.js.map +1 -1
- package/lib/chain/errors/dataColumnSidecarError.js +2 -1
- package/lib/chain/errors/dataColumnSidecarError.js.map +1 -1
- package/lib/chain/errors/executionPayloadBid.d.ts +1 -1
- package/lib/chain/errors/executionPayloadBid.js +2 -1
- package/lib/chain/errors/executionPayloadBid.js.map +1 -1
- package/lib/chain/errors/executionPayloadEnvelope.d.ts +2 -2
- package/lib/chain/errors/executionPayloadEnvelope.d.ts.map +1 -1
- package/lib/chain/errors/executionPayloadEnvelope.js +2 -1
- package/lib/chain/errors/executionPayloadEnvelope.js.map +1 -1
- package/lib/chain/errors/gossipValidation.d.ts.map +1 -1
- package/lib/chain/errors/gossipValidation.js +4 -2
- package/lib/chain/errors/gossipValidation.js.map +1 -1
- package/lib/chain/errors/lightClientError.js +4 -2
- package/lib/chain/errors/lightClientError.js.map +1 -1
- package/lib/chain/errors/payloadAttestation.d.ts +1 -1
- package/lib/chain/errors/payloadAttestation.js +2 -1
- package/lib/chain/errors/payloadAttestation.js.map +1 -1
- package/lib/chain/errors/proposerSlashingError.js +2 -1
- package/lib/chain/errors/proposerSlashingError.js.map +1 -1
- package/lib/chain/errors/syncCommitteeError.js +2 -1
- package/lib/chain/errors/syncCommitteeError.js.map +1 -1
- package/lib/chain/errors/voluntaryExitError.js +2 -1
- package/lib/chain/errors/voluntaryExitError.js.map +1 -1
- package/lib/chain/forkChoice/index.d.ts.map +1 -1
- package/lib/chain/forkChoice/index.js +32 -25
- package/lib/chain/forkChoice/index.js.map +1 -1
- package/lib/chain/initState.d.ts +1 -1
- package/lib/chain/initState.d.ts.map +1 -1
- package/lib/chain/initState.js.map +1 -1
- package/lib/chain/interface.d.ts +4 -6
- package/lib/chain/interface.d.ts.map +1 -1
- package/lib/chain/interface.js +2 -1
- package/lib/chain/interface.js.map +1 -1
- package/lib/chain/lightClient/index.d.ts +0 -29
- package/lib/chain/lightClient/index.d.ts.map +1 -1
- package/lib/chain/lightClient/index.js +1 -1
- package/lib/chain/lightClient/index.js.map +1 -1
- package/lib/chain/lightClient/proofs.js.map +1 -1
- package/lib/chain/opPools/aggregatedAttestationPool.d.ts.map +1 -1
- package/lib/chain/opPools/aggregatedAttestationPool.js +5 -3
- package/lib/chain/opPools/aggregatedAttestationPool.js.map +1 -1
- package/lib/chain/opPools/attestationPool.d.ts.map +1 -1
- package/lib/chain/opPools/attestationPool.js.map +1 -1
- package/lib/chain/opPools/executionPayloadBidPool.d.ts.map +1 -1
- package/lib/chain/opPools/executionPayloadBidPool.js.map +1 -1
- package/lib/chain/opPools/opPool.d.ts.map +1 -1
- package/lib/chain/opPools/opPool.js.map +1 -1
- package/lib/chain/opPools/payloadAttestationPool.d.ts.map +1 -1
- package/lib/chain/opPools/payloadAttestationPool.js.map +1 -1
- package/lib/chain/opPools/syncCommitteeMessagePool.d.ts.map +1 -1
- package/lib/chain/opPools/syncCommitteeMessagePool.js.map +1 -1
- package/lib/chain/opPools/syncContributionAndProofPool.d.ts.map +1 -1
- package/lib/chain/opPools/syncContributionAndProofPool.js.map +1 -1
- package/lib/chain/opPools/types.js +4 -2
- package/lib/chain/opPools/types.js.map +1 -1
- package/lib/chain/opPools/utils.js.map +1 -1
- package/lib/chain/options.d.ts.map +1 -1
- package/lib/chain/options.js.map +1 -1
- package/lib/chain/prepareNextSlot.d.ts +1 -2
- package/lib/chain/prepareNextSlot.d.ts.map +1 -1
- package/lib/chain/prepareNextSlot.js +3 -3
- package/lib/chain/prepareNextSlot.js.map +1 -1
- package/lib/chain/produceBlock/computeNewStateRoot.d.ts +9 -2
- package/lib/chain/produceBlock/computeNewStateRoot.d.ts.map +1 -1
- package/lib/chain/produceBlock/computeNewStateRoot.js +25 -2
- package/lib/chain/produceBlock/computeNewStateRoot.js.map +1 -1
- package/lib/chain/produceBlock/produceBlockBody.d.ts +23 -8
- package/lib/chain/produceBlock/produceBlockBody.d.ts.map +1 -1
- package/lib/chain/produceBlock/produceBlockBody.js +115 -13
- package/lib/chain/produceBlock/produceBlockBody.js.map +1 -1
- package/lib/chain/produceBlock/validateBlobsAndKzgCommitments.js.map +1 -1
- package/lib/chain/regen/errors.d.ts.map +1 -1
- package/lib/chain/regen/errors.js +2 -1
- package/lib/chain/regen/errors.js.map +1 -1
- package/lib/chain/regen/interface.js +4 -2
- package/lib/chain/regen/interface.js.map +1 -1
- package/lib/chain/regen/queued.d.ts.map +1 -1
- package/lib/chain/regen/queued.js +4 -1
- package/lib/chain/regen/queued.js.map +1 -1
- package/lib/chain/regen/regen.d.ts.map +1 -1
- package/lib/chain/regen/regen.js +6 -2
- package/lib/chain/regen/regen.js.map +1 -1
- package/lib/chain/reprocess.d.ts.map +1 -1
- package/lib/chain/reprocess.js +2 -1
- package/lib/chain/reprocess.js.map +1 -1
- package/lib/chain/seenCache/seenAggregateAndProof.d.ts.map +1 -1
- package/lib/chain/seenCache/seenAggregateAndProof.js.map +1 -1
- package/lib/chain/seenCache/seenAttestationData.d.ts.map +1 -1
- package/lib/chain/seenCache/seenAttestationData.js +2 -1
- package/lib/chain/seenCache/seenAttestationData.js.map +1 -1
- package/lib/chain/seenCache/seenAttesters.d.ts.map +1 -1
- package/lib/chain/seenCache/seenAttesters.js.map +1 -1
- package/lib/chain/seenCache/seenBlockAttesters.d.ts.map +1 -1
- package/lib/chain/seenCache/seenBlockAttesters.js.map +1 -1
- package/lib/chain/seenCache/seenBlockProposers.d.ts.map +1 -1
- package/lib/chain/seenCache/seenBlockProposers.js.map +1 -1
- package/lib/chain/seenCache/seenCommittee.d.ts.map +1 -1
- package/lib/chain/seenCache/seenCommittee.js.map +1 -1
- package/lib/chain/seenCache/seenCommitteeContribution.d.ts.map +1 -1
- package/lib/chain/seenCache/seenCommitteeContribution.js.map +1 -1
- package/lib/chain/seenCache/seenExecutionPayloadBids.d.ts.map +1 -1
- package/lib/chain/seenCache/seenExecutionPayloadBids.js.map +1 -1
- package/lib/chain/seenCache/seenExecutionPayloadEnvelope.d.ts.map +1 -1
- package/lib/chain/seenCache/seenExecutionPayloadEnvelope.js.map +1 -1
- package/lib/chain/seenCache/seenGossipBlockInput.d.ts +7 -3
- package/lib/chain/seenCache/seenGossipBlockInput.d.ts.map +1 -1
- package/lib/chain/seenCache/seenGossipBlockInput.js +38 -16
- package/lib/chain/seenCache/seenGossipBlockInput.js.map +1 -1
- package/lib/chain/serializeState.js +1 -0
- package/lib/chain/serializeState.js.map +1 -1
- package/lib/chain/shufflingCache.d.ts.map +1 -1
- package/lib/chain/shufflingCache.js +2 -1
- package/lib/chain/shufflingCache.js.map +1 -1
- package/lib/chain/stateCache/datastore/db.d.ts.map +1 -1
- package/lib/chain/stateCache/datastore/db.js.map +1 -1
- package/lib/chain/stateCache/datastore/file.d.ts.map +1 -1
- package/lib/chain/stateCache/datastore/file.js.map +1 -1
- package/lib/chain/stateCache/fifoBlockStateCache.d.ts.map +1 -1
- package/lib/chain/stateCache/fifoBlockStateCache.js.map +1 -1
- package/lib/chain/stateCache/mapMetrics.d.ts.map +1 -1
- package/lib/chain/stateCache/mapMetrics.js.map +1 -1
- package/lib/chain/stateCache/persistentCheckpointsCache.d.ts +1 -41
- package/lib/chain/stateCache/persistentCheckpointsCache.d.ts.map +1 -1
- package/lib/chain/stateCache/persistentCheckpointsCache.js.map +1 -1
- package/lib/chain/stateCache/types.js +2 -1
- package/lib/chain/stateCache/types.js.map +1 -1
- package/lib/chain/validation/aggregateAndProof.js +1 -1
- package/lib/chain/validation/aggregateAndProof.js.map +1 -1
- package/lib/chain/validation/attestation.d.ts.map +1 -1
- package/lib/chain/validation/attestation.js +14 -7
- package/lib/chain/validation/attestation.js.map +1 -1
- package/lib/chain/validation/attesterSlashing.d.ts.map +1 -1
- package/lib/chain/validation/attesterSlashing.js +9 -2
- package/lib/chain/validation/attesterSlashing.js.map +1 -1
- package/lib/chain/validation/blobSidecar.js +2 -2
- package/lib/chain/validation/blobSidecar.js.map +1 -1
- package/lib/chain/validation/block.d.ts.map +1 -1
- package/lib/chain/validation/block.js +6 -3
- package/lib/chain/validation/block.js.map +1 -1
- package/lib/chain/validation/blsToExecutionChange.js.map +1 -1
- package/lib/chain/validation/dataColumnSidecar.d.ts +2 -2
- package/lib/chain/validation/dataColumnSidecar.d.ts.map +1 -1
- package/lib/chain/validation/dataColumnSidecar.js +1 -1
- package/lib/chain/validation/dataColumnSidecar.js.map +1 -1
- package/lib/chain/validation/executionPayloadBid.js +1 -2
- package/lib/chain/validation/executionPayloadBid.js.map +1 -1
- package/lib/chain/validation/executionPayloadEnvelope.js +4 -4
- package/lib/chain/validation/executionPayloadEnvelope.js.map +1 -1
- package/lib/chain/validation/lightClientFinalityUpdate.js.map +1 -1
- package/lib/chain/validation/lightClientOptimisticUpdate.js.map +1 -1
- package/lib/chain/validation/payloadAttestationMessage.js +9 -3
- package/lib/chain/validation/payloadAttestationMessage.js.map +1 -1
- package/lib/chain/validation/proposerSlashing.js +1 -1
- package/lib/chain/validation/proposerSlashing.js.map +1 -1
- package/lib/chain/validation/signatureSets/aggregateAndProof.js.map +1 -1
- package/lib/chain/validation/signatureSets/contributionAndProof.js.map +1 -1
- package/lib/chain/validation/signatureSets/selectionProof.js.map +1 -1
- package/lib/chain/validation/signatureSets/syncCommittee.js.map +1 -1
- package/lib/chain/validation/signatureSets/syncCommitteeContribution.js.map +1 -1
- package/lib/chain/validation/signatureSets/syncCommitteeSelectionProof.js.map +1 -1
- package/lib/chain/validation/syncCommittee.js.map +1 -1
- package/lib/chain/validation/syncCommitteeContributionAndProof.js +1 -1
- package/lib/chain/validation/syncCommitteeContributionAndProof.js.map +1 -1
- package/lib/chain/validation/voluntaryExit.js.map +1 -1
- package/lib/chain/validatorMonitor.d.ts.map +1 -1
- package/lib/chain/validatorMonitor.js +2 -1
- package/lib/chain/validatorMonitor.js.map +1 -1
- package/lib/constants/network.js +4 -2
- package/lib/constants/network.js.map +1 -1
- package/lib/db/beacon.d.ts +3 -1
- package/lib/db/beacon.d.ts.map +1 -1
- package/lib/db/beacon.js +5 -1
- package/lib/db/beacon.js.map +1 -1
- package/lib/db/buckets.d.ts +24 -22
- package/lib/db/buckets.d.ts.map +1 -1
- package/lib/db/buckets.js +4 -1
- package/lib/db/buckets.js.map +1 -1
- package/lib/db/index.d.ts +1 -0
- package/lib/db/index.d.ts.map +1 -1
- package/lib/db/index.js +1 -0
- package/lib/db/index.js.map +1 -1
- package/lib/db/interface.d.ts +3 -1
- package/lib/db/interface.d.ts.map +1 -1
- package/lib/db/repositories/attesterSlashing.d.ts.map +1 -1
- package/lib/db/repositories/attesterSlashing.js.map +1 -1
- package/lib/db/repositories/backfilledRanges.d.ts.map +1 -1
- package/lib/db/repositories/backfilledRanges.js.map +1 -1
- package/lib/db/repositories/blobSidecars.d.ts.map +1 -1
- package/lib/db/repositories/blobSidecars.js.map +1 -1
- package/lib/db/repositories/blobSidecarsArchive.d.ts.map +1 -1
- package/lib/db/repositories/blobSidecarsArchive.js.map +1 -1
- package/lib/db/repositories/block.d.ts.map +1 -1
- package/lib/db/repositories/block.js.map +1 -1
- package/lib/db/repositories/blockArchive.d.ts.map +1 -1
- package/lib/db/repositories/blockArchive.js +1 -2
- package/lib/db/repositories/blockArchive.js.map +1 -1
- package/lib/db/repositories/blockArchiveIndex.d.ts +2 -2
- package/lib/db/repositories/blockArchiveIndex.d.ts.map +1 -1
- package/lib/db/repositories/blockArchiveIndex.js.map +1 -1
- package/lib/db/repositories/blsToExecutionChange.d.ts.map +1 -1
- package/lib/db/repositories/blsToExecutionChange.js.map +1 -1
- package/lib/db/repositories/checkpointState.d.ts.map +1 -1
- package/lib/db/repositories/checkpointState.js.map +1 -1
- package/lib/db/repositories/dataColumnSidecar.d.ts +5 -3
- package/lib/db/repositories/dataColumnSidecar.d.ts.map +1 -1
- package/lib/db/repositories/dataColumnSidecar.js +14 -1
- package/lib/db/repositories/dataColumnSidecar.js.map +1 -1
- package/lib/db/repositories/dataColumnSidecarArchive.d.ts +5 -3
- package/lib/db/repositories/dataColumnSidecarArchive.d.ts.map +1 -1
- package/lib/db/repositories/dataColumnSidecarArchive.js +14 -1
- package/lib/db/repositories/dataColumnSidecarArchive.js.map +1 -1
- package/lib/db/repositories/executionPayloadEnvelope.d.ts +19 -0
- package/lib/db/repositories/executionPayloadEnvelope.d.ts.map +1 -0
- package/lib/db/repositories/executionPayloadEnvelope.js +22 -0
- package/lib/db/repositories/executionPayloadEnvelope.js.map +1 -0
- package/lib/db/repositories/executionPayloadEnvelopeArchive.d.ts +18 -0
- package/lib/db/repositories/executionPayloadEnvelopeArchive.d.ts.map +1 -0
- package/lib/db/repositories/executionPayloadEnvelopeArchive.js +28 -0
- package/lib/db/repositories/executionPayloadEnvelopeArchive.js.map +1 -0
- package/lib/db/repositories/index.d.ts +2 -0
- package/lib/db/repositories/index.d.ts.map +1 -1
- package/lib/db/repositories/index.js +2 -0
- package/lib/db/repositories/index.js.map +1 -1
- package/lib/db/repositories/lightclientBestUpdate.d.ts.map +1 -1
- package/lib/db/repositories/lightclientBestUpdate.js.map +1 -1
- package/lib/db/repositories/lightclientCheckpointHeader.d.ts.map +1 -1
- package/lib/db/repositories/lightclientCheckpointHeader.js.map +1 -1
- package/lib/db/repositories/lightclientSyncCommittee.d.ts.map +1 -1
- package/lib/db/repositories/lightclientSyncCommittee.js.map +1 -1
- package/lib/db/repositories/lightclientSyncCommitteeWitness.d.ts.map +1 -1
- package/lib/db/repositories/lightclientSyncCommitteeWitness.js.map +1 -1
- package/lib/db/repositories/proposerSlashing.d.ts.map +1 -1
- package/lib/db/repositories/proposerSlashing.js.map +1 -1
- package/lib/db/repositories/stateArchive.d.ts.map +1 -1
- package/lib/db/repositories/stateArchive.js.map +1 -1
- package/lib/db/repositories/stateArchiveIndex.js.map +1 -1
- package/lib/db/repositories/voluntaryExit.d.ts.map +1 -1
- package/lib/db/repositories/voluntaryExit.js.map +1 -1
- package/lib/execution/builder/cache.d.ts.map +1 -1
- package/lib/execution/builder/cache.js.map +1 -1
- package/lib/execution/builder/http.d.ts.map +1 -1
- package/lib/execution/builder/http.js +2 -1
- package/lib/execution/builder/http.js.map +1 -1
- package/lib/execution/builder/index.js.map +1 -1
- package/lib/execution/builder/utils.js.map +1 -1
- package/lib/execution/engine/disabled.d.ts.map +1 -1
- package/lib/execution/engine/disabled.js.map +1 -1
- package/lib/execution/engine/http.d.ts +1 -0
- package/lib/execution/engine/http.d.ts.map +1 -1
- package/lib/execution/engine/http.js +3 -0
- package/lib/execution/engine/http.js.map +1 -1
- package/lib/execution/engine/index.js.map +1 -1
- package/lib/execution/engine/interface.js +4 -2
- package/lib/execution/engine/interface.js.map +1 -1
- package/lib/execution/engine/jsonRpcHttpClient.d.ts +10 -15
- package/lib/execution/engine/jsonRpcHttpClient.d.ts.map +1 -1
- package/lib/execution/engine/jsonRpcHttpClient.js +2 -1
- package/lib/execution/engine/jsonRpcHttpClient.js.map +1 -1
- package/lib/execution/engine/jwt.js.map +1 -1
- package/lib/execution/engine/mock.d.ts.map +1 -1
- package/lib/execution/engine/mock.js.map +1 -1
- package/lib/execution/engine/payloadIdCache.d.ts.map +1 -1
- package/lib/execution/engine/payloadIdCache.js.map +1 -1
- package/lib/execution/engine/types.js.map +1 -1
- package/lib/execution/engine/utils.d.ts +1 -1
- package/lib/execution/engine/utils.d.ts.map +1 -1
- package/lib/execution/engine/utils.js.map +1 -1
- package/lib/metrics/metrics/beacon.d.ts +1 -0
- package/lib/metrics/metrics/beacon.d.ts.map +1 -1
- package/lib/metrics/metrics/beacon.js +5 -0
- package/lib/metrics/metrics/beacon.js.map +1 -1
- package/lib/metrics/metrics/lodestar.d.ts +16 -6
- package/lib/metrics/metrics/lodestar.d.ts.map +1 -1
- package/lib/metrics/metrics/lodestar.js +32 -10
- package/lib/metrics/metrics/lodestar.js.map +1 -1
- package/lib/metrics/metrics.d.ts.map +1 -1
- package/lib/metrics/metrics.js +8 -3
- package/lib/metrics/metrics.js.map +1 -1
- package/lib/metrics/nodeJsMetrics.js.map +1 -1
- package/lib/metrics/server/http.d.ts +1 -1
- package/lib/metrics/server/http.d.ts.map +1 -1
- package/lib/metrics/server/http.js.map +1 -1
- package/lib/metrics/utils/avgMinMax.d.ts.map +1 -1
- package/lib/metrics/utils/avgMinMax.js.map +1 -1
- package/lib/metrics/utils/gauge.d.ts.map +1 -1
- package/lib/metrics/utils/gauge.js.map +1 -1
- package/lib/metrics/utils/registryMetricCreator.d.ts.map +1 -1
- package/lib/metrics/utils/registryMetricCreator.js.map +1 -1
- package/lib/monitoring/clientStats.js.map +1 -1
- package/lib/monitoring/properties.d.ts.map +1 -1
- package/lib/monitoring/properties.js.map +1 -1
- package/lib/monitoring/service.d.ts +2 -2
- package/lib/monitoring/service.d.ts.map +1 -1
- package/lib/monitoring/service.js +3 -2
- package/lib/monitoring/service.js.map +1 -1
- package/lib/monitoring/system.d.ts.map +1 -1
- package/lib/monitoring/system.js.map +1 -1
- package/lib/monitoring/types.js +4 -2
- package/lib/monitoring/types.js.map +1 -1
- package/lib/network/core/events.d.ts +1 -3
- package/lib/network/core/events.d.ts.map +1 -1
- package/lib/network/core/events.js +4 -2
- package/lib/network/core/events.js.map +1 -1
- package/lib/network/core/metrics.d.ts +6 -7
- package/lib/network/core/metrics.d.ts.map +1 -1
- package/lib/network/core/metrics.js.map +1 -1
- package/lib/network/core/networkCore.d.ts +4 -4
- package/lib/network/core/networkCore.d.ts.map +1 -1
- package/lib/network/core/networkCore.js.map +1 -1
- package/lib/network/core/networkCoreWorker.js.map +1 -1
- package/lib/network/core/networkCoreWorkerHandler.d.ts +3 -3
- package/lib/network/core/networkCoreWorkerHandler.d.ts.map +1 -1
- package/lib/network/core/networkCoreWorkerHandler.js.map +1 -1
- package/lib/network/core/types.d.ts +2 -2
- package/lib/network/core/types.d.ts.map +1 -1
- package/lib/network/discv5/index.d.ts +1 -3
- package/lib/network/discv5/index.d.ts.map +1 -1
- package/lib/network/discv5/index.js.map +1 -1
- package/lib/network/discv5/utils.js +2 -1
- package/lib/network/discv5/utils.js.map +1 -1
- package/lib/network/discv5/worker.js.map +1 -1
- package/lib/network/events.d.ts +3 -4
- package/lib/network/events.d.ts.map +1 -1
- package/lib/network/events.js +4 -2
- package/lib/network/events.js.map +1 -1
- package/lib/network/forks.js.map +1 -1
- package/lib/network/gossip/encoding.d.ts +3 -3
- package/lib/network/gossip/encoding.d.ts.map +1 -1
- package/lib/network/gossip/encoding.js.map +1 -1
- package/lib/network/gossip/errors.d.ts.map +1 -1
- package/lib/network/gossip/errors.js.map +1 -1
- package/lib/network/gossip/gossipsub.d.ts +13 -4
- package/lib/network/gossip/gossipsub.d.ts.map +1 -1
- package/lib/network/gossip/gossipsub.js +47 -20
- package/lib/network/gossip/gossipsub.js.map +1 -1
- package/lib/network/gossip/interface.d.ts +6 -6
- package/lib/network/gossip/interface.d.ts.map +1 -1
- package/lib/network/gossip/interface.js +4 -2
- package/lib/network/gossip/interface.js.map +1 -1
- package/lib/network/gossip/metrics.d.ts +12 -14
- package/lib/network/gossip/metrics.d.ts.map +1 -1
- package/lib/network/gossip/metrics.js.map +1 -1
- package/lib/network/gossip/scoringParameters.d.ts +2 -2
- package/lib/network/gossip/scoringParameters.d.ts.map +1 -1
- package/lib/network/gossip/scoringParameters.js +1 -1
- package/lib/network/gossip/scoringParameters.js.map +1 -1
- package/lib/network/gossip/topic.d.ts +3166 -3169
- package/lib/network/gossip/topic.d.ts.map +1 -1
- package/lib/network/gossip/topic.js +2 -2
- package/lib/network/gossip/topic.js.map +1 -1
- package/lib/network/interface.d.ts +6 -5
- package/lib/network/interface.d.ts.map +1 -1
- package/lib/network/libp2p/error.js +2 -1
- package/lib/network/libp2p/error.js.map +1 -1
- package/lib/network/libp2p/index.d.ts +1 -1
- package/lib/network/libp2p/index.d.ts.map +1 -1
- package/lib/network/libp2p/index.js +7 -2
- package/lib/network/libp2p/index.js.map +1 -1
- package/lib/network/metadata.d.ts.map +1 -1
- package/lib/network/metadata.js +4 -2
- package/lib/network/metadata.js.map +1 -1
- package/lib/network/network.d.ts +6 -5
- package/lib/network/network.d.ts.map +1 -1
- package/lib/network/network.js +11 -2
- package/lib/network/network.js.map +1 -1
- package/lib/network/options.d.ts.map +1 -1
- package/lib/network/options.js +3 -0
- package/lib/network/options.js.map +1 -1
- package/lib/network/peers/client.js +2 -1
- package/lib/network/peers/client.js.map +1 -1
- package/lib/network/peers/datastore.d.ts +7 -8
- package/lib/network/peers/datastore.d.ts.map +1 -1
- package/lib/network/peers/datastore.js +10 -10
- package/lib/network/peers/datastore.js.map +1 -1
- package/lib/network/peers/discover.d.ts +0 -7
- package/lib/network/peers/discover.d.ts.map +1 -1
- package/lib/network/peers/discover.js +4 -2
- package/lib/network/peers/discover.js.map +1 -1
- package/lib/network/peers/peerManager.d.ts +3 -1
- package/lib/network/peers/peerManager.d.ts.map +1 -1
- package/lib/network/peers/peerManager.js +103 -53
- package/lib/network/peers/peerManager.js.map +1 -1
- package/lib/network/peers/peersData.d.ts.map +1 -1
- package/lib/network/peers/peersData.js +2 -1
- package/lib/network/peers/peersData.js.map +1 -1
- package/lib/network/peers/score/interface.js +4 -2
- package/lib/network/peers/score/interface.js.map +1 -1
- package/lib/network/peers/score/score.d.ts.map +1 -1
- package/lib/network/peers/score/score.js.map +1 -1
- package/lib/network/peers/score/store.d.ts.map +1 -1
- package/lib/network/peers/score/store.js.map +1 -1
- package/lib/network/peers/score/utils.js.map +1 -1
- package/lib/network/peers/utils/assertPeerRelevance.js +2 -1
- package/lib/network/peers/utils/assertPeerRelevance.js.map +1 -1
- package/lib/network/peers/utils/enrSubnetsDeserialize.js.map +1 -1
- package/lib/network/peers/utils/getConnectedPeerIds.js.map +1 -1
- package/lib/network/peers/utils/prioritizePeers.d.ts +3 -3
- package/lib/network/peers/utils/prioritizePeers.d.ts.map +1 -1
- package/lib/network/peers/utils/prioritizePeers.js +2 -1
- package/lib/network/peers/utils/prioritizePeers.js.map +1 -1
- package/lib/network/peers/utils/subnetMap.d.ts.map +1 -1
- package/lib/network/peers/utils/subnetMap.js.map +1 -1
- package/lib/network/processor/aggregatorTracker.d.ts.map +1 -1
- package/lib/network/processor/aggregatorTracker.js.map +1 -1
- package/lib/network/processor/extractSlotRootFns.js.map +1 -1
- package/lib/network/processor/gossipHandlers.d.ts.map +1 -1
- package/lib/network/processor/gossipHandlers.js +9 -2
- package/lib/network/processor/gossipHandlers.js.map +1 -1
- package/lib/network/processor/gossipQueues/index.js.map +1 -1
- package/lib/network/processor/gossipQueues/indexed.d.ts.map +1 -1
- package/lib/network/processor/gossipQueues/indexed.js.map +1 -1
- package/lib/network/processor/gossipQueues/linear.d.ts.map +1 -1
- package/lib/network/processor/gossipQueues/linear.js.map +1 -1
- package/lib/network/processor/gossipQueues/types.js +4 -2
- package/lib/network/processor/gossipQueues/types.js.map +1 -1
- package/lib/network/processor/gossipValidatorFn.js +1 -1
- package/lib/network/processor/gossipValidatorFn.js.map +1 -1
- package/lib/network/processor/index.d.ts.map +1 -1
- package/lib/network/processor/index.js +4 -2
- package/lib/network/processor/index.js.map +1 -1
- package/lib/network/processor/types.d.ts +1 -1
- package/lib/network/processor/types.d.ts.map +1 -1
- package/lib/network/reqresp/ReqRespBeaconNode.d.ts.map +1 -1
- package/lib/network/reqresp/ReqRespBeaconNode.js.map +1 -1
- package/lib/network/reqresp/handlers/beaconBlocksByRange.d.ts.map +1 -1
- package/lib/network/reqresp/handlers/beaconBlocksByRange.js +3 -2
- package/lib/network/reqresp/handlers/beaconBlocksByRange.js.map +1 -1
- package/lib/network/reqresp/handlers/beaconBlocksByRoot.js.map +1 -1
- package/lib/network/reqresp/handlers/blobSidecarsByRange.d.ts.map +1 -1
- package/lib/network/reqresp/handlers/blobSidecarsByRange.js +3 -2
- package/lib/network/reqresp/handlers/blobSidecarsByRange.js.map +1 -1
- package/lib/network/reqresp/handlers/blobSidecarsByRoot.js +1 -1
- package/lib/network/reqresp/handlers/blobSidecarsByRoot.js.map +1 -1
- package/lib/network/reqresp/handlers/dataColumnSidecarsByRange.d.ts.map +1 -1
- package/lib/network/reqresp/handlers/dataColumnSidecarsByRange.js +3 -2
- package/lib/network/reqresp/handlers/dataColumnSidecarsByRange.js.map +1 -1
- package/lib/network/reqresp/handlers/dataColumnSidecarsByRoot.js +1 -1
- package/lib/network/reqresp/handlers/dataColumnSidecarsByRoot.js.map +1 -1
- package/lib/network/reqresp/handlers/index.js.map +1 -1
- package/lib/network/reqresp/handlers/lightClientBootstrap.js.map +1 -1
- package/lib/network/reqresp/handlers/lightClientFinalityUpdate.js.map +1 -1
- package/lib/network/reqresp/handlers/lightClientOptimisticUpdate.js.map +1 -1
- package/lib/network/reqresp/handlers/lightClientUpdatesByRange.d.ts.map +1 -1
- package/lib/network/reqresp/handlers/lightClientUpdatesByRange.js +7 -1
- package/lib/network/reqresp/handlers/lightClientUpdatesByRange.js.map +1 -1
- package/lib/network/reqresp/interface.js +2 -1
- package/lib/network/reqresp/interface.js.map +1 -1
- package/lib/network/reqresp/protocols.d.ts.map +1 -1
- package/lib/network/reqresp/protocols.js.map +1 -1
- package/lib/network/reqresp/rateLimit.js.map +1 -1
- package/lib/network/reqresp/score.d.ts.map +1 -1
- package/lib/network/reqresp/score.js +0 -1
- package/lib/network/reqresp/score.js.map +1 -1
- package/lib/network/reqresp/types.js +4 -2
- package/lib/network/reqresp/types.js.map +1 -1
- package/lib/network/reqresp/utils/collect.d.ts +1 -1
- package/lib/network/reqresp/utils/collect.js.map +1 -1
- package/lib/network/reqresp/utils/collectSequentialBlocksInRange.d.ts +1 -1
- package/lib/network/reqresp/utils/collectSequentialBlocksInRange.js +2 -1
- package/lib/network/reqresp/utils/collectSequentialBlocksInRange.js.map +1 -1
- package/lib/network/reqresp/utils/dataColumnResponseValidation.d.ts +1 -1
- package/lib/network/reqresp/utils/dataColumnResponseValidation.d.ts.map +1 -1
- package/lib/network/reqresp/utils/dataColumnResponseValidation.js.map +1 -1
- package/lib/network/statusCache.d.ts.map +1 -1
- package/lib/network/statusCache.js.map +1 -1
- package/lib/network/subnets/attnetsService.d.ts.map +1 -1
- package/lib/network/subnets/attnetsService.js +2 -1
- package/lib/network/subnets/attnetsService.js.map +1 -1
- package/lib/network/subnets/interface.js.map +1 -1
- package/lib/network/subnets/syncnetsService.d.ts.map +1 -1
- package/lib/network/subnets/syncnetsService.js.map +1 -1
- package/lib/network/subnets/util.js.map +1 -1
- package/lib/network/util.js +2 -2
- package/lib/network/util.js.map +1 -1
- package/lib/node/nodejs.d.ts +4 -6
- package/lib/node/nodejs.d.ts.map +1 -1
- package/lib/node/nodejs.js +8 -5
- package/lib/node/nodejs.js.map +1 -1
- package/lib/node/notifier.js.map +1 -1
- package/lib/node/utils/interop/deposits.js.map +1 -1
- package/lib/node/utils/interop/state.d.ts +1 -1
- package/lib/node/utils/interop/state.d.ts.map +1 -1
- package/lib/node/utils/interop/state.js.map +1 -1
- package/lib/node/utils/lightclient.js.map +1 -1
- package/lib/node/utils/state.js.map +1 -1
- package/lib/sync/backfill/backfill.d.ts +1 -10
- package/lib/sync/backfill/backfill.d.ts.map +1 -1
- package/lib/sync/backfill/backfill.js +6 -3
- package/lib/sync/backfill/backfill.js.map +1 -1
- package/lib/sync/backfill/errors.js +2 -1
- package/lib/sync/backfill/errors.js.map +1 -1
- package/lib/sync/backfill/verify.js.map +1 -1
- package/lib/sync/interface.js +2 -1
- package/lib/sync/interface.js.map +1 -1
- package/lib/sync/range/batch.d.ts.map +1 -1
- package/lib/sync/range/batch.js +4 -2
- package/lib/sync/range/batch.js.map +1 -1
- package/lib/sync/range/chain.d.ts +0 -10
- package/lib/sync/range/chain.d.ts.map +1 -1
- package/lib/sync/range/chain.js +2 -1
- package/lib/sync/range/chain.js.map +1 -1
- package/lib/sync/range/range.d.ts +1 -3
- package/lib/sync/range/range.d.ts.map +1 -1
- package/lib/sync/range/range.js +4 -2
- package/lib/sync/range/range.js.map +1 -1
- package/lib/sync/range/utils/batches.js.map +1 -1
- package/lib/sync/range/utils/chainTarget.js.map +1 -1
- package/lib/sync/range/utils/hashBlocks.js.map +1 -1
- package/lib/sync/range/utils/peerBalancer.d.ts.map +1 -1
- package/lib/sync/range/utils/peerBalancer.js.map +1 -1
- package/lib/sync/range/utils/updateChains.js.map +1 -1
- package/lib/sync/sync.d.ts.map +1 -1
- package/lib/sync/sync.js.map +1 -1
- package/lib/sync/types.js +4 -2
- package/lib/sync/types.js.map +1 -1
- package/lib/sync/unknownBlock.d.ts +0 -14
- package/lib/sync/unknownBlock.d.ts.map +1 -1
- package/lib/sync/unknownBlock.js.map +1 -1
- package/lib/sync/utils/downloadByRange.d.ts +4 -4
- package/lib/sync/utils/downloadByRange.d.ts.map +1 -1
- package/lib/sync/utils/downloadByRange.js +2 -1
- package/lib/sync/utils/downloadByRange.js.map +1 -1
- package/lib/sync/utils/downloadByRoot.d.ts +8 -8
- package/lib/sync/utils/downloadByRoot.d.ts.map +1 -1
- package/lib/sync/utils/downloadByRoot.js +2 -1
- package/lib/sync/utils/downloadByRoot.js.map +1 -1
- package/lib/sync/utils/pendingBlocksTree.js.map +1 -1
- package/lib/sync/utils/remoteSyncType.d.ts +1 -1
- package/lib/sync/utils/remoteSyncType.d.ts.map +1 -1
- package/lib/sync/utils/remoteSyncType.js +4 -2
- package/lib/sync/utils/remoteSyncType.js.map +1 -1
- package/lib/util/address.js.map +1 -1
- package/lib/util/array.d.ts.map +1 -1
- package/lib/util/array.js.map +1 -1
- package/lib/util/asyncIterableToEvents.d.ts.map +1 -1
- package/lib/util/asyncIterableToEvents.js +2 -1
- package/lib/util/asyncIterableToEvents.js.map +1 -1
- package/lib/util/binarySearch.d.ts.map +1 -1
- package/lib/util/binarySearch.js.map +1 -1
- package/lib/util/bitArray.js +2 -1
- package/lib/util/bitArray.js.map +1 -1
- package/lib/util/blobs.d.ts +2 -2
- package/lib/util/blobs.d.ts.map +1 -1
- package/lib/util/blobs.js.map +1 -1
- package/lib/util/bufferPool.d.ts.map +1 -1
- package/lib/util/bufferPool.js +2 -1
- package/lib/util/bufferPool.js.map +1 -1
- package/lib/util/chunkify.js.map +1 -1
- package/lib/util/clock.d.ts +6 -0
- package/lib/util/clock.d.ts.map +1 -1
- package/lib/util/clock.js +11 -4
- package/lib/util/clock.js.map +1 -1
- package/lib/util/dataColumns.d.ts +11 -3
- package/lib/util/dataColumns.d.ts.map +1 -1
- package/lib/util/dataColumns.js +31 -2
- package/lib/util/dataColumns.js.map +1 -1
- package/lib/util/dependentRoot.js.map +1 -1
- package/lib/util/enum.js.map +1 -1
- package/lib/util/error.js.map +1 -1
- package/lib/util/eventLoop.js.map +1 -1
- package/lib/util/execution.js +2 -1
- package/lib/util/execution.js.map +1 -1
- package/lib/util/file.js.map +1 -1
- package/lib/util/forkChoice.js.map +1 -1
- package/lib/util/forkName.js.map +1 -1
- package/lib/util/graffiti.js.map +1 -1
- package/lib/util/hex.js.map +1 -1
- package/lib/util/ip.js.map +1 -1
- package/lib/util/itTrigger.d.ts.map +1 -1
- package/lib/util/itTrigger.js.map +1 -1
- package/lib/util/map.d.ts.map +1 -1
- package/lib/util/map.js.map +1 -1
- package/lib/util/metadata.js.map +1 -1
- package/lib/util/multifork.d.ts +8 -0
- package/lib/util/multifork.d.ts.map +1 -1
- package/lib/util/multifork.js +37 -0
- package/lib/util/multifork.js.map +1 -1
- package/lib/util/numpy.js.map +1 -1
- package/lib/util/peerId.js.map +1 -1
- package/lib/util/profile.js +2 -1
- package/lib/util/profile.js.map +1 -1
- package/lib/util/promises.js.map +1 -1
- package/lib/util/queue/errors.js +2 -1
- package/lib/util/queue/errors.js.map +1 -1
- package/lib/util/queue/fnQueue.d.ts.map +1 -1
- package/lib/util/queue/fnQueue.js.map +1 -1
- package/lib/util/queue/itemQueue.d.ts.map +1 -1
- package/lib/util/queue/itemQueue.js.map +1 -1
- package/lib/util/queue/options.js +2 -1
- package/lib/util/queue/options.js.map +1 -1
- package/lib/util/serializedCache.d.ts +7 -2
- package/lib/util/serializedCache.d.ts.map +1 -1
- package/lib/util/serializedCache.js +9 -2
- package/lib/util/serializedCache.js.map +1 -1
- package/lib/util/set.d.ts.map +1 -1
- package/lib/util/set.js.map +1 -1
- package/lib/util/shuffle.js.map +1 -1
- package/lib/util/sortBy.js.map +1 -1
- package/lib/util/sszBytes.js.map +1 -1
- package/lib/util/time.js.map +1 -1
- package/lib/util/timeSeries.d.ts.map +1 -1
- package/lib/util/timeSeries.js.map +1 -1
- package/lib/util/types.d.ts.map +1 -1
- package/lib/util/workerEvents.d.ts +1 -1
- package/lib/util/workerEvents.d.ts.map +1 -1
- package/lib/util/workerEvents.js.map +1 -1
- package/lib/util/wrapError.js.map +1 -1
- package/package.json +41 -44
- package/src/api/impl/beacon/blocks/index.ts +147 -3
- package/src/api/impl/beacon/state/index.ts +8 -8
- package/src/api/impl/beacon/state/utils.ts +15 -29
- package/src/api/impl/debug/index.ts +9 -5
- package/src/api/impl/lightclient/index.ts +19 -2
- package/src/api/impl/node/utils.ts +3 -3
- package/src/api/impl/validator/index.ts +153 -17
- package/src/chain/archiveStore/archiveStore.ts +15 -5
- package/src/chain/archiveStore/historicalState/getHistoricalState.ts +10 -11
- package/src/chain/archiveStore/historicalState/worker.ts +3 -3
- package/src/chain/archiveStore/utils/archiveBlocks.ts +4 -5
- package/src/chain/archiveStore/utils/archivePayloads.ts +15 -0
- package/src/chain/archiveStore/utils/updateBackfillRange.ts +1 -1
- package/src/chain/blocks/blockInput/blockInput.ts +103 -3
- package/src/chain/blocks/blockInput/types.ts +18 -0
- package/src/chain/blocks/importBlock.ts +35 -7
- package/src/chain/blocks/index.ts +2 -1
- package/src/chain/blocks/verifyBlocksDataAvailability.ts +3 -0
- package/src/chain/blocks/verifyBlocksExecutionPayloads.ts +9 -2
- package/src/chain/blocks/verifyBlocksSanityChecks.ts +7 -2
- package/src/chain/blocks/writeBlockInputToDb.ts +105 -101
- package/src/chain/bls/multithread/index.ts +7 -7
- package/src/chain/bls/multithread/jobItem.ts +3 -3
- package/src/chain/bls/singleThread.ts +5 -5
- package/src/chain/bls/utils.ts +8 -5
- package/src/chain/chain.ts +82 -45
- package/src/chain/emitter.ts +5 -5
- package/src/chain/errors/executionPayloadBid.ts +1 -1
- package/src/chain/errors/executionPayloadEnvelope.ts +6 -2
- package/src/chain/errors/payloadAttestation.ts +1 -1
- package/src/chain/forkChoice/index.ts +39 -21
- package/src/chain/interface.ts +4 -11
- package/src/chain/lightClient/index.ts +4 -1
- package/src/chain/opPools/aggregatedAttestationPool.ts +1 -1
- package/src/chain/options.ts +1 -0
- package/src/chain/prepareNextSlot.ts +5 -5
- package/src/chain/produceBlock/computeNewStateRoot.ts +36 -3
- package/src/chain/produceBlock/produceBlockBody.ts +162 -13
- package/src/chain/regen/queued.ts +7 -2
- package/src/chain/regen/regen.ts +9 -3
- package/src/chain/seenCache/seenGossipBlockInput.ts +56 -18
- package/src/chain/validation/aggregateAndProof.ts +1 -1
- package/src/chain/validation/attestation.ts +14 -7
- package/src/chain/validation/attesterSlashing.ts +10 -1
- package/src/chain/validation/blobSidecar.ts +2 -2
- package/src/chain/validation/block.ts +9 -4
- package/src/chain/validation/dataColumnSidecar.ts +3 -6
- package/src/chain/validation/executionPayloadBid.ts +1 -2
- package/src/chain/validation/executionPayloadEnvelope.ts +4 -4
- package/src/chain/validation/payloadAttestationMessage.ts +10 -3
- package/src/chain/validation/proposerSlashing.ts +1 -1
- package/src/chain/validation/syncCommitteeContributionAndProof.ts +1 -1
- package/src/db/beacon.ts +8 -0
- package/src/db/buckets.ts +3 -0
- package/src/db/index.ts +1 -0
- package/src/db/interface.ts +5 -0
- package/src/db/repositories/blockArchive.ts +1 -2
- package/src/db/repositories/dataColumnSidecar.ts +18 -3
- package/src/db/repositories/dataColumnSidecarArchive.ts +18 -3
- package/src/db/repositories/executionPayloadEnvelope.ts +26 -0
- package/src/db/repositories/executionPayloadEnvelopeArchive.ts +32 -0
- package/src/db/repositories/index.ts +2 -0
- package/src/execution/engine/http.ts +3 -0
- package/src/metrics/metrics/beacon.ts +5 -0
- package/src/metrics/metrics/lodestar.ts +32 -10
- package/src/metrics/metrics.ts +8 -3
- package/src/monitoring/service.ts +3 -2
- package/src/network/core/networkCore.ts +3 -3
- package/src/network/core/networkCoreWorkerHandler.ts +3 -3
- package/src/network/core/types.ts +2 -2
- package/src/network/events.ts +2 -1
- package/src/network/gossip/encoding.ts +3 -3
- package/src/network/gossip/gossipsub.ts +86 -25
- package/src/network/gossip/interface.ts +6 -6
- package/src/network/gossip/scoringParameters.ts +4 -4
- package/src/network/gossip/topic.ts +2 -1
- package/src/network/interface.ts +7 -4
- package/src/network/libp2p/index.ts +8 -3
- package/src/network/network.ts +26 -7
- package/src/network/options.ts +3 -0
- package/src/network/peers/datastore.ts +13 -10
- package/src/network/peers/peerManager.ts +118 -54
- package/src/network/peers/utils/prioritizePeers.ts +3 -3
- package/src/network/processor/gossipHandlers.ts +19 -4
- package/src/network/processor/gossipValidatorFn.ts +2 -2
- package/src/network/processor/types.ts +1 -1
- package/src/network/reqresp/ReqRespBeaconNode.ts +1 -1
- package/src/network/reqresp/handlers/beaconBlocksByRange.ts +4 -3
- package/src/network/reqresp/handlers/blobSidecarsByRange.ts +3 -2
- package/src/network/reqresp/handlers/blobSidecarsByRoot.ts +1 -1
- package/src/network/reqresp/handlers/dataColumnSidecarsByRange.ts +4 -3
- package/src/network/reqresp/handlers/dataColumnSidecarsByRoot.ts +2 -2
- package/src/network/reqresp/handlers/lightClientUpdatesByRange.ts +6 -1
- package/src/network/reqresp/score.ts +0 -1
- package/src/network/reqresp/utils/collect.ts +1 -1
- package/src/network/reqresp/utils/collectSequentialBlocksInRange.ts +1 -1
- package/src/network/util.ts +2 -2
- package/src/node/nodejs.ts +8 -9
- package/src/sync/utils/downloadByRoot.ts +1 -1
- package/src/sync/utils/remoteSyncType.ts +1 -1
- package/src/util/blobs.ts +3 -3
- package/src/util/clock.ts +9 -4
- package/src/util/dataColumns.ts +37 -1
- package/src/util/multifork.ts +45 -0
- package/src/util/serializedCache.ts +10 -3
- package/src/util/workerEvents.ts +1 -1
package/src/network/events.ts
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import {EventEmitter} from "node:events";
|
|
2
|
-
import {
|
|
2
|
+
import type {TopicValidatorResult} from "@libp2p/gossipsub";
|
|
3
|
+
import type {PeerId} from "@libp2p/interface";
|
|
3
4
|
import {CustodyIndex, Status} from "@lodestar/types";
|
|
4
5
|
import {PeerIdStr} from "../util/peerId.js";
|
|
5
6
|
import {StrictEventEmitterSingleArg} from "../util/strictEvents.js";
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import {Message} from "@libp2p/
|
|
1
|
+
import type {Message} from "@libp2p/gossipsub";
|
|
2
|
+
import type {RPC} from "@libp2p/gossipsub/message";
|
|
3
|
+
import type {DataTransform} from "@libp2p/gossipsub/types";
|
|
2
4
|
// snappyjs is better for compression for smaller payloads
|
|
3
5
|
import xxhashFactory from "xxhash-wasm";
|
|
4
6
|
import {digest} from "@chainsafe/as-sha256";
|
|
5
|
-
import {RPC} from "@chainsafe/libp2p-gossipsub/message";
|
|
6
|
-
import {DataTransform} from "@chainsafe/libp2p-gossipsub/types";
|
|
7
7
|
import snappyWasm from "@chainsafe/snappy-wasm";
|
|
8
8
|
import {ForkName} from "@lodestar/params";
|
|
9
9
|
import {intToBytes} from "@lodestar/utils";
|
|
@@ -1,10 +1,18 @@
|
|
|
1
|
+
import {
|
|
2
|
+
type GossipSub,
|
|
3
|
+
type GossipSubEvents,
|
|
4
|
+
type PublishResult,
|
|
5
|
+
StrictNoSign,
|
|
6
|
+
type TopicValidatorResult,
|
|
7
|
+
gossipsub,
|
|
8
|
+
} from "@libp2p/gossipsub";
|
|
9
|
+
import type {MetricsRegister, TopicLabel, TopicStrToLabel} from "@libp2p/gossipsub/metrics";
|
|
10
|
+
import type {PeerScoreParams, PeerScoreStatsDump} from "@libp2p/gossipsub/score";
|
|
11
|
+
import type {AddrInfo, PublishOpts, TopicStr} from "@libp2p/gossipsub/types";
|
|
12
|
+
import type {PeerId} from "@libp2p/interface";
|
|
1
13
|
import {peerIdFromString} from "@libp2p/peer-id";
|
|
2
14
|
import {multiaddr} from "@multiformats/multiaddr";
|
|
3
15
|
import {ENR} from "@chainsafe/enr";
|
|
4
|
-
import {GossipSub, GossipsubEvents} from "@chainsafe/libp2p-gossipsub";
|
|
5
|
-
import {MetricsRegister, TopicLabel, TopicStrToLabel} from "@chainsafe/libp2p-gossipsub/metrics";
|
|
6
|
-
import {PeerScoreParams} from "@chainsafe/libp2p-gossipsub/score";
|
|
7
|
-
import {AddrInfo, SignaturePolicy, TopicStr} from "@chainsafe/libp2p-gossipsub/types";
|
|
8
16
|
import {routes} from "@lodestar/api";
|
|
9
17
|
import {BeaconConfig, ForkBoundary} from "@lodestar/config";
|
|
10
18
|
import {ATTESTATION_SUBNET_COUNT, SLOTS_PER_EPOCH, SYNC_COMMITTEE_SUBNET_COUNT} from "@lodestar/params";
|
|
@@ -69,6 +77,24 @@ export type Eth2GossipsubOpts = {
|
|
|
69
77
|
|
|
70
78
|
export type ForkBoundaryLabel = string;
|
|
71
79
|
|
|
80
|
+
// Many of the internal properties we need are not available on the public interface,
|
|
81
|
+
// so we create an extended type here to avoid excessive type assertions throughout the codebase.
|
|
82
|
+
// Mind that any updates to the gossipsub package may require updates to this type.
|
|
83
|
+
type GossipSubInternal = GossipSub & {
|
|
84
|
+
mesh: Map<string, Set<string>>;
|
|
85
|
+
peers: Map<string, PeerId>;
|
|
86
|
+
score: {score: (peerIdStr: string) => number};
|
|
87
|
+
direct: Set<string>;
|
|
88
|
+
topics: Map<string, Set<string>>;
|
|
89
|
+
start: () => Promise<void>;
|
|
90
|
+
stop: () => Promise<void>;
|
|
91
|
+
publish: (topic: TopicStr, data: Uint8Array, opts?: PublishOpts) => Promise<PublishResult>;
|
|
92
|
+
getMeshPeers: (topic: TopicStr) => string[];
|
|
93
|
+
dumpPeerScoreStats: () => PeerScoreStatsDump;
|
|
94
|
+
getScore: (peerIdStr: string) => number;
|
|
95
|
+
reportMessageValidationResult: (msgId: string, propagationSource: string, acceptance: TopicValidatorResult) => void;
|
|
96
|
+
};
|
|
97
|
+
|
|
72
98
|
/**
|
|
73
99
|
* Wrapper around js-libp2p-gossipsub with the following extensions:
|
|
74
100
|
* - Eth2 message id
|
|
@@ -82,13 +108,14 @@ export type ForkBoundaryLabel = string;
|
|
|
82
108
|
*
|
|
83
109
|
* See https://github.com/ethereum/consensus-specs/blob/v1.1.10/specs/phase0/p2p-interface.md#the-gossip-domain-gossipsub
|
|
84
110
|
*/
|
|
85
|
-
export class Eth2Gossipsub
|
|
111
|
+
export class Eth2Gossipsub {
|
|
86
112
|
readonly scoreParams: Partial<PeerScoreParams>;
|
|
87
113
|
private readonly config: BeaconConfig;
|
|
88
114
|
private readonly logger: Logger;
|
|
89
115
|
private readonly peersData: PeersData;
|
|
90
116
|
private readonly events: NetworkEventBus;
|
|
91
117
|
private readonly libp2p: Libp2p;
|
|
118
|
+
private readonly gossipsub: GossipSubInternal;
|
|
92
119
|
|
|
93
120
|
// Internal caches
|
|
94
121
|
private readonly gossipTopicCache: GossipTopicCache;
|
|
@@ -103,9 +130,6 @@ export class Eth2Gossipsub extends GossipSub {
|
|
|
103
130
|
let metrics: Eth2GossipsubMetrics | null = null;
|
|
104
131
|
if (metricsRegister) {
|
|
105
132
|
metrics = createEth2GossipsubMetrics(metricsRegister);
|
|
106
|
-
metrics.gossipMesh.peersByType.addCollect(() =>
|
|
107
|
-
this.onScrapeLodestarMetrics(metrics as Eth2GossipsubMetrics, networkConfig)
|
|
108
|
-
);
|
|
109
133
|
}
|
|
110
134
|
|
|
111
135
|
// Parse direct peers from multiaddr strings to AddrInfo objects
|
|
@@ -113,8 +137,8 @@ export class Eth2Gossipsub extends GossipSub {
|
|
|
113
137
|
|
|
114
138
|
// Gossipsub parameters defined here:
|
|
115
139
|
// https://github.com/ethereum/consensus-specs/blob/v1.1.10/specs/phase0/p2p-interface.md#the-gossip-domain-gossipsub
|
|
116
|
-
|
|
117
|
-
globalSignaturePolicy:
|
|
140
|
+
const gossipsubInstance = gossipsub({
|
|
141
|
+
globalSignaturePolicy: StrictNoSign,
|
|
118
142
|
allowPublishToZeroTopicPeers: allowPublishToZeroPeers,
|
|
119
143
|
D: gossipsubD ?? GOSSIP_D,
|
|
120
144
|
Dlo: gossipsubDLow ?? GOSSIP_D_LOW,
|
|
@@ -155,7 +179,12 @@ export class Eth2Gossipsub extends GossipSub {
|
|
|
155
179
|
// This should be large enough to not send IDONTWANT for "small" messages
|
|
156
180
|
// See https://github.com/ChainSafe/lodestar/pull/7077#issuecomment-2383679472
|
|
157
181
|
idontwantMinDataSize: 16829,
|
|
158
|
-
});
|
|
182
|
+
})(modules.libp2p.services.components) as GossipSubInternal;
|
|
183
|
+
|
|
184
|
+
if (metrics) {
|
|
185
|
+
metrics.gossipMesh.peersByType.addCollect(() => this.onScrapeLodestarMetrics(metrics, networkConfig));
|
|
186
|
+
}
|
|
187
|
+
this.gossipsub = gossipsubInstance;
|
|
159
188
|
this.scoreParams = scoreParams;
|
|
160
189
|
this.config = config;
|
|
161
190
|
this.logger = logger;
|
|
@@ -164,7 +193,7 @@ export class Eth2Gossipsub extends GossipSub {
|
|
|
164
193
|
this.libp2p = modules.libp2p;
|
|
165
194
|
this.gossipTopicCache = gossipTopicCache;
|
|
166
195
|
|
|
167
|
-
this.addEventListener("gossipsub:message", this.onGossipsubMessage.bind(this));
|
|
196
|
+
this.gossipsub.addEventListener("gossipsub:message", this.onGossipsubMessage.bind(this));
|
|
168
197
|
this.events.on(NetworkEvent.gossipMessageValidationResult, this.onValidationResult.bind(this));
|
|
169
198
|
|
|
170
199
|
// Having access to this data is CRUCIAL for debugging. While this is a massive log, it must not be deleted.
|
|
@@ -174,6 +203,38 @@ export class Eth2Gossipsub extends GossipSub {
|
|
|
174
203
|
}
|
|
175
204
|
}
|
|
176
205
|
|
|
206
|
+
async start(): Promise<void> {
|
|
207
|
+
await this.gossipsub.start();
|
|
208
|
+
}
|
|
209
|
+
|
|
210
|
+
async stop(): Promise<void> {
|
|
211
|
+
await this.gossipsub.stop();
|
|
212
|
+
}
|
|
213
|
+
|
|
214
|
+
get mesh(): Map<string, Set<string>> {
|
|
215
|
+
return this.gossipsub.mesh;
|
|
216
|
+
}
|
|
217
|
+
|
|
218
|
+
getTopics(): TopicStr[] {
|
|
219
|
+
return this.gossipsub.getTopics();
|
|
220
|
+
}
|
|
221
|
+
|
|
222
|
+
getMeshPeers(topic: TopicStr): string[] {
|
|
223
|
+
return this.gossipsub.getMeshPeers(topic);
|
|
224
|
+
}
|
|
225
|
+
|
|
226
|
+
publish(topic: TopicStr, data: Uint8Array, opts?: PublishOpts): Promise<PublishResult> {
|
|
227
|
+
return this.gossipsub.publish(topic, data, opts);
|
|
228
|
+
}
|
|
229
|
+
|
|
230
|
+
dumpPeerScoreStats(): PeerScoreStatsDump {
|
|
231
|
+
return this.gossipsub.dumpPeerScoreStats();
|
|
232
|
+
}
|
|
233
|
+
|
|
234
|
+
getScore(peerIdStr: string): number {
|
|
235
|
+
return this.gossipsub.getScore(peerIdStr);
|
|
236
|
+
}
|
|
237
|
+
|
|
177
238
|
/**
|
|
178
239
|
* Subscribe to a `GossipTopic`
|
|
179
240
|
*/
|
|
@@ -183,7 +244,7 @@ export class Eth2Gossipsub extends GossipSub {
|
|
|
183
244
|
this.gossipTopicCache.setTopic(topicStr, topic);
|
|
184
245
|
|
|
185
246
|
this.logger.verbose("Subscribe to gossipsub topic", {topic: topicStr});
|
|
186
|
-
this.subscribe(topicStr);
|
|
247
|
+
this.gossipsub.subscribe(topicStr);
|
|
187
248
|
}
|
|
188
249
|
|
|
189
250
|
/**
|
|
@@ -192,15 +253,14 @@ export class Eth2Gossipsub extends GossipSub {
|
|
|
192
253
|
unsubscribeTopic(topic: GossipTopic): void {
|
|
193
254
|
const topicStr = stringifyGossipTopic(this.config, topic);
|
|
194
255
|
this.logger.verbose("Unsubscribe to gossipsub topic", {topic: topicStr});
|
|
195
|
-
this.unsubscribe(topicStr);
|
|
256
|
+
this.gossipsub.unsubscribe(topicStr);
|
|
196
257
|
}
|
|
197
258
|
|
|
198
259
|
private onScrapeLodestarMetrics(metrics: Eth2GossipsubMetrics, networkConfig: NetworkConfig): void {
|
|
199
|
-
const mesh = this.mesh;
|
|
200
|
-
|
|
201
|
-
const
|
|
202
|
-
const
|
|
203
|
-
const score = this.score;
|
|
260
|
+
const mesh = this.gossipsub.mesh;
|
|
261
|
+
const topics = this.gossipsub.topics;
|
|
262
|
+
const peers = this.gossipsub.peers;
|
|
263
|
+
const score = this.gossipsub.score;
|
|
204
264
|
const meshPeersByClient = new Map<string, number>();
|
|
205
265
|
const meshPeerIdStrs = new Set<string>();
|
|
206
266
|
|
|
@@ -305,7 +365,7 @@ export class Eth2Gossipsub extends GossipSub {
|
|
|
305
365
|
metrics.gossipPeer.score.set(gossipScores);
|
|
306
366
|
}
|
|
307
367
|
|
|
308
|
-
private onGossipsubMessage(event:
|
|
368
|
+
private onGossipsubMessage(event: GossipSubEvents["gossipsub:message"]): void {
|
|
309
369
|
const {propagationSource, msgId, msg} = event.detail;
|
|
310
370
|
|
|
311
371
|
// Also validates that the topicStr is known
|
|
@@ -341,7 +401,7 @@ export class Eth2Gossipsub extends GossipSub {
|
|
|
341
401
|
// Without this we'll have huge event loop lag
|
|
342
402
|
// See https://github.com/ChainSafe/lodestar/issues/5604
|
|
343
403
|
callInNextEventLoop(() => {
|
|
344
|
-
this.reportMessageValidationResult(data.msgId, data.propagationSource, data.acceptance);
|
|
404
|
+
this.gossipsub.reportMessageValidationResult(data.msgId, data.propagationSource, data.acceptance);
|
|
345
405
|
});
|
|
346
406
|
}
|
|
347
407
|
|
|
@@ -379,7 +439,7 @@ export class Eth2Gossipsub extends GossipSub {
|
|
|
379
439
|
}
|
|
380
440
|
|
|
381
441
|
// Add to direct peers set only after addresses are stored
|
|
382
|
-
this.direct.add(peerIdStr);
|
|
442
|
+
this.gossipsub.direct.add(peerIdStr);
|
|
383
443
|
|
|
384
444
|
this.logger.info("Added direct peer via API", {peerId: peerIdStr});
|
|
385
445
|
return peerIdStr;
|
|
@@ -389,7 +449,7 @@ export class Eth2Gossipsub extends GossipSub {
|
|
|
389
449
|
* Remove a peer from direct peers.
|
|
390
450
|
*/
|
|
391
451
|
removeDirectPeer(peerIdStr: string): boolean {
|
|
392
|
-
const removed = this.direct.delete(peerIdStr);
|
|
452
|
+
const removed = this.gossipsub.direct.delete(peerIdStr);
|
|
393
453
|
if (removed) {
|
|
394
454
|
this.logger.info("Removed direct peer via API", {peerId: peerIdStr});
|
|
395
455
|
}
|
|
@@ -400,7 +460,7 @@ export class Eth2Gossipsub extends GossipSub {
|
|
|
400
460
|
* Get list of current direct peer IDs.
|
|
401
461
|
*/
|
|
402
462
|
getDirectPeers(): string[] {
|
|
403
|
-
return Array.from(this.direct);
|
|
463
|
+
return Array.from(this.gossipsub.direct);
|
|
404
464
|
}
|
|
405
465
|
}
|
|
406
466
|
|
|
@@ -498,7 +558,8 @@ export function parseDirectPeers(directPeerStrs: routes.lodestar.DirectPeer[], l
|
|
|
498
558
|
try {
|
|
499
559
|
const ma = multiaddr(peerStr);
|
|
500
560
|
|
|
501
|
-
const
|
|
561
|
+
const peerIdComponent = ma.getComponents().findLast((component) => component.name === "p2p");
|
|
562
|
+
const peerIdStr = peerIdComponent?.value;
|
|
502
563
|
if (!peerIdStr) {
|
|
503
564
|
logger.warn("Direct peer multiaddr must contain /p2p/ component with peer ID", {multiaddr: peerStr});
|
|
504
565
|
continue;
|
|
@@ -1,9 +1,10 @@
|
|
|
1
|
-
import {Message, TopicValidatorResult} from "@libp2p/
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
1
|
+
import type {Message, TopicValidatorResult} from "@libp2p/gossipsub";
|
|
2
|
+
import type {PeerIdStr} from "@libp2p/gossipsub/types";
|
|
3
|
+
import type {Libp2p} from "libp2p";
|
|
4
4
|
import {BeaconConfig, ForkBoundary} from "@lodestar/config";
|
|
5
5
|
import {
|
|
6
6
|
AttesterSlashing,
|
|
7
|
+
DataColumnSidecar,
|
|
7
8
|
LightClientFinalityUpdate,
|
|
8
9
|
LightClientOptimisticUpdate,
|
|
9
10
|
SignedAggregateAndProof,
|
|
@@ -14,7 +15,6 @@ import {
|
|
|
14
15
|
altair,
|
|
15
16
|
capella,
|
|
16
17
|
deneb,
|
|
17
|
-
fulu,
|
|
18
18
|
gloas,
|
|
19
19
|
phase0,
|
|
20
20
|
} from "@lodestar/types";
|
|
@@ -98,7 +98,7 @@ export type GossipTypeMap = {
|
|
|
98
98
|
[GossipType.blob_sidecar]: deneb.BlobSidecar;
|
|
99
99
|
[GossipType.beacon_aggregate_and_proof]: SignedAggregateAndProof;
|
|
100
100
|
[GossipType.beacon_attestation]: SingleAttestation;
|
|
101
|
-
[GossipType.data_column_sidecar]:
|
|
101
|
+
[GossipType.data_column_sidecar]: DataColumnSidecar;
|
|
102
102
|
[GossipType.voluntary_exit]: phase0.SignedVoluntaryExit;
|
|
103
103
|
[GossipType.proposer_slashing]: phase0.ProposerSlashing;
|
|
104
104
|
[GossipType.attester_slashing]: AttesterSlashing;
|
|
@@ -117,7 +117,7 @@ export type GossipFnByType = {
|
|
|
117
117
|
[GossipType.blob_sidecar]: (blobSidecar: deneb.BlobSidecar) => Promise<void> | void;
|
|
118
118
|
[GossipType.beacon_aggregate_and_proof]: (aggregateAndProof: SignedAggregateAndProof) => Promise<void> | void;
|
|
119
119
|
[GossipType.beacon_attestation]: (attestation: SingleAttestation) => Promise<void> | void;
|
|
120
|
-
[GossipType.data_column_sidecar]: (dataColumnSidecar:
|
|
120
|
+
[GossipType.data_column_sidecar]: (dataColumnSidecar: DataColumnSidecar) => Promise<void> | void;
|
|
121
121
|
[GossipType.voluntary_exit]: (voluntaryExit: phase0.SignedVoluntaryExit) => Promise<void> | void;
|
|
122
122
|
[GossipType.proposer_slashing]: (proposerSlashing: phase0.ProposerSlashing) => Promise<void> | void;
|
|
123
123
|
[GossipType.attester_slashing]: (attesterSlashing: AttesterSlashing) => Promise<void> | void;
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import {
|
|
2
|
-
PeerScoreParams,
|
|
3
|
-
PeerScoreThresholds,
|
|
4
|
-
TopicScoreParams,
|
|
2
|
+
type PeerScoreParams,
|
|
3
|
+
type PeerScoreThresholds,
|
|
4
|
+
type TopicScoreParams,
|
|
5
5
|
defaultTopicScoreParams,
|
|
6
|
-
} from "@
|
|
6
|
+
} from "@libp2p/gossipsub/score";
|
|
7
7
|
import {BeaconConfig} from "@lodestar/config";
|
|
8
8
|
import {ATTESTATION_SUBNET_COUNT, PTC_SIZE, SLOTS_PER_EPOCH, TARGET_AGGREGATORS_PER_COMMITTEE} from "@lodestar/params";
|
|
9
9
|
import {computeCommitteeCount} from "@lodestar/state-transition";
|
|
@@ -6,6 +6,7 @@ import {
|
|
|
6
6
|
SYNC_COMMITTEE_SUBNET_COUNT,
|
|
7
7
|
isForkPostAltair,
|
|
8
8
|
isForkPostElectra,
|
|
9
|
+
isForkPostFulu,
|
|
9
10
|
} from "@lodestar/params";
|
|
10
11
|
import {Attestation, SingleAttestation, ssz, sszTypesFor} from "@lodestar/types";
|
|
11
12
|
import {GossipAction, GossipActionError, GossipErrorCode} from "../../chain/errors/gossipValidation.js";
|
|
@@ -92,7 +93,7 @@ export function getGossipSSZType(topic: GossipTopic) {
|
|
|
92
93
|
case GossipType.blob_sidecar:
|
|
93
94
|
return ssz.deneb.BlobSidecar;
|
|
94
95
|
case GossipType.data_column_sidecar:
|
|
95
|
-
return ssz.fulu.DataColumnSidecar;
|
|
96
|
+
return isForkPostFulu(fork) ? sszTypesFor(fork).DataColumnSidecar : ssz.fulu.DataColumnSidecar;
|
|
96
97
|
case GossipType.beacon_aggregate_and_proof:
|
|
97
98
|
return sszTypesFor(fork).SignedAggregateAndProof;
|
|
98
99
|
case GossipType.beacon_attestation:
|
package/src/network/interface.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {Identify} from "@libp2p/identify";
|
|
2
|
-
import {
|
|
1
|
+
import type {Identify} from "@libp2p/identify";
|
|
2
|
+
import type {
|
|
3
3
|
ComponentLogger,
|
|
4
4
|
ConnectionGater,
|
|
5
5
|
ConnectionProtector,
|
|
@@ -16,9 +16,10 @@ import {
|
|
|
16
16
|
} from "@libp2p/interface";
|
|
17
17
|
import type {AddressManager, ConnectionManager, Registrar, TransportManager} from "@libp2p/interface-internal";
|
|
18
18
|
import type {Datastore} from "interface-datastore";
|
|
19
|
-
import {Libp2p as ILibp2p} from "libp2p";
|
|
19
|
+
import type {Libp2p as ILibp2p} from "libp2p";
|
|
20
20
|
import {
|
|
21
21
|
AttesterSlashing,
|
|
22
|
+
DataColumnSidecar,
|
|
22
23
|
LightClientFinalityUpdate,
|
|
23
24
|
LightClientOptimisticUpdate,
|
|
24
25
|
SignedAggregateAndProof,
|
|
@@ -31,6 +32,7 @@ import {
|
|
|
31
32
|
capella,
|
|
32
33
|
deneb,
|
|
33
34
|
fulu,
|
|
35
|
+
gloas,
|
|
34
36
|
phase0,
|
|
35
37
|
} from "@lodestar/types";
|
|
36
38
|
import {BlockInputSource} from "../chain/blocks/blockInput/types.js";
|
|
@@ -86,7 +88,7 @@ export interface INetwork extends INetworkCorePublic {
|
|
|
86
88
|
publishBlobSidecar(blobSidecar: deneb.BlobSidecar): Promise<number>;
|
|
87
89
|
publishBeaconAggregateAndProof(aggregateAndProof: SignedAggregateAndProof): Promise<number>;
|
|
88
90
|
publishBeaconAttestation(attestation: SingleAttestation, subnet: SubnetID): Promise<number>;
|
|
89
|
-
publishDataColumnSidecar(dataColumnSideCar:
|
|
91
|
+
publishDataColumnSidecar(dataColumnSideCar: DataColumnSidecar): Promise<number>;
|
|
90
92
|
publishVoluntaryExit(voluntaryExit: phase0.SignedVoluntaryExit): Promise<number>;
|
|
91
93
|
publishBlsToExecutionChange(blsToExecutionChange: capella.SignedBLSToExecutionChange): Promise<number>;
|
|
92
94
|
publishProposerSlashing(proposerSlashing: phase0.ProposerSlashing): Promise<number>;
|
|
@@ -95,6 +97,7 @@ export interface INetwork extends INetworkCorePublic {
|
|
|
95
97
|
publishContributionAndProof(contributionAndProof: altair.SignedContributionAndProof): Promise<number>;
|
|
96
98
|
publishLightClientFinalityUpdate(update: LightClientFinalityUpdate): Promise<number>;
|
|
97
99
|
publishLightClientOptimisticUpdate(update: LightClientOptimisticUpdate): Promise<number>;
|
|
100
|
+
publishSignedExecutionPayloadEnvelope(signedEnvelope: gloas.SignedExecutionPayloadEnvelope): Promise<number>;
|
|
98
101
|
|
|
99
102
|
// Debug
|
|
100
103
|
dumpGossipQueue(gossipType: GossipType): Promise<PendingGossipsubMessage[]>;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import {bootstrap} from "@libp2p/bootstrap";
|
|
2
2
|
import {identify} from "@libp2p/identify";
|
|
3
|
-
import {PrivateKey} from "@libp2p/interface";
|
|
3
|
+
import type {PrivateKey} from "@libp2p/interface";
|
|
4
4
|
import {mdns} from "@libp2p/mdns";
|
|
5
5
|
import {mplex} from "@libp2p/mplex";
|
|
6
6
|
import {prometheusMetrics} from "@libp2p/prometheus-metrics";
|
|
@@ -39,6 +39,7 @@ export async function createNodeJsLibp2p(
|
|
|
39
39
|
nodeJsLibp2pOpts: NodeJsLibp2pOpts = {}
|
|
40
40
|
): Promise<Libp2p> {
|
|
41
41
|
const localMultiaddrs = networkOpts.localMultiaddrs || defaultNetworkOptions.localMultiaddrs;
|
|
42
|
+
const disconnectThreshold = networkOpts.disconnectThreshold ?? defaultNetworkOptions.disconnectThreshold;
|
|
42
43
|
const {peerStoreDir, disablePeerDiscovery} = nodeJsLibp2pOpts;
|
|
43
44
|
|
|
44
45
|
let datastore: undefined | Eth2PeerDataStore = undefined;
|
|
@@ -74,6 +75,11 @@ export async function createNodeJsLibp2p(
|
|
|
74
75
|
|
|
75
76
|
return createLibp2p({
|
|
76
77
|
privateKey,
|
|
78
|
+
nodeInfo: {
|
|
79
|
+
name: "lodestar",
|
|
80
|
+
version: networkOpts.version ?? "unknown",
|
|
81
|
+
userAgent: networkOpts.private ? "" : networkOpts.version ? `lodestar/${networkOpts.version}` : "lodestar",
|
|
82
|
+
},
|
|
77
83
|
addresses: {
|
|
78
84
|
listen: localMultiaddrs,
|
|
79
85
|
announce: [],
|
|
@@ -93,7 +99,7 @@ export async function createNodeJsLibp2p(
|
|
|
93
99
|
},
|
|
94
100
|
}),
|
|
95
101
|
],
|
|
96
|
-
streamMuxers: [mplex({
|
|
102
|
+
streamMuxers: [mplex({disconnectThreshold})],
|
|
97
103
|
peerDiscovery,
|
|
98
104
|
metrics: nodeJsLibp2pOpts.metrics
|
|
99
105
|
? prometheusMetrics({
|
|
@@ -124,7 +130,6 @@ export async function createNodeJsLibp2p(
|
|
|
124
130
|
datastore,
|
|
125
131
|
services: {
|
|
126
132
|
identify: identify({
|
|
127
|
-
agentVersion: networkOpts.private ? "" : networkOpts.version ? `lodestar/${networkOpts.version}` : "lodestar",
|
|
128
133
|
runOnConnectionOpen: false,
|
|
129
134
|
}),
|
|
130
135
|
// individual components are specified because the components object is a Proxy
|
package/src/network/network.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import type {PeerScoreStatsDump} from "@libp2p/gossipsub/score";
|
|
2
|
+
import type {PublishOpts} from "@libp2p/gossipsub/types";
|
|
3
|
+
import type {PeerId, PrivateKey} from "@libp2p/interface";
|
|
2
4
|
import {peerIdFromPrivateKey} from "@libp2p/peer-id";
|
|
3
|
-
import {PeerScoreStatsDump} from "@chainsafe/libp2p-gossipsub/score";
|
|
4
|
-
import {PublishOpts} from "@chainsafe/libp2p-gossipsub/types";
|
|
5
5
|
import {routes} from "@lodestar/api";
|
|
6
6
|
import {BeaconConfig} from "@lodestar/config";
|
|
7
7
|
import {LoggerNode} from "@lodestar/logger/node";
|
|
@@ -10,6 +10,8 @@ import {ResponseIncoming} from "@lodestar/reqresp";
|
|
|
10
10
|
import {computeEpochAtSlot} from "@lodestar/state-transition";
|
|
11
11
|
import {
|
|
12
12
|
AttesterSlashing,
|
|
13
|
+
DataColumnSidecar,
|
|
14
|
+
DataColumnSidecars,
|
|
13
15
|
LightClientBootstrap,
|
|
14
16
|
LightClientFinalityUpdate,
|
|
15
17
|
LightClientOptimisticUpdate,
|
|
@@ -24,6 +26,8 @@ import {
|
|
|
24
26
|
capella,
|
|
25
27
|
deneb,
|
|
26
28
|
fulu,
|
|
29
|
+
gloas,
|
|
30
|
+
isGloasDataColumnSidecar,
|
|
27
31
|
phase0,
|
|
28
32
|
} from "@lodestar/types";
|
|
29
33
|
import {prettyPrintIndices, sleep} from "@lodestar/utils";
|
|
@@ -354,8 +358,11 @@ export class Network implements INetwork {
|
|
|
354
358
|
});
|
|
355
359
|
}
|
|
356
360
|
|
|
357
|
-
async publishDataColumnSidecar(dataColumnSidecar:
|
|
358
|
-
const
|
|
361
|
+
async publishDataColumnSidecar(dataColumnSidecar: DataColumnSidecar): Promise<number> {
|
|
362
|
+
const slot = isGloasDataColumnSidecar(dataColumnSidecar)
|
|
363
|
+
? dataColumnSidecar.slot
|
|
364
|
+
: dataColumnSidecar.signedBlockHeader.message.slot;
|
|
365
|
+
const epoch = computeEpochAtSlot(slot);
|
|
359
366
|
const boundary = this.config.getForkBoundaryAtEpoch(epoch);
|
|
360
367
|
|
|
361
368
|
const subnet = computeSubnetForDataColumnSidecar(this.config, dataColumnSidecar);
|
|
@@ -489,6 +496,17 @@ export class Network implements INetwork {
|
|
|
489
496
|
);
|
|
490
497
|
}
|
|
491
498
|
|
|
499
|
+
async publishSignedExecutionPayloadEnvelope(signedEnvelope: gloas.SignedExecutionPayloadEnvelope): Promise<number> {
|
|
500
|
+
const epoch = computeEpochAtSlot(signedEnvelope.message.slot);
|
|
501
|
+
const boundary = this.config.getForkBoundaryAtEpoch(epoch);
|
|
502
|
+
|
|
503
|
+
return this.publishGossip<GossipType.execution_payload>(
|
|
504
|
+
{type: GossipType.execution_payload, boundary},
|
|
505
|
+
signedEnvelope,
|
|
506
|
+
{ignoreDuplicatePublishError: true}
|
|
507
|
+
);
|
|
508
|
+
}
|
|
509
|
+
|
|
492
510
|
private async publishGossip<K extends GossipType>(
|
|
493
511
|
topic: GossipTopicMap[K],
|
|
494
512
|
object: GossipTypeMap[K],
|
|
@@ -521,7 +539,8 @@ export class Network implements INetwork {
|
|
|
521
539
|
this.config.getForkSeq(this.clock.currentSlot) >= ForkSeq.altair ? [Version.V2] : [Version.V2, Version.V1],
|
|
522
540
|
request
|
|
523
541
|
),
|
|
524
|
-
request
|
|
542
|
+
request,
|
|
543
|
+
this.chain.serializedCache
|
|
525
544
|
);
|
|
526
545
|
}
|
|
527
546
|
|
|
@@ -765,7 +784,7 @@ export class Network implements INetwork {
|
|
|
765
784
|
this.core.setTargetGroupCount(count);
|
|
766
785
|
};
|
|
767
786
|
|
|
768
|
-
private onPublishDataColumns = (sidecars:
|
|
787
|
+
private onPublishDataColumns = (sidecars: DataColumnSidecars): Promise<number[]> => {
|
|
769
788
|
return promiseAllMaybeAsync(sidecars.map((sidecar) => () => this.publishDataColumnSidecar(sidecar)));
|
|
770
789
|
};
|
|
771
790
|
|
package/src/network/options.ts
CHANGED
|
@@ -72,4 +72,7 @@ export const defaultNetworkOptions: NetworkOptions = {
|
|
|
72
72
|
// - for fusaka-devnets, we have 25-30 peers per subnet
|
|
73
73
|
// - for public testnets or mainnet, average number of peers per group is SAMPLES_PER_SLOT * targetPeers / NUMBER_OF_CUSTODY_GROUPS = 6.25 so this should not be an issue
|
|
74
74
|
targetGroupPeers: 6,
|
|
75
|
+
// Keep this high enough for normal req/resp bursts on stable connections.
|
|
76
|
+
// libp2p-mplex default (5) is too low and can cause frequent connection resets.
|
|
77
|
+
disconnectThreshold: 50,
|
|
75
78
|
};
|
|
@@ -8,6 +8,9 @@ type MemoryItem = {
|
|
|
8
8
|
data: Uint8Array;
|
|
9
9
|
};
|
|
10
10
|
|
|
11
|
+
// biome-ignore lint/suspicious/noExplicitAny: used below (copied from upstream)
|
|
12
|
+
type AwaitGenerator<T, TReturn = any, TNext = any> = Generator<T, TReturn, TNext> | AsyncGenerator<T, TReturn, TNext>;
|
|
13
|
+
|
|
11
14
|
/**
|
|
12
15
|
* Before libp2p 0.35, peerstore stays in memory and periodically write to db after n dirty items
|
|
13
16
|
* This has a memory issue because all peer data stays in memory and loaded at startup time
|
|
@@ -93,7 +96,7 @@ export class Eth2PeerDataStore extends BaseDatastore {
|
|
|
93
96
|
* This throws error if not found
|
|
94
97
|
* see https://github.com/ipfs/js-datastore-level/blob/38f44058dd6be858e757a1c90b8edb31590ec0bc/src/index.js#L102
|
|
95
98
|
*/
|
|
96
|
-
async get(key: Key): Promise<Uint8Array> {
|
|
99
|
+
async get(key: Key, options?: AbortOptions): Promise<Uint8Array> {
|
|
97
100
|
const keyStr = key.toString();
|
|
98
101
|
const memoryItem = this._memoryDatastore.get(keyStr);
|
|
99
102
|
if (memoryItem) {
|
|
@@ -102,16 +105,16 @@ export class Eth2PeerDataStore extends BaseDatastore {
|
|
|
102
105
|
}
|
|
103
106
|
|
|
104
107
|
// this throws error if not found
|
|
105
|
-
const dbValue = await this._dbDatastore.get(key);
|
|
108
|
+
const dbValue = await this._dbDatastore.get(key, options);
|
|
106
109
|
// don't call this._memoryDatastore.set directly
|
|
107
110
|
// we want to get through prune() logic with fromDb as true
|
|
108
111
|
await this._put(key, dbValue, true);
|
|
109
112
|
return dbValue;
|
|
110
113
|
}
|
|
111
114
|
|
|
112
|
-
async has(key: Key): Promise<boolean> {
|
|
115
|
+
async has(key: Key, options?: AbortOptions): Promise<boolean> {
|
|
113
116
|
try {
|
|
114
|
-
await this.get(key);
|
|
117
|
+
await this.get(key, options);
|
|
115
118
|
} catch (err) {
|
|
116
119
|
// this is the same to how js-datastore-level handles notFound error
|
|
117
120
|
// https://github.com/ipfs/js-datastore-level/blob/38f44058dd6be858e757a1c90b8edb31590ec0bc/src/index.js#L121
|
|
@@ -121,26 +124,26 @@ export class Eth2PeerDataStore extends BaseDatastore {
|
|
|
121
124
|
return true;
|
|
122
125
|
}
|
|
123
126
|
|
|
124
|
-
async delete(key: Key): Promise<void> {
|
|
127
|
+
async delete(key: Key, options?: AbortOptions): Promise<void> {
|
|
125
128
|
this._memoryDatastore.delete(key.toString());
|
|
126
|
-
await this._dbDatastore.delete(key);
|
|
129
|
+
await this._dbDatastore.delete(key, options);
|
|
127
130
|
}
|
|
128
131
|
|
|
129
|
-
async *_all(q: Query):
|
|
132
|
+
async *_all(q: Query, options?: AbortOptions): AwaitGenerator<Pair> {
|
|
130
133
|
for (const [key, value] of this._memoryDatastore.entries()) {
|
|
131
134
|
yield {
|
|
132
135
|
key: new Key(key),
|
|
133
136
|
value: value.data,
|
|
134
137
|
};
|
|
135
138
|
}
|
|
136
|
-
yield* this._dbDatastore.query(q);
|
|
139
|
+
yield* this._dbDatastore.query(q, options);
|
|
137
140
|
}
|
|
138
141
|
|
|
139
|
-
async *_allKeys(q: KeyQuery):
|
|
142
|
+
async *_allKeys(q: KeyQuery, options?: AbortOptions): AwaitGenerator<Key> {
|
|
140
143
|
for (const key of this._memoryDatastore.keys()) {
|
|
141
144
|
yield new Key(key);
|
|
142
145
|
}
|
|
143
|
-
yield* this._dbDatastore.queryKeys(q);
|
|
146
|
+
yield* this._dbDatastore.queryKeys(q, options);
|
|
144
147
|
}
|
|
145
148
|
|
|
146
149
|
private async _addDirtyItem(keyStr: string): Promise<void> {
|