hornet.application – Hornet
Primary objects for running and configuring HORNET.
Module author: John Paulett <john.paulett -at- vanderbilt.edu>
-
exception hornet.application.InvalidConfiguration
The configuration provided contains an invalid option.
-
args
-
message
- exception message
-
class hornet.application.Config
Configuration object defines the preferences for running HORNET,
including all the plugins that should be run.
Required Attributes:
- plugins (dict(str, hornet.plugin.Plugin)) - Dictionary
plugins to execute. The dictionary keys should be unique identifiers
for each plugin instance.
- output_dir (string) - Path to save output.
- start (date) - Start date of period to analyze.
- end (date) - End date of period to analyze
- period_size (timedelta) - Size of time to split
the period by.
-
class hornet.application.PluginRunner(config)
Main application loop for HORNET. Takes a configuration file and runs
the plugins as specified by that config file.
-
get_plugin(plugin_id)
- Returns the instance of the plugin specified by the id of
plugin_id. The plugin_id is the :
-
run()
- Begin execution of the plugins.
-
stop()
- Teardown the plugins.
-
hornet.application.bind_plugins(parent, plugins_dict)
- Associate the parent with all the plugins and set the
hornet.plugin.Plugin.id attributes of the plugins to the keys
of plugins_dict. Returns a list of the plugins.
-
hornet.application.root_plugins(plugins)
- For the list of plugins, find which ones are not listening to
any other plugins. These plugins are consider the root plugins and
will be started with a hornet.event.ProcessingStart event.
-
hornet.application.setup_plugins(plugins)
- Call the setup() method on all plugins.