Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

This is a base package of Splicer containing a CLI wrapper implemented in splicer.py source file and splicing logic implemented in TM1SpliceExecutor class. The class is described in detail below.

TM1SpliceExecutor (class in TM1SpliceExecutor.py)

The class implements splicing and desplicing logic in two entry point methods that are called from splicer.py when splicing or desplicing is required from the command line. Below you may find in-depth description of the most important methods provided by the class.

Initialization (constructor __init__)

The class is initialized before splicing or desplicing from parser.py and when the init is finished, the instance of TM1SpliceExecutor will have TM1SpliceConfigContainer associated with itself and all configuration files will be already loaded into memory. The configuration data is provided to TM1SpliceExecutor transparently through the TM1SpliceConfigContainer instance (more about the configuration container can be found in Containers (package)

The connection with the TM1 instance is established during the initialization as well.

Splicing Cubes (method splice_cube_rules)

Splicing logic is implemented in splice_cube_rules method and contains following steps.

...

Finally the method will check status of each cube that was spliced to see if any errors have occurred during splicing. If an error was detected during splicing, the changes that have been committed by Splicer will be rolled back.

...

Splicing Individual Cube (method splice_cube_rule)

The method implements actual splicing of the rule file and is phased to following steps.

...