cancel
Showing results for 
Search instead for 
Did you mean: 

Error for SAP PI REST adapter not being captured

samiullah_qureshi
Active Contributor
0 Kudos

Hi Folks,

We are using REST adapter available for SAP PI 7.31 (SP15). We have configured the scenario and it is working fine for success case.

However, whenever there is any error pertaining to the data, we are getting HTTP 500 error in SAP PI and no other information about error.

To check the issue if I call the Web-Service using Postman with same payload, it gives the error code as 500. Also, it provides the error text saying that which field was having issue as shown in below screen shot:

Can we catch this error message anyhow in SAP PI and send it back to source system?

Regards,

Samiullah.

Accepted Solutions (0)

Answers (4)

Answers (4)

PratibhaK
Participant
0 Kudos

Hi Samiullah,

Were you able to sort this? We are facing the same issue in PI 7.4 SP 12.

Thanks,

Pratibha

maheswarareddykonda
Active Contributor
0 Kudos

Hi Sam,

The REST adapter which is available in current version(7.3 SP16 / 7.4SP11) is not capable to fetch the exact error message from server, I have checked with SAP regarding this and they were saying that feature is available in 7.3 SP17 or 7.4 SP12 which is releasing in coming November. Also along with this feature there is one more as get the Http header details from receiver server.

Also checked possibility from them , but unfortunately there is no such.

Former Member
0 Kudos

Samiullah,

To make this happen, you would need to make all elements and fields as optional. With this, even if the element/field is missing, data will go to SAP PI mapping.

However to send a response back, you would need to call a receiver system, capture the response and create an user friendly error message for the sender system.

Calling a receiver system with incomplete data will be challenging task here.

iaki_vila
Active Contributor
0 Kudos

Hi Samiullah,

The http 500 error means in your case an exception in PI, you can't control it. However you can do some alternatives like to configure an alert monitoring to send an email to the sender or to try to control on the receiver endsytem the error in order to response a right payload. Depending where is the error you can try to control, if the problem is in mapping level you can do a java mapping to control the issue, on the adapter level this control would be more complicated. Also, you can try to avoid these data errors on the sender side avoiding to generate an incorrect payload.

Regards.

samiullah_qureshi
Active Contributor
0 Kudos

Thanks Vila for your response.

However, we are having synchronous interface with REST web-service. Therefore, we were intended to report error back to Sender SAP system.

Is there any way, 'if we can capture the error' OR 'at least if we can see these errors in SAP PI monitoring' ?

Regards,

Samiullah.