- Removed lock-free atomic counters from ProofTaskMetrics and replaced them with direct method calls for recording blinded node counts.
- Updated storage and account worker loops to utilize the new metrics recording methods, enhancing clarity and maintainability.
- Simplified the ProofTaskManagerHandle by removing unnecessary metrics fields, streamlining the overall structure.
- Updated the code to utilize ProofTaskManagerHandle for spawning proof workers instead of the deprecated spawn_proof_workers function.
- This change enhances code clarity and maintainability by consolidating the worker management logic within the ProofTaskManagerHandle struct.
- Removed the `clamp_worker_count` function and replaced its logic with direct usage of `max` in the setter methods for storage and account worker counts.
- This change enhances code clarity and reduces unnecessary function overhead while ensuring the minimum worker count is enforced.
- Removed redundant helper functions for error conversion in ProofTaskTrieNodeProvider.
- Simplified error handling by directly mapping errors to SparseTrieError, improving code clarity and maintainability.
- Updated the error conversion helper function in ProofTaskTrieNodeProvider to directly wrap the ProviderError, enhancing clarity and maintainability.
- This change simplifies the error handling logic within the trie_node method.
- Updated the ProofTaskMetrics struct to derive Default, removing the manual implementation of the default method.
- This change enhances code clarity and reduces boilerplate, while maintaining the same functionality.
- Merged separate storage and account proof task handles into a single proof task handle for improved code clarity and maintainability.
- Updated related methods to utilize the consolidated handle, streamlining the management of proof tasks.
- Introduced a `clamp_worker_count` function to centralize the logic for enforcing the minimum worker count.
- Updated setter methods in `TreeConfig` to utilize the new clamping function, improving code readability and maintainability.
- Introduced helper functions to streamline error conversion from ProviderError and channel receive errors to SparseTrieError.
- Enhanced readability and maintainability of the trie_node method by reducing repetitive error handling code.
- Added a debug assertion to ensure active_handles does not underflow when dropping a ProofTaskManagerHandle.
- Implemented metrics recording to flush before exit when the last handle is dropped, enhancing monitoring capabilities.
- Added a constant `MIN_WORKER_COUNT` to enforce a minimum number of workers for storage and account proof tasks.
- Updated `default_storage_worker_count` and `default_account_worker_count` functions to utilize the new minimum constraint.
- Enhanced setter methods in `TreeConfig` to ensure worker counts do not fall below the minimum.
- Modified command-line argument parsing to validate worker counts against the minimum requirement.
- Replaced the ProofTaskManager with a new spawn_proof_workers function for better clarity and maintainability.
- Updated related code to utilize the new function, simplifying the worker spawning process.
- Enhanced metrics tracking for storage and account proof requests, ensuring thread-safe operations.
- Improved error handling and code structure across proof task implementations.
- Removed the generic Factory type from MultiProofConfig and related structs, streamlining their definitions and improving code clarity.
- Updated methods to reflect the removal of the Factory type, enhancing maintainability.
- Adjusted the implementation of PendingMultiproofTask and its associated methods to eliminate unnecessary type parameters, simplifying the codebase.
- Eliminated the Factory type definition from the proof tests, simplifying the code structure.
- This change contributes to improved clarity and maintainability of the test implementation.
- Removed the Factory type parameter from the ParallelProof struct, streamlining its definition and implementation.
- Updated the constructor and related methods to reflect this change, enhancing code clarity and maintainability.
- Eliminated unused PhantomData field, reducing complexity in the struct's design.
- an account worker / loop
- a storage worker / loop
- streamline worker spawning functions in ProofTaskManager
- Consolidated worker spawning logic by renaming and simplifying the `spawn_worker_pool` function to `spawn_storage_workers` and `spawn_account_workers`, enhancing clarity and maintainability.
- Removed the `WorkerType` enum and associated logic, as the worker type is now inferred from the context, reducing complexity.
- Updated comments to better describe the purpose and parameters of the new functions, improving code documentation.
- Introduced `AccountMultiproofParams` struct to encapsulate parameters for building account multiproofs, reducing the number of arguments in the `build_account_multiproof_with_storage_roots` function.
- Updated the `account_worker_loop` to use the new struct, improving code readability and maintainability.
- Introduced `storage_worker_count` and `account_worker_count` fields in `EngineArgs` to allow configuration of the number of workers in the Tokio blocking pool.
- Updated the `tree_config` method to incorporate these new fields, enhancing flexibility in managing proof worker resources.
- Updated CLI documentation to reflect the new configuration options for improved user guidance.