No File ? Send Email : Send Target System | SAP Blogs

This blog topic has been a very common integration requirement in the world of sap xi/pi integration and unfortunately there is no simple solution to this requirement. forum experts provided some solutions like running os script (actually not using xi), use extra admin scenario and check timestamp, use script with extra admin scenario, etc. the discussions and blog below will explain examples of such requirements and solutions.

links,

grzegorz glowacki’s blog: http://scn.sap.com/community/pi-and-soa-middleware/blog/2012/03/07/what-if-file-is-not-there-active- monitoring-of-sender-filing-scenarios-once-a-day

I started to think if this requirement can be achieved in a better way but only with the classic configuration (no bpm and no additional administrative scenario). After thinking for a bit, I came up with two ideas. One option is to use a very simple alert to send an email to the business admin user for sender channel failure indicating no business data for the day (ah, how can sender channel fail?). the second option is to set up an end-to-end scenario and send actual business data or email accordingly (again, how?). the following steps will explain my solutions.

scenario:-

steps:-

  1. Obviously we need a trigger file (.txt) which needs to be grouped in test mode by a scheduled sender file channel based on business requirements.
  2. the trigger file needs to have the same structure that main company payload (.xml), but with only one field 🙂. the value of the field will be very useful to evaluate the conditions, either in the determination of the receiver or in the multiple assignment, to decide the real receiver, that is, direct (or) send an email to the owner / administrator of the company of the target system, for example, if the business data payload has <mt xmlns:ns0=”abc.com”><f1/><f2/><f3/>…<fn /></mt>, then the trigger file can have data < mt xmlns:ns0=”abc.com”><f1>send email</f1></mt>.
  3. two solutions,
    1. first simple solution: use the “additional files” option in the sender’s file channel to collect the trade data as a mandatory attachment >. i.e. the file channel will fail with an error if there is no attachment (actual business data). note: – with this solution, the activation file from step 2 may be empty or may have dummy data
    2. second solution: – use the same “additional files” option in the sender file channel to collect business data but as an optional attachment. i.e. the file channel will never fail with an error when there are no files attached.

Leave a Reply

Your email address will not be published. Required fields are marked *