Skip to Content
avatar image
Former Member

'org.xml.sax.SAXParseException: Premature end of file

Hi,

  The scenario which I am trying to configure is Mainframe(FTP)->PI->FileShare(File). I need to pick the file from mainframe , zip the file and save the file on to file share. The name of the zip file should be as the name of the source file. The steps which I have completed are:

1) Sender- Pick the file from Data set - PI has successfully picked up the file  and I have used content conversion to convert the flat file to xml. and the structure looks like <input>

                 <Record> </Record>

               </input>

               <input> 

                 <Record> </Record>

               </input>

Content Conversion is configured in a such a way that each Record element will hold the record line.

Content conversion is working fine.

2)  Receiver Side - Configured Message Transform Bean to convert the Xml to Plain and the paramters I have configured in the Module tab

Message Transform Bean is followed by PayloadZip Bean in order to zip the text file .

While Communication Channel converting the xml to Plain using Message Transfrom Beam.. The channel has ended up with the following error.

"Transmitting the message to endpoint <local> using connection File_http://sap.com/xi/XI/System failed, due to: com.sap.engine.interfaces.messaging.api.exception.MessagingException: com.sap.aii.af.sdk.xi.adapter.trans.TransformException: Error converting Message: 'java.lang.Exception: Exception in XML Parser (format problem?):'org.xml.sax.SAXParseException: Premature end of file.''; nested exception caused by: java.lang.Exception: Exception in XML Parser (format problem?):'org.xml.sax.SAXParseException: Premature end of file.'

Could you let me know about the fix to resolve the above issue?

Regards,

Kiran.

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

4 Answers

  • avatar image
    Former Member
    Nov 05, 2013 at 01:50 PM

    Hi,

    Any clue on the error  which I am experiencing?

    Regards,

    Kiran.

    Add comment
    10|10000 characters needed characters exceeded

  • Nov 04, 2013 at 04:41 PM

    Hi Kiran,

    The problem is with content conversion of receiver communication channel or you have special character in the message. Please check the content conversion and special char in message.

    Regards,

    Harish

    Add comment
    10|10000 characters needed characters exceeded

  • Nov 04, 2013 at 05:08 PM

    Hi,

    Your file receiver parameter are right in my opinion, but i would change the line break char 'nl' by other thimg, only for testing purpose. Something is doing that the parser believes that there arent characters to proccess. Check that XML will go out with values between its tags, remove the zip module only for testing purposes (from easy way to more difficult, dont try to do all in the first attempt).

    Regards.

    Add comment
    10|10000 characters needed characters exceeded

  • avatar image
    Former Member
    Nov 04, 2013 at 07:24 PM

    Hi,

    I have resolved the issue. When I inlcude payload zip bean to zip the out put of MessageTransform bean. The Zip file has errored out with "Unrecoverable Zip file read error"

    Regards,

    Kiran.


    Add comment
    10|10000 characters needed characters exceeded