calculate stdout download length using the ORM, not raw SQL

This commit is contained in:
Ryan Petrello
2018-01-02 11:05:10 -05:00
parent 35b8e40d3c
commit 2bd656e61d
5 changed files with 33 additions and 10 deletions

View File

@@ -29,6 +29,7 @@ from awx.main.fields import (
)
from awx.main.managers import HostManager
from awx.main.models.base import * # noqa
from awx.main.models.events import InventoryUpdateEvent
from awx.main.models.unified_jobs import * # noqa
from awx.main.models.mixins import ResourceMixin, TaskManagerInventoryUpdateMixin
from awx.main.models.notifications import (
@@ -1590,6 +1591,10 @@ class InventoryUpdate(UnifiedJob, InventorySourceOptions, JobNotificationMixin,
self.inventory_source.source_project.get_project_path(check_if_exists=False),
self.source_path)
@property
def event_class(self):
return InventoryUpdateEvent
@property
def task_impact(self):
return 50