ExecutableTag Alarm configuration

I’ve developed a TagProvider that uses DBTagStore to store/load Tag configuration.

I’m having a problem since upgrading from 7.5.x to 7.6.1

When I create a tag, it initially has an all-empty configuration (other than type). In the new version, when I attempt to store a tag, I get a NullPointerException here:

at com.inductiveautomation.ignition.gateway.sqltags.providers.datasource.tagstore.DBTagStore.storeAlarmConfiguration(DBTagStore.java:2359) at com.inductiveautomation.ignition.gateway.sqltags.providers.datasource.tagstore.DBTagStore.insertTags(DBTagStore.java:1745) at com.inductiveautomation.ignition.gateway.sqltags.providers.datasource.tagstore.DBTagStore.addTagsV2(DBTagStore.java:1664) at com.inductiveautomation.ignition.gateway.sqltags.providers.datasource.tagstore.DBTagStore.addTags(DBTagStore.java:1651)

My tags extend AbstractExecutableTag.

What would I need to do to store the tag with an empty Alarm Configuration? There isn’t too much documentation about this.



I think the quickest, and most appropriate, way to get around this is to switch from defining your tags as a subclass of AbstractExecutableTag, and instead use the TagDefinition class. The “exectuable tags” are normally built by the system off of the definition, and they do tricky things to try to minimize memory. Fundamentally, the error your reported should be fixed, but still, that wouldn’t be 100% correct, because if you’re trying to define a new tag, the AbstractExecutableTag isn’t going to really let you do it correctly.

Since you’re not doing much init, you should be able to simply switch over to TagDefinition without much difficulty.

Let me know how it goes,

Hi Colby,

Thanks for the reply. I decided to try an alternate route for this module: use the built-in Tag Providers and search/modify the tags through the context manager. It’s going OK but have an issue (please see related thread).

If that fails, I will pursue this route again and try your suggestion.


I tried the suggestion and using TagDefinition solved the issue with Executable tags, I just replaced the code by new TagDefinition(myExecutableTag) when adding tags to the TagStore.

However, now I have a problem with folder tags. This is the Exception:

java.lang.NullPointerException at com.inductiveautomation.ignition.gateway.sqltags.providers.AbstractTagStore.flattenTags(AbstractTagStore.java:290) at com.inductiveautomation.ignition.gateway.sqltags.providers.datasource.tagstore.DBTagStore.addTagsV2(DBTagStore.java:1660) at com.inductiveautomation.ignition.gateway.sqltags.providers.datasource.tagstore.DBTagStore.addTags(DBTagStore.java:1651)

I tried using TagDefinition here but without success.

Any ideas?


Make sure you’re passing in some sort of parent folder, even if it’s just empty (TagPathParser.parse("")).


Thanks! that did it.