refactor: rewrite imports to include the /v2 suffix for version 2
parent
96321ff8bd
commit
0ae8bebd75
|
@ -3,7 +3,7 @@ package authorizer
|
||||||
import (
|
import (
|
||||||
"context"
|
"context"
|
||||||
|
|
||||||
"github.com/influxdata/influxdb"
|
"github.com/influxdata/influxdb/v2"
|
||||||
)
|
)
|
||||||
|
|
||||||
// AuthAgent provides a means to authenticate users with resource and their associate actions. It
|
// AuthAgent provides a means to authenticate users with resource and their associate actions. It
|
||||||
|
|
|
@ -4,10 +4,10 @@ import (
|
||||||
"context"
|
"context"
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
"github.com/influxdata/influxdb"
|
"github.com/influxdata/influxdb/v2"
|
||||||
"github.com/influxdata/influxdb/authorizer"
|
"github.com/influxdata/influxdb/v2/authorizer"
|
||||||
icontext "github.com/influxdata/influxdb/context"
|
icontext "github.com/influxdata/influxdb/v2/context"
|
||||||
influxdbtesting "github.com/influxdata/influxdb/testing"
|
influxdbtesting "github.com/influxdata/influxdb/v2/testing"
|
||||||
"github.com/stretchr/testify/require"
|
"github.com/stretchr/testify/require"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
|
@ -4,7 +4,7 @@ import (
|
||||||
"context"
|
"context"
|
||||||
"fmt"
|
"fmt"
|
||||||
|
|
||||||
"github.com/influxdata/influxdb"
|
"github.com/influxdata/influxdb/v2"
|
||||||
)
|
)
|
||||||
|
|
||||||
var _ influxdb.AuthorizationService = (*AuthorizationService)(nil)
|
var _ influxdb.AuthorizationService = (*AuthorizationService)(nil)
|
||||||
|
|
|
@ -7,11 +7,11 @@ import (
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
"github.com/google/go-cmp/cmp"
|
"github.com/google/go-cmp/cmp"
|
||||||
"github.com/influxdata/influxdb"
|
"github.com/influxdata/influxdb/v2"
|
||||||
"github.com/influxdata/influxdb/authorizer"
|
"github.com/influxdata/influxdb/v2/authorizer"
|
||||||
influxdbcontext "github.com/influxdata/influxdb/context"
|
influxdbcontext "github.com/influxdata/influxdb/v2/context"
|
||||||
"github.com/influxdata/influxdb/mock"
|
"github.com/influxdata/influxdb/v2/mock"
|
||||||
influxdbtesting "github.com/influxdata/influxdb/testing"
|
influxdbtesting "github.com/influxdata/influxdb/v2/testing"
|
||||||
)
|
)
|
||||||
|
|
||||||
var authorizationCmpOptions = cmp.Options{
|
var authorizationCmpOptions = cmp.Options{
|
||||||
|
|
|
@ -4,8 +4,8 @@ import (
|
||||||
"context"
|
"context"
|
||||||
"fmt"
|
"fmt"
|
||||||
|
|
||||||
"github.com/influxdata/influxdb"
|
"github.com/influxdata/influxdb/v2"
|
||||||
icontext "github.com/influxdata/influxdb/context"
|
icontext "github.com/influxdata/influxdb/v2/context"
|
||||||
)
|
)
|
||||||
|
|
||||||
func isAllowedAll(a influxdb.Authorizer, permissions []influxdb.Permission) error {
|
func isAllowedAll(a influxdb.Authorizer, permissions []influxdb.Permission) error {
|
||||||
|
|
|
@ -3,7 +3,7 @@ package authorizer
|
||||||
import (
|
import (
|
||||||
"context"
|
"context"
|
||||||
|
|
||||||
"github.com/influxdata/influxdb"
|
"github.com/influxdata/influxdb/v2"
|
||||||
)
|
)
|
||||||
|
|
||||||
// AuthorizeFindAuthorizations takes the given items and returns only the ones that the user is authorized to read.
|
// AuthorizeFindAuthorizations takes the given items and returns only the ones that the user is authorized to read.
|
||||||
|
|
|
@ -4,8 +4,8 @@ import (
|
||||||
"context"
|
"context"
|
||||||
"io"
|
"io"
|
||||||
|
|
||||||
"github.com/influxdata/influxdb"
|
"github.com/influxdata/influxdb/v2"
|
||||||
"github.com/influxdata/influxdb/kit/tracing"
|
"github.com/influxdata/influxdb/v2/kit/tracing"
|
||||||
)
|
)
|
||||||
|
|
||||||
var _ influxdb.BackupService = (*BackupService)(nil)
|
var _ influxdb.BackupService = (*BackupService)(nil)
|
||||||
|
|
|
@ -2,8 +2,8 @@ package authorizer
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"context"
|
"context"
|
||||||
"github.com/influxdata/influxdb"
|
"github.com/influxdata/influxdb/v2"
|
||||||
"github.com/influxdata/influxdb/kit/tracing"
|
"github.com/influxdata/influxdb/v2/kit/tracing"
|
||||||
)
|
)
|
||||||
|
|
||||||
var _ influxdb.BucketService = (*BucketService)(nil)
|
var _ influxdb.BucketService = (*BucketService)(nil)
|
||||||
|
|
|
@ -7,11 +7,11 @@ import (
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
"github.com/google/go-cmp/cmp"
|
"github.com/google/go-cmp/cmp"
|
||||||
"github.com/influxdata/influxdb"
|
"github.com/influxdata/influxdb/v2"
|
||||||
"github.com/influxdata/influxdb/authorizer"
|
"github.com/influxdata/influxdb/v2/authorizer"
|
||||||
influxdbcontext "github.com/influxdata/influxdb/context"
|
influxdbcontext "github.com/influxdata/influxdb/v2/context"
|
||||||
"github.com/influxdata/influxdb/mock"
|
"github.com/influxdata/influxdb/v2/mock"
|
||||||
influxdbtesting "github.com/influxdata/influxdb/testing"
|
influxdbtesting "github.com/influxdata/influxdb/v2/testing"
|
||||||
)
|
)
|
||||||
|
|
||||||
var bucketCmpOptions = cmp.Options{
|
var bucketCmpOptions = cmp.Options{
|
||||||
|
|
|
@ -3,7 +3,7 @@ package authorizer
|
||||||
import (
|
import (
|
||||||
"context"
|
"context"
|
||||||
|
|
||||||
"github.com/influxdata/influxdb"
|
"github.com/influxdata/influxdb/v2"
|
||||||
)
|
)
|
||||||
|
|
||||||
var _ influxdb.CheckService = (*CheckService)(nil)
|
var _ influxdb.CheckService = (*CheckService)(nil)
|
||||||
|
|
|
@ -6,14 +6,13 @@ import (
|
||||||
"sort"
|
"sort"
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
"github.com/influxdata/influxdb/notification/check"
|
|
||||||
|
|
||||||
"github.com/google/go-cmp/cmp"
|
"github.com/google/go-cmp/cmp"
|
||||||
"github.com/influxdata/influxdb"
|
"github.com/influxdata/influxdb/v2"
|
||||||
"github.com/influxdata/influxdb/authorizer"
|
"github.com/influxdata/influxdb/v2/authorizer"
|
||||||
influxdbcontext "github.com/influxdata/influxdb/context"
|
influxdbcontext "github.com/influxdata/influxdb/v2/context"
|
||||||
"github.com/influxdata/influxdb/mock"
|
"github.com/influxdata/influxdb/v2/mock"
|
||||||
influxdbtesting "github.com/influxdata/influxdb/testing"
|
"github.com/influxdata/influxdb/v2/notification/check"
|
||||||
|
influxdbtesting "github.com/influxdata/influxdb/v2/testing"
|
||||||
)
|
)
|
||||||
|
|
||||||
var checkCmpOptions = cmp.Options{
|
var checkCmpOptions = cmp.Options{
|
||||||
|
|
|
@ -3,7 +3,7 @@ package authorizer
|
||||||
import (
|
import (
|
||||||
"context"
|
"context"
|
||||||
|
|
||||||
"github.com/influxdata/influxdb"
|
"github.com/influxdata/influxdb/v2"
|
||||||
)
|
)
|
||||||
|
|
||||||
var _ influxdb.DashboardService = (*DashboardService)(nil)
|
var _ influxdb.DashboardService = (*DashboardService)(nil)
|
||||||
|
|
|
@ -7,11 +7,11 @@ import (
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
"github.com/google/go-cmp/cmp"
|
"github.com/google/go-cmp/cmp"
|
||||||
"github.com/influxdata/influxdb"
|
"github.com/influxdata/influxdb/v2"
|
||||||
"github.com/influxdata/influxdb/authorizer"
|
"github.com/influxdata/influxdb/v2/authorizer"
|
||||||
influxdbcontext "github.com/influxdata/influxdb/context"
|
influxdbcontext "github.com/influxdata/influxdb/v2/context"
|
||||||
"github.com/influxdata/influxdb/mock"
|
"github.com/influxdata/influxdb/v2/mock"
|
||||||
influxdbtesting "github.com/influxdata/influxdb/testing"
|
influxdbtesting "github.com/influxdata/influxdb/v2/testing"
|
||||||
)
|
)
|
||||||
|
|
||||||
var dashboardCmpOptions = cmp.Options{
|
var dashboardCmpOptions = cmp.Options{
|
||||||
|
|
|
@ -4,7 +4,7 @@ import (
|
||||||
"context"
|
"context"
|
||||||
"fmt"
|
"fmt"
|
||||||
|
|
||||||
"github.com/influxdata/influxdb"
|
"github.com/influxdata/influxdb/v2"
|
||||||
)
|
)
|
||||||
|
|
||||||
var _ influxdb.DocumentService = (*DocumentService)(nil)
|
var _ influxdb.DocumentService = (*DocumentService)(nil)
|
||||||
|
|
|
@ -4,7 +4,7 @@ import (
|
||||||
"context"
|
"context"
|
||||||
"errors"
|
"errors"
|
||||||
|
|
||||||
"github.com/influxdata/influxdb"
|
"github.com/influxdata/influxdb/v2"
|
||||||
)
|
)
|
||||||
|
|
||||||
var _ influxdb.LabelService = (*LabelService)(nil)
|
var _ influxdb.LabelService = (*LabelService)(nil)
|
||||||
|
|
|
@ -7,11 +7,11 @@ import (
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
"github.com/google/go-cmp/cmp"
|
"github.com/google/go-cmp/cmp"
|
||||||
"github.com/influxdata/influxdb"
|
"github.com/influxdata/influxdb/v2"
|
||||||
"github.com/influxdata/influxdb/authorizer"
|
"github.com/influxdata/influxdb/v2/authorizer"
|
||||||
influxdbcontext "github.com/influxdata/influxdb/context"
|
influxdbcontext "github.com/influxdata/influxdb/v2/context"
|
||||||
"github.com/influxdata/influxdb/mock"
|
"github.com/influxdata/influxdb/v2/mock"
|
||||||
influxdbtesting "github.com/influxdata/influxdb/testing"
|
influxdbtesting "github.com/influxdata/influxdb/v2/testing"
|
||||||
)
|
)
|
||||||
|
|
||||||
const (
|
const (
|
||||||
|
|
|
@ -3,7 +3,7 @@ package authorizer
|
||||||
import (
|
import (
|
||||||
"context"
|
"context"
|
||||||
|
|
||||||
"github.com/influxdata/influxdb"
|
"github.com/influxdata/influxdb/v2"
|
||||||
)
|
)
|
||||||
|
|
||||||
var _ influxdb.NotificationEndpointService = (*NotificationEndpointService)(nil)
|
var _ influxdb.NotificationEndpointService = (*NotificationEndpointService)(nil)
|
||||||
|
|
|
@ -7,12 +7,12 @@ import (
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
"github.com/google/go-cmp/cmp"
|
"github.com/google/go-cmp/cmp"
|
||||||
"github.com/influxdata/influxdb"
|
"github.com/influxdata/influxdb/v2"
|
||||||
"github.com/influxdata/influxdb/authorizer"
|
"github.com/influxdata/influxdb/v2/authorizer"
|
||||||
influxdbcontext "github.com/influxdata/influxdb/context"
|
influxdbcontext "github.com/influxdata/influxdb/v2/context"
|
||||||
"github.com/influxdata/influxdb/mock"
|
"github.com/influxdata/influxdb/v2/mock"
|
||||||
"github.com/influxdata/influxdb/notification/endpoint"
|
"github.com/influxdata/influxdb/v2/notification/endpoint"
|
||||||
influxdbtesting "github.com/influxdata/influxdb/testing"
|
influxdbtesting "github.com/influxdata/influxdb/v2/testing"
|
||||||
)
|
)
|
||||||
|
|
||||||
var notificationEndpointCmpOptions = cmp.Options{
|
var notificationEndpointCmpOptions = cmp.Options{
|
||||||
|
|
|
@ -3,7 +3,7 @@ package authorizer
|
||||||
import (
|
import (
|
||||||
"context"
|
"context"
|
||||||
|
|
||||||
"github.com/influxdata/influxdb"
|
"github.com/influxdata/influxdb/v2"
|
||||||
)
|
)
|
||||||
|
|
||||||
var _ influxdb.NotificationRuleStore = (*NotificationRuleStore)(nil)
|
var _ influxdb.NotificationRuleStore = (*NotificationRuleStore)(nil)
|
||||||
|
|
|
@ -6,14 +6,13 @@ import (
|
||||||
"sort"
|
"sort"
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
"github.com/influxdata/influxdb/notification/rule"
|
|
||||||
|
|
||||||
"github.com/google/go-cmp/cmp"
|
"github.com/google/go-cmp/cmp"
|
||||||
"github.com/influxdata/influxdb"
|
"github.com/influxdata/influxdb/v2"
|
||||||
"github.com/influxdata/influxdb/authorizer"
|
"github.com/influxdata/influxdb/v2/authorizer"
|
||||||
influxdbcontext "github.com/influxdata/influxdb/context"
|
influxdbcontext "github.com/influxdata/influxdb/v2/context"
|
||||||
"github.com/influxdata/influxdb/mock"
|
"github.com/influxdata/influxdb/v2/mock"
|
||||||
influxdbtesting "github.com/influxdata/influxdb/testing"
|
"github.com/influxdata/influxdb/v2/notification/rule"
|
||||||
|
influxdbtesting "github.com/influxdata/influxdb/v2/testing"
|
||||||
)
|
)
|
||||||
|
|
||||||
var notificationRuleCmpOptions = cmp.Options{
|
var notificationRuleCmpOptions = cmp.Options{
|
||||||
|
|
|
@ -3,7 +3,7 @@ package authorizer
|
||||||
import (
|
import (
|
||||||
"context"
|
"context"
|
||||||
|
|
||||||
"github.com/influxdata/influxdb"
|
"github.com/influxdata/influxdb/v2"
|
||||||
)
|
)
|
||||||
|
|
||||||
var _ influxdb.OrganizationService = (*OrgService)(nil)
|
var _ influxdb.OrganizationService = (*OrgService)(nil)
|
||||||
|
|
|
@ -7,11 +7,11 @@ import (
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
"github.com/google/go-cmp/cmp"
|
"github.com/google/go-cmp/cmp"
|
||||||
"github.com/influxdata/influxdb"
|
"github.com/influxdata/influxdb/v2"
|
||||||
"github.com/influxdata/influxdb/authorizer"
|
"github.com/influxdata/influxdb/v2/authorizer"
|
||||||
influxdbcontext "github.com/influxdata/influxdb/context"
|
influxdbcontext "github.com/influxdata/influxdb/v2/context"
|
||||||
"github.com/influxdata/influxdb/mock"
|
"github.com/influxdata/influxdb/v2/mock"
|
||||||
influxdbtesting "github.com/influxdata/influxdb/testing"
|
influxdbtesting "github.com/influxdata/influxdb/v2/testing"
|
||||||
)
|
)
|
||||||
|
|
||||||
var orgCmpOptions = cmp.Options{
|
var orgCmpOptions = cmp.Options{
|
||||||
|
|
|
@ -3,7 +3,7 @@ package authorizer
|
||||||
import (
|
import (
|
||||||
"context"
|
"context"
|
||||||
|
|
||||||
"github.com/influxdata/influxdb"
|
"github.com/influxdata/influxdb/v2"
|
||||||
)
|
)
|
||||||
|
|
||||||
// PasswordService is a new authorization middleware for a password service.
|
// PasswordService is a new authorization middleware for a password service.
|
||||||
|
|
|
@ -4,10 +4,10 @@ import (
|
||||||
"context"
|
"context"
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
"github.com/influxdata/influxdb"
|
"github.com/influxdata/influxdb/v2"
|
||||||
"github.com/influxdata/influxdb/authorizer"
|
"github.com/influxdata/influxdb/v2/authorizer"
|
||||||
icontext "github.com/influxdata/influxdb/context"
|
icontext "github.com/influxdata/influxdb/v2/context"
|
||||||
"github.com/influxdata/influxdb/mock"
|
"github.com/influxdata/influxdb/v2/mock"
|
||||||
"github.com/stretchr/testify/require"
|
"github.com/stretchr/testify/require"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
|
@ -3,7 +3,7 @@ package authorizer
|
||||||
import (
|
import (
|
||||||
"context"
|
"context"
|
||||||
|
|
||||||
"github.com/influxdata/influxdb"
|
"github.com/influxdata/influxdb/v2"
|
||||||
)
|
)
|
||||||
|
|
||||||
var _ influxdb.ScraperTargetStoreService = (*ScraperTargetStoreService)(nil)
|
var _ influxdb.ScraperTargetStoreService = (*ScraperTargetStoreService)(nil)
|
||||||
|
|
|
@ -7,11 +7,11 @@ import (
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
"github.com/google/go-cmp/cmp"
|
"github.com/google/go-cmp/cmp"
|
||||||
"github.com/influxdata/influxdb"
|
"github.com/influxdata/influxdb/v2"
|
||||||
"github.com/influxdata/influxdb/authorizer"
|
"github.com/influxdata/influxdb/v2/authorizer"
|
||||||
influxdbcontext "github.com/influxdata/influxdb/context"
|
influxdbcontext "github.com/influxdata/influxdb/v2/context"
|
||||||
"github.com/influxdata/influxdb/mock"
|
"github.com/influxdata/influxdb/v2/mock"
|
||||||
influxdbtesting "github.com/influxdata/influxdb/testing"
|
influxdbtesting "github.com/influxdata/influxdb/v2/testing"
|
||||||
)
|
)
|
||||||
|
|
||||||
var scraperCmpOptions = cmp.Options{
|
var scraperCmpOptions = cmp.Options{
|
||||||
|
|
|
@ -3,7 +3,7 @@ package authorizer
|
||||||
import (
|
import (
|
||||||
"context"
|
"context"
|
||||||
|
|
||||||
"github.com/influxdata/influxdb"
|
"github.com/influxdata/influxdb/v2"
|
||||||
)
|
)
|
||||||
|
|
||||||
var _ influxdb.SecretService = (*SecretService)(nil)
|
var _ influxdb.SecretService = (*SecretService)(nil)
|
||||||
|
|
|
@ -6,11 +6,11 @@ import (
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
"github.com/google/go-cmp/cmp"
|
"github.com/google/go-cmp/cmp"
|
||||||
"github.com/influxdata/influxdb"
|
"github.com/influxdata/influxdb/v2"
|
||||||
"github.com/influxdata/influxdb/authorizer"
|
"github.com/influxdata/influxdb/v2/authorizer"
|
||||||
influxdbcontext "github.com/influxdata/influxdb/context"
|
influxdbcontext "github.com/influxdata/influxdb/v2/context"
|
||||||
"github.com/influxdata/influxdb/mock"
|
"github.com/influxdata/influxdb/v2/mock"
|
||||||
influxdbtesting "github.com/influxdata/influxdb/testing"
|
influxdbtesting "github.com/influxdata/influxdb/v2/testing"
|
||||||
)
|
)
|
||||||
|
|
||||||
var secretCmpOptions = cmp.Options{
|
var secretCmpOptions = cmp.Options{
|
||||||
|
|
|
@ -3,7 +3,7 @@ package authorizer
|
||||||
import (
|
import (
|
||||||
"context"
|
"context"
|
||||||
|
|
||||||
"github.com/influxdata/influxdb"
|
"github.com/influxdata/influxdb/v2"
|
||||||
)
|
)
|
||||||
|
|
||||||
var _ influxdb.SourceService = (*SourceService)(nil)
|
var _ influxdb.SourceService = (*SourceService)(nil)
|
||||||
|
|
|
@ -7,11 +7,11 @@ import (
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
"github.com/google/go-cmp/cmp"
|
"github.com/google/go-cmp/cmp"
|
||||||
"github.com/influxdata/influxdb"
|
"github.com/influxdata/influxdb/v2"
|
||||||
"github.com/influxdata/influxdb/authorizer"
|
"github.com/influxdata/influxdb/v2/authorizer"
|
||||||
influxdbcontext "github.com/influxdata/influxdb/context"
|
influxdbcontext "github.com/influxdata/influxdb/v2/context"
|
||||||
"github.com/influxdata/influxdb/mock"
|
"github.com/influxdata/influxdb/v2/mock"
|
||||||
influxdbtesting "github.com/influxdata/influxdb/testing"
|
influxdbtesting "github.com/influxdata/influxdb/v2/testing"
|
||||||
)
|
)
|
||||||
|
|
||||||
var sourceCmpOptions = cmp.Options{
|
var sourceCmpOptions = cmp.Options{
|
||||||
|
|
|
@ -4,8 +4,8 @@ import (
|
||||||
"context"
|
"context"
|
||||||
"fmt"
|
"fmt"
|
||||||
|
|
||||||
"github.com/influxdata/influxdb"
|
"github.com/influxdata/influxdb/v2"
|
||||||
"github.com/influxdata/influxdb/kit/tracing"
|
"github.com/influxdata/influxdb/v2/kit/tracing"
|
||||||
"go.uber.org/zap"
|
"go.uber.org/zap"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
|
@ -5,14 +5,14 @@ import (
|
||||||
"testing"
|
"testing"
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
"github.com/influxdata/influxdb"
|
"github.com/influxdata/influxdb/v2"
|
||||||
"github.com/influxdata/influxdb/authorizer"
|
"github.com/influxdata/influxdb/v2/authorizer"
|
||||||
pctx "github.com/influxdata/influxdb/context"
|
pctx "github.com/influxdata/influxdb/v2/context"
|
||||||
"github.com/influxdata/influxdb/http"
|
"github.com/influxdata/influxdb/v2/http"
|
||||||
"github.com/influxdata/influxdb/inmem"
|
"github.com/influxdata/influxdb/v2/inmem"
|
||||||
"github.com/influxdata/influxdb/kv"
|
"github.com/influxdata/influxdb/v2/kv"
|
||||||
"github.com/influxdata/influxdb/mock"
|
"github.com/influxdata/influxdb/v2/mock"
|
||||||
_ "github.com/influxdata/influxdb/query/builtin"
|
_ "github.com/influxdata/influxdb/v2/query/builtin"
|
||||||
"github.com/pkg/errors"
|
"github.com/pkg/errors"
|
||||||
"go.uber.org/zap/zaptest"
|
"go.uber.org/zap/zaptest"
|
||||||
)
|
)
|
||||||
|
|
|
@ -3,7 +3,7 @@ package authorizer
|
||||||
import (
|
import (
|
||||||
"context"
|
"context"
|
||||||
|
|
||||||
"github.com/influxdata/influxdb"
|
"github.com/influxdata/influxdb/v2"
|
||||||
)
|
)
|
||||||
|
|
||||||
var _ influxdb.TelegrafConfigStore = (*TelegrafConfigService)(nil)
|
var _ influxdb.TelegrafConfigStore = (*TelegrafConfigService)(nil)
|
||||||
|
|
|
@ -7,11 +7,11 @@ import (
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
"github.com/google/go-cmp/cmp"
|
"github.com/google/go-cmp/cmp"
|
||||||
"github.com/influxdata/influxdb"
|
"github.com/influxdata/influxdb/v2"
|
||||||
"github.com/influxdata/influxdb/authorizer"
|
"github.com/influxdata/influxdb/v2/authorizer"
|
||||||
influxdbcontext "github.com/influxdata/influxdb/context"
|
influxdbcontext "github.com/influxdata/influxdb/v2/context"
|
||||||
"github.com/influxdata/influxdb/mock"
|
"github.com/influxdata/influxdb/v2/mock"
|
||||||
influxdbtesting "github.com/influxdata/influxdb/testing"
|
influxdbtesting "github.com/influxdata/influxdb/v2/testing"
|
||||||
)
|
)
|
||||||
|
|
||||||
var telegrafCmpOptions = cmp.Options{
|
var telegrafCmpOptions = cmp.Options{
|
||||||
|
|
|
@ -3,7 +3,7 @@ package authorizer
|
||||||
import (
|
import (
|
||||||
"context"
|
"context"
|
||||||
|
|
||||||
"github.com/influxdata/influxdb"
|
"github.com/influxdata/influxdb/v2"
|
||||||
)
|
)
|
||||||
|
|
||||||
type OrganizationService interface {
|
type OrganizationService interface {
|
||||||
|
|
|
@ -5,11 +5,11 @@ import (
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
"github.com/google/go-cmp/cmp"
|
"github.com/google/go-cmp/cmp"
|
||||||
"github.com/influxdata/influxdb"
|
"github.com/influxdata/influxdb/v2"
|
||||||
"github.com/influxdata/influxdb/authorizer"
|
"github.com/influxdata/influxdb/v2/authorizer"
|
||||||
influxdbcontext "github.com/influxdata/influxdb/context"
|
influxdbcontext "github.com/influxdata/influxdb/v2/context"
|
||||||
"github.com/influxdata/influxdb/mock"
|
"github.com/influxdata/influxdb/v2/mock"
|
||||||
influxdbtesting "github.com/influxdata/influxdb/testing"
|
influxdbtesting "github.com/influxdata/influxdb/v2/testing"
|
||||||
)
|
)
|
||||||
|
|
||||||
type OrgService struct {
|
type OrgService struct {
|
||||||
|
|
|
@ -3,7 +3,7 @@ package authorizer
|
||||||
import (
|
import (
|
||||||
"context"
|
"context"
|
||||||
|
|
||||||
"github.com/influxdata/influxdb"
|
"github.com/influxdata/influxdb/v2"
|
||||||
)
|
)
|
||||||
|
|
||||||
var _ influxdb.UserService = (*UserService)(nil)
|
var _ influxdb.UserService = (*UserService)(nil)
|
||||||
|
|
|
@ -7,11 +7,11 @@ import (
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
"github.com/google/go-cmp/cmp"
|
"github.com/google/go-cmp/cmp"
|
||||||
"github.com/influxdata/influxdb"
|
"github.com/influxdata/influxdb/v2"
|
||||||
"github.com/influxdata/influxdb/authorizer"
|
"github.com/influxdata/influxdb/v2/authorizer"
|
||||||
influxdbcontext "github.com/influxdata/influxdb/context"
|
influxdbcontext "github.com/influxdata/influxdb/v2/context"
|
||||||
"github.com/influxdata/influxdb/mock"
|
"github.com/influxdata/influxdb/v2/mock"
|
||||||
influxdbtesting "github.com/influxdata/influxdb/testing"
|
influxdbtesting "github.com/influxdata/influxdb/v2/testing"
|
||||||
)
|
)
|
||||||
|
|
||||||
var userCmpOptions = cmp.Options{
|
var userCmpOptions = cmp.Options{
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
package authorizer_test
|
package authorizer_test
|
||||||
|
|
||||||
import "github.com/influxdata/influxdb"
|
import "github.com/influxdata/influxdb/v2"
|
||||||
|
|
||||||
// Authorizer is mock authorizer that can be used in testing.
|
// Authorizer is mock authorizer that can be used in testing.
|
||||||
type Authorizer struct {
|
type Authorizer struct {
|
||||||
|
|
|
@ -3,7 +3,7 @@ package authorizer
|
||||||
import (
|
import (
|
||||||
"context"
|
"context"
|
||||||
|
|
||||||
"github.com/influxdata/influxdb"
|
"github.com/influxdata/influxdb/v2"
|
||||||
)
|
)
|
||||||
|
|
||||||
var _ influxdb.VariableService = (*VariableService)(nil)
|
var _ influxdb.VariableService = (*VariableService)(nil)
|
||||||
|
|
|
@ -7,11 +7,11 @@ import (
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
"github.com/google/go-cmp/cmp"
|
"github.com/google/go-cmp/cmp"
|
||||||
"github.com/influxdata/influxdb"
|
"github.com/influxdata/influxdb/v2"
|
||||||
"github.com/influxdata/influxdb/authorizer"
|
"github.com/influxdata/influxdb/v2/authorizer"
|
||||||
influxdbcontext "github.com/influxdata/influxdb/context"
|
influxdbcontext "github.com/influxdata/influxdb/v2/context"
|
||||||
"github.com/influxdata/influxdb/mock"
|
"github.com/influxdata/influxdb/v2/mock"
|
||||||
influxdbtesting "github.com/influxdata/influxdb/testing"
|
influxdbtesting "github.com/influxdata/influxdb/v2/testing"
|
||||||
)
|
)
|
||||||
|
|
||||||
var variableCmpOptions = cmp.Options{
|
var variableCmpOptions = cmp.Options{
|
||||||
|
|
|
@ -3,8 +3,8 @@ package influxdb_test
|
||||||
import (
|
import (
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
platform "github.com/influxdata/influxdb"
|
platform "github.com/influxdata/influxdb/v2"
|
||||||
influxdbtesting "github.com/influxdata/influxdb/testing"
|
influxdbtesting "github.com/influxdata/influxdb/v2/testing"
|
||||||
)
|
)
|
||||||
|
|
||||||
func TestAuthorizer_PermissionAllowed(t *testing.T) {
|
func TestAuthorizer_PermissionAllowed(t *testing.T) {
|
||||||
|
|
|
@ -8,9 +8,9 @@ import (
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
bolt "github.com/coreos/bbolt"
|
bolt "github.com/coreos/bbolt"
|
||||||
platform "github.com/influxdata/influxdb"
|
platform "github.com/influxdata/influxdb/v2"
|
||||||
"github.com/influxdata/influxdb/rand"
|
"github.com/influxdata/influxdb/v2/rand"
|
||||||
"github.com/influxdata/influxdb/snowflake"
|
"github.com/influxdata/influxdb/v2/snowflake"
|
||||||
"go.uber.org/zap"
|
"go.uber.org/zap"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
|
@ -8,7 +8,7 @@ import (
|
||||||
"path/filepath"
|
"path/filepath"
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
"github.com/influxdata/influxdb/bolt"
|
"github.com/influxdata/influxdb/v2/bolt"
|
||||||
"go.uber.org/zap/zaptest"
|
"go.uber.org/zap/zaptest"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
|
@ -6,7 +6,7 @@ import (
|
||||||
"math/rand"
|
"math/rand"
|
||||||
|
|
||||||
bolt "github.com/coreos/bbolt"
|
bolt "github.com/coreos/bbolt"
|
||||||
platform "github.com/influxdata/influxdb"
|
platform "github.com/influxdata/influxdb/v2"
|
||||||
"go.uber.org/zap"
|
"go.uber.org/zap"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
|
@ -4,8 +4,8 @@ import (
|
||||||
"context"
|
"context"
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
platform "github.com/influxdata/influxdb"
|
platform "github.com/influxdata/influxdb/v2"
|
||||||
"github.com/influxdata/influxdb/mock"
|
"github.com/influxdata/influxdb/v2/mock"
|
||||||
)
|
)
|
||||||
|
|
||||||
func TestID(t *testing.T) {
|
func TestID(t *testing.T) {
|
||||||
|
|
|
@ -10,8 +10,8 @@ import (
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
bolt "github.com/coreos/bbolt"
|
bolt "github.com/coreos/bbolt"
|
||||||
"github.com/influxdata/influxdb/kit/tracing"
|
"github.com/influxdata/influxdb/v2/kit/tracing"
|
||||||
"github.com/influxdata/influxdb/kv"
|
"github.com/influxdata/influxdb/v2/kv"
|
||||||
"go.uber.org/zap"
|
"go.uber.org/zap"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
|
@ -4,8 +4,8 @@ import (
|
||||||
"context"
|
"context"
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
"github.com/influxdata/influxdb/kv"
|
"github.com/influxdata/influxdb/v2/kv"
|
||||||
platformtesting "github.com/influxdata/influxdb/testing"
|
platformtesting "github.com/influxdata/influxdb/v2/testing"
|
||||||
)
|
)
|
||||||
|
|
||||||
func initKVStore(f platformtesting.KVStoreFields, t *testing.T) (kv.Store, func()) {
|
func initKVStore(f platformtesting.KVStoreFields, t *testing.T) (kv.Store, func()) {
|
||||||
|
|
|
@ -3,8 +3,8 @@ package bolt_test
|
||||||
import (
|
import (
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
"github.com/influxdata/influxdb/kit/prom"
|
"github.com/influxdata/influxdb/v2/kit/prom"
|
||||||
"github.com/influxdata/influxdb/kit/prom/promtest"
|
"github.com/influxdata/influxdb/v2/kit/prom/promtest"
|
||||||
"go.uber.org/zap/zaptest"
|
"go.uber.org/zap/zaptest"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
|
@ -6,7 +6,7 @@ import (
|
||||||
"regexp"
|
"regexp"
|
||||||
"strings"
|
"strings"
|
||||||
|
|
||||||
"github.com/influxdata/influxdb/chronograf"
|
"github.com/influxdata/influxdb/v2/chronograf"
|
||||||
"github.com/influxdata/kapacitor/pipeline"
|
"github.com/influxdata/kapacitor/pipeline"
|
||||||
"github.com/influxdata/kapacitor/pipeline/tick"
|
"github.com/influxdata/kapacitor/pipeline/tick"
|
||||||
)
|
)
|
||||||
|
|
|
@ -3,7 +3,7 @@ package kapacitor
|
||||||
import (
|
import (
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
"github.com/influxdata/influxdb/chronograf"
|
"github.com/influxdata/influxdb/v2/chronograf"
|
||||||
)
|
)
|
||||||
|
|
||||||
func TestAlertServices(t *testing.T) {
|
func TestAlertServices(t *testing.T) {
|
||||||
|
|
|
@ -7,7 +7,7 @@ import (
|
||||||
"strings"
|
"strings"
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
"github.com/influxdata/influxdb/chronograf"
|
"github.com/influxdata/influxdb/v2/chronograf"
|
||||||
"github.com/influxdata/kapacitor/pipeline"
|
"github.com/influxdata/kapacitor/pipeline"
|
||||||
"github.com/influxdata/kapacitor/tick"
|
"github.com/influxdata/kapacitor/tick"
|
||||||
"github.com/influxdata/kapacitor/tick/ast"
|
"github.com/influxdata/kapacitor/tick/ast"
|
||||||
|
|
|
@ -5,7 +5,7 @@ import (
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
"github.com/google/go-cmp/cmp"
|
"github.com/google/go-cmp/cmp"
|
||||||
"github.com/influxdata/influxdb/chronograf"
|
"github.com/influxdata/influxdb/v2/chronograf"
|
||||||
)
|
)
|
||||||
|
|
||||||
func TestReverse(t *testing.T) {
|
func TestReverse(t *testing.T) {
|
||||||
|
|
|
@ -4,8 +4,8 @@ import (
|
||||||
"context"
|
"context"
|
||||||
"fmt"
|
"fmt"
|
||||||
|
|
||||||
"github.com/influxdata/influxdb/chronograf"
|
"github.com/influxdata/influxdb/v2/chronograf"
|
||||||
"github.com/influxdata/influxdb/chronograf/id"
|
"github.com/influxdata/influxdb/v2/chronograf/id"
|
||||||
client "github.com/influxdata/kapacitor/client/v1"
|
client "github.com/influxdata/kapacitor/client/v1"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
|
@ -8,7 +8,7 @@ import (
|
||||||
|
|
||||||
"github.com/google/go-cmp/cmp"
|
"github.com/google/go-cmp/cmp"
|
||||||
"github.com/google/go-cmp/cmp/cmpopts"
|
"github.com/google/go-cmp/cmp/cmpopts"
|
||||||
"github.com/influxdata/influxdb/chronograf"
|
"github.com/influxdata/influxdb/v2/chronograf"
|
||||||
client "github.com/influxdata/kapacitor/client/v1"
|
client "github.com/influxdata/kapacitor/client/v1"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
|
@ -3,7 +3,7 @@ package kapacitor
|
||||||
import (
|
import (
|
||||||
"fmt"
|
"fmt"
|
||||||
|
|
||||||
"github.com/influxdata/influxdb/chronograf"
|
"github.com/influxdata/influxdb/v2/chronograf"
|
||||||
)
|
)
|
||||||
|
|
||||||
// Data returns the tickscript data section for querying
|
// Data returns the tickscript data section for querying
|
||||||
|
|
|
@ -5,7 +5,7 @@ import (
|
||||||
"fmt"
|
"fmt"
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
"github.com/influxdata/influxdb/chronograf"
|
"github.com/influxdata/influxdb/v2/chronograf"
|
||||||
)
|
)
|
||||||
|
|
||||||
var config = `{
|
var config = `{
|
||||||
|
|
|
@ -3,7 +3,7 @@ package kapacitor
|
||||||
import (
|
import (
|
||||||
"fmt"
|
"fmt"
|
||||||
|
|
||||||
"github.com/influxdata/influxdb/chronograf"
|
"github.com/influxdata/influxdb/v2/chronograf"
|
||||||
)
|
)
|
||||||
|
|
||||||
// HTTPEndpoint is the default location of the tickscript output
|
// HTTPEndpoint is the default location of the tickscript output
|
||||||
|
|
|
@ -3,7 +3,7 @@ package kapacitor
|
||||||
import (
|
import (
|
||||||
"fmt"
|
"fmt"
|
||||||
|
|
||||||
"github.com/influxdata/influxdb/chronograf"
|
"github.com/influxdata/influxdb/v2/chronograf"
|
||||||
)
|
)
|
||||||
|
|
||||||
// InfluxOut creates a kapacitor influxDBOut node to write alert data to Database, RP, Measurement.
|
// InfluxOut creates a kapacitor influxDBOut node to write alert data to Database, RP, Measurement.
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
package kapacitor
|
package kapacitor
|
||||||
|
|
||||||
import "testing"
|
import "testing"
|
||||||
import "github.com/influxdata/influxdb/chronograf"
|
import "github.com/influxdata/influxdb/v2/chronograf"
|
||||||
|
|
||||||
func TestInfluxOut(t *testing.T) {
|
func TestInfluxOut(t *testing.T) {
|
||||||
tests := []struct {
|
tests := []struct {
|
||||||
|
|
|
@ -3,8 +3,8 @@ package kapacitor_test
|
||||||
import (
|
import (
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
"github.com/influxdata/influxdb/chronograf/kapacitor"
|
"github.com/influxdata/influxdb/v2/chronograf/kapacitor"
|
||||||
"github.com/influxdata/influxdb/chronograf/mocks"
|
"github.com/influxdata/influxdb/v2/chronograf/mocks"
|
||||||
client "github.com/influxdata/kapacitor/client/v1"
|
client "github.com/influxdata/kapacitor/client/v1"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
|
@ -3,8 +3,8 @@ package kapacitor_test
|
||||||
import (
|
import (
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
"github.com/influxdata/influxdb/chronograf/kapacitor"
|
"github.com/influxdata/influxdb/v2/chronograf/kapacitor"
|
||||||
"github.com/influxdata/influxdb/chronograf/mocks"
|
"github.com/influxdata/influxdb/v2/chronograf/mocks"
|
||||||
client "github.com/influxdata/kapacitor/client/v1"
|
client "github.com/influxdata/kapacitor/client/v1"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
|
@ -4,7 +4,7 @@ import (
|
||||||
"bytes"
|
"bytes"
|
||||||
"encoding/json"
|
"encoding/json"
|
||||||
|
|
||||||
"github.com/influxdata/influxdb/chronograf"
|
"github.com/influxdata/influxdb/v2/chronograf"
|
||||||
"github.com/influxdata/kapacitor/pipeline"
|
"github.com/influxdata/kapacitor/pipeline"
|
||||||
totick "github.com/influxdata/kapacitor/pipeline/tick"
|
totick "github.com/influxdata/kapacitor/pipeline/tick"
|
||||||
)
|
)
|
||||||
|
|
|
@ -3,7 +3,7 @@ package kapacitor
|
||||||
import (
|
import (
|
||||||
"fmt"
|
"fmt"
|
||||||
|
|
||||||
"github.com/influxdata/influxdb/chronograf"
|
"github.com/influxdata/influxdb/v2/chronograf"
|
||||||
)
|
)
|
||||||
|
|
||||||
var _ chronograf.Ticker = &Alert{}
|
var _ chronograf.Ticker = &Alert{}
|
||||||
|
|
|
@ -5,7 +5,7 @@ import (
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
"github.com/google/go-cmp/cmp"
|
"github.com/google/go-cmp/cmp"
|
||||||
"github.com/influxdata/influxdb/chronograf"
|
"github.com/influxdata/influxdb/v2/chronograf"
|
||||||
"github.com/sergi/go-diff/diffmatchpatch"
|
"github.com/sergi/go-diff/diffmatchpatch"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
|
@ -3,7 +3,7 @@ package kapacitor
|
||||||
import (
|
import (
|
||||||
"fmt"
|
"fmt"
|
||||||
|
|
||||||
"github.com/influxdata/influxdb/chronograf"
|
"github.com/influxdata/influxdb/v2/chronograf"
|
||||||
)
|
)
|
||||||
|
|
||||||
const (
|
const (
|
||||||
|
|
|
@ -3,7 +3,7 @@ package kapacitor
|
||||||
import (
|
import (
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
"github.com/influxdata/influxdb/chronograf"
|
"github.com/influxdata/influxdb/v2/chronograf"
|
||||||
)
|
)
|
||||||
|
|
||||||
func TestTrigger(t *testing.T) {
|
func TestTrigger(t *testing.T) {
|
||||||
|
|
|
@ -6,7 +6,7 @@ import (
|
||||||
"strings"
|
"strings"
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
"github.com/influxdata/influxdb/chronograf"
|
"github.com/influxdata/influxdb/v2/chronograf"
|
||||||
"github.com/influxdata/kapacitor/pipeline"
|
"github.com/influxdata/kapacitor/pipeline"
|
||||||
"github.com/influxdata/kapacitor/tick"
|
"github.com/influxdata/kapacitor/tick"
|
||||||
"github.com/influxdata/kapacitor/tick/ast"
|
"github.com/influxdata/kapacitor/tick/ast"
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
package kapacitor
|
package kapacitor
|
||||||
|
|
||||||
import "testing"
|
import "testing"
|
||||||
import "github.com/influxdata/influxdb/chronograf"
|
import "github.com/influxdata/influxdb/v2/chronograf"
|
||||||
|
|
||||||
func TestValidateAlert(t *testing.T) {
|
func TestValidateAlert(t *testing.T) {
|
||||||
tests := []struct {
|
tests := []struct {
|
||||||
|
|
|
@ -6,7 +6,7 @@ import (
|
||||||
"strconv"
|
"strconv"
|
||||||
"strings"
|
"strings"
|
||||||
|
|
||||||
"github.com/influxdata/influxdb/chronograf"
|
"github.com/influxdata/influxdb/v2/chronograf"
|
||||||
)
|
)
|
||||||
|
|
||||||
var (
|
var (
|
||||||
|
|
|
@ -4,7 +4,7 @@ import (
|
||||||
"fmt"
|
"fmt"
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
"github.com/influxdata/influxdb/chronograf"
|
"github.com/influxdata/influxdb/v2/chronograf"
|
||||||
)
|
)
|
||||||
|
|
||||||
func TestVarsCritStringEqual(t *testing.T) {
|
func TestVarsCritStringEqual(t *testing.T) {
|
||||||
|
|
|
@ -7,9 +7,9 @@ import (
|
||||||
"os"
|
"os"
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
"github.com/influxdata/influxdb/chronograf"
|
"github.com/influxdata/influxdb/v2/chronograf"
|
||||||
"github.com/influxdata/influxdb/chronograf/bolt"
|
"github.com/influxdata/influxdb/v2/chronograf/bolt"
|
||||||
"github.com/influxdata/influxdb/chronograf/mocks"
|
"github.com/influxdata/influxdb/v2/chronograf/mocks"
|
||||||
)
|
)
|
||||||
|
|
||||||
// TestNow is a set time for testing.
|
// TestNow is a set time for testing.
|
||||||
|
|
|
@ -4,8 +4,8 @@ import (
|
||||||
"context"
|
"context"
|
||||||
|
|
||||||
bolt "github.com/coreos/bbolt"
|
bolt "github.com/coreos/bbolt"
|
||||||
"github.com/influxdata/influxdb/chronograf"
|
"github.com/influxdata/influxdb/v2/chronograf"
|
||||||
"github.com/influxdata/influxdb/chronograf/bolt/internal"
|
"github.com/influxdata/influxdb/v2/chronograf/bolt/internal"
|
||||||
)
|
)
|
||||||
|
|
||||||
// Ensure BuildStore struct implements chronograf.BuildStore interface
|
// Ensure BuildStore struct implements chronograf.BuildStore interface
|
||||||
|
|
|
@ -9,8 +9,8 @@ import (
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
bolt "github.com/coreos/bbolt"
|
bolt "github.com/coreos/bbolt"
|
||||||
"github.com/influxdata/influxdb/chronograf"
|
"github.com/influxdata/influxdb/v2/chronograf"
|
||||||
"github.com/influxdata/influxdb/chronograf/id"
|
"github.com/influxdata/influxdb/v2/chronograf/id"
|
||||||
)
|
)
|
||||||
|
|
||||||
// Client is a client for the boltDB data store.
|
// Client is a client for the boltDB data store.
|
||||||
|
|
|
@ -5,8 +5,8 @@ import (
|
||||||
"fmt"
|
"fmt"
|
||||||
|
|
||||||
bolt "github.com/coreos/bbolt"
|
bolt "github.com/coreos/bbolt"
|
||||||
"github.com/influxdata/influxdb/chronograf"
|
"github.com/influxdata/influxdb/v2/chronograf"
|
||||||
"github.com/influxdata/influxdb/chronograf/bolt/internal"
|
"github.com/influxdata/influxdb/v2/chronograf/bolt/internal"
|
||||||
)
|
)
|
||||||
|
|
||||||
// Ensure ConfigStore implements chronograf.ConfigStore.
|
// Ensure ConfigStore implements chronograf.ConfigStore.
|
||||||
|
|
|
@ -5,7 +5,7 @@ import (
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
"github.com/google/go-cmp/cmp"
|
"github.com/google/go-cmp/cmp"
|
||||||
"github.com/influxdata/influxdb/chronograf"
|
"github.com/influxdata/influxdb/v2/chronograf"
|
||||||
)
|
)
|
||||||
|
|
||||||
func TestConfig_Get(t *testing.T) {
|
func TestConfig_Get(t *testing.T) {
|
||||||
|
|
|
@ -5,8 +5,8 @@ import (
|
||||||
"strconv"
|
"strconv"
|
||||||
|
|
||||||
bolt "github.com/coreos/bbolt"
|
bolt "github.com/coreos/bbolt"
|
||||||
"github.com/influxdata/influxdb/chronograf"
|
"github.com/influxdata/influxdb/v2/chronograf"
|
||||||
"github.com/influxdata/influxdb/chronograf/bolt/internal"
|
"github.com/influxdata/influxdb/v2/chronograf/bolt/internal"
|
||||||
)
|
)
|
||||||
|
|
||||||
// Ensure DashboardsStore implements chronograf.DashboardsStore.
|
// Ensure DashboardsStore implements chronograf.DashboardsStore.
|
||||||
|
|
|
@ -5,7 +5,7 @@ import (
|
||||||
"fmt"
|
"fmt"
|
||||||
|
|
||||||
"github.com/gogo/protobuf/proto"
|
"github.com/gogo/protobuf/proto"
|
||||||
"github.com/influxdata/influxdb/chronograf"
|
"github.com/influxdata/influxdb/v2/chronograf"
|
||||||
)
|
)
|
||||||
|
|
||||||
//go:generate protoc --plugin ../../../scripts/protoc-gen-gogo --gogo_out=. internal.proto
|
//go:generate protoc --plugin ../../../scripts/protoc-gen-gogo --gogo_out=. internal.proto
|
||||||
|
|
|
@ -5,8 +5,8 @@ import (
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
"github.com/google/go-cmp/cmp"
|
"github.com/google/go-cmp/cmp"
|
||||||
"github.com/influxdata/influxdb/chronograf"
|
"github.com/influxdata/influxdb/v2/chronograf"
|
||||||
"github.com/influxdata/influxdb/chronograf/bolt/internal"
|
"github.com/influxdata/influxdb/v2/chronograf/bolt/internal"
|
||||||
)
|
)
|
||||||
|
|
||||||
func TestMarshalSource(t *testing.T) {
|
func TestMarshalSource(t *testing.T) {
|
||||||
|
|
|
@ -4,8 +4,8 @@ import (
|
||||||
"context"
|
"context"
|
||||||
|
|
||||||
bolt "github.com/coreos/bbolt"
|
bolt "github.com/coreos/bbolt"
|
||||||
"github.com/influxdata/influxdb/chronograf"
|
"github.com/influxdata/influxdb/v2/chronograf"
|
||||||
"github.com/influxdata/influxdb/chronograf/bolt/internal"
|
"github.com/influxdata/influxdb/v2/chronograf/bolt/internal"
|
||||||
)
|
)
|
||||||
|
|
||||||
// Ensure LayoutsStore implements chronograf.LayoutsStore.
|
// Ensure LayoutsStore implements chronograf.LayoutsStore.
|
||||||
|
|
|
@ -5,8 +5,8 @@ import (
|
||||||
"fmt"
|
"fmt"
|
||||||
|
|
||||||
bolt "github.com/coreos/bbolt"
|
bolt "github.com/coreos/bbolt"
|
||||||
"github.com/influxdata/influxdb/chronograf"
|
"github.com/influxdata/influxdb/v2/chronograf"
|
||||||
"github.com/influxdata/influxdb/chronograf/bolt/internal"
|
"github.com/influxdata/influxdb/v2/chronograf/bolt/internal"
|
||||||
)
|
)
|
||||||
|
|
||||||
// Ensure MappingsStore implements chronograf.MappingsStore.
|
// Ensure MappingsStore implements chronograf.MappingsStore.
|
||||||
|
|
|
@ -6,7 +6,7 @@ import (
|
||||||
|
|
||||||
"github.com/google/go-cmp/cmp"
|
"github.com/google/go-cmp/cmp"
|
||||||
"github.com/google/go-cmp/cmp/cmpopts"
|
"github.com/google/go-cmp/cmp/cmpopts"
|
||||||
"github.com/influxdata/influxdb/chronograf"
|
"github.com/influxdata/influxdb/v2/chronograf"
|
||||||
)
|
)
|
||||||
|
|
||||||
var mappingCmpOptions = cmp.Options{
|
var mappingCmpOptions = cmp.Options{
|
||||||
|
|
|
@ -5,8 +5,8 @@ import (
|
||||||
"fmt"
|
"fmt"
|
||||||
|
|
||||||
bolt "github.com/coreos/bbolt"
|
bolt "github.com/coreos/bbolt"
|
||||||
"github.com/influxdata/influxdb/chronograf"
|
"github.com/influxdata/influxdb/v2/chronograf"
|
||||||
"github.com/influxdata/influxdb/chronograf/bolt/internal"
|
"github.com/influxdata/influxdb/v2/chronograf/bolt/internal"
|
||||||
)
|
)
|
||||||
|
|
||||||
// Ensure OrganizationConfigStore implements chronograf.OrganizationConfigStore.
|
// Ensure OrganizationConfigStore implements chronograf.OrganizationConfigStore.
|
||||||
|
|
|
@ -5,7 +5,7 @@ import (
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
"github.com/google/go-cmp/cmp"
|
"github.com/google/go-cmp/cmp"
|
||||||
"github.com/influxdata/influxdb/chronograf"
|
"github.com/influxdata/influxdb/v2/chronograf"
|
||||||
)
|
)
|
||||||
|
|
||||||
func TestOrganizationConfig_FindOrCreate(t *testing.T) {
|
func TestOrganizationConfig_FindOrCreate(t *testing.T) {
|
||||||
|
|
|
@ -5,9 +5,9 @@ import (
|
||||||
"fmt"
|
"fmt"
|
||||||
|
|
||||||
bolt "github.com/coreos/bbolt"
|
bolt "github.com/coreos/bbolt"
|
||||||
"github.com/influxdata/influxdb/chronograf"
|
"github.com/influxdata/influxdb/v2/chronograf"
|
||||||
"github.com/influxdata/influxdb/chronograf/bolt/internal"
|
"github.com/influxdata/influxdb/v2/chronograf/bolt/internal"
|
||||||
"github.com/influxdata/influxdb/chronograf/organizations"
|
"github.com/influxdata/influxdb/v2/chronograf/organizations"
|
||||||
)
|
)
|
||||||
|
|
||||||
// Ensure OrganizationsStore implements chronograf.OrganizationsStore.
|
// Ensure OrganizationsStore implements chronograf.OrganizationsStore.
|
||||||
|
|
|
@ -6,9 +6,9 @@ import (
|
||||||
|
|
||||||
"github.com/google/go-cmp/cmp"
|
"github.com/google/go-cmp/cmp"
|
||||||
"github.com/google/go-cmp/cmp/cmpopts"
|
"github.com/google/go-cmp/cmp/cmpopts"
|
||||||
"github.com/influxdata/influxdb/chronograf"
|
"github.com/influxdata/influxdb/v2/chronograf"
|
||||||
"github.com/influxdata/influxdb/chronograf/bolt"
|
"github.com/influxdata/influxdb/v2/chronograf/bolt"
|
||||||
"github.com/influxdata/influxdb/chronograf/roles"
|
"github.com/influxdata/influxdb/v2/chronograf/roles"
|
||||||
)
|
)
|
||||||
|
|
||||||
var orgCmpOptions = cmp.Options{
|
var orgCmpOptions = cmp.Options{
|
||||||
|
|
|
@ -4,8 +4,8 @@ import (
|
||||||
"context"
|
"context"
|
||||||
|
|
||||||
bolt "github.com/coreos/bbolt"
|
bolt "github.com/coreos/bbolt"
|
||||||
"github.com/influxdata/influxdb/chronograf"
|
"github.com/influxdata/influxdb/v2/chronograf"
|
||||||
"github.com/influxdata/influxdb/chronograf/bolt/internal"
|
"github.com/influxdata/influxdb/v2/chronograf/bolt/internal"
|
||||||
)
|
)
|
||||||
|
|
||||||
// Ensure ServersStore implements chronograf.ServersStore.
|
// Ensure ServersStore implements chronograf.ServersStore.
|
||||||
|
|
|
@ -5,7 +5,7 @@ import (
|
||||||
"reflect"
|
"reflect"
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
"github.com/influxdata/influxdb/chronograf"
|
"github.com/influxdata/influxdb/v2/chronograf"
|
||||||
)
|
)
|
||||||
|
|
||||||
// Ensure an ServerStore can store, retrieve, update, and delete servers.
|
// Ensure an ServerStore can store, retrieve, update, and delete servers.
|
||||||
|
|
|
@ -5,9 +5,9 @@ import (
|
||||||
"math"
|
"math"
|
||||||
|
|
||||||
bolt "github.com/coreos/bbolt"
|
bolt "github.com/coreos/bbolt"
|
||||||
"github.com/influxdata/influxdb/chronograf"
|
"github.com/influxdata/influxdb/v2/chronograf"
|
||||||
"github.com/influxdata/influxdb/chronograf/bolt/internal"
|
"github.com/influxdata/influxdb/v2/chronograf/bolt/internal"
|
||||||
"github.com/influxdata/influxdb/chronograf/roles"
|
"github.com/influxdata/influxdb/v2/chronograf/roles"
|
||||||
)
|
)
|
||||||
|
|
||||||
// Ensure SourcesStore implements chronograf.SourcesStore.
|
// Ensure SourcesStore implements chronograf.SourcesStore.
|
||||||
|
|
|
@ -5,8 +5,8 @@ import (
|
||||||
"reflect"
|
"reflect"
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
"github.com/influxdata/influxdb/chronograf"
|
"github.com/influxdata/influxdb/v2/chronograf"
|
||||||
"github.com/influxdata/influxdb/chronograf/bolt"
|
"github.com/influxdata/influxdb/v2/chronograf/bolt"
|
||||||
)
|
)
|
||||||
|
|
||||||
// Ensure an SourceStore can store, retrieve, update, and delete sources.
|
// Ensure an SourceStore can store, retrieve, update, and delete sources.
|
||||||
|
|
|
@ -5,8 +5,8 @@ import (
|
||||||
"fmt"
|
"fmt"
|
||||||
|
|
||||||
bolt "github.com/coreos/bbolt"
|
bolt "github.com/coreos/bbolt"
|
||||||
"github.com/influxdata/influxdb/chronograf"
|
"github.com/influxdata/influxdb/v2/chronograf"
|
||||||
"github.com/influxdata/influxdb/chronograf/bolt/internal"
|
"github.com/influxdata/influxdb/v2/chronograf/bolt/internal"
|
||||||
)
|
)
|
||||||
|
|
||||||
// Ensure UsersStore implements chronograf.UsersStore.
|
// Ensure UsersStore implements chronograf.UsersStore.
|
||||||
|
|
|
@ -6,7 +6,7 @@ import (
|
||||||
|
|
||||||
"github.com/google/go-cmp/cmp"
|
"github.com/google/go-cmp/cmp"
|
||||||
"github.com/google/go-cmp/cmp/cmpopts"
|
"github.com/google/go-cmp/cmp/cmpopts"
|
||||||
"github.com/influxdata/influxdb/chronograf"
|
"github.com/influxdata/influxdb/v2/chronograf"
|
||||||
)
|
)
|
||||||
|
|
||||||
// IgnoreFields is used because ID is created by BoltDB and cannot be predicted reliably
|
// IgnoreFields is used because ID is created by BoltDB and cannot be predicted reliably
|
||||||
|
|
|
@ -5,7 +5,7 @@ import (
|
||||||
"encoding/json"
|
"encoding/json"
|
||||||
"fmt"
|
"fmt"
|
||||||
|
|
||||||
"github.com/influxdata/influxdb/chronograf"
|
"github.com/influxdata/influxdb/v2/chronograf"
|
||||||
)
|
)
|
||||||
|
|
||||||
//go:generate env GO111MODULE=on go run github.com/kevinburke/go-bindata/go-bindata -o bin_gen.go -tags assets -ignore README|apps|.sh|go -pkg canned .
|
//go:generate env GO111MODULE=on go run github.com/kevinburke/go-bindata/go-bindata -o bin_gen.go -tags assets -ignore README|apps|.sh|go -pkg canned .
|
||||||
|
|
|
@ -4,7 +4,7 @@ import (
|
||||||
"context"
|
"context"
|
||||||
"strings"
|
"strings"
|
||||||
|
|
||||||
"github.com/influxdata/influxdb/chronograf"
|
"github.com/influxdata/influxdb/v2/chronograf"
|
||||||
)
|
)
|
||||||
|
|
||||||
type AddCommand struct {
|
type AddCommand struct {
|
||||||
|
|
|
@ -8,9 +8,9 @@ import (
|
||||||
"strings"
|
"strings"
|
||||||
"text/tabwriter"
|
"text/tabwriter"
|
||||||
|
|
||||||
"github.com/influxdata/influxdb/chronograf"
|
"github.com/influxdata/influxdb/v2/chronograf"
|
||||||
"github.com/influxdata/influxdb/chronograf/bolt"
|
"github.com/influxdata/influxdb/v2/chronograf/bolt"
|
||||||
"github.com/influxdata/influxdb/chronograf/mocks"
|
"github.com/influxdata/influxdb/v2/chronograf/mocks"
|
||||||
)
|
)
|
||||||
|
|
||||||
func NewBoltClient(path string) (*bolt.Client, error) {
|
func NewBoltClient(path string) (*bolt.Client, error) {
|
||||||
|
|
|
@ -5,8 +5,8 @@ import (
|
||||||
"log"
|
"log"
|
||||||
"os"
|
"os"
|
||||||
|
|
||||||
"github.com/influxdata/influxdb/chronograf"
|
"github.com/influxdata/influxdb/v2/chronograf"
|
||||||
"github.com/influxdata/influxdb/chronograf/server"
|
"github.com/influxdata/influxdb/v2/chronograf/server"
|
||||||
flags "github.com/jessevdk/go-flags"
|
flags "github.com/jessevdk/go-flags"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
|
@ -7,8 +7,8 @@ import (
|
||||||
|
|
||||||
"context"
|
"context"
|
||||||
|
|
||||||
"github.com/influxdata/influxdb/chronograf"
|
"github.com/influxdata/influxdb/v2/chronograf"
|
||||||
"github.com/influxdata/influxdb/chronograf/influx"
|
"github.com/influxdata/influxdb/v2/chronograf/influx"
|
||||||
)
|
)
|
||||||
|
|
||||||
var _ chronograf.TimeSeries = &Client{}
|
var _ chronograf.TimeSeries = &Client{}
|
||||||
|
|
|
@ -7,9 +7,9 @@ import (
|
||||||
"reflect"
|
"reflect"
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
"github.com/influxdata/influxdb/chronograf"
|
"github.com/influxdata/influxdb/v2/chronograf"
|
||||||
"github.com/influxdata/influxdb/chronograf/enterprise"
|
"github.com/influxdata/influxdb/v2/chronograf/enterprise"
|
||||||
"github.com/influxdata/influxdb/chronograf/influx"
|
"github.com/influxdata/influxdb/v2/chronograf/influx"
|
||||||
)
|
)
|
||||||
|
|
||||||
func Test_Enterprise_FetchesDataNodes(t *testing.T) {
|
func Test_Enterprise_FetchesDataNodes(t *testing.T) {
|
||||||
|
|
|
@ -13,8 +13,8 @@ import (
|
||||||
"net/url"
|
"net/url"
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
"github.com/influxdata/influxdb/chronograf"
|
"github.com/influxdata/influxdb/v2/chronograf"
|
||||||
"github.com/influxdata/influxdb/chronograf/influx"
|
"github.com/influxdata/influxdb/v2/chronograf/influx"
|
||||||
)
|
)
|
||||||
|
|
||||||
// Shared transports for all clients to prevent leaking connections
|
// Shared transports for all clients to prevent leaking connections
|
||||||
|
|
|
@ -13,7 +13,7 @@ import (
|
||||||
"testing"
|
"testing"
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
"github.com/influxdata/influxdb/chronograf/influx"
|
"github.com/influxdata/influxdb/v2/chronograf/influx"
|
||||||
)
|
)
|
||||||
|
|
||||||
func TestMetaClient_ShowCluster(t *testing.T) {
|
func TestMetaClient_ShowCluster(t *testing.T) {
|
||||||
|
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue