From 9f3139eb839d676a375ee3ac6fc7e7e66c6fac40 Mon Sep 17 00:00:00 2001
From: slavaromanov <monodry@gmail.com>
Date: Fri, 25 Oct 2019 21:11:42 +0300
Subject: [PATCH] migrate to influxdb1-client/v2

---
 client.go      | 7 ++++++-
 decode.go      | 2 +-
 decode_test.go | 2 +-
 3 files changed, 8 insertions(+), 3 deletions(-)

diff --git a/client.go b/client.go
index e8bc062..5f8cd7e 100644
--- a/client.go
+++ b/client.go
@@ -6,7 +6,7 @@ import (
 	"strings"
 	"time"
 
-	influxClient "github.com/influxdata/influxdb/client/v2"
+	influxClient "github.com/influxdata/influxdb1-client/v2"
 )
 
 var reRemoveExtraSpace = regexp.MustCompile(`\s\s+`)
@@ -108,6 +108,11 @@ func (c *helperClient) Query(q influxClient.Query) (*influxClient.Response, erro
 	return c.client.Query(q)
 }
 
+// QueryAsChunk -
+func (c *helperClient) QueryAsChunk(q influxClient.Query) (*influxClient.ChunkedResponse, error) {
+	return c.client.QueryAsChunk(q)
+}
+
 // Close releases any resources a Client may be using.
 func (c *helperClient) Close() error {
 	return c.client.Close()
diff --git a/decode.go b/decode.go
index eaca62f..cf3b466 100644
--- a/decode.go
+++ b/decode.go
@@ -4,7 +4,7 @@ import (
 	"reflect"
 	"time"
 
-	influxModels "github.com/influxdata/influxdb/models"
+	influxModels "github.com/influxdata/influxdb1-client/models"
 	"github.com/mitchellh/mapstructure"
 )
 
diff --git a/decode_test.go b/decode_test.go
index 52d7cf8..d9e927a 100644
--- a/decode_test.go
+++ b/decode_test.go
@@ -8,7 +8,7 @@ import (
 	"testing"
 	"time"
 
-	influxModels "github.com/influxdata/influxdb/models"
+	influxModels "github.com/influxdata/influxdb1-client/models"
 )
 
 func TestDecode(t *testing.T) {