diff --git a/config.env b/config.env index 7633de5..b22e762 100644 --- a/config.env +++ b/config.env @@ -14,6 +14,7 @@ GRPC_SURUGAYA_SCRAPPER_PORT=9070 TASK_RETRY_COUNT=3 TASK_RETRY_MINUTES=5 +TASK_TIMEOUT_MINUTES=5 ORIGIN_SURUGAYA_ENABLED=false ORIGIN_MANDARAKE_ENABLED=false diff --git a/config/config.go b/config/config.go index b19ffe0..f2ebaa4 100644 --- a/config/config.go +++ b/config/config.go @@ -29,6 +29,7 @@ type GrpcConfig struct { type TasksConfig struct { RetryCount int RetryMinutes int + TaskTimeout int } type OriginEnabled struct { @@ -62,6 +63,7 @@ func NewConfig() *Config { TasksCfg: TasksConfig{ RetryCount: getEnvInt("TASK_RETRY_COUNT", 3), RetryMinutes: getEnvInt("TASK_RETRY_MINUTES", 5), + TaskTimeout: getEnvInt("TASK_TIMEOUT_MINUTES", 5), }, OriginEnabled: OriginEnabled{