IBM webMethods Hybrid Integration

IBM webMethods Hybrid Integration

Join this online group to communicate across IBM product users and experts by sharing advice and best practices with peers and staying up to date regarding product enhancements.



#Automation


#Applicationintegration
#webMethods
#Integration
 View Only
Expand all | Collapse all

Strange error inserting nonXML document for Tamino 4.4.1

  • 1.  Strange error inserting nonXML document for Tamino 4.4.1

    Posted 01/31/06 01:12 PM

    I am trying to insert non-XML document using code like

      TNonXMLObjectAccessor accessor = connection.newNonXMLObjectAccessor(TAccessLocation.newInstance(collection));
    TNonXMLObject nonXMLObject = TNonXMLObject.newInstance(inputStream, null, document, docname, contentType);
    accessor.insert( nonXMLObject );
    

    and get the error in the last line:

    [Fatal Error] :1:424: An invalid XML character (Unicode: 0x1) was found in the element content of the document.

    com.softwareag.tamino.db.API.accessor.TInsertException( message: null, tag: JavaTaminoAPI_4_4_1_8, java: 1.5.0_06, os: Windows XP 5.1 ):

    For Tamino 4.2.1 it was working OK. contentType is text/html.


    #webMethods
    #webMethods-Tamino-XML-Server-APIs
    #API-Management


  • 2.  RE: Strange error inserting nonXML document for Tamino 4.4.1

    Posted 01/31/06 03:10 PM

    It also fails with JavaTaminoAPI_4_2_0_52


    #API-Management
    #webMethods-Tamino-XML-Server-APIs
    #webMethods


  • 3.  RE: Strange error inserting nonXML document for Tamino 4.4.1

    Posted 01/31/06 04:14 PM

    I don’t suppose you have a test document available?

    Something small that fails would be sufficient.


    #webMethods-Tamino-XML-Server-APIs
    #API-Management
    #webMethods


  • 4.  RE: Strange error inserting nonXML document for Tamino 4.4.1

    Posted 02/01/06 11:05 AM

    Actually the problem is that I need just to insert my bytes into Tamino, but I need to specify the contentType (or Tamino will throw the Exception if it do not know about it) and prevent Tamino from attemts to index it.

    Using “audio/mpeg” content type solves the problem for 4.4.1 but id oesn’t works with Tamino 4.2.1


    #webMethods-Tamino-XML-Server-APIs
    #webMethods
    #API-Management


  • 5.  RE: Strange error inserting nonXML document for Tamino 4.4.1

    Posted 02/02/06 03:15 PM

    I am not able to reproduce the problem.

    Can you please paste the part of your non-XML doc that fails ?


    #webMethods
    #webMethods-Tamino-XML-Server-APIs
    #API-Management


  • 6.  RE: Strange error inserting nonXML document for Tamino 4.4.1

    Posted 02/02/06 03:20 PM

    This is just String “The report is awaiting execution” converted to new ByteArrayInputStream(text.getBytes(“UTF-8”)).


    #API-Management
    #webMethods-Tamino-XML-Server-APIs
    #webMethods


  • 7.  RE: Strange error inserting nonXML document for Tamino 4.4.1

    Posted 02/03/06 05:23 AM

    I am still not to the problem.

    Here is what i worked with and it works fine.

    String text = “The report is awaiting execution”;
    InputStream is = new ByteArrayInputStream(text.getBytes(“UTF-8”));
    TNonXMLObject nonXMLObject = TNonXMLObject.newInstance(is, null, “ino:nonXML”, “text1”, “text/html”);
    accessor.insert( nonXMLObject );

    Its working fine for me on both 4.2.1 and 4.4.1 as well


    #webMethods-Tamino-XML-Server-APIs
    #API-Management
    #webMethods


  • 8.  RE: Strange error inserting nonXML document for Tamino 4.4.1

    Posted 02/03/06 11:04 AM

    But can you explain how the error above could happen?


    #API-Management
    #webMethods-Tamino-XML-Server-APIs
    #webMethods


  • 9.  RE: Strange error inserting nonXML document for Tamino 4.4.1

    Posted 02/03/06 11:34 AM

    It would help us if you can attach the HTTP Sniffer logs at the situation of the problem


    #webMethods-Tamino-XML-Server-APIs
    #webMethods
    #API-Management