diff options
Diffstat (limited to 'rumba/storyboard.py')
-rw-r--r-- | rumba/storyboard.py | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/rumba/storyboard.py b/rumba/storyboard.py index 56be7e0..beadf91 100644 --- a/rumba/storyboard.py +++ b/rumba/storyboard.py @@ -1035,6 +1035,24 @@ class StoryBoard(_SBEntity): logger.debug('Log list is:\n%s', logs_list) node.fetch_files(logs_list, dst_dir) + def schedule_export_dif_bandwidth(self, t, filename, dif): + """ + Schedules the generation of a csv file of the bandwidth used by + flows in a certain DIF at a certain time. + + :param filename: The output csv filename. + :param dif: The DIF to export + """ + if self.experiment is None: + raise ValueError("An experiment is needed to schedule commands.") + + if self._script is None: + self._script = _Script(self) + + action = functools.partial(self.experiment.export_dif_bandwidth, + filename, dif) + self._script.add_event(Event(action, ev_time=t)) + def schedule_link_state(self, t, dif, state): """ Schedules a link's (`rumba.model.ShimEthDIF`) state to go |