Closed pranzlch closed 2 years ago
Hi @pranzlch,
thanks for using our bundle.
The problem is probably in your configuration of JsonPathReader
. You cannot rename fields when you use Infer Schema
. Try to rename tag_value
to tag_value_int
.
For more info see: https://github.com/influxdata/nifi-influxdb-bundle/issues/63#issuecomment-1011073845
Regards
Hi!
I changed the properties in the JSONPathReader to match the keys in the JSON:
and also in the PutInfluxDatabaseRecord_2 processor properties:
Works fine!
Hi! I'm trying to insert data from a SCADA system to an Influx DB. But the only reaction I get is the message
2022-07-27 14:45:55,865 INFO [Timer-Driven Process Thread-5] o.i.n.p.PutInfluxDatabaseRecord_2 PutInfluxDatabaseRecord_2[id=3f45277b-0182-1000-60a1-dcd6d238c16a] The all fields of FlowFile=3f42a181-2cac-4110-a4f0-b0a288b67a32 has null value. There is nothing to store to InfluxDB
I'm using NiFi 1.12.1 on Windows Server 2019 and installed version 1.8.0. InfluxDB is on anither Windows 2019 Server in version 2.3.0.
From the SCADA system I got an JSON flow file:
{ "ext_id": "WuT_OPC_Connector.FEU-BS01.E.0", "tag_value_int": 258.2, "tag_tsp": "20220727124121.0000388", "status": "GOOD", "prevValue": 248.06 }
I'm using the PutInfluxDatabaseRecord_2 processor with a JSONPathReader as Record Reader and StandardInfluxDatabaseService_2 as InfluxDB Controller Service.
The StandardInfluxDatabaseService_2 configuration can be seen here:
The InfluxDB connection URL is http://SERVERNAME:8086 and the InfluxDB Access Token is correct.
The JSONPathReader configuration can be seen here:
The PutInfluxDatabaseRecord_2 configuration can bee seen here
and here