diff --git a/bumiworker/bumiworker/tasks.py b/bumiworker/bumiworker/tasks.py index 28ed4406e..28e11f0ff 100644 --- a/bumiworker/bumiworker/tasks.py +++ b/bumiworker/bumiworker/tasks.py @@ -561,13 +561,15 @@ def _execute(self): class SetFailedNotifiable(SetFailed): def send_failure_service_email(self, organization_id, reason, failed_modules): + _, org = self.rest_cl.organization_get(organization_id) recipient = self.config_cl.optscale_error_email_recipient() if not recipient: return subject = '[%s] Bumi task execution failed' % self.config_cl.public_ip() template_params = { 'texts': { - 'organization': {'id': organization_id}, + 'organization': {'id': organization_id, + 'name': org['name']}, 'reason': reason, 'failed_modules': failed_modules }} diff --git a/herald/modules/email_generator/templates/bumi_module_execution_failed.html b/herald/modules/email_generator/templates/bumi_module_execution_failed.html index 223725d77..fccdac6fb 100644 --- a/herald/modules/email_generator/templates/bumi_module_execution_failed.html +++ b/herald/modules/email_generator/templates/bumi_module_execution_failed.html @@ -1,526 +1,480 @@ - - - - - - - - - - - - - - - - - - - - - - -
- -
-
- - - -
- -
- - - -
- - +
+ + + + + - - - - - - -
- - - - - - -
- -
- - - - - - - - - - - - - - - - - - - {{#texts.failed_modules}} - - - - - {{/texts.failed_modules}} - -
-
-

Some recommendation modules have failed on {{etcd.control_panel_link}}

-
-
-
-

Organization name: {{texts.organization.name}}

-
-
-
-

Organization id: {{texts.organization.id}}

-
-
-
-

Failed modules:

-
-
-
-

Module

-
-
-
-

Error

-
-
-
- {{module}} -
-
-
- {{error}} -
-
-
- -
-
- -
- - - - - - -
- -
- - - - - - -
-
-

This email was generated automatically, you don’t need to reply to it.

-
-
-
- -
-
- -
- - - - - - -
- -
- - - - - - -
-
-

{{texts.copyright}} -

-

Hystax Inc. All Rights - Reserved -

-
-
-
- -
- - - - - - -
- -
-
- -
- - - - - - -
-
-

{{texts.address}} -

-
-
-
- -
-
- -
- - - -
- -
- - - -
- - - - - - - -
- - - - - - -
- - - -
-
- - - - - - - -
- - - - - - -
- - - -
-
- - - - -
- - + + +
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + {{#texts.failed_modules}} + + + + + + + + {{/texts.failed_modules}} + + + + + + - - - - - - + + diff --git a/herald/modules/email_generator/templates/bumi_task_execution_failed.html b/herald/modules/email_generator/templates/bumi_task_execution_failed.html index 3d0889098..5a046e8e7 100644 --- a/herald/modules/email_generator/templates/bumi_task_execution_failed.html +++ b/herald/modules/email_generator/templates/bumi_task_execution_failed.html @@ -1,526 +1,524 @@ - - - - - - - - - - - - - - - - - - - - - - -
- -
-
- - - -
- -
- - - -
- - +
+ + + + + - - - - - - -
- - - - - - -
- -
- - - - - - - - - - - - - - - - - - - {{#texts.failed_modules}} - - - - - {{/texts.failed_modules}} - -
-
-

Bumi task execution failed on {{etcd.control_panel_link}}

-
-
-
-

Organization id: {{texts.organization.id}}

-
-
-
-

Reason: {{texts.reason}}

-
-
-
-

Failed modules:

-
-
-
-

Module

-
-
-
-

Error

-
-
-
- {{module}} -
-
-
- {{error}} -
-
-
- -
-
- -
- - - - - - -
- -
- - - - - - -
-
-

This email was generated automatically, you don’t need to reply to it.

-
-
-
- -
-
- -
- - - - - - -
- -
- - - - - - -
-
-

{{texts.copyright}} -

-

Hystax Inc. All Rights - Reserved -

-
-
-
- -
- - - - - - -
- -
-
- -
- - - - - - -
-
-

{{texts.address}} -

-
-
-
- -
-
- -
- - - -
- -
- - - -
- - - - - - - -
- - - - - - -
- - - -
-
- - - - - - - -
- - - - - - -
- - - -
-
- - - - -
- - + + +
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + {{#texts.failed_modules}} + + + + + + + + {{/texts.failed_modules}} + + + + + + - - - - - - + + diff --git a/herald/send_templates.py b/herald/send_templates.py index 1e23e5fd1..08fe06e43 100755 --- a/herald/send_templates.py +++ b/herald/send_templates.py @@ -918,8 +918,10 @@ 'template_params': { 'texts': { 'organization': { - 'id': '6946211f-47ff-43a3-a9a3-3e5f57d52415' + 'id': '6946211f-47ff-43a3-a9a3-3e5f57d52415', + 'name': 'Czar Pictures' }, + "reason": "Timeout error while process task 1639638582 (organization_id b74f3ca6-c392-4bcb-96b3-2ffaa0281810)", 'failed_modules': [{ 'module': 'instance_migration', 'error': 'Timeout error while process task 1639638582 ' diff --git a/rest_api/live_demo.tar.xz b/rest_api/live_demo.tar.xz index 8ef836ee6..649f69f9f 100644 Binary files a/rest_api/live_demo.tar.xz and b/rest_api/live_demo.tar.xz differ