diff --git a/pom.xml b/pom.xml
index 0e30e69e624..d7a7b538c15 100644
--- a/pom.xml
+++ b/pom.xml
@@ -130,6 +130,7 @@
23.6-jre
4.5.4
4.4.8
+ 2.15
2.9.2
1.9.2
0.16
@@ -524,6 +525,11 @@
groovy-all
${cs.groovy.version}
+
+ org.influxdb
+ influxdb-java
+ ${cs.influxdb-java.version}
+
org.eclipse.jetty
jetty-jmx
diff --git a/server/pom.xml b/server/pom.xml
index 4c69f7d6eae..c0ee1197dcb 100644
--- a/server/pom.xml
+++ b/server/pom.xml
@@ -160,7 +160,6 @@
org.influxdb
influxdb-java
- 2.8
diff --git a/server/src/main/java/com/cloud/server/StatsCollector.java b/server/src/main/java/com/cloud/server/StatsCollector.java
index 80b745e3480..7ae7905ce48 100644
--- a/server/src/main/java/com/cloud/server/StatsCollector.java
+++ b/server/src/main/java/com/cloud/server/StatsCollector.java
@@ -51,6 +51,7 @@ import org.apache.commons.collections.CollectionUtils;
import org.apache.commons.collections.MapUtils;
import org.apache.commons.lang.StringUtils;
import org.apache.log4j.Logger;
+import org.influxdb.BatchOptions;
import org.influxdb.InfluxDB;
import org.influxdb.InfluxDBFactory;
import org.influxdb.dto.BatchPoints;
@@ -1502,6 +1503,7 @@ public class StatsCollector extends ManagerBase implements ComponentMethodInterc
*/
protected void writeBatches(InfluxDB influxDbConnection, String dbName, List points) {
BatchPoints batchPoints = BatchPoints.database(dbName).build();
+ influxDbConnection.enableBatch(BatchOptions.DEFAULTS);
for (Point point : points) {
batchPoints.point(point);