# OPC-UA server / read only tags

**URL:** <https://forum.inductiveautomation.com/t/opc-ua-server-read-only-tags/11681>\
**Category:** General Discussion\
**Created:** [May 17, 2016, 3:43pm UTC](https://forum.inductiveautomation.com/t/opc-ua-server-read-only-tags/11681 "2016-05-17T15:43:02Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![jflemaitre](https://avatars.discourse-cdn.com/v4/letter/j/a88e57/32.png) [@jflemaitre](https://forum.inductiveautomation.com/u/jflemaitre)\
**Post date:** [May 17, 2016, 3:43pm UTC](https://forum.inductiveautomation.com/t/opc-ua-server-read-only-tags/11681/1 "2016-05-17T15:43:02Z")

</div>

Hello,

I’m writing a small module in java to be put in ignition. I’m trying  
to expose tag to OPC-UA client as described on your website. I’m able  
to expose tag and to override the write handler as decribed on the  
user manual :

ourProvider = new SimpleTagProvider(“DynamicTags”);

ourTagType = TagType.Custom;  
ourProvider.configureTagType(ourTagType,  
TagEditingFlags.STANDARD\_STATUS, null);

ourProvider.configureTag(tag.getKey(), tag.getDataType(),  
TagType.Custom);

ourProvider.registerWriteHandler(tag.getKey(), new WriteHandler() {  
@Override  
public Quality write(TagPath target, Object value) {

…

But each tag I create has a read/right access when I connect a OPC-UA  
client to the gateway. Is there a java way to configure tag in read  
only mode?

Best,
