Skip to Content
0

Dynamic URL in HTTP_AAE PO 7.40

Jul 10, 2017 at 03:10 PM

339

avatar image
Former Member

Hi,

My Scenario is proxy to Third party and its Sync. I have to use the dynamic URL. I am not sure if I should use HTTP_AAE or REST as I need to use POST. I am trying to use HTTP_AAE and using the below UDF.

//Get the dynamic configuration from the container DynamicConfiguration conf = (DynamicConfiguration) container.getTransformationParameters().get(StreamTransformationConstants.DYNAMIC_CONFIGURATION); // beginning of setHttpHeader d2a0e4bf0852e83b928c90e621036c29 String funcName = "updateHttpURL"; // get trace object using container AbstractTrace trace = container.getTrace(); trace.addInfo(funcName + "called with value - 1" ); //Create the TServerLocation key in namespace http://sap.com/xi/XI/System/SOAP. This key will hold the dynamically created URL DynamicConfigurationKey key = DynamicConfigurationKey.create("http://sap.com/xi/XI/System/HTTP_AAE", "urlParamOne"); //Put the url value from the input in the configuration under the specified key conf.put(key, url); //return the data for mapping to the output return data;


MY CC config is

I am now getting an error ERROR_SENDING_HTTP_REQUEST-Message Processing Failed. Reason : java.net.UnknownHostException: 192


Obviously its not taking the dynamic IP.

Please suggest.

1.jpg (74.0 kB)
2.jpg (84.2 kB)
10 |10000 characters needed characters left characters exceeded
* Please Login or Register to Answer, Follow or Comment.

3 Answers

Best Answer
Manoj K Jul 10, 2017 at 03:39 PM
0

Sherwin,

I believe HTTP_AAE adapter doesn't support Dynamic URL . Only Dynamic Query parameters is possible via HTTP_AAE.

1742088 - FAQ: PI 7.30 / PI 7.31 HTTP_AAE Adapter

  • Q4: Is it possible to send the Host & Port details HTTP_AAE adapter to form an HTTP URL(using Dynamic Configuration)?

A: It is not possible to make use of Dynamic Configuration to send host & port to form HTTP URL.

Br,

Manoj

Show 4 Share
10 |10000 characters needed characters left characters exceeded
Former Member

Hi Manoj,

So what should be the configuration for REST adapter ?

Thanks,

Sherwin

0

Why not using SOAP ? SOAP does support POST operation by default.

soap.png (308.8 kB)
0
Former Member
Manoj K

HI Manoj,

I'll try using SOAP and then Ill update you.

Thanks,

Sherwin

0
Former Member
Manoj K

Hi Manoj,

I am trying using the SOAP but it is giving error

ct="TV" bresettabindex="true">Returning to application. Exception: com.sap.engine.interfaces.messaging.api.exception.MessagingException: Error encountered while executing mapping: com.sap.aii.af.service.mapping.MappingException: Mapping failed in runtimeRuntime Exception when executing application mapping program com/sap/xi/tf/_MM_EVA_Esku_Details_Sync_Response_; Details: com.sap.aii.utilxi.misc.api.BaseRuntimeException; The element type "br" must be terminated by the matching end-tag "</br>".



Successful test with http request (REST)

Unsuccessful test with http request (SOAP)

Please suggest.

Thanks,

Sherwin

11.png (53.4 kB)
12.png (57.5 kB)
0
Ryan Crosby Jul 10, 2017 at 03:18 PM
0

Hi Sherwin,

In your screenshot you have a host of "192." instead of a valid IP address. The configuration would need to be adjusted before you could attempt to execute the scenario end to end.

Regards,

Ryan Crosby

Show 3 Share
10 |10000 characters needed characters left characters exceeded
Former Member

Hi Ryan,

I was using SOAP before and in that scenario it doesn't matter which value are you putting in Target host so I did the same thing here but it's not working . I have to use dynamic URL so I can't give one particular URL here.

Thanks,

Sherwin

0

Are you also trying to change the host or just the parameters?

Regards,

Ryan Crosby

0
Former Member
Ryan Crosby

HI Ryan,

I am trying to use the dynamic URL which is coming from ECC. ECC will send target URL and I will use it and will send the data to that particular URL.

Thanks,

Pardeep

0
avatar image
Former Member Jul 11, 2017 at 01:23 PM
0

Hi Guys,

The issue is resolved. I used the SOAP channel with java UDF and XSLT mapping.

Thanks,

Sherwin

Share
10 |10000 characters needed characters left characters exceeded