diff --git a/basedosdados_api/api/v1/tasks.py b/basedosdados_api/api/v1/tasks.py index 0ba09a25..6ab33ce0 100644 --- a/basedosdados_api/api/v1/tasks.py +++ b/basedosdados_api/api/v1/tasks.py @@ -3,14 +3,14 @@ from huey.contrib.djhuey import periodic_task from loguru import logger -from basedosdados_api.api.v1.admin import _update_table_metadata +from basedosdados_api.api.v1.admin import update_table_metadata @periodic_task(crontab(minute="*/10")) -def every_ten_mins(): +def every_ten_mins_task(): logger.info("Am I alive between these periods?") @periodic_task(crontab(day_of_week="0", hour="0", minute="0")) -def update_table_metadata(): - _update_table_metadata() +def update_table_metadata_task(): + update_table_metadata() diff --git a/basedosdados_api/settings/base.py b/basedosdados_api/settings/base.py index 9d7b421c..9113690a 100644 --- a/basedosdados_api/settings/base.py +++ b/basedosdados_api/settings/base.py @@ -413,8 +413,7 @@ "results": True, "immediate": False, "connection": { - # TODO: Delete this hotfix - "host": getenv("REDIS_URL", "localhost").replace("http://", ""), + "host": getenv("REDIS_URL", "localhost"), "port": getenv("REDIS_PORT", 6379), "db": getenv("REDIS_DB", 1), "read_timeout": 1,