Notification of Failed Records

Hi,
I’m trying to determine a general approach to notifying someone of failed records. This is the case where the records are output to another port or file in case of failure, but the graph itself doesn’t fail (as is typical with a reformat error log) I would like to email the contents of these files in cases where they are non-zero length.

A file SIZE file event would tell me when the file changed, but doesn’t seem to have a straight-forward mechanism for actually delivering the contents of the file. There is a check box, but that appears to be for the log file and not the file that generated the event.

If the attached file isn’t the file that generated the event, then I suppose I could have this event run a shell script and from there email the file in ${event_file_path}/${event_file_name}.

Any better way to do this? Thanks.

Hello,

it’s exactly how you described it.
However, there is another way how to achieve required behavior.
I suggest to use “email sender” component in the last phase of the graph:
http://wiki.cloveretl.org/doku.php?id=c … mailsender
* It can send file attachment
* It sends one email for each input records, so If there are some error records to send, you’ll put just one record to the email sender.
If there are no records to send, you won’t put any record to the email sender.

Best regards,
Martin Varecha