XML content parse error

Julia Zashchitina
Added almost 3 years ago

Hello everyone.

We want to send pictures thumbnails as base-64 encoded images with Tigase Server. If there are lots of them (as in attached message request), server results in

2016-03-02 12:13:09.509 [pool-17-thread-5]  XMPPDomBuilderHandler.error()     WARNING:  XML content parse error.
2016-03-02 12:13:09.509 [pool-17-thread-5]  XMPPIOService.processSocketData()  WARNING:, type: accept, Socket: TLS: Socket[addr=/37.yy.yy.yy,port=55199,localport=5222], jid:, data parsing error, stopping connection

and stops connection with client socket. After that we are not able to reconnect and have to create new session.

Is there a way to fix this issue?

Thanks in advance.

m.xmp (2.2 MB) m.xmp

Replies (3)

Added by Daniel Wisnewski IoT 1 Cloud almost 3 years ago


What version of Tigase are you using, and can you share your file?

Added by Wojciech Kapcia TigaseTeam almost 3 years ago

Julia, can you in addition:

  • enable --debug=xmpp and check exact error?

Most likely you are hitting limitation of CDATA length, which is by default set to int MAX_CDATA_SIZE = 1024 * 1024@. You can configure it with the system property @tigase.xml.max_cdata_size (either passing it as JVM property -Dtigase.xml.max_cdata_size=… or including in etc/ with double-dashes: @--tigase.xml.max_cdata_size=…@).

Added by Julia Zashchitina almost 3 years ago

Thanks a lot, setting --tigase.xml.max_cdata_size property fixed it.