- Introduced `service_config.py` to manage configuration loading, validation, and schema management, enhancing modularity and security. - Created a `ServiceConfig` class for handling configuration with robust error handling and default values. - Refactored `DataCollectionService` to utilize the new `ServiceConfig`, streamlining configuration management and improving readability. - Added a `CollectorFactory` to encapsulate collector creation logic, promoting separation of concerns. - Updated `CollectorManager` and related components to align with the new architecture, ensuring better maintainability. - Enhanced logging practices across the service for improved monitoring and debugging. These changes significantly improve the architecture and maintainability of the data collection service, aligning with project standards for modularity and performance.
28 lines
841 B
Python
28 lines
841 B
Python
"""
|
|
Data collection and processing package for the Crypto Trading Bot Platform.
|
|
|
|
This package contains modules for collecting market data from various exchanges,
|
|
processing and validating the data, and storing it in the database.
|
|
"""
|
|
|
|
from .base_collector import (
|
|
BaseDataCollector, DataCollectorError
|
|
)
|
|
from .collector.collector_state_telemetry import CollectorStatus
|
|
from .common.ohlcv_data import OHLCVData, DataValidationError
|
|
from .common.data_types import DataType, MarketDataPoint
|
|
from .collector_manager import CollectorManager
|
|
from .collector_types import ManagerStatus, CollectorConfig
|
|
|
|
__all__ = [
|
|
'BaseDataCollector',
|
|
'DataCollectorError',
|
|
'DataValidationError',
|
|
'DataType',
|
|
'CollectorStatus',
|
|
'MarketDataPoint',
|
|
'OHLCVData',
|
|
'CollectorManager',
|
|
'ManagerStatus',
|
|
'CollectorConfig'
|
|
] |