cancel
Showing results for 
Search instead for 
Did you mean: 

RuntimeException during appliction Java mapping

Former Member
0 Kudos

Hi Experts,

We are getting error in sxmb_moni in production.

   SAP:Error SOAP:mustUnderstand="" xmlns:SAP="http://sap.com/xi/XI/Message/30" xmlns:SOAP="http://schexxxxx.org/">

<SAP:Category>Application</SAP:Category>

<SAP:Code area="MAPPING">EXCEPTION_DURING_EXECUTE</SAP:Code>

<SAP:P1>com/sap/xi/tf/_EmapBatchInfo_MM_</SAP:P1>

<SAP:P2>com.sap.aii.utilxi.misc.api.BaseRuntimeException:</SAP:P2> s.xmlsoap.org

<SAP:P3>An invalid XML character (Unicode: 0x0) was found</SAP:P3>

<SAP:P4>in the element content of the document.</SAP:P4>

<SAP:AdditionalText />

<SAP:Stack>Runtime exception occurred during application mapping com/sap/xi/tf/_xxxxx_MM_; com.sap.aii.utilxi.misc.api.BaseRuntimeException:
   An invalid XML character (Unicode: 0x0) was foundin the element content of the document.</SAP:Stack>

<SAP:Retry>M</SAP:Retry>
  
    When i am checked the payload in mapping test tab it is showing another error.

  Content is not allowed in prolog.

 

         Content is not allowed in prolog.
com.sap.aii.utilxi.misc.api.BaseRuntimeException: Content is not allowed in prolog.
at com.sap.aii.mappingtool.tf7.rt.xparser.MTSaxHandler.run(MTSaxHandler.java:264)
at com.sap.aii.mappingtool.tf7.rt.xparser.XParser.run(XParser.java:81)
Caused by: org.xml.sax.SAXParseException: Content is not allowed in prolog.
at com.sun.org.apache.xerces.internal.util.ErrorHandlerWrapper.createSAXParseException(ErrorHandlerWrapper.java:236)
at com.sun.org.apache.xerces.internal.util.ErrorHandlerWrapper.fatalError(ErrorHandlerWrapper.java:215)
at com.sun.org.apache.xerces.internal.impl.XMLErrorReporter.reportError(XMLErrorReporter.java:386)
at com.sun.org.apache.xerces.internal.impl.XMLErrorReporter.reportError(XMLErrorReporter.java:316)
at com.sun.org.apache.xerces.internal.impl.XMLScanner.reportFatalError(XMLScanner.java:1441)
at com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl$PrologDispatcher.dispatch(XMLDocumentScannerImpl.java:899)
at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanDocument(XMLDocumentFragmentScannerImpl.java:368)
at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:834)
at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:764)
at com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(XMLParser.java:148)
at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.parse(AbstractSAXParser.java:1242)
at javax.xml.parsers.SAXParser.parse(SAXParser.java:375)
at com.sap.aii.mappingtool.tf7.rt.xparser.MTSaxHandler.run(MTSaxHandler.java:261)
... 1 more
Root Cause:
org.xml.sax.SAXParseException: Content is not allowed in prolog.
at com.sun.org.apache.xerces.internal.util.ErrorHandlerWrapper.createSAXParseException(ErrorHandlerWrapper.java:236)
at com.sun.org.apache.xerces.internal.util.ErrorHandlerWrapper.fatalError(ErrorHandlerWrapper.java:215)
at com.sun.org.apache.xerces.internal.impl.XMLErrorReporter.reportError(XMLErrorReporter.java:386)
at com.sun.org.apache.xerces.internal.impl.XMLErrorReporter.reportError(XMLErrorReporter.java:316)
at com.sun.org.apache.xerces.internal.impl.XMLScanner.reportFatalError(XMLScanner.java:1441)
at com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl$PrologDispatcher.dispatch(XMLDocumentScannerImpl.java:899)
at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanDocument(XMLDocumentFragmentScannerImpl.java:368)
at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:834)
at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:764)
at com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(XMLParser.java:148)
at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.parse(AbstractSAXParser.java:1242)
at javax.xml.parsers.SAXParser.parse(SAXParser.java:375)
at com.sap.aii.mappingtool.tf7.rt.xparser.MTSaxHandler.run(MTSaxHandler.java:261)
at com.sap.aii.mappingtool.tf7.rt.xparser.XParser.run(XParser.java:81)
Content is not allowed in prolog.

15:05:40 End of test    


Please kindly give suggestions to solve this. It is production error.

Thanks

Rakesh

Accepted Solutions (1)

Accepted Solutions (1)

gagandeep_batra
Active Contributor
0 Kudos

Hi Rakesh,

Can you check with the data: the error is coming because of wrong data:

An invalid XML character (Unicode: 0x0) was found


if it is send RFC or IDOC you can make it enable with by Checked at RFC destination unicode option


Regards

gagan

Former Member
0 Kudos

Hi Gagan,

Thanks For your replay.

I was checked the data in message mapping test tab by deleting some fields in xml but also same error it is showing. i think Data is in good format.

The below error iam getting when i testing data in message mapping.

ERROR:   Content is not allowed in prolog.

Kindly help me..

Thanks

Rakesh

Former Member
0 Kudos

Hi Gagan,

It is File to Proxy scenario..

Thanks

Rakesh

Muniyappan
Active Contributor
0 Kudos

Hi Rakesh,

Can you open the xml file in wordpad and see if it has any special chars?

check this thread also.

Error in moni as invalid XML character (Unicode... | SCN

Regards,

muniyappan.

Answers (3)

Answers (3)

Former Member
0 Kudos

Hi Rakesh

The log clearly says that there is a unicode character 0x0 in your xml message. Unicode 0x0 means NULL value.

Please open your xml file in text pad or editpad pro and find out the null character.

Remove the null character and then re-run the xml file. This will solve your problem.

binlathip
Explorer
0 Kudos

Hi Indrajit

If this way can solve problem. How should I do if text files are generated from 3rd system like POS system.

Thank you.

suchitatomar
Participant
0 Kudos

Hi Binla,

Can you please post your exact requirement in new thread to ensure your query is addressed properly 🙂

Regards

Suchita

Former Member
0 Kudos

Hi,

if you are using the bapi as source message, can you please check the RFC connection of type 3 in ECC system is unicode enabled and also make sure that the sender RFC channel in the integration directory unicode check box enabled or not.And also check the xml you are sending by testing it in the message mapping.

Regards,

Venkat

Former Member
0 Kudos

Hi,

I cross checked the xml file in message mapping it is working fine.. means in test tab  given xml message and it passed the mapping.

But still the error showing in same way..

The scenario is File(FCC) to Proxy..

Thanks

Rakesh

Former Member
0 Kudos

Hey,

Did u check this weblog

Regards,

Krishna

manoj_khavatkopp
Active Contributor
0 Kudos

Did you found the solution for this, facing the same problem

Former Member
0 Kudos

Hi Manoj,

We found the exact problem causing for that error. In XML message we found the space for one field. Its like data issue.

Thanks

Rakesh

Former Member
0 Kudos

Hi,

Please go for Cache Refresh once.

It may solve your issue.

Thanks,

Vivek Jain