Moved do_execute method to AuditHandler class

Both Continuous and Oneshot audits made same action in
do_execute, so it's a good idea to move it to the base
class

TrivialFix

Change-Id: Ic0353f010509ce45f94126e4db0e629417128ded
This commit is contained in:
Egor Panfilov
2018-04-22 17:17:53 +03:00
parent 5b70c28047
commit ad1593bb36
3 changed files with 9 additions and 10 deletions

View File

@@ -74,6 +74,13 @@ class AuditHandler(BaseAuditHandler):
def strategy_context(self):
return self._strategy_context
def do_execute(self, audit, request_context):
# execute the strategy
solution = self.strategy_context.execute_strategy(
audit, request_context)
return solution
def do_schedule(self, request_context, audit, solution):
try:
notifications.audit.send_action_notification(