[toml] remove js_job_timeout/js_id_timeout as there aren't used

parent ae6685ad
...@@ -79,9 +79,7 @@ convertConfigs ini@(Ini.GargConfig { .. }) iniMail nlpConfig connInfo = ...@@ -79,9 +79,7 @@ convertConfigs ini@(Ini.GargConfig { .. }) iniMail nlpConfig connInfo =
, _f_searx_url = _gc_frame_searx_url , _f_searx_url = _gc_frame_searx_url
, _f_istex_url = _gc_frame_istex_url } , _f_istex_url = _gc_frame_istex_url }
, _gc_jobs = CTypes.JobsConfig { _jc_max_docs_parsers = _gc_max_docs_parsers , _gc_jobs = CTypes.JobsConfig { _jc_max_docs_parsers = _gc_max_docs_parsers
, _jc_max_docs_scrapers = _gc_max_docs_scrapers , _jc_max_docs_scrapers = _gc_max_docs_scrapers }
, _jc_js_job_timeout = _gc_js_job_timeout
, _jc_js_id_timeout = _gc_js_id_timeout }
, _gc_apis = CTypes.APIsConfig { _ac_epo_api_url = _gc_epo_api_url , _gc_apis = CTypes.APIsConfig { _ac_epo_api_url = _gc_epo_api_url
, _ac_scrapyd_url } , _ac_scrapyd_url }
, _gc_worker = WorkerSettings { _wsDefinitions = [ wd ] , _gc_worker = WorkerSettings { _wsDefinitions = [ wd ]
......
...@@ -89,10 +89,6 @@ istex_url = URL_TO_CHANGE ...@@ -89,10 +89,6 @@ istex_url = URL_TO_CHANGE
max_docs_parsers = 4000 max_docs_parsers = 4000
max_docs_scrapers = 4000 max_docs_scrapers = 4000
# in seconds
js_job_timeout = 6000
js_id_timeout = 6000
[database] [database]
# PostgreSQL access # PostgreSQL access
......
...@@ -153,9 +153,6 @@ newEnv logger config dispatcher = do ...@@ -153,9 +153,6 @@ newEnv logger config dispatcher = do
let !nodeStory_env = mkNodeStoryEnv let !nodeStory_env = mkNodeStoryEnv
-- secret <- Jobs.genSecret -- secret <- Jobs.genSecret
-- let jobs_settings = (Jobs.defaultJobSettings 1 secret)
-- & Jobs.l_jsJobTimeout .~ (fromIntegral $ config_env ^. hasConfig ^. gc_jobs . jc_js_job_timeout)
-- & Jobs.l_jsIDTimeout .~ (fromIntegral $ config_env ^. hasConfig ^. gc_jobs . jc_js_id_timeout)
!_env_jwt_settings <- jwtSettings (_gc_secrets config) !_env_jwt_settings <- jwtSettings (_gc_secrets config)
......
...@@ -41,8 +41,6 @@ module Gargantext.Core.Config.Types ...@@ -41,8 +41,6 @@ module Gargantext.Core.Config.Types
, JobsConfig(..) , JobsConfig(..)
, jc_max_docs_parsers , jc_max_docs_parsers
, jc_max_docs_scrapers , jc_max_docs_scrapers
, jc_js_job_timeout
, jc_js_id_timeout
, MicroServicesSettings(..) , MicroServicesSettings(..)
, NotificationsConfig(..) , NotificationsConfig(..)
, JWKFile(..) , JWKFile(..)
...@@ -290,24 +288,19 @@ jwtSettings (SecretsConfig { _s_jwk_file = JWKFile jwkFile }) = do ...@@ -290,24 +288,19 @@ jwtSettings (SecretsConfig { _s_jwk_file = JWKFile jwkFile }) = do
data JobsConfig = data JobsConfig =
JobsConfig { _jc_max_docs_parsers :: !Integer JobsConfig { _jc_max_docs_parsers :: !Integer
, _jc_max_docs_scrapers :: !Integer , _jc_max_docs_scrapers :: !Integer }
, _jc_js_job_timeout :: !Integer
, _jc_js_id_timeout :: !Integer }
deriving (Generic, Show) deriving (Generic, Show)
instance FromValue JobsConfig where instance FromValue JobsConfig where
fromValue = parseTableFromValue $ do fromValue = parseTableFromValue $ do
_jc_max_docs_parsers <- reqKey "max_docs_parsers" _jc_max_docs_parsers <- reqKey "max_docs_parsers"
_jc_max_docs_scrapers <- reqKey "max_docs_scrapers" _jc_max_docs_scrapers <- reqKey "max_docs_scrapers"
_jc_js_job_timeout <- reqKey "js_job_timeout"
_jc_js_id_timeout <- reqKey "js_id_timeout"
return $ JobsConfig { .. } return $ JobsConfig { .. }
instance ToValue JobsConfig where instance ToValue JobsConfig where
toValue = defaultTableToValue toValue = defaultTableToValue
instance ToTable JobsConfig where instance ToTable JobsConfig where
toTable (JobsConfig { .. }) = table [ "max_docs_parsers" .= _jc_max_docs_parsers toTable (JobsConfig { .. }) =
, "max_docs_scrapers" .= _jc_max_docs_scrapers table [ "max_docs_parsers" .= _jc_max_docs_parsers
, "js_job_timeout" .= _jc_js_job_timeout , "max_docs_scrapers" .= _jc_max_docs_scrapers ]
, "js_id_timeout" .= _jc_js_id_timeout ]
makeLenses ''JobsConfig makeLenses ''JobsConfig
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment