Send email if an input file as not arrived

Five Stars

Send email if an input file as not arrived

Hi there,

 

I am trying to implement the following

 

Read files from tList by name

eg: file_20150601.txt, file_20150602.txt, file_20150603. 

If an incremental file is missing from the list, the job will load until the previous file and wait for next input file. 

 

Eg : If the folder only had two files, file_20150601.txt, file_20150603 my job will go to tWaitforFile file_20150602.txt after loading file_20150601.txt. 

 

I have everything working until that point. However, I want to send email after every iteration of tWaitForFile that the expected file is not available in the directory. How can I achieve that?

 

My Current tfile setting is attached. I have a tsendMail , after this, however it is only sending one email -after all iterations are completed. 

 

Thanks

Forteen Stars TRF
Forteen Stars

Re: Send email if an input file as not arrived

tWaitForFile terminates when the condition is completed.
So you should change your job as:
tLoop--tFileExists--(if no)--tSendMail--tSleep
+-(if yes)--tSetGlobalVar

The while condition is based on a global variable (lets say "done") setted to the appropriate value (for example true) when the file is detected

TRF

Tutorial

Introduction to Talend Open Studio for Data Integration.

Definitive Guide to Data Integration

Practical steps to developing your data integration strategy.

Definitive Guide to Data Quality

Create systems and workflow to manage clean data ingestion and data transformation.