<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic how to check the flag file from S3 folder in Talend Studio</title>
    <link>https://community.qlik.com/t5/Talend-Studio/how-to-check-the-flag-file-from-S3-folder/m-p/2211682#M9609</link>
    <description>&lt;P&gt;Hi Everyone,&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;I have a scenario in which i am running a job from Talend which is pulling all the files from AWS S3 folder.But before doing so ,i need to check if the Flag file is present there then only i can proceed.&lt;/P&gt; 
&lt;P&gt;Suppose ,I have files like this:&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;File_trigger.Flag&lt;/P&gt; 
&lt;P&gt;abc.csv&lt;/P&gt; 
&lt;P&gt;bcd.csv&lt;/P&gt; 
&lt;P&gt;efg.csv&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;If the file_trigger.flag is present on AWS S3 then only my job starts pulling the files abc.csv ,bcd.csv etc...&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;I have made my job which is pulling all the files from S3 but now this is a new scenrio. Could you please let me know how to proceed with that?&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;Regards,&lt;/P&gt; 
&lt;P&gt;Mohit&lt;/P&gt;</description>
    <pubDate>Sat, 16 Nov 2024 07:07:27 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2024-11-16T07:07:27Z</dc:date>
    <item>
      <title>how to check the flag file from S3 folder</title>
      <link>https://community.qlik.com/t5/Talend-Studio/how-to-check-the-flag-file-from-S3-folder/m-p/2211682#M9609</link>
      <description>&lt;P&gt;Hi Everyone,&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;I have a scenario in which i am running a job from Talend which is pulling all the files from AWS S3 folder.But before doing so ,i need to check if the Flag file is present there then only i can proceed.&lt;/P&gt; 
&lt;P&gt;Suppose ,I have files like this:&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;File_trigger.Flag&lt;/P&gt; 
&lt;P&gt;abc.csv&lt;/P&gt; 
&lt;P&gt;bcd.csv&lt;/P&gt; 
&lt;P&gt;efg.csv&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;If the file_trigger.flag is present on AWS S3 then only my job starts pulling the files abc.csv ,bcd.csv etc...&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;I have made my job which is pulling all the files from S3 but now this is a new scenrio. Could you please let me know how to proceed with that?&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;Regards,&lt;/P&gt; 
&lt;P&gt;Mohit&lt;/P&gt;</description>
      <pubDate>Sat, 16 Nov 2024 07:07:27 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/how-to-check-the-flag-file-from-S3-folder/m-p/2211682#M9609</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2024-11-16T07:07:27Z</dc:date>
    </item>
    <item>
      <title>Re: how to check the flag file from S3 folder</title>
      <link>https://community.qlik.com/t5/Talend-Studio/how-to-check-the-flag-file-from-S3-folder/m-p/2211683#M9610</link>
      <description>&lt;P&gt;you could install aws cli&amp;nbsp;commandline client, and setup it&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;after use tSystm with command&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&amp;nbsp;aws s3 ls s3://bucket/&lt;SPAN&gt;File_trigger.Flag&lt;/SPAN&gt;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;tSystem will return 0 if file exists, and 1 if not, use it in tRunIf trigger as value&lt;/P&gt;
&lt;PRE&gt;((Integer)globalMap.get("tSystem_1_EXIT_VALUE"))&amp;gt;0&lt;/PRE&gt;</description>
      <pubDate>Wed, 05 Dec 2018 20:35:32 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/how-to-check-the-flag-file-from-S3-folder/m-p/2211683#M9610</guid>
      <dc:creator>vapukov</dc:creator>
      <dc:date>2018-12-05T20:35:32Z</dc:date>
    </item>
    <item>
      <title>Re: how to check the flag file from S3 folder</title>
      <link>https://community.qlik.com/t5/Talend-Studio/how-to-check-the-flag-file-from-S3-folder/m-p/2211684#M9611</link>
      <description>&lt;P&gt;Hi Vapukov,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;AWS CLI command line is installed already.&lt;/P&gt;
&lt;P&gt;Still i need to connect to AWS before using tsystem command.I know the connection and other things.&lt;/P&gt;
&lt;P&gt;But How tsystem will fetch AWS connection details and trigger the above command from Talend.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;regards,&lt;/P&gt;
&lt;P&gt;Mohit&lt;/P&gt;</description>
      <pubDate>Thu, 06 Dec 2018 07:36:39 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/how-to-check-the-flag-file-from-S3-folder/m-p/2211684#M9611</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2018-12-06T07:36:39Z</dc:date>
    </item>
    <item>
      <title>Re: how to check the flag file from S3 folder</title>
      <link>https://community.qlik.com/t5/Talend-Studio/how-to-check-the-flag-file-from-S3-folder/m-p/2211685#M9612</link>
      <description>&lt;P&gt;if you have installed aws-cli, you know - it self-contained, it do not need anything for work, you must configure it separate&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;so in you job:&lt;/P&gt;&lt;P&gt;preJob - connection&lt;/P&gt;&lt;P&gt;Job:&lt;/P&gt;&lt;P&gt;- tSystem&lt;/P&gt;&lt;P&gt;- and after RunIf all other&lt;/P&gt;</description>
      <pubDate>Thu, 06 Dec 2018 08:51:56 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/how-to-check-the-flag-file-from-S3-folder/m-p/2211685#M9612</guid>
      <dc:creator>vapukov</dc:creator>
      <dc:date>2018-12-06T08:51:56Z</dc:date>
    </item>
    <item>
      <title>Re: how to check the flag file from S3 folder</title>
      <link>https://community.qlik.com/t5/Talend-Studio/how-to-check-the-flag-file-from-S3-folder/m-p/2211686#M9613</link>
      <description>&lt;P&gt;Thanks,I will try it &lt;span class="lia-inline-image-display-wrapper" image-alt="0683p000009MACn.png"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/154443iC5B8CACEF3D12C6A/image-size/large?v=v2&amp;amp;px=999" role="button" title="0683p000009MACn.png" alt="0683p000009MACn.png" /&gt;&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 07 Dec 2018 07:45:47 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/how-to-check-the-flag-file-from-S3-folder/m-p/2211686#M9613</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2018-12-07T07:45:47Z</dc:date>
    </item>
    <item>
      <title>Re: how to check the flag file from S3 folder</title>
      <link>https://community.qlik.com/t5/Talend-Studio/how-to-check-the-flag-file-from-S3-folder/m-p/2211687#M9614</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;&amp;nbsp; &amp;nbsp;&amp;nbsp;Below is another solution for your query. I have setup two sample files in S3 for testing.&lt;/P&gt; 
&lt;P&gt;&lt;SPAN class="lia-inline-image-display-wrapper lia-image-align-center" image-alt="image.png" style="width: 400px;"&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="0683p000009M1F6.png"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/139934i57DF399617A1D45C/image-size/large?v=v2&amp;amp;px=999" role="button" title="0683p000009M1F6.png" alt="0683p000009M1F6.png" /&gt;&lt;/span&gt;&lt;/SPAN&gt;&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;Below is the output of the flow with only flag file as output.&lt;/P&gt; 
&lt;P&gt;&lt;SPAN class="lia-inline-image-display-wrapper lia-image-align-center" image-alt="image.png" style="width: 999px;"&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="0683p000009M1Mu.png"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/128085iA03BDEA4A3661D70/image-size/large?v=v2&amp;amp;px=999" role="button" title="0683p000009M1Mu.png" alt="0683p000009M1Mu.png" /&gt;&lt;/span&gt;&lt;/SPAN&gt;&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;Below are the details of each components. I have added tLogrow components for printing and you can remove them in actual code.&lt;/P&gt; 
&lt;P&gt;&lt;SPAN class="lia-inline-image-display-wrapper lia-image-align-center" image-alt="image.png" style="width: 999px;"&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="0683p000009M1Mz.png"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/145936i7C6E21C028800619/image-size/large?v=v2&amp;amp;px=999" role="button" title="0683p000009M1Mz.png" alt="0683p000009M1Mz.png" /&gt;&lt;/span&gt;&lt;/SPAN&gt;&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;&lt;SPAN class="lia-inline-image-display-wrapper lia-image-align-center" image-alt="image.png" style="width: 999px;"&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="0683p000009M1N4.png"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/155659i2B0F7810083F7D20/image-size/large?v=v2&amp;amp;px=999" role="button" title="0683p000009M1N4.png" alt="0683p000009M1N4.png" /&gt;&lt;/span&gt;&lt;/SPAN&gt;&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;&lt;SPAN class="lia-inline-image-display-wrapper lia-image-align-center" image-alt="image.png" style="width: 999px;"&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="0683p000009M1Ip.png"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/133975iD7CC8B19916C5F4A/image-size/large?v=v2&amp;amp;px=999" role="button" title="0683p000009M1Ip.png" alt="0683p000009M1Ip.png" /&gt;&lt;/span&gt;&lt;/SPAN&gt;&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;Both approaches provide same result but one is employing command line method and other through GUI.&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;If the reply has helped you, could you please mark the topic as resolved? Kudos are also welcome &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;Warm Regards,&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;Nikhil Thampi&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 07 Dec 2018 10:12:40 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/how-to-check-the-flag-file-from-S3-folder/m-p/2211687#M9614</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2018-12-07T10:12:40Z</dc:date>
    </item>
    <item>
      <title>Re: how to check the flag file from S3 folder</title>
      <link>https://community.qlik.com/t5/Talend-Studio/how-to-check-the-flag-file-from-S3-folder/m-p/2211688#M9615</link>
      <description>&lt;P&gt;I exclude this variant because as is it requires double reading for all files (as on picture) and with 1000 files it could be long&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;but, if using the full Flag file name as a Key prefix in tS3List - it could reduce the number of iteration to 1&lt;/P&gt;
&lt;P&gt;unfortunately, right now I have not S3 access and cannot test it, but it could be a best choice if work&lt;/P&gt;</description>
      <pubDate>Fri, 07 Dec 2018 10:30:20 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/how-to-check-the-flag-file-from-S3-folder/m-p/2211688#M9615</guid>
      <dc:creator>vapukov</dc:creator>
      <dc:date>2018-12-07T10:30:20Z</dc:date>
    </item>
    <item>
      <title>Re: how to check the flag file from S3 folder</title>
      <link>https://community.qlik.com/t5/Talend-Studio/how-to-check-the-flag-file-from-S3-folder/m-p/2211689#M9616</link>
      <description>&lt;P&gt;&lt;A href="https://community.qlik.com/s/profile/005390000067LRbAAM"&gt;@vapukov&lt;/A&gt;&amp;nbsp;- Perfect idea !&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;I added the flag file name in the Key prefix and it reduced the number of iterations to 1.&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;&lt;SPAN class="lia-inline-image-display-wrapper lia-image-align-center" image-alt="image.png" style="width: 999px;"&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="0683p000009M1N9.png"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/142950iDB6E32A32CE32305/image-size/large?v=v2&amp;amp;px=999" role="button" title="0683p000009M1N9.png" alt="0683p000009M1N9.png" /&gt;&lt;/span&gt;&lt;/SPAN&gt;&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;The modified job flow is as below.&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;&lt;SPAN class="lia-inline-image-display-wrapper lia-image-align-center" image-alt="Job Output" style="width: 864px;"&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="0683p000009M1NE.png"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/145448i737A7D5E1D3A34B5/image-size/large?v=v2&amp;amp;px=999" role="button" title="0683p000009M1NE.png" alt="0683p000009M1NE.png" /&gt;&lt;/span&gt;&lt;SPAN class="lia-inline-image-caption" onclick="event.preventDefault();"&gt;Job Output&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;Warm Regards,&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;Nikhil Thampi&lt;/P&gt;</description>
      <pubDate>Fri, 07 Dec 2018 11:33:41 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/how-to-check-the-flag-file-from-S3-folder/m-p/2211689#M9616</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2018-12-07T11:33:41Z</dc:date>
    </item>
  </channel>
</rss>

