Skip to content

Commit

Permalink
chore: rename imports from platform to influxdb
Browse files Browse the repository at this point in the history
I did this with a dumb editor macro, so some comments changed too.

Also rename root package from platform to influxdb.

In interest of minimizing risk, anyone importing the root package has
now aliased it to "platform" so that no changes beyond imports were
necessary in those files.

Lastly, replace the old platform module to local path /dev/null so that
nobody can accidentally reintroduce a platform dependency while
migrating platform code to influxdb.
  • Loading branch information
mark-rushakoff committed Jan 10, 2019
1 parent c1975c2 commit d73d73c
Show file tree
Hide file tree
Showing 730 changed files with 1,569 additions and 1,625 deletions.
8 changes: 4 additions & 4 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ jobs:
jstest:
docker:
- image: circleci/golang:1.11-node-browsers
working_directory: /go/src/github.com/influxdata/platform
working_directory: /go/src/github.com/influxdata/influxdb
steps:
- checkout

Expand All @@ -29,7 +29,7 @@ jobs:
environment:
GOCACHE: /tmp/go-cache
GOFLAGS: "-mod=readonly -p=4" # Go on Circle thinks 32 CPUs are available, but there aren't.
working_directory: /go/src/github.com/influxdata/platform
working_directory: /go/src/github.com/influxdata/influxdb
steps:
- checkout

Expand Down Expand Up @@ -81,7 +81,7 @@ jobs:
environment:
GOCACHE: /tmp/go-cache
GOFLAGS: "-mod=readonly -p=4" # Go on Circle thinks 32 CPUs are available, but there aren't.
working_directory: /go/src/github.com/influxdata/platform
working_directory: /go/src/github.com/influxdata/influxdb
steps:
- checkout

Expand All @@ -107,7 +107,7 @@ jobs:
environment:
GOCACHE: /tmp/go-cache
GOFLAGS: "-mod=readonly -p=4" # Go on Circle thinks 32 CPUs are available, but there aren't.
working_directory: /go/src/github.com/influxdata/platform
working_directory: /go/src/github.com/influxdata/influxdb
steps:
- checkout

Expand Down
2 changes: 1 addition & 1 deletion auth.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package platform
package influxdb

import (
"context"
Expand Down
2 changes: 1 addition & 1 deletion authz.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package platform
package influxdb

import (
"errors"
Expand Down
4 changes: 2 additions & 2 deletions authz_test.go
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
package platform_test
package influxdb_test

import (
"testing"

"github.com/influxdata/platform"
platform "github.com/influxdata/influxdb"
)

func TestAuthorizer_PermissionAllowed(t *testing.T) {
Expand Down
2 changes: 1 addition & 1 deletion bolt/authorization.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import (
"encoding/json"

bolt "github.com/coreos/bbolt"
"github.com/influxdata/platform"
platform "github.com/influxdata/influxdb"
)

var (
Expand Down
6 changes: 3 additions & 3 deletions bolt/authorization_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,9 @@ import (
"context"
"testing"

"github.com/influxdata/platform"
"github.com/influxdata/platform/bolt"
platformtesting "github.com/influxdata/platform/testing"
platform "github.com/influxdata/influxdb"
"github.com/influxdata/influxdb/bolt"
platformtesting "github.com/influxdata/influxdb/testing"
)

func initAuthorizationService(f platformtesting.AuthorizationFields, t *testing.T) (platform.AuthorizationService, string, func()) {
Expand Down
4 changes: 2 additions & 2 deletions bolt/basic_auth_service_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@ import (
"context"
"testing"

"github.com/influxdata/platform"
platformtesting "github.com/influxdata/platform/testing"
platform "github.com/influxdata/influxdb"
platformtesting "github.com/influxdata/influxdb/testing"
)

func initBasicAuthService(f platformtesting.UserFields, t *testing.T) (platform.BasicAuthService, func()) {
Expand Down
6 changes: 3 additions & 3 deletions bolt/bbolt.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,9 @@ import (
"time"

"github.com/coreos/bbolt"
"github.com/influxdata/platform"
"github.com/influxdata/platform/rand"
"github.com/influxdata/platform/snowflake"
platform "github.com/influxdata/influxdb"
"github.com/influxdata/influxdb/rand"
"github.com/influxdata/influxdb/snowflake"
"go.uber.org/zap"
)

Expand Down
2 changes: 1 addition & 1 deletion bolt/bbolt_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import (
"path/filepath"
"testing"

"github.com/influxdata/platform/bolt"
"github.com/influxdata/influxdb/bolt"
"golang.org/x/crypto/bcrypt"
)

Expand Down
4 changes: 2 additions & 2 deletions bolt/bucket.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@ import (
"time"

bolt "github.com/coreos/bbolt"
"github.com/influxdata/platform"
platformcontext "github.com/influxdata/platform/context"
platform "github.com/influxdata/influxdb"
platformcontext "github.com/influxdata/influxdb/context"
)

var (
Expand Down
6 changes: 3 additions & 3 deletions bolt/bucket_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,9 @@ import (
"context"
"testing"

"github.com/influxdata/platform"
"github.com/influxdata/platform/bolt"
platformtesting "github.com/influxdata/platform/testing"
platform "github.com/influxdata/influxdb"
"github.com/influxdata/influxdb/bolt"
platformtesting "github.com/influxdata/influxdb/testing"
)

func initBucketService(f platformtesting.BucketFields, t *testing.T) (platform.BucketService, string, func()) {
Expand Down
4 changes: 2 additions & 2 deletions bolt/dashboard.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@ import (
"time"

bolt "github.com/coreos/bbolt"
"github.com/influxdata/platform"
platformcontext "github.com/influxdata/platform/context"
platform "github.com/influxdata/influxdb"
platformcontext "github.com/influxdata/influxdb/context"
)

var (
Expand Down
6 changes: 3 additions & 3 deletions bolt/dashboard_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,9 @@ import (
"context"
"testing"

"github.com/influxdata/platform"
"github.com/influxdata/platform/bolt"
platformtesting "github.com/influxdata/platform/testing"
platform "github.com/influxdata/influxdb"
"github.com/influxdata/influxdb/bolt"
platformtesting "github.com/influxdata/influxdb/testing"
)

func initDashboardService(f platformtesting.DashboardFields, t *testing.T) (platform.DashboardService, string, func()) {
Expand Down
2 changes: 1 addition & 1 deletion bolt/keyvalue_log.go
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ import (
"time"

bolt "github.com/coreos/bbolt"
"github.com/influxdata/platform"
platform "github.com/influxdata/influxdb"
)

var (
Expand Down
4 changes: 2 additions & 2 deletions bolt/keyvalue_log_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@ import (
"context"
"testing"

"github.com/influxdata/platform"
platformtesting "github.com/influxdata/platform/testing"
platform "github.com/influxdata/influxdb"
platformtesting "github.com/influxdata/influxdb/testing"
)

func initKeyValueLog(f platformtesting.KeyValueLogFields, t *testing.T) (platform.KeyValueLog, func()) {
Expand Down
2 changes: 1 addition & 1 deletion bolt/kv.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import (
"time"

bolt "github.com/coreos/bbolt"
"github.com/influxdata/platform/kv"
"github.com/influxdata/influxdb/kv"
"go.uber.org/zap"
)

Expand Down
6 changes: 3 additions & 3 deletions bolt/kv_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,9 @@ import (
"context"
"testing"

"github.com/influxdata/platform"
"github.com/influxdata/platform/kv"
platformtesting "github.com/influxdata/platform/testing"
platform "github.com/influxdata/influxdb"
"github.com/influxdata/influxdb/kv"
platformtesting "github.com/influxdata/influxdb/testing"
)

func initKVStore(f platformtesting.KVStoreFields, t *testing.T) (kv.Store, func()) {
Expand Down
2 changes: 1 addition & 1 deletion bolt/label.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import (
"fmt"

bolt "github.com/coreos/bbolt"
"github.com/influxdata/platform"
platform "github.com/influxdata/influxdb"
)

var (
Expand Down
6 changes: 3 additions & 3 deletions bolt/label_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,9 @@ import (
"context"
"testing"

"github.com/influxdata/platform"
"github.com/influxdata/platform/bolt"
platformtesting "github.com/influxdata/platform/testing"
platform "github.com/influxdata/influxdb"
"github.com/influxdata/influxdb/bolt"
platformtesting "github.com/influxdata/influxdb/testing"
)

func initLabelService(f platformtesting.LabelFields, t *testing.T) (platform.LabelService, string, func()) {
Expand Down
2 changes: 1 addition & 1 deletion bolt/lookup_service.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ package bolt
import (
"context"

"github.com/influxdata/platform"
platform "github.com/influxdata/influxdb"
)

var _ platform.LookupService = (*Client)(nil)
Expand Down
8 changes: 4 additions & 4 deletions bolt/lookup_service_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,10 @@ import (
"context"
"testing"

"github.com/influxdata/platform"
"github.com/influxdata/platform/bolt"
"github.com/influxdata/platform/mock"
platformtesting "github.com/influxdata/platform/testing"
platform "github.com/influxdata/influxdb"
"github.com/influxdata/influxdb/bolt"
"github.com/influxdata/influxdb/mock"
platformtesting "github.com/influxdata/influxdb/testing"
)

var (
Expand Down
2 changes: 1 addition & 1 deletion bolt/macro.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import (
"encoding/json"

bolt "github.com/coreos/bbolt"
"github.com/influxdata/platform"
platform "github.com/influxdata/influxdb"
)

var (
Expand Down
6 changes: 3 additions & 3 deletions bolt/macro_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,11 @@ package bolt_test

import (
"context"
"github.com/influxdata/platform/bolt"
"testing"

"github.com/influxdata/platform"
platformtesting "github.com/influxdata/platform/testing"
platform "github.com/influxdata/influxdb"
"github.com/influxdata/influxdb/bolt"
platformtesting "github.com/influxdata/influxdb/testing"
)

func initMacroService(f platformtesting.MacroFields, t *testing.T) (platform.MacroService, string, func()) {
Expand Down
2 changes: 1 addition & 1 deletion bolt/onboarding.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import (
"time"

bolt "github.com/coreos/bbolt"
"github.com/influxdata/platform"
platform "github.com/influxdata/influxdb"
)

var onboardingBucket = []byte("onboardingv1")
Expand Down
4 changes: 2 additions & 2 deletions bolt/onboarding_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@ import (
"context"
"testing"

"github.com/influxdata/platform"
platformtesting "github.com/influxdata/platform/testing"
platform "github.com/influxdata/influxdb"
platformtesting "github.com/influxdata/influxdb/testing"
)

func initOnboardingService(f platformtesting.OnboardingFields, t *testing.T) (platform.OnboardingService, func()) {
Expand Down
4 changes: 2 additions & 2 deletions bolt/organization.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@ import (
"time"

bolt "github.com/coreos/bbolt"
"github.com/influxdata/platform"
platformcontext "github.com/influxdata/platform/context"
platform "github.com/influxdata/influxdb"
platformcontext "github.com/influxdata/influxdb/context"
)

var (
Expand Down
6 changes: 3 additions & 3 deletions bolt/organization_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,9 @@ import (
"context"
"testing"

"github.com/influxdata/platform"
"github.com/influxdata/platform/bolt"
platformtesting "github.com/influxdata/platform/testing"
platform "github.com/influxdata/influxdb"
"github.com/influxdata/influxdb/bolt"
platformtesting "github.com/influxdata/influxdb/testing"
)

func initOrganizationService(f platformtesting.OrganizationFields, t *testing.T) (platform.OrganizationService, string, func()) {
Expand Down
2 changes: 1 addition & 1 deletion bolt/scraper.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import (
"encoding/json"

bolt "github.com/coreos/bbolt"
"github.com/influxdata/platform"
platform "github.com/influxdata/influxdb"
)

var (
Expand Down
6 changes: 3 additions & 3 deletions bolt/scraper_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,9 @@ import (
"context"
"testing"

"github.com/influxdata/platform"
"github.com/influxdata/platform/bolt"
platformtesting "github.com/influxdata/platform/testing"
platform "github.com/influxdata/influxdb"
"github.com/influxdata/influxdb/bolt"
platformtesting "github.com/influxdata/influxdb/testing"
)

func initScraperTargetStoreService(f platformtesting.TargetFields, t *testing.T) (platform.ScraperTargetStoreService, string, func()) {
Expand Down
2 changes: 1 addition & 1 deletion bolt/secret.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import (
"fmt"

bolt "github.com/coreos/bbolt"
"github.com/influxdata/platform"
platform "github.com/influxdata/influxdb"
)

var (
Expand Down
4 changes: 2 additions & 2 deletions bolt/secret_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@ import (
"context"
"testing"

"github.com/influxdata/platform"
platformtesting "github.com/influxdata/platform/testing"
platform "github.com/influxdata/influxdb"
platformtesting "github.com/influxdata/influxdb/testing"
)

func initSecretService(f platformtesting.SecretServiceFields, t *testing.T) (platform.SecretService, func()) {
Expand Down
2 changes: 1 addition & 1 deletion bolt/session.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import (
"time"

bolt "github.com/coreos/bbolt"
"github.com/influxdata/platform"
platform "github.com/influxdata/influxdb"
)

var (
Expand Down
6 changes: 3 additions & 3 deletions bolt/session_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,9 @@ import (
"context"
"testing"

"github.com/influxdata/platform"
"github.com/influxdata/platform/bolt"
platformtesting "github.com/influxdata/platform/testing"
platform "github.com/influxdata/influxdb"
"github.com/influxdata/influxdb/bolt"
platformtesting "github.com/influxdata/influxdb/testing"
)

func initSessionService(f platformtesting.SessionFields, t *testing.T) (platform.SessionService, string, func()) {
Expand Down
2 changes: 1 addition & 1 deletion bolt/source.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import (
"fmt"

bolt "github.com/coreos/bbolt"
"github.com/influxdata/platform"
platform "github.com/influxdata/influxdb"
)

var (
Expand Down
Loading

0 comments on commit d73d73c

Please sign in to comment.