Decipher log message

sgenzer
sgenzer
Altair Employee
edited November 2024 in Community Q&A
What does this log message mean?

Apr 21, 2016 10:02:30 AM WARNING: Could build DOM from XML! Just using plain text. Reason: Error on line 1: Content is not allowed in prolog.
Tagged:

Answers

  • Marco_Boeck
    Marco_Boeck New Altair Community Member
    Hi,

    it means that someone expected XML but did not get it, e.g. the first character was not '<'.

    What did you do to trigger this?

    Regards,
    Marco
  • sgenzer
    sgenzer
    Altair Employee
    As you may have surmised, I am testing various APIs in RM.  I got the log message when using Enrich Data by Webservice, doing an API call to an IBM Watson API called "Language Translation".  As I mentioned in another post, I am having a LOT of trouble debugging API calls using this operator.
  • JEdward
    JEdward New Altair Community Member
    Generally if you are debugging a webservice for the first time try to get some sample outputs and store them locally using write document. 
    This way you can test expected outputs.  Try different variables in the call also to get some sample standard responses and sample error responses. 

    Then once you have it setup and working for all standard messages put it inside a Handle Exception operator and have several methods to deal with non-standard responses.  For example if it's an error you've met before in your testing your can capture the response in your process.  If it's a brand new error response you can store the content of the XML doc and alert you to update your process to investigate. 

    For example is the API perhaps returning JSON data rather than XML?