Move entry/poh to own crate to speed up poh bench build (#18225)

This commit is contained in:
sakridge
2021-07-14 14:16:29 +02:00
committed by GitHub
parent a4a24b6531
commit 7f2254225e
57 changed files with 152 additions and 90 deletions

35
Cargo.lock generated
View File

@@ -4591,6 +4591,7 @@ dependencies = [
"solana-clap-utils", "solana-clap-utils",
"solana-client", "solana-client",
"solana-config-program", "solana-config-program",
"solana-entry",
"solana-frozen-abi 1.8.0", "solana-frozen-abi 1.8.0",
"solana-frozen-abi-macro 1.8.0", "solana-frozen-abi-macro 1.8.0",
"solana-gossip", "solana-gossip",
@@ -4678,6 +4679,27 @@ dependencies = [
"tar", "tar",
] ]
[[package]]
name = "solana-entry"
version = "1.8.0"
dependencies = [
"bincode",
"dlopen",
"dlopen_derive",
"log 0.4.14",
"matches",
"rand 0.7.3",
"rayon",
"serde",
"solana-logger 1.8.0",
"solana-measure",
"solana-merkle-tree",
"solana-metrics",
"solana-perf",
"solana-rayon-threadlimit",
"solana-sdk",
]
[[package]] [[package]]
name = "solana-failure-program" name = "solana-failure-program"
version = "1.8.0" version = "1.8.0"
@@ -4779,6 +4801,7 @@ dependencies = [
"serde_yaml", "serde_yaml",
"solana-clap-utils", "solana-clap-utils",
"solana-cli-config", "solana-cli-config",
"solana-entry",
"solana-ledger", "solana-ledger",
"solana-logger 1.8.0", "solana-logger 1.8.0",
"solana-runtime", "solana-runtime",
@@ -4823,6 +4846,7 @@ dependencies = [
"serial_test 0.5.1", "serial_test 0.5.1",
"solana-clap-utils", "solana-clap-utils",
"solana-client", "solana-client",
"solana-entry",
"solana-frozen-abi 1.8.0", "solana-frozen-abi 1.8.0",
"solana-frozen-abi-macro 1.8.0", "solana-frozen-abi-macro 1.8.0",
"solana-ledger", "solana-ledger",
@@ -4899,8 +4923,6 @@ dependencies = [
"chrono", "chrono",
"chrono-humanize", "chrono-humanize",
"crossbeam-channel", "crossbeam-channel",
"dlopen",
"dlopen_derive",
"ed25519-dalek", "ed25519-dalek",
"fs_extra", "fs_extra",
"futures 0.3.15", "futures 0.3.15",
@@ -4923,6 +4945,7 @@ dependencies = [
"sha2 0.9.5", "sha2 0.9.5",
"solana-account-decoder", "solana-account-decoder",
"solana-bpf-loader-program", "solana-bpf-loader-program",
"solana-entry",
"solana-frozen-abi 1.8.0", "solana-frozen-abi 1.8.0",
"solana-frozen-abi-macro 1.8.0", "solana-frozen-abi-macro 1.8.0",
"solana-logger 1.8.0", "solana-logger 1.8.0",
@@ -4966,6 +4989,7 @@ dependencies = [
"solana-clap-utils", "solana-clap-utils",
"solana-cli-output", "solana-cli-output",
"solana-core", "solana-core",
"solana-entry",
"solana-ledger", "solana-ledger",
"solana-logger 1.8.0", "solana-logger 1.8.0",
"solana-measure", "solana-measure",
@@ -4997,6 +5021,7 @@ dependencies = [
"solana-config-program", "solana-config-program",
"solana-core", "solana-core",
"solana-download-utils", "solana-download-utils",
"solana-entry",
"solana-faucet", "solana-faucet",
"solana-gossip", "solana-gossip",
"solana-ledger", "solana-ledger",
@@ -5048,7 +5073,6 @@ name = "solana-measure"
version = "1.8.0" version = "1.8.0"
dependencies = [ dependencies = [
"log 0.4.14", "log 0.4.14",
"solana-metrics",
"solana-sdk", "solana-sdk",
] ]
@@ -5181,6 +5205,7 @@ dependencies = [
"log 0.4.14", "log 0.4.14",
"matches", "matches",
"rand 0.7.3", "rand 0.7.3",
"solana-entry",
"solana-ledger", "solana-ledger",
"solana-logger 1.8.0", "solana-logger 1.8.0",
"solana-measure", "solana-measure",
@@ -5201,7 +5226,7 @@ dependencies = [
"rand 0.7.3", "rand 0.7.3",
"rayon", "rayon",
"solana-clap-utils", "solana-clap-utils",
"solana-ledger", "solana-entry",
"solana-logger 1.8.0", "solana-logger 1.8.0",
"solana-measure", "solana-measure",
"solana-perf", "solana-perf",
@@ -5355,6 +5380,7 @@ dependencies = [
"serial_test 0.4.0", "serial_test 0.4.0",
"solana-account-decoder", "solana-account-decoder",
"solana-client", "solana-client",
"solana-entry",
"solana-faucet", "solana-faucet",
"solana-gossip", "solana-gossip",
"solana-ledger", "solana-ledger",
@@ -5733,6 +5759,7 @@ dependencies = [
"solana-client", "solana-client",
"solana-core", "solana-core",
"solana-download-utils", "solana-download-utils",
"solana-entry",
"solana-faucet", "solana-faucet",
"solana-genesis-utils", "solana-genesis-utils",
"solana-gossip", "solana-gossip",

View File

@@ -15,6 +15,7 @@ members = [
"core", "core",
"dos", "dos",
"download-utils", "download-utils",
"entry",
"faucet", "faucet",
"frozen-abi", "frozen-abi",
"perf", "perf",

View File

@@ -48,6 +48,7 @@ solana-banks-server = { path = "../banks-server", version = "=1.8.0" }
solana-clap-utils = { path = "../clap-utils", version = "=1.8.0" } solana-clap-utils = { path = "../clap-utils", version = "=1.8.0" }
solana-client = { path = "../client", version = "=1.8.0" } solana-client = { path = "../client", version = "=1.8.0" }
solana-config-program = { path = "../programs/config", version = "=1.8.0" } solana-config-program = { path = "../programs/config", version = "=1.8.0" }
solana-entry = { path = "../entry", version = "=1.8.0" }
solana-gossip = { path = "../gossip", version = "=1.8.0" } solana-gossip = { path = "../gossip", version = "=1.8.0" }
solana-ledger = { path = "../ledger", version = "=1.8.0" } solana-ledger = { path = "../ledger", version = "=1.8.0" }
solana-logger = { path = "../logger", version = "=1.8.0" } solana-logger = { path = "../logger", version = "=1.8.0" }

View File

@@ -10,10 +10,10 @@ use rayon::prelude::*;
use solana_core::banking_stage::{BankingStage, BankingStageStats}; use solana_core::banking_stage::{BankingStage, BankingStageStats};
use solana_core::cost_model::CostModel; use solana_core::cost_model::CostModel;
use solana_core::cost_tracker::CostTracker; use solana_core::cost_tracker::CostTracker;
use solana_entry::entry::{next_hash, Entry};
use solana_gossip::cluster_info::ClusterInfo; use solana_gossip::cluster_info::ClusterInfo;
use solana_gossip::cluster_info::Node; use solana_gossip::cluster_info::Node;
use solana_ledger::blockstore_processor::process_entries; use solana_ledger::blockstore_processor::process_entries;
use solana_ledger::entry::{next_hash, Entry};
use solana_ledger::genesis_utils::{create_genesis_config, GenesisConfigInfo}; use solana_ledger::genesis_utils::{create_genesis_config, GenesisConfigInfo};
use solana_ledger::{blockstore::Blockstore, get_tmp_ledger_path}; use solana_ledger::{blockstore::Blockstore, get_tmp_ledger_path};
use solana_perf::packet::to_packets_chunked; use solana_perf::packet::to_packets_chunked;

View File

@@ -4,9 +4,9 @@ extern crate solana_ledger;
extern crate test; extern crate test;
use rand::Rng; use rand::Rng;
use solana_entry::entry::{create_ticks, Entry};
use solana_ledger::{ use solana_ledger::{
blockstore::{entries_to_test_shreds, Blockstore}, blockstore::{entries_to_test_shreds, Blockstore},
entry::{create_ticks, Entry},
get_tmp_ledger_path, get_tmp_ledger_path,
}; };
use solana_sdk::{clock::Slot, hash::Hash}; use solana_sdk::{clock::Slot, hash::Hash};

View File

@@ -5,9 +5,9 @@ extern crate test;
use log::*; use log::*;
use solana_core::retransmit_stage::retransmitter; use solana_core::retransmit_stage::retransmitter;
use solana_entry::entry::Entry;
use solana_gossip::cluster_info::{ClusterInfo, Node}; use solana_gossip::cluster_info::{ClusterInfo, Node};
use solana_gossip::contact_info::ContactInfo; use solana_gossip::contact_info::ContactInfo;
use solana_ledger::entry::Entry;
use solana_ledger::genesis_utils::{create_genesis_config, GenesisConfigInfo}; use solana_ledger::genesis_utils::{create_genesis_config, GenesisConfigInfo};
use solana_ledger::leader_schedule_cache::LeaderScheduleCache; use solana_ledger::leader_schedule_cache::LeaderScheduleCache;
use solana_ledger::shred::Shredder; use solana_ledger::shred::Shredder;

View File

@@ -5,7 +5,7 @@ extern crate test;
use rand::seq::SliceRandom; use rand::seq::SliceRandom;
use raptorq::{Decoder, Encoder}; use raptorq::{Decoder, Encoder};
use solana_ledger::entry::{create_ticks, Entry}; use solana_entry::entry::{create_ticks, Entry};
use solana_ledger::shred::{ use solana_ledger::shred::{
max_entries_per_n_shred, max_ticks_per_n_shreds, ProcessShredsStats, Shred, Shredder, max_entries_per_n_shred, max_ticks_per_n_shreds, ProcessShredsStats, Shred, Shredder,
MAX_DATA_SHREDS_PER_FEC_BLOCK, SHRED_PAYLOAD_SIZE, SIZE_OF_CODING_SHRED_HEADERS, MAX_DATA_SHREDS_PER_FEC_BLOCK, SHRED_PAYLOAD_SIZE, SIZE_OF_CODING_SHRED_HEADERS,

View File

@@ -6,8 +6,9 @@ use crossbeam_channel::{Receiver as CrossbeamReceiver, RecvTimeoutError};
use itertools::Itertools; use itertools::Itertools;
use lru::LruCache; use lru::LruCache;
use retain_mut::RetainMut; use retain_mut::RetainMut;
use solana_entry::entry::hash_transactions;
use solana_gossip::cluster_info::ClusterInfo; use solana_gossip::cluster_info::ClusterInfo;
use solana_ledger::{blockstore_processor::TransactionStatusSender, entry::hash_transactions}; use solana_ledger::blockstore_processor::TransactionStatusSender;
use solana_measure::measure::Measure; use solana_measure::measure::Measure;
use solana_metrics::{inc_new_counter_debug, inc_new_counter_info}; use solana_metrics::{inc_new_counter_debug, inc_new_counter_info};
use solana_perf::{ use solana_perf::{
@@ -23,10 +24,10 @@ use solana_runtime::{
TransactionExecutionResult, TransactionExecutionResult,
}, },
bank_utils, bank_utils,
hashed_transaction::HashedTransaction,
transaction_batch::TransactionBatch, transaction_batch::TransactionBatch,
vote_sender_types::ReplayVoteSender, vote_sender_types::ReplayVoteSender,
}; };
use solana_sdk::hashed_transaction::HashedTransaction;
use solana_sdk::{ use solana_sdk::{
clock::{ clock::{
Slot, DEFAULT_TICKS_PER_SLOT, MAX_PROCESSING_AGE, MAX_TRANSACTION_FORWARDING_DELAY, Slot, DEFAULT_TICKS_PER_SLOT, MAX_PROCESSING_AGE, MAX_TRANSACTION_FORWARDING_DELAY,
@@ -1572,10 +1573,10 @@ mod tests {
use crate::cost_model::CostModel; use crate::cost_model::CostModel;
use crossbeam_channel::unbounded; use crossbeam_channel::unbounded;
use itertools::Itertools; use itertools::Itertools;
use solana_entry::entry::{next_entry, Entry, EntrySlice};
use solana_gossip::cluster_info::Node; use solana_gossip::cluster_info::Node;
use solana_ledger::{ use solana_ledger::{
blockstore::{entries_to_test_shreds, Blockstore}, blockstore::{entries_to_test_shreds, Blockstore},
entry::{next_entry, Entry, EntrySlice},
genesis_utils::{create_genesis_config, GenesisConfigInfo}, genesis_utils::{create_genesis_config, GenesisConfigInfo},
get_tmp_ledger_path, get_tmp_ledger_path,
leader_schedule_cache::LeaderScheduleCache, leader_schedule_cache::LeaderScheduleCache,

View File

@@ -446,10 +446,10 @@ pub fn broadcast_shreds(
pub mod test { pub mod test {
use super::*; use super::*;
use crossbeam_channel::unbounded; use crossbeam_channel::unbounded;
use solana_entry::entry::create_ticks;
use solana_gossip::cluster_info::{ClusterInfo, Node}; use solana_gossip::cluster_info::{ClusterInfo, Node};
use solana_ledger::{ use solana_ledger::{
blockstore::{make_slot_entries, Blockstore}, blockstore::{make_slot_entries, Blockstore},
entry::create_ticks,
genesis_utils::{create_genesis_config, GenesisConfigInfo}, genesis_utils::{create_genesis_config, GenesisConfigInfo},
get_tmp_ledger_path, get_tmp_ledger_path,
shred::{max_ticks_per_n_shreds, ProcessShredsStats, Shredder}, shred::{max_ticks_per_n_shreds, ProcessShredsStats, Shredder},

View File

@@ -1,5 +1,6 @@
use super::*; use super::*;
use solana_ledger::{entry::Entry, shred::Shredder}; use solana_entry::entry::Entry;
use solana_ledger::shred::Shredder;
use solana_runtime::blockhash_queue::BlockhashQueue; use solana_runtime::blockhash_queue::BlockhashQueue;
use solana_sdk::{ use solana_sdk::{
hash::Hash, hash::Hash,

View File

@@ -1,5 +1,5 @@
use super::*; use super::*;
use solana_ledger::entry::Entry; use solana_entry::entry::Entry;
use solana_ledger::shred::Shredder; use solana_ledger::shred::Shredder;
use solana_sdk::hash::Hash; use solana_sdk::hash::Hash;
use solana_sdk::signature::Keypair; use solana_sdk::signature::Keypair;

View File

@@ -1,5 +1,6 @@
use crate::result::Result; use crate::result::Result;
use solana_ledger::{entry::Entry, shred::Shred}; use solana_entry::entry::Entry;
use solana_ledger::shred::Shred;
use solana_poh::poh_recorder::WorkingBankEntry; use solana_poh::poh_recorder::WorkingBankEntry;
use solana_runtime::bank::Bank; use solana_runtime::bank::Bank;
use solana_sdk::clock::Slot; use solana_sdk::clock::Slot;

View File

@@ -5,12 +5,9 @@ use super::{
*, *,
}; };
use crate::{broadcast_stage::broadcast_utils::UnfinishedSlotInfo, cluster_nodes::ClusterNodes}; use crate::{broadcast_stage::broadcast_utils::UnfinishedSlotInfo, cluster_nodes::ClusterNodes};
use solana_ledger::{ use solana_entry::entry::Entry;
entry::Entry, use solana_ledger::shred::{
shred::{ ProcessShredsStats, Shred, Shredder, MAX_DATA_SHREDS_PER_FEC_BLOCK, SHRED_TICK_REFERENCE_MASK,
ProcessShredsStats, Shred, Shredder, MAX_DATA_SHREDS_PER_FEC_BLOCK,
SHRED_TICK_REFERENCE_MASK,
},
}; };
use solana_sdk::{pubkey::Pubkey, signature::Keypair, timing::duration_as_us}; use solana_sdk::{pubkey::Pubkey, signature::Keypair, timing::duration_as_us};
use std::{collections::HashMap, sync::RwLock, time::Duration}; use std::{collections::HashMap, sync::RwLock, time::Duration};
@@ -502,11 +499,11 @@ impl BroadcastRun for StandardBroadcastRun {
#[cfg(test)] #[cfg(test)]
mod test { mod test {
use super::*; use super::*;
use solana_entry::entry::create_ticks;
use solana_gossip::cluster_info::{ClusterInfo, Node}; use solana_gossip::cluster_info::{ClusterInfo, Node};
use solana_ledger::genesis_utils::create_genesis_config; use solana_ledger::genesis_utils::create_genesis_config;
use solana_ledger::{ use solana_ledger::{
blockstore::Blockstore, entry::create_ticks, get_tmp_ledger_path, blockstore::Blockstore, get_tmp_ledger_path, shred::max_ticks_per_n_shreds,
shred::max_ticks_per_n_shreds,
}; };
use solana_runtime::bank::Bank; use solana_runtime::bank::Bank;
use solana_sdk::{ use solana_sdk::{

View File

@@ -1,6 +1,6 @@
use crossbeam_channel::{Receiver, RecvTimeoutError, Sender}; use crossbeam_channel::{Receiver, RecvTimeoutError, Sender};
use solana_entry::entry::Entry;
use solana_ledger::blockstore::{Blockstore, CompletedDataSetInfo}; use solana_ledger::blockstore::{Blockstore, CompletedDataSetInfo};
use solana_ledger::entry::Entry;
use solana_rpc::{max_slots::MaxSlots, rpc_subscriptions::RpcSubscriptions}; use solana_rpc::{max_slots::MaxSlots, rpc_subscriptions::RpcSubscriptions};
use solana_sdk::signature::Signature; use solana_sdk::signature::Signature;
use std::{ use std::{

View File

@@ -23,12 +23,12 @@ use crate::{
window_service::DuplicateSlotReceiver, window_service::DuplicateSlotReceiver,
}; };
use solana_client::rpc_response::SlotUpdate; use solana_client::rpc_response::SlotUpdate;
use solana_entry::entry::VerifyRecyclers;
use solana_gossip::cluster_info::ClusterInfo; use solana_gossip::cluster_info::ClusterInfo;
use solana_ledger::{ use solana_ledger::{
block_error::BlockError, block_error::BlockError,
blockstore::Blockstore, blockstore::Blockstore,
blockstore_processor::{self, BlockstoreProcessorError, TransactionStatusSender}, blockstore_processor::{self, BlockstoreProcessorError, TransactionStatusSender},
entry::VerifyRecyclers,
leader_schedule_cache::LeaderScheduleCache, leader_schedule_cache::LeaderScheduleCache,
}; };
use solana_measure::measure::Measure; use solana_measure::measure::Measure;
@@ -2674,12 +2674,12 @@ mod tests {
vote_simulator::{self, VoteSimulator}, vote_simulator::{self, VoteSimulator},
}; };
use crossbeam_channel::unbounded; use crossbeam_channel::unbounded;
use solana_entry::entry::{self, Entry};
use solana_gossip::{cluster_info::Node, crds::Cursor}; use solana_gossip::{cluster_info::Node, crds::Cursor};
use solana_ledger::{ use solana_ledger::{
blockstore::make_slot_entries, blockstore::make_slot_entries,
blockstore::{entries_to_test_shreds, BlockstoreError}, blockstore::{entries_to_test_shreds, BlockstoreError},
create_new_tmp_ledger, create_new_tmp_ledger,
entry::{self, Entry},
genesis_utils::{create_genesis_config, create_genesis_config_with_leader}, genesis_utils::{create_genesis_config, create_genesis_config_with_leader},
get_tmp_ledger_path, get_tmp_ledger_path,
shred::{ shred::{

View File

@@ -18,6 +18,7 @@ use crate::{
}; };
use crossbeam_channel::{bounded, unbounded}; use crossbeam_channel::{bounded, unbounded};
use rand::{thread_rng, Rng}; use rand::{thread_rng, Rng};
use solana_entry::poh::compute_hash_time_ns;
use solana_gossip::{ use solana_gossip::{
cluster_info::{ cluster_info::{
ClusterInfo, Node, DEFAULT_CONTACT_DEBUG_INTERVAL_MILLIS, ClusterInfo, Node, DEFAULT_CONTACT_DEBUG_INTERVAL_MILLIS,
@@ -33,7 +34,6 @@ use solana_ledger::{
blockstore_processor::{self, TransactionStatusSender}, blockstore_processor::{self, TransactionStatusSender},
leader_schedule::FixedSchedule, leader_schedule::FixedSchedule,
leader_schedule_cache::LeaderScheduleCache, leader_schedule_cache::LeaderScheduleCache,
poh::compute_hash_time_ns,
}; };
use solana_measure::measure::Measure; use solana_measure::measure::Measure;
use solana_metrics::datapoint_info; use solana_metrics::datapoint_info;
@@ -1626,8 +1626,8 @@ mod tests {
fn test_backup_and_clear_blockstore() { fn test_backup_and_clear_blockstore() {
use std::time::Instant; use std::time::Instant;
solana_logger::setup(); solana_logger::setup();
use solana_ledger::get_tmp_ledger_path; use solana_entry::entry;
use solana_ledger::{blockstore, entry}; use solana_ledger::{blockstore, get_tmp_ledger_path};
let blockstore_path = get_tmp_ledger_path!(); let blockstore_path = get_tmp_ledger_path!();
{ {
let blockstore = Blockstore::open(&blockstore_path).unwrap(); let blockstore = Blockstore::open(&blockstore_path).unwrap();

View File

@@ -625,10 +625,10 @@ impl WindowService {
#[cfg(test)] #[cfg(test)]
mod test { mod test {
use super::*; use super::*;
use solana_entry::entry::{create_ticks, Entry};
use solana_gossip::contact_info::ContactInfo; use solana_gossip::contact_info::ContactInfo;
use solana_ledger::{ use solana_ledger::{
blockstore::{make_many_slot_entries, Blockstore}, blockstore::{make_many_slot_entries, Blockstore},
entry::{create_ticks, Entry},
genesis_utils::create_genesis_config_with_leader, genesis_utils::create_genesis_config_with_leader,
get_tmp_ledger_path, get_tmp_ledger_path,
shred::{DataShredHeader, Shredder}, shred::{DataShredHeader, Shredder},

36
entry/Cargo.toml Normal file
View File

@@ -0,0 +1,36 @@
[package]
name = "solana-entry"
version = "1.8.0"
description = "Solana Entry"
authors = ["Solana Maintainers <maintainers@solana.foundation>"]
repository = "https://github.com/solana-labs/solana"
license = "Apache-2.0"
homepage = "https://solana.com/"
documentation = "https://docs.rs/solana-poh"
edition = "2018"
[dependencies]
bincode = "1.3.3"
dlopen = "0.1.8"
dlopen_derive = "0.1.4"
log = "0.4.11"
rand = "0.7.0"
rayon = "1.5.1"
serde = "1.0.126"
solana-measure = { path = "../measure", version = "=1.8.0" }
solana-merkle-tree = { path = "../merkle-tree", version = "=1.8.0" }
solana-metrics = { path = "../metrics", version = "=1.8.0" }
solana-perf = { path = "../perf", version = "=1.8.0" }
solana-rayon-threadlimit = { path = "../rayon-threadlimit", version = "=1.8.0" }
solana-sdk = { path = "../sdk", version = "=1.8.0" }
[dev-dependencies]
matches = "0.1.6"
solana-logger = { path = "../logger", version = "=1.8.0" }
[lib]
crate-type = ["lib"]
name = "solana_entry"
[package.metadata.docs.rs]
targets = ["x86_64-unknown-linux-gnu"]

View File

@@ -17,8 +17,8 @@ use solana_perf::cuda_runtime::PinnedVec;
use solana_perf::perf_libs; use solana_perf::perf_libs;
use solana_perf::recycler::Recycler; use solana_perf::recycler::Recycler;
use solana_rayon_threadlimit::get_thread_count; use solana_rayon_threadlimit::get_thread_count;
use solana_runtime::hashed_transaction::HashedTransaction;
use solana_sdk::hash::Hash; use solana_sdk::hash::Hash;
use solana_sdk::hashed_transaction::HashedTransaction;
use solana_sdk::packet::PACKET_DATA_SIZE; use solana_sdk::packet::PACKET_DATA_SIZE;
use solana_sdk::timing; use solana_sdk::timing;
use solana_sdk::transaction::Transaction; use solana_sdk::transaction::Transaction;

5
entry/src/lib.rs Normal file
View File

@@ -0,0 +1,5 @@
#![allow(clippy::integer_arithmetic)]
pub mod entry;
pub mod poh;
extern crate log;

View File

@@ -18,6 +18,7 @@ serde_json = "1.0.64"
serde_yaml = "0.8.17" serde_yaml = "0.8.17"
solana-clap-utils = { path = "../clap-utils", version = "=1.8.0" } solana-clap-utils = { path = "../clap-utils", version = "=1.8.0" }
solana-cli-config = { path = "../cli-config", version = "=1.8.0" } solana-cli-config = { path = "../cli-config", version = "=1.8.0" }
solana-entry = { path = "../entry", version = "=1.8.0" }
solana-ledger = { path = "../ledger", version = "=1.8.0" } solana-ledger = { path = "../ledger", version = "=1.8.0" }
solana-logger = { path = "../logger", version = "=1.8.0" } solana-logger = { path = "../logger", version = "=1.8.0" }
solana-runtime = { path = "../runtime", version = "=1.8.0" } solana-runtime = { path = "../runtime", version = "=1.8.0" }

View File

@@ -6,10 +6,9 @@ use solana_clap_utils::{
input_parsers::{cluster_type_of, pubkey_of, pubkeys_of, unix_timestamp_from_rfc3339_datetime}, input_parsers::{cluster_type_of, pubkey_of, pubkeys_of, unix_timestamp_from_rfc3339_datetime},
input_validators::{is_pubkey_or_keypair, is_rfc3339_datetime, is_slot, is_valid_percentage}, input_validators::{is_pubkey_or_keypair, is_rfc3339_datetime, is_slot, is_valid_percentage},
}; };
use solana_entry::poh::compute_hashes_per_tick;
use solana_genesis::{genesis_accounts::add_genesis_accounts, Base64Account}; use solana_genesis::{genesis_accounts::add_genesis_accounts, Base64Account};
use solana_ledger::{ use solana_ledger::{blockstore::create_new_ledger, blockstore_db::AccessType};
blockstore::create_new_ledger, blockstore_db::AccessType, poh::compute_hashes_per_tick,
};
use solana_runtime::hardened_unpack::MAX_GENESIS_ARCHIVE_UNPACKED_SIZE; use solana_runtime::hardened_unpack::MAX_GENESIS_ARCHIVE_UNPACKED_SIZE;
use solana_sdk::{ use solana_sdk::{
account::{Account, AccountSharedData, ReadableAccount, WritableAccount}, account::{Account, AccountSharedData, ReadableAccount, WritableAccount},

View File

@@ -28,6 +28,7 @@ serde_bytes = "0.11"
serde_derive = "1.0.103" serde_derive = "1.0.103"
solana-clap-utils = { path = "../clap-utils", version = "=1.8.0" } solana-clap-utils = { path = "../clap-utils", version = "=1.8.0" }
solana-client = { path = "../client", version = "=1.8.0" } solana-client = { path = "../client", version = "=1.8.0" }
solana-entry = { path = "../entry", version = "=1.8.0" }
solana-frozen-abi = { path = "../frozen-abi", version = "=1.8.0" } solana-frozen-abi = { path = "../frozen-abi", version = "=1.8.0" }
solana-frozen-abi-macro = { path = "../frozen-abi/macro", version = "=1.8.0" } solana-frozen-abi-macro = { path = "../frozen-abi/macro", version = "=1.8.0" }
solana-ledger = { path = "../ledger", version = "=1.8.0" } solana-ledger = { path = "../ledger", version = "=1.8.0" }

View File

@@ -287,7 +287,8 @@ impl Sanitize for DuplicateShred {
pub(crate) mod tests { pub(crate) mod tests {
use super::*; use super::*;
use rand::Rng; use rand::Rng;
use solana_ledger::{entry::Entry, shred::Shredder}; use solana_entry::entry::Entry;
use solana_ledger::shred::Shredder;
use solana_sdk::{hash, signature::Keypair, signature::Signer, system_transaction}; use solana_sdk::{hash, signature::Keypair, signature::Signer, system_transaction};
use std::sync::Arc; use std::sync::Arc;

View File

@@ -26,6 +26,7 @@ serde_yaml = "0.8.17"
solana-clap-utils = { path = "../clap-utils", version = "=1.8.0" } solana-clap-utils = { path = "../clap-utils", version = "=1.8.0" }
solana-cli-output = { path = "../cli-output", version = "=1.8.0" } solana-cli-output = { path = "../cli-output", version = "=1.8.0" }
solana-core = { path = "../core", version = "=1.8.0" } solana-core = { path = "../core", version = "=1.8.0" }
solana-entry = { path = "../entry", version = "=1.8.0" }
solana-ledger = { path = "../ledger", version = "=1.8.0" } solana-ledger = { path = "../ledger", version = "=1.8.0" }
solana-logger = { path = "../logger", version = "=1.8.0" } solana-logger = { path = "../logger", version = "=1.8.0" }
solana-measure = { path = "../measure", version = "=1.8.0" } solana-measure = { path = "../measure", version = "=1.8.0" }

View File

@@ -16,7 +16,7 @@ use solana_clap_utils::{
}; };
use solana_core::cost_model::CostModel; use solana_core::cost_model::CostModel;
use solana_core::cost_tracker::CostTracker; use solana_core::cost_tracker::CostTracker;
use solana_ledger::entry::Entry; use solana_entry::entry::Entry;
use solana_ledger::{ use solana_ledger::{
ancestor_iterator::AncestorIterator, ancestor_iterator::AncestorIterator,
bank_forks_utils, bank_forks_utils,

View File

@@ -15,8 +15,6 @@ byteorder = "1.4.3"
chrono = { version = "0.4.11", features = ["serde"] } chrono = { version = "0.4.11", features = ["serde"] }
chrono-humanize = "0.2.1" chrono-humanize = "0.2.1"
crossbeam-channel = "0.5" crossbeam-channel = "0.5"
dlopen_derive = "0.1.4"
dlopen = "0.1.8"
ed25519-dalek = "1.0.1" ed25519-dalek = "1.0.1"
fs_extra = "1.2.0" fs_extra = "1.2.0"
futures = "0.3.15" futures = "0.3.15"
@@ -34,6 +32,7 @@ serde = "1.0.126"
serde_bytes = "0.11.5" serde_bytes = "0.11.5"
sha2 = "0.9.5" sha2 = "0.9.5"
solana-bpf-loader-program = { path = "../programs/bpf_loader", version = "=1.8.0" } solana-bpf-loader-program = { path = "../programs/bpf_loader", version = "=1.8.0" }
solana-entry = { path = "../entry", version = "=1.8.0" }
solana-frozen-abi = { path = "../frozen-abi", version = "=1.8.0" } solana-frozen-abi = { path = "../frozen-abi", version = "=1.8.0" }
solana-frozen-abi-macro = { path = "../frozen-abi/macro", version = "=1.8.0" } solana-frozen-abi-macro = { path = "../frozen-abi/macro", version = "=1.8.0" }
solana-transaction-status = { path = "../transaction-status", version = "=1.8.0" } solana-transaction-status = { path = "../transaction-status", version = "=1.8.0" }

View File

@@ -4,10 +4,10 @@ use crate::{
self, BlockstoreProcessorError, BlockstoreProcessorResult, CacheBlockMetaSender, self, BlockstoreProcessorError, BlockstoreProcessorResult, CacheBlockMetaSender,
ProcessOptions, TransactionStatusSender, ProcessOptions, TransactionStatusSender,
}, },
entry::VerifyRecyclers,
leader_schedule_cache::LeaderScheduleCache, leader_schedule_cache::LeaderScheduleCache,
}; };
use log::*; use log::*;
use solana_entry::entry::VerifyRecyclers;
use solana_runtime::{ use solana_runtime::{
bank_forks::BankForks, bank_forks::BankForks,
snapshot_config::SnapshotConfig, snapshot_config::SnapshotConfig,

View File

@@ -8,7 +8,6 @@ use crate::{
IteratorMode, LedgerColumn, Result, WriteBatch, IteratorMode, LedgerColumn, Result, WriteBatch,
}, },
blockstore_meta::*, blockstore_meta::*,
entry::{create_ticks, Entry},
erasure::ErasureConfig, erasure::ErasureConfig,
leader_schedule_cache::LeaderScheduleCache, leader_schedule_cache::LeaderScheduleCache,
next_slots_iterator::NextSlotsIterator, next_slots_iterator::NextSlotsIterator,
@@ -22,6 +21,7 @@ use rayon::{
ThreadPool, ThreadPool,
}; };
use rocksdb::DBRawIterator; use rocksdb::DBRawIterator;
use solana_entry::entry::{create_ticks, Entry};
use solana_measure::measure::Measure; use solana_measure::measure::Measure;
use solana_metrics::{datapoint_debug, datapoint_error}; use solana_metrics::{datapoint_debug, datapoint_error};
use solana_rayon_threadlimit::get_thread_count; use solana_rayon_threadlimit::get_thread_count;
@@ -3981,7 +3981,6 @@ fn adjust_ulimit_nofile(enforce_ulimit_nofile: bool) -> Result<()> {
pub mod tests { pub mod tests {
use super::*; use super::*;
use crate::{ use crate::{
entry::{next_entry, next_entry_mut},
genesis_utils::{create_genesis_config, GenesisConfigInfo}, genesis_utils::{create_genesis_config, GenesisConfigInfo},
leader_schedule::{FixedSchedule, LeaderSchedule}, leader_schedule::{FixedSchedule, LeaderSchedule},
shred::{max_ticks_per_n_shreds, DataShredHeader}, shred::{max_ticks_per_n_shreds, DataShredHeader},
@@ -3991,6 +3990,7 @@ pub mod tests {
use itertools::Itertools; use itertools::Itertools;
use rand::{seq::SliceRandom, thread_rng}; use rand::{seq::SliceRandom, thread_rng};
use solana_account_decoder::parse_token::UiTokenAmount; use solana_account_decoder::parse_token::UiTokenAmount;
use solana_entry::entry::{next_entry, next_entry_mut};
use solana_runtime::bank::{Bank, RewardType}; use solana_runtime::bank::{Bank, RewardType};
use solana_sdk::{ use solana_sdk::{
hash::{self, hash, Hash}, hash::{self, hash, Hash},

View File

@@ -392,11 +392,9 @@ impl Blockstore {
#[cfg(test)] #[cfg(test)]
pub mod tests { pub mod tests {
use super::*; use super::*;
use crate::{ use crate::{blockstore::tests::make_slot_entries_with_transactions, get_tmp_ledger_path};
blockstore::tests::make_slot_entries_with_transactions, entry::next_entry_mut,
get_tmp_ledger_path,
};
use bincode::serialize; use bincode::serialize;
use solana_entry::entry::next_entry_mut;
use solana_sdk::{ use solana_sdk::{
hash::{hash, Hash}, hash::{hash, Hash},
message::Message, message::Message,

View File

@@ -1,10 +1,6 @@
use crate::{ use crate::{
block_error::BlockError, block_error::BlockError, blockstore::Blockstore, blockstore_db::BlockstoreError,
blockstore::Blockstore, blockstore_meta::SlotMeta, leader_schedule_cache::LeaderScheduleCache,
blockstore_db::BlockstoreError,
blockstore_meta::SlotMeta,
entry::{create_ticks, Entry, EntrySlice, EntryType, EntryVerificationStatus, VerifyRecyclers},
leader_schedule_cache::LeaderScheduleCache,
}; };
use chrono_humanize::{Accuracy, HumanTime, Tense}; use chrono_humanize::{Accuracy, HumanTime, Tense};
use crossbeam_channel::Sender; use crossbeam_channel::Sender;
@@ -12,6 +8,9 @@ use itertools::Itertools;
use log::*; use log::*;
use rand::{seq::SliceRandom, thread_rng}; use rand::{seq::SliceRandom, thread_rng};
use rayon::{prelude::*, ThreadPool}; use rayon::{prelude::*, ThreadPool};
use solana_entry::entry::{
create_ticks, Entry, EntrySlice, EntryType, EntryVerificationStatus, VerifyRecyclers,
};
use solana_measure::measure::Measure; use solana_measure::measure::Measure;
use solana_metrics::{datapoint_error, inc_new_counter_debug}; use solana_metrics::{datapoint_error, inc_new_counter_debug};
use solana_rayon_threadlimit::get_thread_count; use solana_rayon_threadlimit::get_thread_count;
@@ -1305,15 +1304,13 @@ pub fn fill_blockstore_slot_with_ticks(
#[cfg(test)] #[cfg(test)]
pub mod tests { pub mod tests {
use super::*; use super::*;
use crate::{ use crate::genesis_utils::{
entry::{create_ticks, next_entry, next_entry_mut},
genesis_utils::{
create_genesis_config, create_genesis_config_with_leader, GenesisConfigInfo, create_genesis_config, create_genesis_config_with_leader, GenesisConfigInfo,
},
}; };
use crossbeam_channel::unbounded; use crossbeam_channel::unbounded;
use matches::assert_matches; use matches::assert_matches;
use rand::{thread_rng, Rng}; use rand::{thread_rng, Rng};
use solana_entry::entry::{create_ticks, next_entry, next_entry_mut};
use solana_runtime::genesis_utils::{ use solana_runtime::genesis_utils::{
self, create_genesis_config_with_vote_accounts, ValidatorVoteKeypairs, self, create_genesis_config_with_vote_accounts, ValidatorVoteKeypairs,
}; };

View File

@@ -14,14 +14,12 @@ pub mod blockstore_db;
pub mod blockstore_meta; pub mod blockstore_meta;
pub mod blockstore_processor; pub mod blockstore_processor;
pub mod builtins; pub mod builtins;
pub mod entry;
pub mod erasure; pub mod erasure;
pub mod genesis_utils; pub mod genesis_utils;
pub mod leader_schedule; pub mod leader_schedule;
pub mod leader_schedule_cache; pub mod leader_schedule_cache;
pub mod leader_schedule_utils; pub mod leader_schedule_utils;
pub mod next_slots_iterator; pub mod next_slots_iterator;
pub mod poh;
pub mod rooted_slot_iterator; pub mod rooted_slot_iterator;
pub mod shred; pub mod shred;
pub mod sigverify_shreds; pub mod sigverify_shreds;

View File

@@ -49,11 +49,7 @@
//! So, given a) - c), we must restrict data shred's payload length such that the entire coding //! So, given a) - c), we must restrict data shred's payload length such that the entire coding
//! payload can fit into one coding shred / packet. //! payload can fit into one coding shred / packet.
use crate::{ use crate::{blockstore::MAX_DATA_SHREDS_PER_SLOT, erasure::Session};
blockstore::MAX_DATA_SHREDS_PER_SLOT,
entry::{create_ticks, Entry},
erasure::Session,
};
use bincode::config::Options; use bincode::config::Options;
use core::cell::RefCell; use core::cell::RefCell;
use rayon::{ use rayon::{
@@ -62,6 +58,7 @@ use rayon::{
ThreadPool, ThreadPool,
}; };
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
use solana_entry::entry::{create_ticks, Entry};
use solana_measure::measure::Measure; use solana_measure::measure::Measure;
use solana_perf::packet::{limited_deserialize, Packet}; use solana_perf::packet::{limited_deserialize, Packet};
use solana_rayon_threadlimit::get_thread_count; use solana_rayon_threadlimit::get_thread_count;

View File

@@ -1,4 +1,4 @@
use solana_ledger::entry; use solana_entry::entry;
use solana_ledger::{ use solana_ledger::{
blockstore::{self, Blockstore}, blockstore::{self, Blockstore},
get_tmp_ledger_path, get_tmp_ledger_path,

View File

@@ -1,5 +1,5 @@
#![allow(clippy::integer_arithmetic)] #![allow(clippy::integer_arithmetic)]
use solana_ledger::entry::Entry; use solana_entry::entry::Entry;
use solana_ledger::shred::{ use solana_ledger::shred::{
max_entries_per_n_shred, verify_test_data_shred, Shred, Shredder, max_entries_per_n_shred, verify_test_data_shred, Shred, Shredder,
MAX_DATA_SHREDS_PER_FEC_BLOCK, SIZE_OF_DATA_SHRED_PAYLOAD, MAX_DATA_SHREDS_PER_FEC_BLOCK, SIZE_OF_DATA_SHRED_PAYLOAD,

View File

@@ -21,6 +21,7 @@ solana-config-program = { path = "../programs/config", version = "=1.8.0" }
solana-core = { path = "../core", version = "=1.8.0" } solana-core = { path = "../core", version = "=1.8.0" }
solana-client = { path = "../client", version = "=1.8.0" } solana-client = { path = "../client", version = "=1.8.0" }
solana-download-utils = { path = "../download-utils", version = "=1.8.0" } solana-download-utils = { path = "../download-utils", version = "=1.8.0" }
solana-entry = { path = "../entry", version = "=1.8.0" }
solana-faucet = { path = "../faucet", version = "=1.8.0" } solana-faucet = { path = "../faucet", version = "=1.8.0" }
solana-gossip = { path = "../gossip", version = "=1.8.0" } solana-gossip = { path = "../gossip", version = "=1.8.0" }
solana-ledger = { path = "../ledger", version = "=1.8.0" } solana-ledger = { path = "../ledger", version = "=1.8.0" }

View File

@@ -7,6 +7,7 @@ use rand::{thread_rng, Rng};
use rayon::prelude::*; use rayon::prelude::*;
use solana_client::thin_client::create_client; use solana_client::thin_client::create_client;
use solana_core::consensus::VOTE_THRESHOLD_DEPTH; use solana_core::consensus::VOTE_THRESHOLD_DEPTH;
use solana_entry::entry::{Entry, EntrySlice};
use solana_gossip::{ use solana_gossip::{
cluster_info::{self, VALIDATOR_PORT_RANGE}, cluster_info::{self, VALIDATOR_PORT_RANGE},
contact_info::ContactInfo, contact_info::ContactInfo,
@@ -14,10 +15,7 @@ use solana_gossip::{
gossip_error::GossipError, gossip_error::GossipError,
gossip_service::discover_cluster, gossip_service::discover_cluster,
}; };
use solana_ledger::{ use solana_ledger::blockstore::Blockstore;
blockstore::Blockstore,
entry::{Entry, EntrySlice},
};
use solana_sdk::{ use solana_sdk::{
client::SyncClient, client::SyncClient,
clock::{self, Slot, NUM_CONSECUTIVE_LEADER_SLOTS}, clock::{self, Slot, NUM_CONSECUTIVE_LEADER_SLOTS},

View File

@@ -13,7 +13,6 @@ edition = "2018"
[dependencies] [dependencies]
log = "0.4.14" log = "0.4.14"
solana-sdk = { path = "../sdk", version = "=1.8.0" } solana-sdk = { path = "../sdk", version = "=1.8.0" }
solana-metrics = { path = "../metrics", version = "=1.8.0" }
[package.metadata.docs.rs] [package.metadata.docs.rs]
targets = ["x86_64-unknown-linux-gnu"] targets = ["x86_64-unknown-linux-gnu"]

View File

@@ -14,7 +14,7 @@ log = "0.4.14"
rand = "0.7.0" rand = "0.7.0"
rayon = "1.5.1" rayon = "1.5.1"
solana-logger = { path = "../logger", version = "=1.8.0" } solana-logger = { path = "../logger", version = "=1.8.0" }
solana-ledger = { path = "../ledger", version = "=1.8.0" } solana-entry = { path = "../entry", version = "=1.8.0" }
solana-sdk = { path = "../sdk", version = "=1.8.0" } solana-sdk = { path = "../sdk", version = "=1.8.0" }
solana-clap-utils = { path = "../clap-utils", version = "=1.8.0" } solana-clap-utils = { path = "../clap-utils", version = "=1.8.0" }
solana-measure = { path = "../measure", version = "=1.8.0" } solana-measure = { path = "../measure", version = "=1.8.0" }

View File

@@ -1,9 +1,9 @@
#![allow(clippy::integer_arithmetic)] #![allow(clippy::integer_arithmetic)]
use clap::{crate_description, crate_name, value_t, App, Arg}; use clap::{crate_description, crate_name, value_t, App, Arg};
#[cfg(any(target_arch = "x86", target_arch = "x86_64"))] #[cfg(any(target_arch = "x86", target_arch = "x86_64"))]
use solana_ledger::entry::{self, create_ticks, init_poh, EntrySlice, VerifyRecyclers}; use solana_entry::entry::{self, create_ticks, init_poh, EntrySlice, VerifyRecyclers};
#[cfg(not(any(target_arch = "x86", target_arch = "x86_64")))] #[cfg(not(any(target_arch = "x86", target_arch = "x86_64")))]
use solana_ledger::entry::{create_ticks, init_poh, EntrySlice, VerifyRecyclers}; use solana_entry::entry::{create_ticks, init_poh, EntrySlice, VerifyRecyclers};
use solana_measure::measure::Measure; use solana_measure::measure::Measure;
use solana_perf::perf_libs; use solana_perf::perf_libs;
use solana_sdk::hash::hash; use solana_sdk::hash::hash;

View File

@@ -13,6 +13,7 @@ edition = "2018"
core_affinity = "0.5.10" core_affinity = "0.5.10"
crossbeam-channel = "0.5" crossbeam-channel = "0.5"
log = "0.4.14" log = "0.4.14"
solana-entry = { path = "../entry", version = "=1.8.0" }
solana-ledger = { path = "../ledger", version = "=1.8.0" } solana-ledger = { path = "../ledger", version = "=1.8.0" }
solana-measure = { path = "../measure", version = "=1.8.0" } solana-measure = { path = "../measure", version = "=1.8.0" }
solana-metrics = { path = "../metrics", version = "=1.8.0" } solana-metrics = { path = "../metrics", version = "=1.8.0" }

View File

@@ -4,7 +4,7 @@
extern crate test; extern crate test;
use { use {
solana_ledger::poh::Poh, solana_entry::poh::Poh,
solana_poh::poh_service::DEFAULT_HASHES_PER_BATCH, solana_poh::poh_service::DEFAULT_HASHES_PER_BATCH,
solana_sdk::hash::Hash, solana_sdk::hash::Hash,
std::sync::{ std::sync::{

View File

@@ -2,7 +2,7 @@
extern crate test; extern crate test;
use { use {
solana_ledger::entry::{next_entry_mut, Entry, EntrySlice}, solana_entry::entry::{next_entry_mut, Entry, EntrySlice},
solana_sdk::{ solana_sdk::{
hash::{hash, Hash}, hash::{hash, Hash},
signature::{Keypair, Signer}, signature::{Keypair, Signer},

View File

@@ -17,9 +17,8 @@ use {
unbounded, Receiver as CrossbeamReceiver, RecvTimeoutError, Sender as CrossbeamSender, unbounded, Receiver as CrossbeamReceiver, RecvTimeoutError, Sender as CrossbeamSender,
}, },
log::*, log::*,
solana_ledger::{ solana_entry::{entry::Entry, poh::Poh},
blockstore::Blockstore, entry::Entry, leader_schedule_cache::LeaderScheduleCache, poh::Poh, solana_ledger::{blockstore::Blockstore, leader_schedule_cache::LeaderScheduleCache},
},
solana_runtime::bank::Bank, solana_runtime::bank::Bank,
solana_sdk::{ solana_sdk::{
clock::NUM_CONSECUTIVE_LEADER_SLOTS, hash::Hash, poh_config::PohConfig, pubkey::Pubkey, clock::NUM_CONSECUTIVE_LEADER_SLOTS, hash::Hash, poh_config::PohConfig, pubkey::Pubkey,

View File

@@ -4,7 +4,7 @@ use {
crate::poh_recorder::{PohRecorder, Record}, crate::poh_recorder::{PohRecorder, Record},
crossbeam_channel::Receiver, crossbeam_channel::Receiver,
log::*, log::*,
solana_ledger::poh::Poh, solana_entry::poh::Poh,
solana_measure::measure::Measure, solana_measure::measure::Measure,
solana_sdk::poh_config::PohConfig, solana_sdk::poh_config::PohConfig,
std::{ std::{

View File

@@ -3177,7 +3177,6 @@ name = "solana-measure"
version = "1.8.0" version = "1.8.0"
dependencies = [ dependencies = [
"log", "log",
"solana-metrics",
"solana-sdk", "solana-sdk",
] ]

View File

@@ -29,6 +29,7 @@ serde_derive = "1.0.103"
serde_json = "1.0.56" serde_json = "1.0.56"
solana-account-decoder = { path = "../account-decoder", version = "=1.8.0" } solana-account-decoder = { path = "../account-decoder", version = "=1.8.0" }
solana-client = { path = "../client", version = "=1.8.0" } solana-client = { path = "../client", version = "=1.8.0" }
solana-entry = { path = "../entry", version = "=1.8.0" }
solana-faucet = { path = "../faucet", version = "=1.8.0" } solana-faucet = { path = "../faucet", version = "=1.8.0" }
solana-gossip = { path = "../gossip", version = "=1.8.0" } solana-gossip = { path = "../gossip", version = "=1.8.0" }
solana-ledger = { path = "../ledger", version = "=1.8.0" } solana-ledger = { path = "../ledger", version = "=1.8.0" }

View File

@@ -3852,12 +3852,12 @@ pub fn create_test_transactions_and_populate_blockstore(
let success_tx = let success_tx =
solana_sdk::system_transaction::transfer(mint_keypair, &keypair1.pubkey(), 2, blockhash); solana_sdk::system_transaction::transfer(mint_keypair, &keypair1.pubkey(), 2, blockhash);
let success_signature = success_tx.signatures[0]; let success_signature = success_tx.signatures[0];
let entry_1 = solana_ledger::entry::next_entry(&blockhash, 1, vec![success_tx]); let entry_1 = solana_entry::entry::next_entry(&blockhash, 1, vec![success_tx]);
// Failed transaction, InstructionError // Failed transaction, InstructionError
let ix_error_tx = let ix_error_tx =
solana_sdk::system_transaction::transfer(keypair2, &keypair3.pubkey(), 10, blockhash); solana_sdk::system_transaction::transfer(keypair2, &keypair3.pubkey(), 10, blockhash);
let ix_error_signature = ix_error_tx.signatures[0]; let ix_error_signature = ix_error_tx.signatures[0];
let entry_2 = solana_ledger::entry::next_entry(&entry_1.hash, 1, vec![ix_error_tx]); let entry_2 = solana_entry::entry::next_entry(&entry_1.hash, 1, vec![ix_error_tx]);
// Failed transaction // Failed transaction
let fail_tx = solana_sdk::system_transaction::transfer( let fail_tx = solana_sdk::system_transaction::transfer(
mint_keypair, mint_keypair,
@@ -3865,7 +3865,7 @@ pub fn create_test_transactions_and_populate_blockstore(
2, 2,
Hash::default(), Hash::default(),
); );
let entry_3 = solana_ledger::entry::next_entry(&entry_2.hash, 1, vec![fail_tx]); let entry_3 = solana_entry::entry::next_entry(&entry_2.hash, 1, vec![fail_tx]);
let mut entries = vec![entry_1, entry_2, entry_3]; let mut entries = vec![entry_1, entry_2, entry_3];
let shreds = solana_ledger::blockstore::entries_to_test_shreds( let shreds = solana_ledger::blockstore::entries_to_test_shreds(

View File

@@ -44,7 +44,6 @@ use crate::{
blockhash_queue::BlockhashQueue, blockhash_queue::BlockhashQueue,
builtins::{self, ActivationType}, builtins::{self, ActivationType},
epoch_stakes::{EpochStakes, NodeVoteAccounts}, epoch_stakes::{EpochStakes, NodeVoteAccounts},
hashed_transaction::{HashedTransaction, HashedTransactionSlice},
inline_spl_token_v2_0, inline_spl_token_v2_0,
instruction_recorder::InstructionRecorder, instruction_recorder::InstructionRecorder,
log_collector::LogCollector, log_collector::LogCollector,
@@ -85,6 +84,7 @@ use solana_sdk::{
genesis_config::{ClusterType, GenesisConfig}, genesis_config::{ClusterType, GenesisConfig},
hard_forks::HardForks, hard_forks::HardForks,
hash::{extend_and_hash, hashv, Hash}, hash::{extend_and_hash, hashv, Hash},
hashed_transaction::{HashedTransaction, HashedTransactionSlice},
incinerator, incinerator,
inflation::Inflation, inflation::Inflation,
instruction::CompiledInstruction, instruction::CompiledInstruction,

View File

@@ -1,10 +1,9 @@
use crate::{ use crate::{
bank::{Bank, TransactionResults}, bank::{Bank, TransactionResults},
genesis_utils::{self, GenesisConfigInfo, ValidatorVoteKeypairs}, genesis_utils::{self, GenesisConfigInfo, ValidatorVoteKeypairs},
hashed_transaction::HashedTransaction,
vote_sender_types::ReplayVoteSender, vote_sender_types::ReplayVoteSender,
}; };
use solana_sdk::{pubkey::Pubkey, signature::Signer}; use solana_sdk::{hashed_transaction::HashedTransaction, pubkey::Pubkey, signature::Signer};
use solana_vote_program::vote_transaction; use solana_vote_program::vote_transaction;
pub fn setup_bank_and_vote_pubkeys(num_vote_accounts: usize, stake: u64) -> (Bank, Vec<Pubkey>) { pub fn setup_bank_and_vote_pubkeys(num_vote_accounts: usize, stake: u64) -> (Bank, Vec<Pubkey>) {

View File

@@ -20,7 +20,6 @@ pub mod contains;
pub mod epoch_stakes; pub mod epoch_stakes;
pub mod genesis_utils; pub mod genesis_utils;
pub mod hardened_unpack; pub mod hardened_unpack;
pub mod hashed_transaction;
pub mod inline_spl_token_v2_0; pub mod inline_spl_token_v2_0;
pub mod instruction_recorder; pub mod instruction_recorder;
pub mod loader_utils; pub mod loader_utils;

View File

@@ -1,5 +1,5 @@
use crate::bank::Bank; use crate::bank::Bank;
use crate::hashed_transaction::HashedTransaction; use solana_sdk::hashed_transaction::HashedTransaction;
use solana_sdk::transaction::{Result, Transaction}; use solana_sdk::transaction::{Result, Transaction};
use std::borrow::Cow; use std::borrow::Cow;

View File

@@ -1,4 +1,6 @@
use solana_sdk::{hash::Hash, transaction::Transaction}; #![cfg(feature = "full")]
use crate::{hash::Hash, transaction::Transaction};
use std::borrow::Cow; use std::borrow::Cow;
/// Transaction and the hash of its message /// Transaction and the hash of its message

View File

@@ -26,6 +26,7 @@ pub mod feature_set;
pub mod genesis_config; pub mod genesis_config;
pub mod hard_forks; pub mod hard_forks;
pub mod hash; pub mod hash;
pub mod hashed_transaction;
pub mod inflation; pub mod inflation;
pub mod keyed_account; pub mod keyed_account;
pub mod log; pub mod log;

View File

@@ -33,6 +33,7 @@ solana-cli-config = { path = "../cli-config", version = "=1.8.0" }
solana-client = { path = "../client", version = "=1.8.0" } solana-client = { path = "../client", version = "=1.8.0" }
solana-core = { path = "../core", version = "=1.8.0" } solana-core = { path = "../core", version = "=1.8.0" }
solana-download-utils = { path = "../download-utils", version = "=1.8.0" } solana-download-utils = { path = "../download-utils", version = "=1.8.0" }
solana-entry = { path = "../entry", version = "=1.8.0" }
solana-faucet = { path = "../faucet", version = "=1.8.0" } solana-faucet = { path = "../faucet", version = "=1.8.0" }
solana-genesis-utils = { path = "../genesis-utils", version = "=1.8.0" } solana-genesis-utils = { path = "../genesis-utils", version = "=1.8.0" }
solana-gossip = { path = "../gossip", version = "=1.8.0" } solana-gossip = { path = "../gossip", version = "=1.8.0" }

View File

@@ -2620,7 +2620,7 @@ pub fn main() {
solana_perf::perf_libs::init_cuda(); solana_perf::perf_libs::init_cuda();
enable_recycler_warming(); enable_recycler_warming();
} }
solana_ledger::entry::init_poh(); solana_entry::entry::init_poh();
solana_runtime::snapshot_utils::remove_tmp_snapshot_archives(&snapshot_output_dir); solana_runtime::snapshot_utils::remove_tmp_snapshot_archives(&snapshot_output_dir);
let identity_keypair = Arc::new(identity_keypair); let identity_keypair = Arc::new(identity_keypair);