mirror of
https://github.com/sigp/lighthouse.git
synced 2026-04-17 12:58:31 +00:00
Delete dead code
This commit is contained in:
@@ -1,4 +1,3 @@
|
||||
use crate::DatabasePayloadEnvelope;
|
||||
use crate::config::{OnDiskStoreConfig, StoreConfig};
|
||||
use crate::database::interface::BeaconNodeBackend;
|
||||
use crate::forwards_iter::{HybridForwardsBlockRootsIterator, HybridForwardsStateRootsIterator};
|
||||
@@ -746,27 +745,6 @@ impl<E: EthSpec, Hot: ItemStore<E>, Cold: ItemStore<E>> HotColdDB<E, Hot, Cold>
|
||||
.map_err(|e| e.into())
|
||||
}
|
||||
|
||||
pub fn try_get_full_payload_envelope(
|
||||
&self,
|
||||
block_root: &Hash256,
|
||||
) -> Result<Option<DatabasePayloadEnvelope<E>>, Error> {
|
||||
// TODO(gloas) metrics
|
||||
// metrics::inc_counter(&metrics::PAYLOAD_ENVELOPE_GET_COUNT);
|
||||
|
||||
// Load the execution payload envelope
|
||||
// TODO(gloas) we'll want to implement a way to load a blinded envelope
|
||||
let Some(envelope) = self.get_payload_envelope(block_root)? else {
|
||||
return Ok(None);
|
||||
};
|
||||
|
||||
Ok(Some(DatabasePayloadEnvelope::Full(envelope)))
|
||||
|
||||
// TODO(gloas) implement the logic described below (see `try_get_full_block`)
|
||||
// If the payload envelope is after the split point then we should have the full execution payload
|
||||
// stored in the database. If it isn't but payload pruning is disabled, try to load it
|
||||
// on-demand.
|
||||
}
|
||||
|
||||
pub fn get_payload_envelope(
|
||||
&self,
|
||||
block_root: &Hash256,
|
||||
|
||||
@@ -390,13 +390,6 @@ pub enum DatabaseBlock<E: EthSpec> {
|
||||
Blinded(SignedBeaconBlock<E, BlindedPayload<E>>),
|
||||
}
|
||||
|
||||
/// An execution payload envelope from the database
|
||||
// TODO(gloas) implement blinded variant
|
||||
pub enum DatabasePayloadEnvelope<E: EthSpec> {
|
||||
Full(SignedExecutionPayloadEnvelope<E>),
|
||||
Blinded(SignedExecutionPayloadEnvelope<E>),
|
||||
}
|
||||
|
||||
impl DBColumn {
|
||||
pub fn as_str(self) -> &'static str {
|
||||
self.into()
|
||||
|
||||
Reference in New Issue
Block a user