Error Actions and Error Log (deprecated since 3.0)
Since CloverETL 3.0, these attributes are deprecated.
They should be replaced with either |
The Error codes can be used in some components to define the following two attributes:
Error actions
Any of these values means that a fatal error occurred and the user decides if the process should stop or continue.
To define what should be done with the record, click the Error actions attribute row, click the button that appears and specify the actions in the following dialog.
By clicking the Plus sign button, you add rows to this dialog pane.
Select STOP or CONTINUE in the Error action column.
Type an integer number to the Error code column.
Leaving MIN_INT
value in the left column means that the action will be applied to all other integer values that have not been specified explicitly in this dialog.
The Error actions attribute has a form of a sequence of assignments (errorCode=someAction
) each separated by a semicolon.
-
The left side can be
MIN_INT
or any integer number less than 0 specified as some return value in the transformation definition.If
errorCode
isMIN_INT
, this means that the specified action will be performed for all values that have not been specified in the sequence. -
The right side of assignments can be
STOP
and/orCONTINUE
.If
someAction
isSTOP
, when its correspondingerrorCode
is returned,TransformExceptions
is thrown and the graph stops.If
someAction
isCONTINUE
, when its correspondingerrorCode
is returned, error message is written to Console or to the file specified by the Error log attribute and graph continues with the next record.
-1=CONTINUE;-3=CONTINUE;MIN_INT=STOP
.
In this case, if the transformation returns -1
or -3
, the process continues, if it returns any other negative value (including -2
), the process stops.
Error log
In this attribute, you can specify whether the error messages should be written on Console or in a specified file. The file should be defined using URL File Dialog.