зеркало из https://github.com/mozilla/treeherder.git
Bug 1302529 - Add store_pulse_resultsets to bin script
This commit is contained in:
Родитель
5408342cd2
Коммит
9c508817fd
|
@ -14,7 +14,7 @@ if [ ! -f $LOGFILE ]; then
|
|||
touch $LOGFILE
|
||||
fi
|
||||
|
||||
exec newrelic-admin run-program celery -A treeherder worker -Q buildapi_pending,buildapi_running,buildapi_4hr,store_pulse_jobs \
|
||||
exec newrelic-admin run-program celery -A treeherder worker -Q buildapi_pending,buildapi_running,buildapi_4hr,store_pulse_jobs,store_pulse_resultsets \
|
||||
--concurrency=5 --logfile=$LOGFILE -l INFO \
|
||||
--maxtasksperchild=20 -n buildapi.%h
|
||||
|
||||
|
|
|
@ -24,16 +24,18 @@ class ResultsetLoader:
|
|||
transformed_data = transformer.transform(repo.name)
|
||||
|
||||
with JobsModel(repo.name) as jobs_model:
|
||||
logger.info("Storing resultset for {} {}".format(
|
||||
logger.info("Storing resultset for {} {} {}".format(
|
||||
repo.name,
|
||||
transformer.repo_url))
|
||||
transformer.repo_url,
|
||||
transformer.branch))
|
||||
jobs_model.store_result_set_data([transformed_data])
|
||||
|
||||
except ObjectDoesNotExist:
|
||||
newrelic.agent.record_custom_event("skip_unknown_repository",
|
||||
message_body["details"])
|
||||
logger.warn("Skipping unsupported repo: {}".format(
|
||||
transformer.repo_url))
|
||||
logger.warn("Skipping unsupported repo: {} {}".format(
|
||||
transformer.repo_url,
|
||||
transformer.branch))
|
||||
except Exception as ex:
|
||||
newrelic.agent.record_exception(exc=ex)
|
||||
logger.exception("Error transforming resultset", exc_info=ex)
|
||||
|
|
Загрузка…
Ссылка в новой задаче