upgrade to go micro v4.1.0

This commit is contained in:
Willy Kloucek
2021-10-14 15:56:19 +02:00
parent ce136b4940
commit 6d5a3733ff
45 changed files with 109 additions and 100 deletions
+1 -1
View File
@@ -5,10 +5,10 @@ import (
"fmt"
"github.com/asim/go-micro/plugins/client/grpc/v3"
merrors "github.com/asim/go-micro/v3/errors"
"github.com/owncloud/ocis/accounts/pkg/config"
index "github.com/owncloud/ocis/accounts/pkg/proto/v0"
"github.com/urfave/cli/v2"
merrors "go-micro.dev/v4/errors"
)
// RebuildIndex rebuilds the entire configured index.
+1 -1
View File
@@ -3,8 +3,8 @@ package proto
import (
context "context"
client "github.com/asim/go-micro/v3/client"
empty "github.com/golang/protobuf/ptypes/empty"
client "go-micro.dev/v4/client"
)
// MockAccountsService can be used to write tests
+3 -3
View File
@@ -16,9 +16,9 @@ import (
import (
context "context"
api "github.com/asim/go-micro/v3/api"
client "github.com/asim/go-micro/v3/client"
server "github.com/asim/go-micro/v3/server"
api "go-micro.dev/v4/api"
client "go-micro.dev/v4/client"
server "go-micro.dev/v4/server"
)
// Reference imports to suppress errors if they are not otherwise used.
@@ -12,8 +12,6 @@ import (
mgrpcc "github.com/asim/go-micro/plugins/client/grpc/v3"
"github.com/asim/go-micro/v3/client"
merrors "github.com/asim/go-micro/v3/errors"
"github.com/golang/protobuf/ptypes/empty"
"github.com/owncloud/ocis/accounts/pkg/command"
"github.com/owncloud/ocis/accounts/pkg/config"
@@ -22,6 +20,8 @@ import (
"github.com/owncloud/ocis/ocis-pkg/service/grpc"
settings "github.com/owncloud/ocis/settings/pkg/proto/v0"
"github.com/stretchr/testify/assert"
"go-micro.dev/v4/client"
merrors "go-micro.dev/v4/errors"
"google.golang.org/genproto/protobuf/field_mask"
"google.golang.org/protobuf/types/known/timestamppb"
)
+1 -1
View File
@@ -1,7 +1,6 @@
package http
import (
"github.com/asim/go-micro/v3"
"github.com/go-chi/chi/v5"
chimiddleware "github.com/go-chi/chi/v5/middleware"
"github.com/owncloud/ocis/accounts/pkg/assets"
@@ -10,6 +9,7 @@ import (
"github.com/owncloud/ocis/ocis-pkg/middleware"
"github.com/owncloud/ocis/ocis-pkg/service/http"
"github.com/owncloud/ocis/ocis-pkg/version"
"go-micro.dev/v4"
)
// Server initializes the http service and server.
+2 -2
View File
@@ -16,8 +16,6 @@ import (
"go.opentelemetry.io/otel/attribute"
merrors "github.com/asim/go-micro/v3/errors"
"github.com/asim/go-micro/v3/metadata"
"github.com/gofrs/uuid"
"github.com/golang/protobuf/ptypes/empty"
fieldmask_utils "github.com/mennanov/fieldmask-utils"
@@ -31,6 +29,8 @@ import (
settings "github.com/owncloud/ocis/settings/pkg/proto/v0"
settings_svc "github.com/owncloud/ocis/settings/pkg/service/v0"
"github.com/rs/zerolog"
merrors "go-micro.dev/v4/errors"
"go-micro.dev/v4/metadata"
"golang.org/x/crypto/bcrypt"
"google.golang.org/genproto/protobuf/field_mask"
p "google.golang.org/protobuf/proto"
@@ -9,9 +9,6 @@ import (
"testing"
"time"
"github.com/asim/go-micro/v3/client"
merrors "github.com/asim/go-micro/v3/errors"
"github.com/asim/go-micro/v3/metadata"
"github.com/golang/protobuf/ptypes/empty"
"github.com/owncloud/ocis/accounts/pkg/config"
"github.com/owncloud/ocis/accounts/pkg/proto/v0"
@@ -21,6 +18,9 @@ import (
settings "github.com/owncloud/ocis/settings/pkg/proto/v0"
ssvc "github.com/owncloud/ocis/settings/pkg/service/v0"
"github.com/stretchr/testify/assert"
"go-micro.dev/v4/client"
merrors "go-micro.dev/v4/errors"
"go-micro.dev/v4/metadata"
)
const dataPath = "/var/tmp/ocis-accounts-tests"
+1 -1
View File
@@ -5,11 +5,11 @@ import (
"path"
"strconv"
merrors "github.com/asim/go-micro/v3/errors"
"github.com/gofrs/uuid"
"github.com/golang/protobuf/ptypes/empty"
"github.com/owncloud/ocis/accounts/pkg/proto/v0"
"github.com/owncloud/ocis/accounts/pkg/storage"
merrors "go-micro.dev/v4/errors"
p "google.golang.org/protobuf/proto"
)