mirror of
https://github.com/ARM-software/workload-automation.git
synced 2025-09-02 11:22:41 +01:00
Expose context in OP initialize and finalize
Expose the context to the initialize and finalize functions for Output Processors. This was found to be necessary for the upcoming PostgreSQL Output Processor.
This commit is contained in:
committed by
Marc Bonnici
parent
4c4fd2a267
commit
718f2c1c90
@@ -40,10 +40,10 @@ class OutputProcessor(Plugin):
|
||||
msg = 'Instrument "{}" is required by {}, but is not installed.'
|
||||
raise ConfigError(msg.format(instrument, self.name))
|
||||
|
||||
def initialize(self):
|
||||
def initialize(self, context):
|
||||
pass
|
||||
|
||||
def finalize(self):
|
||||
def finalize(self, context):
|
||||
pass
|
||||
|
||||
|
||||
@@ -104,13 +104,13 @@ class ProcessorManager(object):
|
||||
for proc in self.processors:
|
||||
proc.validate()
|
||||
|
||||
def initialize(self):
|
||||
def initialize(self, context):
|
||||
for proc in self.processors:
|
||||
proc.initialize()
|
||||
proc.initialize(context)
|
||||
|
||||
def finalize(self):
|
||||
def finalize(self, context):
|
||||
for proc in self.processors:
|
||||
proc.finalize()
|
||||
proc.finalize(context)
|
||||
|
||||
def process_job_output(self, context):
|
||||
self.do_for_each_proc('process_job_output', 'Processing using "{}"',
|
||||
|
Reference in New Issue
Block a user