"""Configuration management using Pydantic Settings.""" from pydantic_settings import BaseSettings from functools import lru_cache class Settings(BaseSettings): """Application settings loaded from environment variables.""" # Service Info service_name: str = "mve-incrementables-parser" service_version: str = "1.0.0" # Authentication auth_username: str auth_password_hash: str jwt_secret: str jwt_expires_minutes: int = 60 jwt_algorithm: str = "HS256" # File Upload max_file_mb: int = 10 # Logging log_level: str = "INFO" # Redis/Celery redis_url: str = "redis://localhost:6379/0" celery_broker_url: str = "redis://localhost:6379/0" celery_result_backend: str = "redis://localhost:6379/0" class Config: env_file = ".env" case_sensitive = False @lru_cache() def get_settings() -> Settings: """Get cached settings instance.""" return Settings()