aboutsummaryrefslogtreecommitdiff
path: root/rumba/elements
diff options
context:
space:
mode:
authorMarco Capitani <m.capitani@nextworks.it>2018-06-06 10:30:34 +0200
committerMarco Capitani <m.capitani@nextworks.it>2018-06-06 12:15:27 +0200
commit28d34549ecf3a6fe5dde672569b7e8f5e05f1a5e (patch)
treef3a1d2ca96f06860b44f725c50d94678625af49b /rumba/elements
parenta1f2be15e901981efbaeaacc9a331342c1d3911e (diff)
downloadrumba-28d34549ecf3a6fe5dde672569b7e8f5e05f1a5e.tar.gz
rumba-28d34549ecf3a6fe5dde672569b7e8f5e05f1a5e.zip
sb + our: add server_decorator functionality and our decorator
Diffstat (limited to 'rumba/elements')
-rw-r--r--rumba/elements/experimentation.py10
1 files changed, 9 insertions, 1 deletions
diff --git a/rumba/elements/experimentation.py b/rumba/elements/experimentation.py
index 8f3f40a..0f734f8 100644
--- a/rumba/elements/experimentation.py
+++ b/rumba/elements/experimentation.py
@@ -117,7 +117,8 @@ class Experiment(object):
log_dir=None,
prototype_logs=None,
enrollment_strategy='minimal',
- dt_strategy='full-mesh'):
+ dt_strategy='full-mesh',
+ server_decorator=None):
"""
:param testbed: The testbed of the experiment.
:param nodes: The list of nodes in the experiment.
@@ -127,10 +128,17 @@ class Experiment(object):
:param prototype_logs: Where the prototype logs its output.
:param enrollment_strategy: Can be 'full-mesh', 'minimal' or 'manual'.
:param dt_strategy: For data flows, 'full-mesh', 'minimal' or 'manual'.
+ :param server_decorator: a decorator function which will be applied to
+ storyboard.server instances when using
+ this prototype
"""
if nodes is None:
nodes = list()
self.nodes = nodes
+ if server_decorator is None:
+ def server_decorator(server):
+ return server
+ self.server_decorator = server_decorator
self.git_repo = git_repo
self.git_branch = git_branch
self.testbed = testbed