on ‎2017 Aug 09 3:58 PM
I have tried to setup a HTTP Rest adapter to take JSON requests. I would like to setup one adapter to handle all the requests from our Hybris system.
For this Rest adapter, I need it to support 4 different calls:
Shipment
Registration
Sample
Request
I tried setting up the Rest adapter with the following settings:
Channel Selection:

Rest Resources:

Rest Operation:
Standard - no changes past default
Operation Determination:

This works to a point. It picks the correct Operation Determination but runs the wrong OM.
Here is a snippet of the log from a Registration attempt:

What am I doing wrong? Any advice?
Request clarification before answering.
Hi Brian,
Based on the error it looks like it is triggering an incorrect mapping as per the operation that is setup in the configuration. The first place I would check is the integration flow configuration in relation to the operation mapping that is defined for each operation.
Regards,
Ryan Crosby
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I am generating these tests and the 2 requests are quite different. I did have a few issues with the ICO objects.
First I have 2 ICO objects created, both use the same CC (as all the above is defined in one CC).
The only other difference is that both have the Software component turned off (blanked out). If that is filled in I get an error that no objects could be found. It seems to me that the system is just picking the first ICO object it finds.
I thought I understood how to create a HTTP Rest adapter and the subsequent objects - but alas, I do not...
Hi Brian,
Therein lies your problem - you can reuse the channel across multiple sender interfaces but not if the configurations are not tied to interfaces within the ESR. The request handling in the REST sender channel would need to generate the exact Message Type for the system to pick the appropriate ICO if you have more than one. Without that link it will simply pick the first one that it finds.
Regards,
Ryan Crosby
So how do I configure the Rest adapter to work? If I set the software component on the ICO object - this is what I get for an error:
Error while sending message to module processor: Sender Channel: Catching exception calling messaging system: InterfaceDetermination did not yield any actual interface
I cannot get past that error... Any suggestions?
Hi Brian,
This is the part where the configuration of your REST sender channel has to generate a message that your system knows what to do with. Here is an easy way to determine what gaps you have... for each operation take your generated payload and copy/paste it into your operation mapping test tab. If the operation mapping does not process it correctly then you have a mismatch in your interface definition vs. what is generated in the REST adapter based on the source payload. You have to keep in mind that the root XML node and structure of that node must match the expected Message Type of the sender interface for which you want to execute a message. That includes the name as an exact match and is case sensitive, the namespace, and all the structural elements of the defined Message Type.
Regards,
Ryan Crosby
There in lies the problem Ryan. I can do exactly as you specify. I can take the input from the message monitor and paste it in the OM - it works. Here is the input:
<SIOS_Hybris_SFDC__Registration xmlns="http://lonza.com/xi/Hybris"> <REQUEST xmlns=""> <IV_EMAIL>axel@gmail.com</IV_EMAIL> <IV_LAISO>en</IV_LAISO> <IS_ADDRESS> <KUNNR>0006005715</KUNNR> <ORGANISATION>Norman, Fox & Co.</ORGANISATION> <HOUSE_NO>14970</HOUSE_NO> <STREET>Don Julian Road</STREET> <SUITE/> <ADD_STREET/> <CITY>City Of Industry</CITY> <STATE_PROV>CA</STATE_PROV> <ZIP_CODE>91746</ZIP_CODE> <COUNTRY>US</COUNTRY> <VAT/> <EORIP_NO/> <CP_TITLE>Herr</CP_TITLE> <CP_AK_TITLE/> <CP_NAME_FIRST>Axel</CP_NAME_FIRST> <CP_NAME_LAST>Volz</CP_NAME_LAST> <CP_PHONE/> <CP_FAX/> <CP_EMAIL/> <CP_FLOOR/> <CP_ROOMNUM/> <CP_BUILDING/> <CP_DEPARTMENT/> </IS_ADDRESS> <IV_BU>CC</IV_BU> <IV_CUST_TYPE>0q0</IV_CUST_TYPE> </REQUEST> </SIOS_Hybris_SFDC__Registration>
above is all test data so nothing secret. I validated the namespaces were correct. The OM testing works just fine. I can find no reason why I keep getting the "interface determination did not yeild any actual interface".
Hi Brian,
The payload that you shared isn't an XML document - the system won't determine an appropriate interface if the message is in that format when the interface determination executes. The output from the REST sender adapter should yield an XML message that corresponds to the Message Type of your sender interface for the operation that you want to execute.
Regards,
Ryan Crosby
Actually it is, but the text box remove all the XML tags.
<SIOS_Hybris_SFDC__Registration xmlns="http://lonza.com/xi/Hybris">
<REQUEST xmlns="">
<IV_EMAIL>axel@gmail.com</IV_EMAIL>
<IV_LAISO>en</IV_LAISO>
<IS_ADDRESS>
<KUNNR>0006005715</KUNNR>
<ORGANISATION>Norman, Fox & Co.</ORGANISATION>
<HOUSE_NO>14970</HOUSE_NO>
<STREET>Don Julian Road</STREET>
<SUITE/>
<ADD_STREET/>
<CITY>City Of Industry</CITY>
<STATE_PROV>CA</STATE_PROV>
<ZIP_CODE>91746</ZIP_CODE>
<COUNTRY>US</COUNTRY>
<VAT/>
<EORIP_NO/>
<CP_TITLE>Herr</CP_TITLE>
<CP_AK_TITLE/>
<CP_NAME_FIRST>Axel</CP_NAME_FIRST>
<CP_NAME_LAST>Volz</CP_NAME_LAST>
<CP_PHONE/>
<CP_FAX/>
<CP_EMAIL/>
<CP_FLOOR/>
<CP_ROOMNUM/>
<CP_BUILDING/>
<CP_DEPARTMENT/>
</IS_ADDRESS>
<IV_BU>CC</IV_BU>
<IV_CUST_TYPE>0cq0</IV_CUST_TYPE>
</REQUEST>
</SIOS_Hybris_SFDC__Registration>
I have copied this into the OM test window and it works with no issues. Yet I still get an error. Here is the message log for the transaction:
8/9/2017 07:42:10.042 PM Information Parsed attribute "operation": "POST"
8/9/2017 07:42:10.042 PM Information Mapped message to http://lonza.com/xi/Hybris:SIOS_Hybris_SFDC__Registration. Matching rule: Registration->Registration
8/9/2017 07:42:10.061 PM Information MP: processing local module localejbs/CallSapAdapter
8/9/2017 07:42:10.061 PM Information Application attempting to send an XI message synchronously using connection REST_http://sap.com/xi/XI/System
8/9/2017 07:42:10.079 PM Error Returning to application. Exception: com.sap.aii.adapter.xi.routing.RoutingException: InterfaceDetermination did not yield any actual interface
The Rest adapter picks up the correct matching rule but will not work.
I have made sure the XSD also uses the same namespace as well.
I re-read my submission but I don't think I was very clear with the problem. When I try to send a "Registration" transaction to the HTTP REST Adapter, the adapter sees it as a Registration and picks the correct Service Interface.
However the wrong Operation Mapping is actually called. The one that is called is for the Shipment transaction (not the Registration). These are on 2 very different Service Interfaces and Integrated Configuration Objects.
If you can, I am looking for insight into what is going on. I also welcome any suggestions on how to better setup the HTTP Rest adapter.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
| User | Count |
|---|---|
| 9 | |
| 7 | |
| 6 | |
| 4 | |
| 3 | |
| 3 | |
| 3 | |
| 2 | |
| 2 | |
| 2 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.