Module feasibity for tag history to-from No-SQL DB

Is that feasible (with a reasonable complexity) to achieve a module for :

  1. storing tag history data (with ignition history deadband) to a No-SQL DB
  2. retrieving these history data for easy chart ?



First, it’s going to depend on what flavor of No-SQL you’re using. SQL databases have a lot in common with each other, No-SQL less so. And for each No-SQL database, there are varying levels of support for interacting with Java.

If this were my project, I’d start by seeing if there was something that would mimic a JDBC driver for my No-SQL database. (Like – not an endorsement, I just hear it mentioned commonly in NoSQL discussions.) That would let you treat your NoSQL database just like any other SQL database you connect to ignition, and you could store and retrieve tag history the same way.

I assume your purpose in using a NoSQL database for tag history is to get sparse columns to save space? If that’s the case, and you can’t find a driver you like for your NoSQL database, you can also look at keeping a shorter duration of detailed history and then using aggregated data for the rest of your history.

The No-SQL DB will be a Time Serie DB : InfluxDB with is Java API.
I was wondering if the part of the Ignition SDK for Tag History management (store and retrieve Data) is not too tied with SQL DB ?

Tag history providers themselves are an extension point (SQLTagHistoryProviderType). In your gateway hook’s setup method, you’ll call context.getTagManager().addSQLTagHistoryProviderType(myProviderTypeInstance);
In your SQLTagHistoryProviderType, the createHistoryProvider method will return your new implementation of TagHistoryProvider. I imagine you’ll want that implementation to have an instance of an implementation of DataSink. Check the javadocs for both of those. These interfaces are just the starting points – you’ll need to trace through the methods to see what other things you’ll need to implement/subclass.

Thanks kathy for the starting point.
After a quick look at the javadoc about TagHistoryProviderType and DataSink, it seems to be quite difficult to implement a new TagHistoryProviderType.
An example in the inductiveautomation/ignition-sdk-examples would be very usefull… :wink:
In the meantime, for a very limited proof of concept, I can create a standard sql provider and pick data in this temporary db to store then data into influxDb and operate data outside Ignition :frowning:

1 Like

Any luck integrating InfluxDB?

I’ve recently been looking at this option, and saw you had considered it. I’m also looking at Neo4J and ArangoDB as graph DB’s, and imagine I’ll need to wire up the Arango via it’s API like Influx.

Are there any plans to add this to the examples?

No plans. Doesn’t mean it can’t/won’t happen, just not something we have on our roadmap. Pull Requests are always welcome if someone else has a workable proof of concept.

1 Like

Please check the link :Influx Ignition Module Third party