diff options
author | ahothan <ahothan@cisco.com> | 2018-03-25 00:46:25 -0700 |
---|---|---|
committer | ahothan <ahothan@cisco.com> | 2018-03-25 00:46:25 -0700 |
commit | aea0c395c0eb20b34a289aa4ed0f3f023e9f57b2 (patch) | |
tree | b31f5d10ed5e9c08e7bf48745eced583a8daf60c | |
parent | 42b8c6bee8e2f64c53b86ceba76210645b10da69 (diff) |
[NFVBENCH-77] Config plugin misses config options coming from REST requests
Pass latest config to get_run_spec()
Change-Id: I169f482faa0ba016d266db006da45e3fe0bb4331
Signed-off-by: ahothan <ahothan@cisco.com>
-rw-r--r-- | nfvbench/config_plugin.py | 6 | ||||
-rw-r--r-- | nfvbench/nfvbench.py | 2 |
2 files changed, 4 insertions, 4 deletions
diff --git a/nfvbench/config_plugin.py b/nfvbench/config_plugin.py index 78c2ebb..f6654eb 100644 --- a/nfvbench/config_plugin.py +++ b/nfvbench/config_plugin.py @@ -49,7 +49,7 @@ class ConfigPluginBase(object): """Returns OpenStack specs for host.""" @abc.abstractmethod - def get_run_spec(self, openstack_spec): + def get_run_spec(self, config, openstack_spec): """Returns RunSpec for given platform.""" @abc.abstractmethod @@ -81,9 +81,9 @@ class ConfigPlugin(ConfigPluginBase): """Returns OpenStack specs for host.""" return specs.OpenStackSpec() - def get_run_spec(self, openstack_spec): + def get_run_spec(self, config, openstack_spec): """Returns RunSpec for given platform.""" - return specs.RunSpec(self.config.no_vswitch_access, openstack_spec) + return specs.RunSpec(config.no_vswitch_access, openstack_spec) def validate_config(self, config, openstack_spec): pass diff --git a/nfvbench/nfvbench.py b/nfvbench/nfvbench.py index bf6e5d0..5899652 100644 --- a/nfvbench/nfvbench.py +++ b/nfvbench/nfvbench.py @@ -68,7 +68,7 @@ class NFVBench(object): sys.stdout.flush() def setup(self): - self.specs.set_run_spec(self.config_plugin.get_run_spec(self.specs.openstack)) + self.specs.set_run_spec(self.config_plugin.get_run_spec(self.config, self.specs.openstack)) self.chain_runner = ChainRunner(self.config, self.clients, self.cred, |