# UDT "ReadStructuredTagsRequest" Error

**URL:** <https://forum.inductiveautomation.com/t/udt-readstructuredtagsrequest-error/106013>\
**Category:** Ignition\
**Tags:** ignition81\
**Created:** [May 7, 2025, 10:59pm UTC](https://forum.inductiveautomation.com/t/udt-readstructuredtagsrequest-error/106013 "2025-05-07T22:59:05Z")\
**Posts on this page:** 10\
**Page:** 1

<div class="post-metadata">

**Author:** ![Philip\_Knowlton](https://avatars.discourse-cdn.com/v4/letter/p/e495f1/32.png) [@Philip\_Knowlton](https://forum.inductiveautomation.com/u/Philip_Knowlton)\
**Post date:** [May 7, 2025, 10:59pm UTC](https://forum.inductiveautomation.com/t/udt-readstructuredtagsrequest-error/106013/1 "2025-05-07T22:59:05Z")

</div>

Hello all,

> **Environment:**  
> Ignition Version: 8.1.47  
> Device Connection: 1768-L43S CompactLogix Revision 20.13 (Allen-Bradley Logix Driver)

I created a UDT yesterday and all the tags were happy and connected, but one of the instances continually threw the following "drivers.LogixDriver.Requests.ReadStructuredTagsRequest" error to the gateway logs (but only for ONE of the UDT instances):

```python
java.lang.IndexOutOfBoundsException: readerIndex(4) + length(88) exceeds writerIndex(6): CompositeByteBuf(ridx: 4, widx: 6, cap: 6, components=2)

at io.netty.buffer.AbstractByteBuf.checkReadableBytes0(AbstractByteBuf.java:1442)

at io.netty.buffer.AbstractByteBuf.checkReadableBytes(AbstractByteBuf.java:1428)

at io.netty.buffer.AbstractByteBuf.readSlice(AbstractByteBuf.java:879)

at io.netty.buffer.SwappedByteBuf.readSlice(SwappedByteBuf.java:631)

at com.inductiveautomation.xopc.drivers.logix.requests.ReadStructuredTagsRequest.readStructuredTag(ReadStructuredTagsRequest.java:439)

at com.inductiveautomation.xopc.drivers.logix.requests.ReadStructuredTagsRequest.readTag(ReadStructuredTagsRequest.java:268)

at com.inductiveautomation.xopc.drivers.logix.requests.ReadStructuredTagsRequest.handleResponse(ReadStructuredTagsRequest.java:186)

at com.inductiveautomation.xopc.drivers.logix.requests.ReadStructuredTagsRequest.lambda$buildMultipleServicePacketService$2(ReadStructuredTagsRequest.java:117)

at com.digitalpetri.enip.cip.services.MultipleServicePacketService.decodeResponse(MultipleServicePacketService.java:70)

at com.digitalpetri.enip.cip.services.MultipleServicePacketService.decodeResponse(MultipleServicePacketService.java:18)

at com.digitalpetri.enip.cip.CipClient.lambda$invokeConnected$0(CipClient.java:71)

at java.base/java.util.concurrent.CompletableFuture.uniWhenComplete(Unknown Source)

at java.base/java.util.concurrent.CompletableFuture$UniWhenComplete.tryFire(Unknown Source)

at java.base/java.util.concurrent.CompletableFuture.postComplete(Unknown Source)

at java.base/java.util.concurrent.CompletableFuture.complete(Unknown Source)

at com.digitalpetri.enip.cip.CipClient$ConnectedDataHandler.itemsReceived(CipClient.java:270)

at com.digitalpetri.enip.cip.CipClient.onUnitDataReceived(CipClient.java:239)

at com.digitalpetri.enip.EtherNetIpClient.onChannelRead(EtherNetIpClient.java:196)

at com.digitalpetri.enip.EtherNetIpClient.access$900(EtherNetIpClient.java:50)

at com.digitalpetri.enip.EtherNetIpClient$EtherNetIpClientHandler.lambda$channelRead0$0(EtherNetIpClient.java:346)

at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)

at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)

at java.base/java.lang.Thread.run(Unknown Source)

```

I've done some digging and haven't come up with anything that suggested what might be going on, and I don't really understand the error. As I was typing this up, I disabled and re-enabled that device connection and so far the error hasn't come back (but that might just be a fluke).

I'm including the UDT definition JSON below as well in case there might be something misconfigured. All but 2 of the tags are data type Real in the PLC

Thanks in advance for any help 🙂

```python
{
  "name": "Foam Usage Logging",
  "parameters": {
    "includeGlobal": {
      "dataType": "String",
      "value": ""
    },
    "Asset": {
      "dataType": "Integer"
    }
  },
  "tagType": "UdtType",
  "tags": [
    {
      "opcItemPath": {
        "bindType": "parameter",
        "binding": "ns\u003d1;s\u003d[{InstanceName}]{includeGlobal}{TagName}"
      },
      "valueSource": "opc",
      "dataType": "Int4",
      "name": "FoamTrig",
      "tagType": "AtomicTag",
      "enabled": true,
      "opcServer": "IgnitionOPCUA"
    },
    {
      "opcItemPath": {
        "bindType": "parameter",
        "binding": "ns\u003d1;s\u003d[{InstanceName}]{includeGlobal}{TagName}"
      },
      "valueSource": "opc",
      "dataType": "Float4",
      "name": "PolyTotalSftUseageGrams",
      "tagType": "AtomicTag",
      "opcServer": "IgnitionOPCUA"
    },
    {
      "opcItemPath": {
        "bindType": "parameter",
        "binding": "ns\u003d1;s\u003d[{InstanceName}]{includeGlobal}{TagName}"
      },
      "valueSource": "opc",
      "dataType": "Float4",
      "name": "TotsftIsoUseageGrams",
      "tagType": "AtomicTag",
      "opcServer": "IgnitionOPCUA"
    },
    {
      "value": {
        "bindType": "parameter",
        "binding": "{Asset}"
      },
      "valueSource": "memory",
      "name": "Asset",
      "tagType": "AtomicTag"
    },
    {
      "opcItemPath": {
        "bindType": "parameter",
        "binding": "ns\u003d1;s\u003d[{InstanceName}]{includeGlobal}{TagName}"
      },
      "valueSource": "opc",
      "dataType": "Float4",
      "name": "PolyTotalGallonPerSft",
      "tagType": "AtomicTag",
      "opcServer": "IgnitionOPCUA"
    },
    {
      "opcItemPath": {
        "bindType": "parameter",
        "binding": "ns\u003d1;s\u003d[{InstanceName}]{includeGlobal}{TagName}"
      },
      "valueSource": "opc",
      "dataType": "Float4",
      "name": "IsoTotalGallonPerSft",
      "tagType": "AtomicTag",
      "opcServer": "IgnitionOPCUA"
    },
    {
      "opcItemPath": {
        "bindType": "parameter",
        "binding": "ns\u003d1;s\u003d[{InstanceName}]{includeGlobal}{TagName}"
      },
      "valueSource": "opc",
      "dataType": "Float4",
      "name": "TotIsoUseagePounds",
      "tagType": "AtomicTag",
      "opcServer": "IgnitionOPCUA"
    },
    {
      "opcItemPath": {
        "bindType": "parameter",
        "binding": "ns\u003d1;s\u003d[{InstanceName}]{includeGlobal}{TagName}"
      },
      "valueSource": "opc",
      "dataType": "Float4",
      "name": "PolyTotalUseagePounds",
      "tagType": "AtomicTag",
      "opcServer": "IgnitionOPCUA"
    }
  ]
}

```

---

<div class="post-metadata">

**Author:** ![pturmel](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/pturmel/32/3295_2.png) [@pturmel](https://forum.inductiveautomation.com/u/pturmel)\
**Post date:** [May 7, 2025, 11:05pm UTC](https://forum.inductiveautomation.com/t/udt-readstructuredtagsrequest-error/106013/2 "2025-05-07T23:05:20Z")

</div>

You should be using the legacy driver (CompactLogix) for that firmware.

---

<div class="post-metadata">

**Author:** ![Philip\_Knowlton](https://avatars.discourse-cdn.com/v4/letter/p/e495f1/32.png) [@Philip\_Knowlton](https://forum.inductiveautomation.com/u/Philip_Knowlton)\
**Post date:** [May 8, 2025, 12:38am UTC](https://forum.inductiveautomation.com/t/udt-readstructuredtagsrequest-error/106013/3 "2025-05-08T00:38:49Z")

</div>

Excellent information, thank you! I hadn't read the documentation on the drivers before now.

If I delete the device connection that currently exists and recreate it with the same name using the correct driver, will my tags reconnect properly or will it break more in my system?

---

<div class="post-metadata">

**Author:** ![pturmel](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/pturmel/32/3295_2.png) [@pturmel](https://forum.inductiveautomation.com/u/pturmel)\
**Post date:** [May 8, 2025, 12:56am UTC](https://forum.inductiveautomation.com/t/udt-readstructuredtagsrequest-error/106013/4 "2025-05-08T00:56:19Z")

</div>

Unfortunately, the legacy drivers have slightly different OPC Item Path syntax--you'll have to fix them all.

Exporting to json and using regexp in a text editor can do the trick.

---

<div class="post-metadata">

**Author:** ![Philip\_Knowlton](https://avatars.discourse-cdn.com/v4/letter/p/e495f1/32.png) [@Philip\_Knowlton](https://forum.inductiveautomation.com/u/Philip_Knowlton)\
**Post date:** [May 8, 2025, 1:03am UTC](https://forum.inductiveautomation.com/t/udt-readstructuredtagsrequest-error/106013/5 "2025-05-08T01:03:19Z")

</div>

Dang...

Do you have any example of what might change? Is it predictable?

I think I'll recreate the connection in my sandbox gateway and see what paths are different.

---

<div class="post-metadata">

**Author:** ![pturmel](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/pturmel/32/3295_2.png) [@pturmel](https://forum.inductiveautomation.com/u/pturmel)\
**Post date:** [May 8, 2025, 1:31am UTC](https://forum.inductiveautomation.com/t/udt-readstructuredtagsrequest-error/106013/6 "2025-05-08T01:31:33Z")

</div>

Non-program tags all need `global.` as a prefix. Arrays repeat the base name in an extra hierarchy level.

---

<div class="post-metadata">

**Author:** ![Philip\_Knowlton](https://avatars.discourse-cdn.com/v4/letter/p/e495f1/32.png) [@Philip\_Knowlton](https://forum.inductiveautomation.com/u/Philip_Knowlton)\
**Post date:** [May 8, 2025, 1:37am UTC](https://forum.inductiveautomation.com/t/udt-readstructuredtagsrequest-error/106013/7 "2025-05-08T01:37:12Z")

</div>

Thanks again for your help, Phil!

---

<div class="post-metadata">

**Author:** ![pturmel](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/pturmel/32/3295_2.png) [@pturmel](https://forum.inductiveautomation.com/u/pturmel)\
**Post date:** [May 8, 2025, 2:01am UTC](https://forum.inductiveautomation.com/t/udt-readstructuredtagsrequest-error/106013/8 "2025-05-08T02:01:02Z")

</div>

> [@Philip\_Knowlton](#):
>
> Pete!

_Cough_

Um, no.

---

<div class="post-metadata">

**Author:** ![Philip\_Knowlton](https://avatars.discourse-cdn.com/v4/letter/p/e495f1/32.png) [@Philip\_Knowlton](https://forum.inductiveautomation.com/u/Philip_Knowlton)\
**Post date:** [May 8, 2025, 2:03am UTC](https://forum.inductiveautomation.com/t/udt-readstructuredtagsrequest-error/106013/9 "2025-05-08T02:03:48Z")

</div>

Whoops, please accept my apology from one Phil to another. 🤣

---

<div class="post-metadata">

**Author:** ![nminchin](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/nminchin/32/6911_2.png) [@nminchin](https://forum.inductiveautomation.com/u/nminchin)\
**Post date:** [May 8, 2025, 3:48am UTC](https://forum.inductiveautomation.com/t/udt-readstructuredtagsrequest-error/106013/10 "2025-05-08T03:48:10Z")

</div>

Wait, you're _not_ Pete???
