1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
//! # Stratum Apps - SV2 Application Utilities
//!
//! This crate consolidates the essential utilities needed for building Stratum V2 applications.
//! It combines the functionality from the original separate utility crates into a single,
//! well-organized library with feature-based compilation.
//!
//! ## Features
//!
//! ### Core Features
//! - `network` - High-level networking utilities (enabled by default)
//! - `fallback-coordinator` - Runtime fallback coordination helpers (enabled by default)
//! - `config` - Configuration management helpers (enabled by default)
//! - `payout` - Shared payout-mode parsing and coinbase-output distribution helpers
//! - `monitoring` - HTTP and Prometheus monitoring helpers (optional)
//! - `asic-rs-telemetry` - Optional miner telemetry helpers powered by `asic-rs`
//! - `std` - Standard-library support for key and random utilities (enabled by default)
//! - `core` - Re-export and enable `stratum-core`
//! - `bitcoin-core-sv2` - Re-export and enable `bitcoin_core_sv2`
//!
//! ### Role-Specific Feature Bundles
//! - `pool` - Everything needed for pool applications
//! - `jd_client` - Everything needed for JD client applications
//! - `jd_server` - Configuration helpers and Bitcoin Core IPC runtime APIs for JD server
//! applications
//! - `translator` - Everything needed for translator applications (includes SV1 and payout helpers)
//! - `mining_device` - Configuration helpers for mining device applications
//!
//! ## Modules
//!
//! - [`network_helpers`] - High-level networking utilities for SV2 connections
//! - [`config_helpers`] - Configuration management and parsing utilities
//! - [`payout`] - Payout-mode parsing and coinbase-output construction/verification helpers
/// Re-export all the modules from `stratum_core`
pub use stratum_core;
/// Re-export all the modules from `bitcoin_core_sv2`
pub use bitcoin_core_sv2;
/// High-level networking utilities for SV2 connections
///
/// Provides connection management, encrypted streams, and protocol handling.
/// Originally from the `network_helpers_sv2` crate.
/// Configuration management helpers
///
/// Utilities for parsing configuration files, handling coinbase outputs,
/// and setting up logging. Originally from the `config_helpers_sv2` crate.
/// Custom Mutex
///
/// A wrapper around std::sync::Mutex
/// Key utilities for cryptographic operations
///
/// Provides Secp256k1 key management, serialization/deserialization, and signature services.
/// Supports both standard and no_std environments.
/// Utility methods used in apps.
/// Channel monitoring - expose channel data via HTTP JSON APIs
// Task orchestrator used in SRI apps.
/// Template provider type
///
/// Provides the type of template provider that will be used.
/// Creates a CoinbaseOutputConstraints message from a list of coinbase outputs
/// Shared payout-mode parsing and coinbase-output distribution helpers.
/// Fallback coordinator
/// Share synchronous primitives
/// Shared async channel cleanup helpers.