# system.opc.readValues from Frontend to Backend

**URL:** <https://forum.inductiveautomation.com/t/system-opc-readvalues-from-frontend-to-backend/81638>\
**Category:** Ignition\
**Created:** [November 8, 2023, 5:06am UTC](https://forum.inductiveautomation.com/t/system-opc-readvalues-from-frontend-to-backend/81638 "2023-11-08T05:06:01Z")\
**Posts on this page:** 7\
**Page:** 1

<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:** [November 8, 2023, 5:06am UTC](https://forum.inductiveautomation.com/t/system-opc-readvalues-from-frontend-to-backend/81638/1 "2023-11-08T05:06:01Z")

</div>

I need to read tag values via opc from a frontend Ignition GW, reading the tags from a backend GW OPC server. I can't issue a `system.opc.readValues` from the Frontend and have to request it to run on the backend, but...

The tag provider names are different, slightly, in both gateways. The frontend remote tag provider is slightly different to the relevant backend gateway tag provider. I would like some way to get the mapped remote tag provider name from the configuration rather than dumb hard-coding it.

How would I read the Frontend GW's remote tag provider info, and get the name of the tag provider it's looking at in the remote gateway?

---

<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:** [November 8, 2023, 1:31pm UTC](https://forum.inductiveautomation.com/t/system-opc-readvalues-from-frontend-to-backend/81638/2 "2023-11-08T13:31:37Z")

</div>

If you are going to be using `system.opc.*`, you don't need to know the remote tag provider name. Just read the tag props for OPC Server and OPC Item Path in the front end. Then supply those in your `system.util.sendRequest` to the backend for it to do the actual OPC read.

---

<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:** [November 8, 2023, 2:29pm UTC](https://forum.inductiveautomation.com/t/system-opc-readvalues-from-frontend-to-backend/81638/3 "2023-11-08T14:29:54Z")

</div>

> [@pturmel](#):
>
> OPC Server and OPC Item Path in the front end.

This is what I was doing, but the opcitempath has the frontend's tag provider name when you read the tags (eg `system.tag.readBlocking('tag/path.opcitempath')`) from the frontend 😕

---

<div class="post-metadata">

**Author:** ![Kevin.Herron](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/kevin.herron/32/7259_2.png) [@Kevin.Herron](https://forum.inductiveautomation.com/u/Kevin.Herron)\
**Post date:** [November 8, 2023, 2:31pm UTC](https://forum.inductiveautomation.com/t/system-opc-readvalues-from-frontend-to-backend/81638/4 "2023-11-08T14:31:38Z")

</div>

OPC item paths don’t contain tag providers unless they are tags being exposed by the OPC server on the other end of that connection.

Your scenario is very unclear to me at the moment.

---

<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:** [November 8, 2023, 2:35pm UTC](https://forum.inductiveautomation.com/t/system-opc-readvalues-from-frontend-to-backend/81638/5 "2023-11-08T14:35:41Z")

</div>

True...

I think I over thought the issue which turns out to be a non-issue as I have all I need to read the OPC tags from the remote gateway... Tag providers are irrelevant for opc reads, whoops.

> [@pturmel](#):
>
> you don't need to know the remote tag provider name

Thanks guys!

---

<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:** [November 8, 2023, 2:45pm UTC](https://forum.inductiveautomation.com/t/system-opc-readvalues-from-frontend-to-backend/81638/6 "2023-11-08T14:45:26Z")

</div>

Extra question:  
In a multi-backend system, how would I know which backend to request running the OPC read from, programmatically?

---

<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:** [November 8, 2023, 3:12pm UTC](https://forum.inductiveautomation.com/t/system-opc-readvalues-from-frontend-to-backend/81638/7 "2023-11-08T15:12:22Z")

</div>

Hmmm. Have to poke around with introspecting a remote tag provider obtained from the gateway context. The Remote Tag Provider isn't in the SDK javadocs.
