# Unable to serialize XML format in JMS Sink Connect

**URL:** <https://forum.confluent.io/t/unable-to-serialize-xml-format-in-jms-sink-connect/4175>\
**Category:** Kafka Connect\
**Created:** [16 February 2022 06:20 UTC](https://forum.confluent.io/t/unable-to-serialize-xml-format-in-jms-sink-connect/4175 "2022-02-16T06:20:41Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Kameshwaran](https://avatars.discourse-cdn.com/v4/letter/k/90ced4/32.png) [@Kameshwaran](https://forum.confluent.io/u/Kameshwaran)\
**Post date:** [16 February 2022 06:20 UTC](https://forum.confluent.io/t/unable-to-serialize-xml-format-in-jms-sink-connect/4175/1 "2022-02-16T06:20:41Z")

</div>

Hi,

We are using JMS Connect to consume XML messages and produce it to the kafka topics using avro format to serialize in topics. While consuming the same XML message from the topic to a JMS queue using JMS sink connect the XML message is being wrapped in a JSON format along with JSON headers. Is there any way to serialize the XML message in XML format alone ?

PFB the reference:  
Posted : (Expected Result)

```auto
(<Root>
<Child>
<Hello>hello</Hello>
</Child>
</Root>)

```

Received :

```auto
{"messageID":"ID:<755895.1644562443183.0>","messageType":"text","timestamp":1644562443183,"deliveryMode":2,"correlationID":null,"replyTo":null,"destination":{"destinationType":"topic","name":"com.bt.jms.module.orb2b.apb2bod1!bt.jms.topic.test1"},"redelivered":false,"type":null,"expiration":0,"priority":4,"properties":{"JMSXDeliveryCount":{"propertyType":"integer","boolean":null,"byte":null,"short":null,"integer":1,"long":null,"float":null,"double":null,"string":null,"bytes":null}},"bytes":null,"map":null,"text":"(<Root>
<Child>
<Hello>hello</Hello>
</Child>
</Root>)"}

```

---

<div class="post-metadata">

**Author:** ![vnadkarni](https://sea1.discourse-cdn.com/flex019/user_avatar/forum.confluent.io/vnadkarni/32/1839_2.png) [@vnadkarni](https://forum.confluent.io/u/vnadkarni)\
**Post date:** [16 February 2022 11:28 UTC](https://forum.confluent.io/t/unable-to-serialize-xml-format-in-jms-sink-connect/4175/2 "2022-02-16T11:28:23Z")

</div>

Hi @Kameshwaran . The exact same message was posted by @Shahul_Hameed at [Consuming with JMS Connectors causing format issues](https://forum.confluent.io/t/consuming-with-jms-connectors-causing-format-issues/4176) . I presume you work together.

---

<div class="post-metadata">

**Author:** ![Kameshwaran](https://avatars.discourse-cdn.com/v4/letter/k/90ced4/32.png) [@Kameshwaran](https://forum.confluent.io/u/Kameshwaran)\
**Post date:** [16 February 2022 11:47 UTC](https://forum.confluent.io/t/unable-to-serialize-xml-format-in-jms-sink-connect/4175/3 "2022-02-16T11:47:25Z")

</div>

Hi @vnadkarni, Yes we work together. Can you please help us here with the issue

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/flex019/uploads/confluentcommunity/original/1X/c49438c90c9df282e9996fdf6971be890c71b65a.svg) [@system](https://forum.confluent.io/u/system)\
**Post date:** [18 March 2022 11:47 UTC](https://forum.confluent.io/t/unable-to-serialize-xml-format-in-jms-sink-connect/4175/4 "2022-03-18T11:47:30Z")

</div>

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.
