cancel
Showing results for 
Search instead for 
Did you mean: 

RFC TO HTTP receiver scenario.Adding file name to HTTP receiver

Former Member
0 Kudos

Hi All,

Scenario is ZBAPI ->XI-> HTTP conncetivity to EXternal Partners .

ZBAPI sends the Partner data informtaion to XI . I need to create a Partnerdata xml in XI and pass it to HTTP Connectivity (Certificates ) to External Partners

Connectivity is working but I need to add the time stamp to the Partner data xml in the HTTP Receiver .

I dont get the time stamp in ZBAPI

I checked many blogs to create UDF of getfilename, dynamic configuration , but here there is no FTP sender channel .

Can someone help me in giving ideas as hope to assign the time stamp in runtime to HTTPS Receiver Channel .

Thank you ,

Best Regards,

Vara

Accepted Solutions (1)

Accepted Solutions (1)

former_member184681
Active Contributor
0 Kudos

Hi Vara,

In your question you actually mentioned three different communication methods (HTTP, HTTPS and FTP), but only one of them can really work with files and it is the FTP adapter. Moreover, what you need is the Receiver FTP Communication Channel, not the Sender one (as you need to deliver your message to an external system, not to collect it from there). What you need to do is find your Receiver Communication Channel, go to Advanced tab and mark "Use Adapter-Specific Message Attributes", as well as the File Name (that appears once you mark the first one). Then, in your message mapping, you just put the current timestamp to the respective dynamic configuration parameter. Find an example of how to make the whole change [here|http://www.saptechnical.com/Tips/XI/ASMA/Index.htm].

However, if I misunderstood you and you need to use the current timestamp in the message body instead of the file name, it will be even simpler. In this case, just go to your Message Mapping and in the target field, put the "currentDate" function from the "Date" group, then double click on it, click the "extended view" button and put your expected date and time format.

Hope this helps,

Grzegorz

Former Member
0 Kudos

Thank you for the information ! And iam really sorry for delay response .

Yes your inout helped me a lot . I did create HTTP header to assign Current Date (Standard function in XI) as DynamicConfiguratin to the xsd header, but the Partner were Ok with the Message ID sending as an Additional Attribute

Hence I checked Message ID as an attribute to the HTTP receiver Channel pointing to RFCF destintaion of Partners

Answers (2)

Answers (2)

baskar_gopalakrishnan2
Active Contributor
0 Kudos

>Can someone help me in giving ideas as hope to assign the time stamp in runtime to HTTPS Receiver Channel?

If you want to include timestamp in the target xml payload, then it is possible. You can create UDF during mapping and add the timestamp in the payload.

Example:

String DATE_FORMAT_NOW = "yyyy-MM-dd HH:mm:ss"; //any date and time format you want
Calendar cal = Calendar.getInstance();
SimpleDateFormat sdf = new SimpleDateFormat(DATE_FORMAT_NOW);
return sdf.format(cal.getTime());

Former Member
0 Kudos

Hi Vara,

As far as I know there is no way that you can add timestamp in a HTTP receiver adapter cause it won't use filenames. HTTP adapter will not treat a message as a file like file adapter so I guess you can't add time stamp to the filename.

if your requirement is to have filename with timestamp then you should use file adapter or else convince your end user to find out some way on their side to add timestamp when they receive the message.

thanks...

Sukarna...