The Precision100 framework follows an inside out architecture, nearly all components of the framework can be enhanced by using operator
s. An operator
can be used to encapsulate commonly repeated activites of a project e.g. spool operator
or it can be used to interface with tools e.g. sql-plus operator
. If you dont find a operator
that suits your purpose you can always define your own. As with a project the operator
is well defined by the framework.
The framework supports three kinds of operator
s.
operator
which executes work instructions. e.g. sql-plusoperator
.repo-operator
which serves as an interface to the different repository types. e.g file-repo-operator and git-repo-operatorrepo-operator
s.connect-operator
s which serves as an inteface with different kinds of connections. e.g. oracleconnect-operator
encapulates the connection information needed to connect to a Oracle database
By default the framework ships with the following,
- file-repo-operator (
repo-operator
) - git-repo-operator (
repo-operator
) - unknown-repo-operator (
repo-operator
) - shell (
operator
) - unknown-file-type (
operator
)
If any other operator
is needed by the project they must be installed before executing any iteration
s.
As with Precision 100 projects, an operator
is also a file system folder that contains the following,
- A operator registry file i.e.
operator.reg
in the folder (mandatory). - A folder by name
conf
(mandatory). - A folder by name
bin
(mandatory). - A file by name
operator-template.sh
in thebin
folder (mandatory). - A file by name
.operator.env.sh
in theconf
folder (optional) - A shell file by name
on-install.sh
in the folder (optional) - A shell file by name
on-exec.sh
in the folder (optional) - A shell file by name
on-init-exec.sh
in the folder (optional)
An instruction
can be described as an operator
along with its parameters. The following list gives the operators
and the parameters it can take.
Operator | Instruction Example | Description |
---|---|---|
shell | 10,abc.sh,sh | Executes abc.sh |
unknown-file-type | Not invoked directly | |
sql-plus | 10,abc.sql,sql | Executes sqlplus @abc.sql... |
loader | 10,abc.ctl,loader | Executes sqlldr control=abc.ctl... |
smart-loader | 10,table_abc,smart-loader | Creates table_abc.ctl and executes sqlldr control=table_abc.ctl.. |
spool | 10,table_abc,spool | Uses sqlplus to spool select * from table_abc |
map-file | 10,casa.tsv,map-file | Creates table O_CASA, transformation script O-CASA-TRANSFORM.sql and executes it using sqlplus |
smart-map-file | 10,casa.tsv,smart-map-file | Similar to map-file, except that this operator using a dictionary to map functional names into column names for the table |
The shell operator
executes a shell script that is located in the container
. The name of the shell script is passed as a parameter in the instruction
. It throws an error if the script cannot be found in the container
.
The shell operator
comes installed with the framework. To install a newer version execute the following
./bin/install-operator.sh <path to operator bundle> shell
Name of the script file
None.
10,abc.sh,sh
or
10,abc.sh,shell
This operator
is installed as a part of the framework, it is invoked when the framework is unable to identify the operator
needed to execute the instruction. This operator
merely echos the warning to standred output.
The unknown-file-type operator
comes installed with the framework. To install a newer version execute the following
./bin/install-operator.sh <path to operator bundle> unknown-file-type
None.
None.
This operator
is never used directly. This is internally used by the framework as a fallback for conditions where it is not able to identify which operator to use.