0

我正在尝试使用以下查询从我的流入数据库中检索数据:

select * from signal

但是,一旦我运行处理器,我就会得到“空指针异常” 。这是我的处理器的样子:

在此处输入图像描述

我尝试从“ ExecuteInfluxDatabaseQuery ”和“ ExecuteInfluxDbQuery ”处理器中检索数据。两者都给出空指针异常。我的 infux 版本是 1.7.9。

以下是 ExecuteInfluxDb 设置:

在此处输入图像描述

如何从 InfluxDb 成功检索数据?提前致谢

这是堆栈跟踪:

2020-03-02 19:18:51,919 ERROR [Timer-Driven Process Thread-30] o.a.n.p.influxdb.ExecuteInfluxDBQuery ExecuteInfluxDBQuery[id=0170127f-cdc1-1b49-fd8b-f8e45de6a362] ExecuteInfluxDBQuery[id=0170127f-cdc1-1b49-fd8b-f8e45de6a362] failed to process session due to java.lang.NullPointerException; Processor Administratively Yielded for 1 sec: java.lang.NullPointerException

java.lang.NullPointerException: null

 at org.apache.nifi.processors.influxdb.ExecuteInfluxDBQuery.onTrigger(ExecuteInfluxDBQuery.java:182)

 at org.apache.nifi.processor.AbstractProcessor.onTrigger(AbstractProcessor.java:27)

 at org.apache.nifi.controller.StandardProcessorNode.onTrigger(StandardProcessorNode.java:1176)

 at org.apache.nifi.controller.tasks.ConnectableTask.invoke(ConnectableTask.java:213)

 at org.apache.nifi.controller.scheduling.TimerDrivenSchedulingAgent$1.run(TimerDrivenSchedulingAgent.java:117)

 at org.apache.nifi.engine.FlowEngine$2.run(FlowEngine.java:110)

 at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:515)

 at java.base/java.util.concurrent.FutureTask.runAndReset(FutureTask.java:305)

 at java.base/java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:305)

 at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)

 at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)

 at java.base/java.lang.Thread.run(Thread.java:834)

2020-03-02 19:18:51,919 WARN [Timer-Driven Process Thread-30] o.a.n.controller.tasks.ConnectableTask Administratively Yielding ExecuteInfluxDBQuery[id=0170127f-cdc1-1b49-fd8b-f8e45de6a362] due to uncaught Exception: java.lang.NullPointerException

java.lang.NullPointerException: null

 at org.apache.nifi.processors.influxdb.ExecuteInfluxDBQuery.onTrigger(ExecuteInfluxDBQuery.java:182)

 at org.apache.nifi.processor.AbstractProcessor.onTrigger(AbstractProcessor.java:27)

 at org.apache.nifi.controller.StandardProcessorNode.onTrigger(StandardProcessorNode.java:1176)

 at org.apache.nifi.controller.tasks.ConnectableTask.invoke(ConnectableTask.java:213)

 at org.apache.nifi.controller.scheduling.TimerDrivenSchedulingAgent$1.run(TimerDrivenSchedulingAgent.java:117)

 at org.apache.nifi.engine.FlowEngine$2.run(FlowEngine.java:110)

 at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:515)

 at java.base/java.util.concurrent.FutureTask.runAndReset(FutureTask.java:305)

 at java.base/java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:305)

 at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)

 at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)

 at java.base/java.lang.Thread.run(Thread.java:834)

2020-03-02 19:18:52,665 INFO [Flow Service Tasks Thread-1] o.a.nifi.controller.StandardFlowService Saved flow controller org.apache.nifi.controller.FlowController@76951619 // Another save pending = false

2020-03-02 19:18:52,920 ERROR [Timer-Driven Process Thread-25] o.a.n.p.influxdb.ExecuteInfluxDBQuery ExecuteInfluxDBQuery[id=0170127f-cdc1-1b49-fd8b-f8e45de6a362] ExecuteInfluxDBQuery[id=0170127f-cdc1-1b49-fd8b-f8e45de6a362] failed to process session due to java.lang.NullPointerException; Processor Administratively Yielded for 1 sec: java.lang.NullPointerException

java.lang.NullPointerException: null
4

0 回答 0