fixed broken logs (#7934)
* fixed broken logs * bring back old lock order * removed bloom groups from blockchain * revert unrelated changes * simplify blockchain_block_blooms
This commit is contained in:
@@ -18,7 +18,6 @@
|
||||
|
||||
use std::ops;
|
||||
use std::io::Write;
|
||||
use blooms::{GroupPosition, BloomGroup};
|
||||
use db::Key;
|
||||
use engines::epoch::{Transition as EpochTransition};
|
||||
use header::BlockNumber;
|
||||
@@ -37,8 +36,6 @@ pub enum ExtrasIndex {
|
||||
BlockHash = 1,
|
||||
/// Transaction address index
|
||||
TransactionAddress = 2,
|
||||
/// Block blooms index
|
||||
BlocksBlooms = 3,
|
||||
/// Block receipts index
|
||||
BlockReceipts = 4,
|
||||
/// Epoch transition data index.
|
||||
@@ -86,31 +83,6 @@ impl Key<BlockDetails> for H256 {
|
||||
}
|
||||
}
|
||||
|
||||
pub struct LogGroupKey([u8; 6]);
|
||||
|
||||
impl ops::Deref for LogGroupKey {
|
||||
type Target = [u8];
|
||||
|
||||
fn deref(&self) -> &Self::Target {
|
||||
&self.0
|
||||
}
|
||||
}
|
||||
|
||||
impl Key<BloomGroup> for GroupPosition {
|
||||
type Target = LogGroupKey;
|
||||
|
||||
fn key(&self) -> Self::Target {
|
||||
let mut result = [0u8; 6];
|
||||
result[0] = ExtrasIndex::BlocksBlooms as u8;
|
||||
result[1] = self.level;
|
||||
result[2] = (self.index >> 24) as u8;
|
||||
result[3] = (self.index >> 16) as u8;
|
||||
result[4] = (self.index >> 8) as u8;
|
||||
result[5] = self.index as u8;
|
||||
LogGroupKey(result)
|
||||
}
|
||||
}
|
||||
|
||||
impl Key<TransactionAddress> for H256 {
|
||||
type Target = H264;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user