技术文章 - CS381824

使用 Influx V2 Persistence Provider 时,数据无法从 ThingWorx 写入 InfluxDB,Tomcat stdout 日志中出现错误“写入数据期间发生错误”

已修改: 11-Apr-2023   


注意:本文已使用机器翻译软件翻译,以方便非英语客户阅读。但翻译内容可能包含语法错误或不准确之处。请注意, PTC对本文所含信息的翻译准确性及使用后果不承担任何责任。请在 此处 查看本文的英文原始版本以便参考。有关机器翻译的更多详情,请单击 此处
感谢您告诉我们。我们将尽快审阅此译文。

适用于

  • ThingWorx Platform 9.3 F000 to SP5

说明

  • 在 ThingWorx Platform 中使用 Influx V2 Persistence Provider 时,写入 InfluxDB(Influx)的数据存在较大差距
  • ThingWorx 正确发送和接收边缘数据点,但 ThingWorx 未成功将这些数据点写入 Influx
  • 配置 Influx2PersistenceProviderPackage 后,许多数据点未发送到 Influx
  • Influx2 Persistence Provider 无法将所有数据点发送到 Influx
  • 在 Apache Tomcat stdout 文件中看到以下内容:
    • SEVERE [RxNewThreadScheduler-224133] com.influxdb.client.write.events.WriteErrorEvent.logEvent 写入数据时发生错误
      com.influxdb.exceptions.InfluxException: 中断
      在 com.influxdb.client.internal.AbstractWriteClient.toInfluxException(AbstractWriteClient.java:552)
      在 com.influxdb.client.internal.AbstractWriteClient.lambda$new$12(AbstractWriteClient.java:179)
      在 io.reactivex.internal.subscribers.LambdaSubscriber.onNext(LambdaSubscriber.java:65)
      ...
      引起:java.io.InterruptedIOException:中断
      在 okio.Timeout.throwIfReached(Timeout.kt:98)
      在 okio.OutputStreamSink.write(JvmOkio.kt:50)
      在 okio.AsyncTimeout$sink$1.write(AsyncTimeout.kt:103)
      ...
    • 警告 com.influxdb.client.write.events.BackpressureEvent.logEvent 背压应用,尝试增加 WriteOptions.bufferLimit
    • 警告 com.influxdb.client.internal.InfluxDBClientImpl.makeWriteApi 已经创建了 11 个“WriteApi”实例。 'WriteApi' 假设作为单例运行,应该跨线程重用。如果您想使用一次性摄取,请使用“WriteApiBlocking”。
这是文章 381824 的 PDF 版本,可能已过期。最新版本 CS381824