Skip to Content

Error with getMessageID

HI Guys,

I am getting below error in a mapping ERP_COD_BusinessPartnerERPBulkReplicateRequest.

This is a HCI process to replicate business partner from SAP ERP

Error Details

com.sap.xi.mapping.camel.XiMappingException: com.sap.aii.mappingtool.tf7.MessageMappingException: Runtime exception during processing target field mapping /ns0:BusinessPartnerERPBulkReplicateRequest/MessageHeader/ID. The root message is: Exception:[com.sap.aii.mappingtool.tf7.rt.BehaviorInvocationException: while trying to invoke the method java.lang.String.toUpperCase() of a null object loaded from local variable 'MessageID'] in class com.sap.xi.tf._ERP_COD_BusinessPartnerERPBulkReplicateRequest_ method getMessageID[com.sap.aii.mappingtool.tf7.rt.Context@6a42bf25] while trying to invoke the method java.lang.String.toUpperCase() of a null object loaded from local variable 'MessageID', cause: java.lang.NullPointerException: while trying to invoke the method java.lang.String.toUpperCase() of a null object loaded from local variable 'MessageID'

This is the HCI flow.

This is the mapping where it has issue as per the error message.

I even tried to test the mapping in HCI and it works there, however does not works in runtime. :)

Can you guys help.

Thanks

Yatan

screenshot-8.jpg (108.3 kB)
screenshot-7.jpg (156.7 kB)
screenshot-6.jpg (136.1 kB)
Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

2 Answers

  • Mar 19 at 04:10 AM

    Hi Yatanveer Singh,

    Is the getMessageId a UDF in HCI , if yes then it should have atleast one input for it. it might be un used in your script logic.

    Thanks and Regards,

    Vijay.

    Add comment
    10|10000 characters needed characters exceeded

  • Mar 21 at 04:17 PM

    Hi Yatanveer,

    You message mapping is using groovy script - getMessage ID. May be it is trying to fetch value from some local variable which is set in some of the earlier step in your iFlow. This local variable is not set properly, hence your groovy script is fetching some null value and trying to convert that to upper case which is irrelevant.

    Check your groovy script - what value it is trying to fetch and where it is set and why it is not stored with any value.

    Check steps Set Monitoring ID. May be local variable is getting set in this step.

    Thanks,

    Apu

    Add comment
    10|10000 characters needed characters exceeded