diff --git a/Cargo.lock b/Cargo.lock index f72fdc655..c28817994 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -2393,7 +2393,7 @@ dependencies = [ [[package]] name = "kaspa-addresses" -version = "0.14.1" +version = "0.14.3" dependencies = [ "borsh", "criterion", @@ -2410,7 +2410,7 @@ dependencies = [ [[package]] name = "kaspa-addressmanager" -version = "0.14.1" +version = "0.14.3" dependencies = [ "borsh", "igd-next", @@ -2433,14 +2433,14 @@ dependencies = [ [[package]] name = "kaspa-alloc" -version = "0.14.1" +version = "0.14.3" dependencies = [ "mimalloc", ] [[package]] name = "kaspa-bip32" -version = "0.14.1" +version = "0.14.3" dependencies = [ "borsh", "bs58", @@ -2467,7 +2467,7 @@ dependencies = [ [[package]] name = "kaspa-cli" -version = "0.14.1" +version = "0.14.3" dependencies = [ "async-trait", "borsh", @@ -2514,7 +2514,7 @@ dependencies = [ [[package]] name = "kaspa-connectionmanager" -version = "0.14.1" +version = "0.14.3" dependencies = [ "duration-string", "futures-util", @@ -2531,7 +2531,7 @@ dependencies = [ [[package]] name = "kaspa-consensus" -version = "0.14.1" +version = "0.14.3" dependencies = [ "arc-swap", "async-channel 2.3.1", @@ -2574,7 +2574,7 @@ dependencies = [ [[package]] name = "kaspa-consensus-client" -version = "0.14.1" +version = "0.14.3" dependencies = [ "ahash", "cfg-if 1.0.0", @@ -2602,7 +2602,7 @@ dependencies = [ [[package]] name = "kaspa-consensus-core" -version = "0.14.1" +version = "0.14.3" dependencies = [ "async-trait", "bincode", @@ -2640,7 +2640,7 @@ dependencies = [ [[package]] name = "kaspa-consensus-notify" -version = "0.14.1" +version = "0.14.3" dependencies = [ "async-channel 2.3.1", "cfg-if 1.0.0", @@ -2659,7 +2659,7 @@ dependencies = [ [[package]] name = "kaspa-consensus-wasm" -version = "0.14.1" +version = "0.14.3" dependencies = [ "cfg-if 1.0.0", "faster-hex", @@ -2683,7 +2683,7 @@ dependencies = [ [[package]] name = "kaspa-consensusmanager" -version = "0.14.1" +version = "0.14.3" dependencies = [ "duration-string", "futures", @@ -2701,7 +2701,7 @@ dependencies = [ [[package]] name = "kaspa-core" -version = "0.14.1" +version = "0.14.3" dependencies = [ "cfg-if 1.0.0", "ctrlc", @@ -2719,7 +2719,7 @@ dependencies = [ [[package]] name = "kaspa-daemon" -version = "0.14.1" +version = "0.14.3" dependencies = [ "async-trait", "borsh", @@ -2741,7 +2741,7 @@ dependencies = [ [[package]] name = "kaspa-database" -version = "0.14.1" +version = "0.14.3" dependencies = [ "bincode", "enum-primitive-derive", @@ -2763,7 +2763,7 @@ dependencies = [ [[package]] name = "kaspa-grpc-client" -version = "0.14.1" +version = "0.14.3" dependencies = [ "async-channel 2.3.1", "async-stream", @@ -2794,7 +2794,7 @@ dependencies = [ [[package]] name = "kaspa-grpc-core" -version = "0.14.1" +version = "0.14.3" dependencies = [ "async-channel 2.3.1", "async-stream", @@ -2823,7 +2823,7 @@ dependencies = [ [[package]] name = "kaspa-grpc-server" -version = "0.14.1" +version = "0.14.3" dependencies = [ "async-channel 2.3.1", "async-stream", @@ -2858,7 +2858,7 @@ dependencies = [ [[package]] name = "kaspa-hashes" -version = "0.14.1" +version = "0.14.3" dependencies = [ "blake2b_simd", "borsh", @@ -2879,7 +2879,7 @@ dependencies = [ [[package]] name = "kaspa-index-core" -version = "0.14.1" +version = "0.14.3" dependencies = [ "async-channel 2.3.1", "async-trait", @@ -2898,7 +2898,7 @@ dependencies = [ [[package]] name = "kaspa-index-processor" -version = "0.14.1" +version = "0.14.3" dependencies = [ "async-channel 2.3.1", "async-trait", @@ -2926,7 +2926,7 @@ dependencies = [ [[package]] name = "kaspa-math" -version = "0.14.1" +version = "0.14.3" dependencies = [ "borsh", "criterion", @@ -2947,14 +2947,14 @@ dependencies = [ [[package]] name = "kaspa-merkle" -version = "0.14.1" +version = "0.14.3" dependencies = [ "kaspa-hashes", ] [[package]] name = "kaspa-metrics-core" -version = "0.14.1" +version = "0.14.3" dependencies = [ "async-trait", "borsh", @@ -2970,7 +2970,7 @@ dependencies = [ [[package]] name = "kaspa-mining" -version = "0.14.1" +version = "0.14.3" dependencies = [ "criterion", "futures-util", @@ -2997,7 +2997,7 @@ dependencies = [ [[package]] name = "kaspa-mining-errors" -version = "0.14.1" +version = "0.14.3" dependencies = [ "kaspa-consensus-core", "thiserror", @@ -3005,7 +3005,7 @@ dependencies = [ [[package]] name = "kaspa-muhash" -version = "0.14.1" +version = "0.14.3" dependencies = [ "criterion", "kaspa-hashes", @@ -3018,7 +3018,7 @@ dependencies = [ [[package]] name = "kaspa-notify" -version = "0.14.1" +version = "0.14.3" dependencies = [ "async-channel 2.3.1", "async-trait", @@ -3054,7 +3054,7 @@ dependencies = [ [[package]] name = "kaspa-p2p-flows" -version = "0.14.1" +version = "0.14.3" dependencies = [ "async-trait", "chrono", @@ -3085,7 +3085,7 @@ dependencies = [ [[package]] name = "kaspa-p2p-lib" -version = "0.14.1" +version = "0.14.3" dependencies = [ "borsh", "ctrlc", @@ -3116,7 +3116,7 @@ dependencies = [ [[package]] name = "kaspa-perf-monitor" -version = "0.14.1" +version = "0.14.3" dependencies = [ "kaspa-core", "log", @@ -3128,7 +3128,7 @@ dependencies = [ [[package]] name = "kaspa-pow" -version = "0.14.1" +version = "0.14.3" dependencies = [ "criterion", "js-sys", @@ -3144,7 +3144,7 @@ dependencies = [ [[package]] name = "kaspa-rpc-core" -version = "0.14.1" +version = "0.14.3" dependencies = [ "async-channel 2.3.1", "async-trait", @@ -3186,7 +3186,7 @@ dependencies = [ [[package]] name = "kaspa-rpc-macros" -version = "0.14.1" +version = "0.14.3" dependencies = [ "convert_case 0.6.0", "proc-macro-error", @@ -3198,7 +3198,7 @@ dependencies = [ [[package]] name = "kaspa-rpc-service" -version = "0.14.1" +version = "0.14.3" dependencies = [ "async-trait", "kaspa-addresses", @@ -3227,7 +3227,7 @@ dependencies = [ [[package]] name = "kaspa-testing-integration" -version = "0.14.1" +version = "0.14.3" dependencies = [ "async-channel 2.3.1", "async-trait", @@ -3287,7 +3287,7 @@ dependencies = [ [[package]] name = "kaspa-txscript" -version = "0.14.1" +version = "0.14.3" dependencies = [ "blake2b_simd", "borsh", @@ -3319,7 +3319,7 @@ dependencies = [ [[package]] name = "kaspa-txscript-errors" -version = "0.14.1" +version = "0.14.3" dependencies = [ "secp256k1", "thiserror", @@ -3327,7 +3327,7 @@ dependencies = [ [[package]] name = "kaspa-utils" -version = "0.14.1" +version = "0.14.3" dependencies = [ "arc-swap", "async-channel 2.3.1", @@ -3363,7 +3363,7 @@ dependencies = [ [[package]] name = "kaspa-utils-tower" -version = "0.14.1" +version = "0.14.3" dependencies = [ "cfg-if 1.0.0", "futures", @@ -3377,7 +3377,7 @@ dependencies = [ [[package]] name = "kaspa-utxoindex" -version = "0.14.1" +version = "0.14.3" dependencies = [ "futures", "kaspa-consensus", @@ -3398,7 +3398,7 @@ dependencies = [ [[package]] name = "kaspa-wallet" -version = "0.14.1" +version = "0.14.3" dependencies = [ "async-std", "async-trait", @@ -3410,7 +3410,7 @@ dependencies = [ [[package]] name = "kaspa-wallet-cli-wasm" -version = "0.14.1" +version = "0.14.3" dependencies = [ "async-trait", "js-sys", @@ -3424,7 +3424,7 @@ dependencies = [ [[package]] name = "kaspa-wallet-core" -version = "0.14.1" +version = "0.14.3" dependencies = [ "aes", "ahash", @@ -3505,7 +3505,7 @@ dependencies = [ [[package]] name = "kaspa-wallet-keys" -version = "0.14.1" +version = "0.14.3" dependencies = [ "async-trait", "borsh", @@ -3538,7 +3538,7 @@ dependencies = [ [[package]] name = "kaspa-wallet-macros" -version = "0.14.1" +version = "0.14.3" dependencies = [ "convert_case 0.5.0", "proc-macro-error", @@ -3551,7 +3551,7 @@ dependencies = [ [[package]] name = "kaspa-wallet-pskt" -version = "0.14.1" +version = "0.14.3" dependencies = [ "bincode", "derive_builder", @@ -3578,7 +3578,7 @@ dependencies = [ [[package]] name = "kaspa-wasm" -version = "0.14.1" +version = "0.14.3" dependencies = [ "cfg-if 1.0.0", "js-sys", @@ -3606,7 +3606,7 @@ dependencies = [ [[package]] name = "kaspa-wasm-core" -version = "0.14.1" +version = "0.14.3" dependencies = [ "faster-hex", "hexplay", @@ -3617,7 +3617,7 @@ dependencies = [ [[package]] name = "kaspa-wrpc-client" -version = "0.14.1" +version = "0.14.3" dependencies = [ "async-std", "async-trait", @@ -3652,7 +3652,7 @@ dependencies = [ [[package]] name = "kaspa-wrpc-example-subscriber" -version = "0.14.1" +version = "0.14.3" dependencies = [ "ctrlc", "futures", @@ -3667,7 +3667,7 @@ dependencies = [ [[package]] name = "kaspa-wrpc-proxy" -version = "0.14.1" +version = "0.14.3" dependencies = [ "async-trait", "clap 4.5.16", @@ -3686,7 +3686,7 @@ dependencies = [ [[package]] name = "kaspa-wrpc-server" -version = "0.14.1" +version = "0.14.3" dependencies = [ "async-trait", "borsh", @@ -3714,7 +3714,7 @@ dependencies = [ [[package]] name = "kaspa-wrpc-wasm" -version = "0.14.1" +version = "0.14.3" dependencies = [ "ahash", "async-std", @@ -3743,7 +3743,7 @@ dependencies = [ [[package]] name = "kaspad" -version = "0.14.1" +version = "0.14.3" dependencies = [ "async-channel 2.3.1", "cfg-if 1.0.0", @@ -5188,7 +5188,7 @@ dependencies = [ [[package]] name = "rothschild" -version = "0.14.1" +version = "0.14.3" dependencies = [ "async-channel 2.3.1", "clap 4.5.16", @@ -5665,7 +5665,7 @@ dependencies = [ [[package]] name = "simpa" -version = "0.14.1" +version = "0.14.3" dependencies = [ "async-channel 2.3.1", "cfg-if 1.0.0", diff --git a/Cargo.toml b/Cargo.toml index 9be64f39e..0a6799e43 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -62,7 +62,7 @@ members = [ [workspace.package] rust-version = "1.80.0" -version = "0.14.1" +version = "0.14.3" authors = ["Kaspa developers"] license = "ISC" repository = "https://github.com/kaspanet/rusty-kaspa" @@ -79,61 +79,61 @@ include = [ ] [workspace.dependencies] -# kaspa-testing-integration = { version = "0.14.1", path = "testing/integration" } -kaspa-addresses = { version = "0.14.1", path = "crypto/addresses" } -kaspa-addressmanager = { version = "0.14.1", path = "components/addressmanager" } -kaspa-bip32 = { version = "0.14.1", path = "wallet/bip32" } -kaspa-cli = { version = "0.14.1", path = "cli" } -kaspa-connectionmanager = { version = "0.14.1", path = "components/connectionmanager" } -kaspa-consensus = { version = "0.14.1", path = "consensus" } -kaspa-consensus-core = { version = "0.14.1", path = "consensus/core" } -kaspa-consensus-client = { version = "0.14.1", path = "consensus/client" } -kaspa-consensus-notify = { version = "0.14.1", path = "consensus/notify" } -kaspa-consensus-wasm = { version = "0.14.1", path = "consensus/wasm" } -kaspa-consensusmanager = { version = "0.14.1", path = "components/consensusmanager" } -kaspa-core = { version = "0.14.1", path = "core" } -kaspa-daemon = { version = "0.14.1", path = "daemon" } -kaspa-database = { version = "0.14.1", path = "database" } -kaspa-grpc-client = { version = "0.14.1", path = "rpc/grpc/client" } -kaspa-grpc-core = { version = "0.14.1", path = "rpc/grpc/core" } -kaspa-grpc-server = { version = "0.14.1", path = "rpc/grpc/server" } -kaspa-hashes = { version = "0.14.1", path = "crypto/hashes" } -kaspa-index-core = { version = "0.14.1", path = "indexes/core" } -kaspa-index-processor = { version = "0.14.1", path = "indexes/processor" } -kaspa-math = { version = "0.14.1", path = "math" } -kaspa-merkle = { version = "0.14.1", path = "crypto/merkle" } -kaspa-metrics-core = { version = "0.14.1", path = "metrics/core" } -kaspa-mining = { version = "0.14.1", path = "mining" } -kaspa-mining-errors = { version = "0.14.1", path = "mining/errors" } -kaspa-muhash = { version = "0.14.1", path = "crypto/muhash" } -kaspa-notify = { version = "0.14.1", path = "notify" } -kaspa-p2p-flows = { version = "0.14.1", path = "protocol/flows" } -kaspa-p2p-lib = { version = "0.14.1", path = "protocol/p2p" } -kaspa-perf-monitor = { version = "0.14.1", path = "metrics/perf_monitor" } -kaspa-pow = { version = "0.14.1", path = "consensus/pow" } -kaspa-rpc-core = { version = "0.14.1", path = "rpc/core" } -kaspa-rpc-macros = { version = "0.14.1", path = "rpc/macros" } -kaspa-rpc-service = { version = "0.14.1", path = "rpc/service" } -kaspa-txscript = { version = "0.14.1", path = "crypto/txscript" } -kaspa-txscript-errors = { version = "0.14.1", path = "crypto/txscript/errors" } -kaspa-utils = { version = "0.14.1", path = "utils" } -kaspa-utils-tower = { version = "0.14.1", path = "utils/tower" } -kaspa-utxoindex = { version = "0.14.1", path = "indexes/utxoindex" } -kaspa-wallet = { version = "0.14.1", path = "wallet/native" } -kaspa-wallet-cli-wasm = { version = "0.14.1", path = "wallet/wasm" } -kaspa-wallet-keys = { version = "0.14.1", path = "wallet/keys" } -kaspa-wallet-pskt = { version = "0.14.1", path = "wallet/pskt" } -kaspa-wallet-core = { version = "0.14.1", path = "wallet/core" } -kaspa-wallet-macros = { version = "0.14.1", path = "wallet/macros" } -kaspa-wasm = { version = "0.14.1", path = "wasm" } -kaspa-wasm-core = { version = "0.14.1", path = "wasm/core" } -kaspa-wrpc-client = { version = "0.14.1", path = "rpc/wrpc/client" } -kaspa-wrpc-proxy = { version = "0.14.1", path = "rpc/wrpc/proxy" } -kaspa-wrpc-server = { version = "0.14.1", path = "rpc/wrpc/server" } -kaspa-wrpc-wasm = { version = "0.14.1", path = "rpc/wrpc/wasm" } -kaspa-wrpc-example-subscriber = { version = "0.14.1", path = "rpc/wrpc/examples/subscriber" } -kaspad = { version = "0.14.1", path = "kaspad" } -kaspa-alloc = { version = "0.14.1", path = "utils/alloc" } +# kaspa-testing-integration = { version = "0.14.3", path = "testing/integration" } +kaspa-addresses = { version = "0.14.3", path = "crypto/addresses" } +kaspa-addressmanager = { version = "0.14.3", path = "components/addressmanager" } +kaspa-bip32 = { version = "0.14.3", path = "wallet/bip32" } +kaspa-cli = { version = "0.14.3", path = "cli" } +kaspa-connectionmanager = { version = "0.14.3", path = "components/connectionmanager" } +kaspa-consensus = { version = "0.14.3", path = "consensus" } +kaspa-consensus-core = { version = "0.14.3", path = "consensus/core" } +kaspa-consensus-client = { version = "0.14.3", path = "consensus/client" } +kaspa-consensus-notify = { version = "0.14.3", path = "consensus/notify" } +kaspa-consensus-wasm = { version = "0.14.3", path = "consensus/wasm" } +kaspa-consensusmanager = { version = "0.14.3", path = "components/consensusmanager" } +kaspa-core = { version = "0.14.3", path = "core" } +kaspa-daemon = { version = "0.14.3", path = "daemon" } +kaspa-database = { version = "0.14.3", path = "database" } +kaspa-grpc-client = { version = "0.14.3", path = "rpc/grpc/client" } +kaspa-grpc-core = { version = "0.14.3", path = "rpc/grpc/core" } +kaspa-grpc-server = { version = "0.14.3", path = "rpc/grpc/server" } +kaspa-hashes = { version = "0.14.3", path = "crypto/hashes" } +kaspa-index-core = { version = "0.14.3", path = "indexes/core" } +kaspa-index-processor = { version = "0.14.3", path = "indexes/processor" } +kaspa-math = { version = "0.14.3", path = "math" } +kaspa-merkle = { version = "0.14.3", path = "crypto/merkle" } +kaspa-metrics-core = { version = "0.14.3", path = "metrics/core" } +kaspa-mining = { version = "0.14.3", path = "mining" } +kaspa-mining-errors = { version = "0.14.3", path = "mining/errors" } +kaspa-muhash = { version = "0.14.3", path = "crypto/muhash" } +kaspa-notify = { version = "0.14.3", path = "notify" } +kaspa-p2p-flows = { version = "0.14.3", path = "protocol/flows" } +kaspa-p2p-lib = { version = "0.14.3", path = "protocol/p2p" } +kaspa-perf-monitor = { version = "0.14.3", path = "metrics/perf_monitor" } +kaspa-pow = { version = "0.14.3", path = "consensus/pow" } +kaspa-rpc-core = { version = "0.14.3", path = "rpc/core" } +kaspa-rpc-macros = { version = "0.14.3", path = "rpc/macros" } +kaspa-rpc-service = { version = "0.14.3", path = "rpc/service" } +kaspa-txscript = { version = "0.14.3", path = "crypto/txscript" } +kaspa-txscript-errors = { version = "0.14.3", path = "crypto/txscript/errors" } +kaspa-utils = { version = "0.14.3", path = "utils" } +kaspa-utils-tower = { version = "0.14.3", path = "utils/tower" } +kaspa-utxoindex = { version = "0.14.3", path = "indexes/utxoindex" } +kaspa-wallet = { version = "0.14.3", path = "wallet/native" } +kaspa-wallet-cli-wasm = { version = "0.14.3", path = "wallet/wasm" } +kaspa-wallet-keys = { version = "0.14.3", path = "wallet/keys" } +kaspa-wallet-pskt = { version = "0.14.3", path = "wallet/pskt" } +kaspa-wallet-core = { version = "0.14.3", path = "wallet/core" } +kaspa-wallet-macros = { version = "0.14.3", path = "wallet/macros" } +kaspa-wasm = { version = "0.14.3", path = "wasm" } +kaspa-wasm-core = { version = "0.14.3", path = "wasm/core" } +kaspa-wrpc-client = { version = "0.14.3", path = "rpc/wrpc/client" } +kaspa-wrpc-proxy = { version = "0.14.3", path = "rpc/wrpc/proxy" } +kaspa-wrpc-server = { version = "0.14.3", path = "rpc/wrpc/server" } +kaspa-wrpc-wasm = { version = "0.14.3", path = "rpc/wrpc/wasm" } +kaspa-wrpc-example-subscriber = { version = "0.14.3", path = "rpc/wrpc/examples/subscriber" } +kaspad = { version = "0.14.3", path = "kaspad" } +kaspa-alloc = { version = "0.14.3", path = "utils/alloc" } # external aes = "0.8.3" diff --git a/mining/src/mempool/config.rs b/mining/src/mempool/config.rs index b90a36577..04407b411 100644 --- a/mining/src/mempool/config.rs +++ b/mining/src/mempool/config.rs @@ -5,7 +5,7 @@ pub(crate) const DEFAULT_MEMPOOL_SIZE_LIMIT: usize = 1_000_000_000; pub(crate) const DEFAULT_MAXIMUM_BUILD_BLOCK_TEMPLATE_ATTEMPTS: u64 = 5; pub(crate) const DEFAULT_TRANSACTION_EXPIRE_INTERVAL_SECONDS: u64 = 24 * 60 * 60; -pub(crate) const DEFAULT_TRANSACTION_EXPIRE_SCAN_INTERVAL_SECONDS: u64 = 10; +pub(crate) const DEFAULT_TRANSACTION_EXPIRE_SCAN_INTERVAL_SECONDS: u64 = 60; pub(crate) const DEFAULT_ACCEPTED_TRANSACTION_EXPIRE_INTERVAL_SECONDS: u64 = 120; pub(crate) const DEFAULT_ACCEPTED_TRANSACTION_EXPIRE_SCAN_INTERVAL_SECONDS: u64 = 10; pub(crate) const DEFAULT_ORPHAN_EXPIRE_INTERVAL_SECONDS: u64 = 60; @@ -124,7 +124,9 @@ impl Config { } pub fn apply_ram_scale(mut self, ram_scale: f64) -> Self { - self.maximum_transaction_count = (self.maximum_transaction_count as f64 * ram_scale.min(1.0)) as usize; // Allow only scaling down + // Allow only scaling down + self.maximum_transaction_count = (self.maximum_transaction_count as f64 * ram_scale.min(1.0)) as usize; + self.mempool_size_limit = (self.mempool_size_limit as f64 * ram_scale.min(1.0)) as usize; self }