【问题标题】:Missing of data while pushing multiple data simultaneously to influxdb.?将多个数据同时推送到influxdb时丢失数据。?
【发布时间】:2018-06-20 04:57:20
【问题描述】:

我正在借助一些代码使用 JMeter 同时将数据推送到 influxdb。数据被推送到数据库,但如果代码必须推送 100 个数据,则流入数据库仅填充 96 或 97 个条目。当内置的流入监听器推送 100 个条目时,我的代码无法将所有一百个条目推送到流入。我的代码 sn-p 如下。

InfluxDB influxDB = InfluxDBFactory.connect(“http:/l/ocalhost:8086”,“TestingDB,”");
influxDB.createDatabase(“MYTestData”);

Point point1 = Point.measurement(“myTable”)
.time(System.currentTimeMillis() , TimeUnit.MILLISECONDS)
.tag(“CustomerID”,"ID1234 ")
.tag(“empID”,"emp1234 ")
.tag(“TestID”,“test12343”)

influxDB.write(“DBname”, “autogen”, point1);

如果我用 10 个用户运行相同的代码并进行 10 次迭代,我需要获得 100 个数据点,而我只获得 95 个或更多条目。 为什么inbuild listener可以100%推送数据而我不行???

【问题讨论】:

    标签: java jmeter time-series influxdb beanshell


    【解决方案1】:

    这可能是由于 Beanshell 在高负载时存在已知的性能问题。

    如果您想使用 JMeter 脚本功能,请确保使用 JSR223 Test ElementsGroovy 语言。

    更好的选择是使用自定义Listener - 查看How to write a plugin for JMeter

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 2019-12-08
      • 2013-10-04
      • 2018-01-25
      • 2011-10-30
      • 2021-08-28
      • 2011-07-02
      • 2015-11-27
      相关资源
      最近更新 更多