This module has been deprecated. Although the code is still working for our oldest model, it is not expected to work with the new Bastion API.

class genvid.toolbox.EventsTool(*args, **kwargs)

Bases: ConfigTool

Tool that manages events configuration.

Deprecated since version 1.33.0: Deprecated in favor of ClusterAPI() events defs methods.

MAP_REDUCES = 'genvid/events/mapreduce/'

The key prefix for all map-reduce definitions.

update_map_reduce(name, mrdef)

Update a map-reduce definition.


Get all map-reduce definitions available.


Transform the map object produced by map “<id>” {} hcl syntax into the expected { “maps” : [ { “id”: … ] } object for events.

load_map_reduce(name, path)

Load a map-reduce from a file.

If the file ends with .hcl, use the HCL format for map-reduce. Otherwise, consider it a JSON file.


Print the list of map-reduce configured on stdout.


Add the events commands to the parser.

Run from add_commands() to add the events commands to the parser.

run_events_command(command, options)

Detect if the command is an events command and execute it.

Call from run_command() to handle events commands. Events commands are added with the help of add_events_commands().


handled, result: A tuple with a boolean saying if the

command were handled and it’s result if it was.

class config.EventsTool

Implementation of genvid.toolbox.EventsTool