on 11-26-2008 3:01 PM
Hi Experts ,
Mine is a FTP XI R/3 scenerio. Data from FTP enter XI [ FTP adapters] , and after logicical manipulatations enter R/3 as idocs using IDOC adapters . The problem is sometime the production is needed to be put down, and at that time data is picked up by XI from FTP. This needs to be checked. The requirement is to write a CODE that can test the R/3 connection and if successful, then allow the data to be passed , and if DOWN , then send MAIL alerts to certain users, and may be stop the process.
Pls tell me indetails what can I do, and what all coding is necessary.There is no BPM in this scenerio.
Pls revert back if you need any other info.
Regards,
Arnab
I beleive better option is to develop and Adapter Module. In the Module write a code that will simply try to connect with R3. Now connected, then forward message to IE, else stop its processing and trigger an email.
Thanks
Farooq
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Farooq ,
I have gone through the linls above by Carlos. They are gud, but too complex for me to undertsand and utilize them!
Can you please tell me , how to develop an Adapter Module and start coding in it !
You seem to have the very clear picture, of my issue infront of you!
>
> I beleive better option is to develop and Adapter Module. In the Module write a code that will simply try to connect with R3. Now connected, then forward message to IE, else stop its processing and trigger an email.
>
> Thanks
> Farooq
Regards,
Arnab.
Hi
Case 1:
You can create and RFC in R/3 which will just return you value TRUE if it System is up, just one field. if it cannot access the system it will throw an error with HTTP code 500, catch this error
write an java map ( i mean use the same FTP adapter to read all the data), in this java map write an method to check the status of the R/3 which will return you some value lets assume boolean ( true if system is up, false is system is down, in this method you have to catch the exception if it throws 500 http code check this logic how you want to handle)
so if this method is true, then process your files which are in your execute method as input stream also you can just email in this map itself notifying the concerned person telling SAP is down).
You can create two receivers one for sending email and other for processing the files, use the java map above to determine receiver based on the RFC call status you select your receiver.
Adapter Module: You can also do same using module, but if you write it as MAP you have flexibility in main ting from your side (NO XI server acess to deploy module and all).
Other important thing here is in any case you have to close your active XI pipeline, if you write it as a module and suppose you found SAP is down then you will send email, then how will you close the pipeline meaning fully...try to make this interface as such it executes sucessfully in eihter case just change in business logic based on receiver.
Make sure the logic in RFC just checks any system paramter to return you true or false, in doing so you should also take care of other RFC errors which might come if your RFC adapter itself is down, so when you catch the error 500 also check what the status code the RFC adapter can return if it is not able to connect to R/3.
Case 2:
If you have JDK 1.5 or higher,
then you can use the standard Java Method to check the status of the server
String host = "172.16.0.2"
int timeOut = 3000; // I recommend 3 seconds at least
boolean status = InetAddress.getByName(host).isReachable(timeOut)
this is same as PING command from CMD Prompt we run, with this also you can check the status is up or down of the server, to know more about this java class check this link
http://java.sun.com/j2se/1.4.2/docs/api/java/net/InetAddress.html
so based on this boolean value decide how you want to complete the rest design of XI.
regards
Nisar Khan
Edited by: Nisar Khan on Nov 27, 2008 1:02 AM
Edited by: Nisar Khan on Nov 27, 2008 1:28 AM
Hi Arnab
You can develop adapter module to connect to R/3 before pushing the file.
The same can be achieved using a shell script that you can use in your file adapter channel that can do a PING operation to R/3 and can send email as well about R/3 is up or not.
Similar to this with modification based on your R/3 OS & firewall
http://bash.cyberciti.biz/monitoring/monitor-windows-linux-server-with-ping-script/
Thanks
Gaurav
hi,
If you know when your R/3 system is down, you can deactivate your FTP Sender Communication
Channel. And when your R/3 is up again, activate your Communication Channel
Carlos
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Carlos,
sorry I didnt expalin the complete story. the FTP is loaded with data from another 3rd Party system, which is managed by some other team, and we have no control with the flow of data , and when and hw the R/3 can go down, ,and I believe there is a place to write code in the communication channel . I simply donnow where to write it,what to write, and how to code so as to stimulate mails .Alerting the client by mails not to send data is a clent requirement .
Regards,
Arnab
Yes, but can u tell me, the complexity of this, and simply as I am new, hw to do this?
Also , as OI novice, I am asking you, is there anything I can do in the "Run Operating system Command before messege Processing" option available in the processing parameters of the communication channel , or may be some ABAP code testing the SM59 connectoin that can be associated with the messege mapping or communication channel,
i sound nuts and vague , but I am just thinking of the possibilities as a novice
Regards,
Arnab
User | Count |
---|---|
87 | |
10 | |
10 | |
10 | |
7 | |
6 | |
6 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.