1
0
mirror of https://github.com/go-micro/go-micro.git synced 2025-08-04 21:42:57 +02:00
* v3

* revert plugins

* fixup some issues
This commit is contained in:
Asim Aslam
2021-01-20 13:54:31 +00:00
committed by GitHub
parent bf4ab679e1
commit d94936f6c9
369 changed files with 1442 additions and 817 deletions

View File

@ -1,4 +1,4 @@
# Go Micro [![License](https://img.shields.io/:license-apache-blue.svg)](https://opensource.org/licenses/Apache-2.0) [![Go.Dev reference](https://img.shields.io/badge/go.dev-reference-007d9c?logo=go&logoColor=white&style=flat-square)](https://pkg.go.dev/github.com/micro/go-micro/v2?tab=doc) [![Travis CI](https://api.travis-ci.org/micro/go-micro.svg?branch=master)](https://travis-ci.org/micro/go-micro) [![Go Report Card](https://goreportcard.com/badge/micro/go-micro)](https://goreportcard.com/report/github.com/micro/go-micro) # Go Micro [![License](https://img.shields.io/:license-apache-blue.svg)](https://opensource.org/licenses/Apache-2.0) [![Go.Dev reference](https://img.shields.io/badge/go.dev-reference-007d9c?logo=go&logoColor=white&style=flat-square)](https://pkg.go.dev/github.com/asim/go-micro/v3?tab=doc) [![Travis CI](https://api.travis-ci.org/micro/go-micro.svg?branch=master)](https://travis-ci.org/micro/go-micro) [![Go Report Card](https://goreportcard.com/badge/micro/go-micro)](https://goreportcard.com/report/github.com/micro/go-micro)
Go Micro is a framework for distributed systems development. Go Micro is a framework for distributed systems development.
@ -51,7 +51,7 @@ are pluggable and allows Go Micro to be runtime agnostic. You can plugin any und
To make use of Go Micro To make use of Go Micro
```golang ```golang
import "github.com/micro/go-micro/v2" import "github.com/asim/go-micro/v3"
// create a new service // create a new service
service := micro.NewService( service := micro.NewService(

View File

@ -5,8 +5,8 @@ import (
"regexp" "regexp"
"strings" "strings"
"github.com/micro/go-micro/v2/registry" "github.com/asim/go-micro/v3/registry"
"github.com/micro/go-micro/v2/server" "github.com/asim/go-micro/v3/server"
) )
type Api interface { type Api interface {

View File

@ -4,13 +4,13 @@ package api
import ( import (
"net/http" "net/http"
goapi "github.com/micro/go-micro/v2/api" goapi "github.com/asim/go-micro/v3/api"
"github.com/micro/go-micro/v2/api/handler" "github.com/asim/go-micro/v3/api/handler"
api "github.com/micro/go-micro/v2/api/proto" api "github.com/asim/go-micro/v3/api/proto"
"github.com/micro/go-micro/v2/client" "github.com/asim/go-micro/v3/client"
"github.com/micro/go-micro/v2/errors" "github.com/asim/go-micro/v3/errors"
"github.com/micro/go-micro/v2/selector" "github.com/asim/go-micro/v3/selector"
"github.com/micro/go-micro/v2/util/ctx" "github.com/asim/go-micro/v3/util/ctx"
) )
type apiHandler struct { type apiHandler struct {

View File

@ -7,9 +7,9 @@ import (
"net/http" "net/http"
"strings" "strings"
api "github.com/micro/go-micro/v2/api/proto" api "github.com/asim/go-micro/v3/api/proto"
"github.com/micro/go-micro/v2/registry" "github.com/asim/go-micro/v3/registry"
"github.com/micro/go-micro/v2/selector" "github.com/asim/go-micro/v3/selector"
"github.com/oxtoacart/bpool" "github.com/oxtoacart/bpool"
) )

View File

@ -10,10 +10,10 @@ import (
"strings" "strings"
"time" "time"
"github.com/asim/go-micro/v3/api/handler"
proto "github.com/asim/go-micro/v3/api/proto"
"github.com/asim/go-micro/v3/util/ctx"
"github.com/google/uuid" "github.com/google/uuid"
"github.com/micro/go-micro/v2/api/handler"
proto "github.com/micro/go-micro/v2/api/proto"
"github.com/micro/go-micro/v2/util/ctx"
"github.com/oxtoacart/bpool" "github.com/oxtoacart/bpool"
) )

View File

@ -8,9 +8,9 @@ import (
"net/http/httputil" "net/http/httputil"
"net/url" "net/url"
"github.com/micro/go-micro/v2/api" "github.com/asim/go-micro/v3/api"
"github.com/micro/go-micro/v2/api/handler" "github.com/asim/go-micro/v3/api/handler"
"github.com/micro/go-micro/v2/selector" "github.com/asim/go-micro/v3/selector"
) )
const ( const (

View File

@ -6,12 +6,12 @@ import (
"net/http/httptest" "net/http/httptest"
"testing" "testing"
"github.com/micro/go-micro/v2/api/handler" "github.com/asim/go-micro/v3/api/handler"
"github.com/micro/go-micro/v2/api/resolver" "github.com/asim/go-micro/v3/api/resolver"
"github.com/micro/go-micro/v2/api/resolver/vpath" "github.com/asim/go-micro/v3/api/resolver/vpath"
"github.com/micro/go-micro/v2/api/router" "github.com/asim/go-micro/v3/api/router"
regRouter "github.com/micro/go-micro/v2/api/router/registry" regRouter "github.com/asim/go-micro/v3/api/router/registry"
"github.com/micro/go-micro/v2/registry" "github.com/asim/go-micro/v3/registry"
) )
func testHttp(t *testing.T, path, service, ns string) { func testHttp(t *testing.T, path, service, ns string) {

View File

@ -1,8 +1,8 @@
package handler package handler
import ( import (
"github.com/micro/go-micro/v2/api/router" "github.com/asim/go-micro/v3/api/router"
"github.com/micro/go-micro/v2/client" "github.com/asim/go-micro/v3/client"
) )
var ( var (

View File

@ -9,21 +9,21 @@ import (
"strconv" "strconv"
"strings" "strings"
"github.com/asim/go-micro/v3/api"
"github.com/asim/go-micro/v3/api/handler"
"github.com/asim/go-micro/v3/api/internal/proto"
"github.com/asim/go-micro/v3/client"
"github.com/asim/go-micro/v3/codec"
"github.com/asim/go-micro/v3/codec/jsonrpc"
"github.com/asim/go-micro/v3/codec/protorpc"
"github.com/asim/go-micro/v3/errors"
"github.com/asim/go-micro/v3/logger"
"github.com/asim/go-micro/v3/metadata"
"github.com/asim/go-micro/v3/registry"
"github.com/asim/go-micro/v3/selector"
"github.com/asim/go-micro/v3/util/ctx"
"github.com/asim/go-micro/v3/util/qson"
jsonpatch "github.com/evanphx/json-patch/v5" jsonpatch "github.com/evanphx/json-patch/v5"
"github.com/micro/go-micro/v2/api"
"github.com/micro/go-micro/v2/api/handler"
"github.com/micro/go-micro/v2/api/internal/proto"
"github.com/micro/go-micro/v2/client"
"github.com/micro/go-micro/v2/codec"
"github.com/micro/go-micro/v2/codec/jsonrpc"
"github.com/micro/go-micro/v2/codec/protorpc"
"github.com/micro/go-micro/v2/errors"
"github.com/micro/go-micro/v2/logger"
"github.com/micro/go-micro/v2/metadata"
"github.com/micro/go-micro/v2/registry"
"github.com/micro/go-micro/v2/selector"
"github.com/micro/go-micro/v2/util/ctx"
"github.com/micro/go-micro/v2/util/qson"
"github.com/oxtoacart/bpool" "github.com/oxtoacart/bpool"
) )

View File

@ -6,8 +6,8 @@ import (
"net/http" "net/http"
"testing" "testing"
go_api "github.com/asim/go-micro/v3/api/proto"
"github.com/golang/protobuf/proto" "github.com/golang/protobuf/proto"
go_api "github.com/micro/go-micro/v2/api/proto"
) )
func TestRequestPayloadFromRequest(t *testing.T) { func TestRequestPayloadFromRequest(t *testing.T) {

View File

@ -9,14 +9,14 @@ import (
"strings" "strings"
"time" "time"
"github.com/asim/go-micro/v3/api"
"github.com/asim/go-micro/v3/client"
raw "github.com/asim/go-micro/v3/codec/bytes"
"github.com/asim/go-micro/v3/logger"
"github.com/asim/go-micro/v3/selector"
"github.com/gobwas/httphead" "github.com/gobwas/httphead"
"github.com/gobwas/ws" "github.com/gobwas/ws"
"github.com/gobwas/ws/wsutil" "github.com/gobwas/ws/wsutil"
"github.com/micro/go-micro/v2/api"
"github.com/micro/go-micro/v2/client"
raw "github.com/micro/go-micro/v2/codec/bytes"
"github.com/micro/go-micro/v2/logger"
"github.com/micro/go-micro/v2/selector"
) )
// serveWebsocket will stream rpc back over websockets assuming json // serveWebsocket will stream rpc back over websockets assuming json

View File

@ -11,9 +11,9 @@ import (
"net/url" "net/url"
"strings" "strings"
"github.com/micro/go-micro/v2/api" "github.com/asim/go-micro/v3/api"
"github.com/micro/go-micro/v2/api/handler" "github.com/asim/go-micro/v3/api/handler"
"github.com/micro/go-micro/v2/selector" "github.com/asim/go-micro/v3/selector"
) )
const ( const (

View File

@ -6,7 +6,7 @@ import (
"net/http" "net/http"
"strings" "strings"
"github.com/micro/go-micro/v2/api/resolver" "github.com/asim/go-micro/v3/api/resolver"
) )
type Resolver struct{} type Resolver struct{}

View File

@ -4,7 +4,7 @@ package host
import ( import (
"net/http" "net/http"
"github.com/micro/go-micro/v2/api/resolver" "github.com/asim/go-micro/v3/api/resolver"
) )
type Resolver struct { type Resolver struct {

View File

@ -5,7 +5,7 @@ import (
"net/http" "net/http"
"strings" "strings"
"github.com/micro/go-micro/v2/api/resolver" "github.com/asim/go-micro/v3/api/resolver"
) )
type Resolver struct { type Resolver struct {

View File

@ -7,7 +7,7 @@ import (
"regexp" "regexp"
"strings" "strings"
"github.com/micro/go-micro/v2/api/resolver" "github.com/asim/go-micro/v3/api/resolver"
) )
func NewResolver(opts ...resolver.Option) resolver.Resolver { func NewResolver(opts ...resolver.Option) resolver.Resolver {

View File

@ -1,9 +1,9 @@
package router package router
import ( import (
"github.com/micro/go-micro/v2/api/resolver" "github.com/asim/go-micro/v3/api/resolver"
"github.com/micro/go-micro/v2/api/resolver/vpath" "github.com/asim/go-micro/v3/api/resolver/vpath"
"github.com/micro/go-micro/v2/registry" "github.com/asim/go-micro/v3/registry"
) )
type Options struct { type Options struct {

View File

@ -10,13 +10,13 @@ import (
"sync" "sync"
"time" "time"
"github.com/micro/go-micro/v2/api" "github.com/asim/go-micro/v3/api"
"github.com/micro/go-micro/v2/api/router" "github.com/asim/go-micro/v3/api/router"
"github.com/micro/go-micro/v2/api/router/util" "github.com/asim/go-micro/v3/api/router/util"
"github.com/micro/go-micro/v2/logger" "github.com/asim/go-micro/v3/logger"
"github.com/micro/go-micro/v2/metadata" "github.com/asim/go-micro/v3/metadata"
"github.com/micro/go-micro/v2/registry" "github.com/asim/go-micro/v3/registry"
"github.com/micro/go-micro/v2/registry/cache" "github.com/asim/go-micro/v3/registry/cache"
) )
// endpoint struct, that holds compiled pcre // endpoint struct, that holds compiled pcre

View File

@ -3,7 +3,7 @@ package registry
import ( import (
"testing" "testing"
"github.com/micro/go-micro/v2/registry" "github.com/asim/go-micro/v3/registry"
"github.com/stretchr/testify/assert" "github.com/stretchr/testify/assert"
) )

View File

@ -4,7 +4,7 @@ package router
import ( import (
"net/http" "net/http"
"github.com/micro/go-micro/v2/api" "github.com/asim/go-micro/v3/api"
) )
// Router is used to determine an endpoint for a request // Router is used to determine an endpoint for a request

View File

@ -8,13 +8,13 @@ import (
"strings" "strings"
"sync" "sync"
"github.com/micro/go-micro/v2/api" "github.com/asim/go-micro/v3/api"
"github.com/micro/go-micro/v2/api/router" "github.com/asim/go-micro/v3/api/router"
"github.com/micro/go-micro/v2/api/router/util" "github.com/asim/go-micro/v3/api/router/util"
"github.com/micro/go-micro/v2/logger" "github.com/asim/go-micro/v3/logger"
"github.com/micro/go-micro/v2/metadata" "github.com/asim/go-micro/v3/metadata"
"github.com/micro/go-micro/v2/registry" "github.com/asim/go-micro/v3/registry"
rutil "github.com/micro/go-micro/v2/util/registry" rutil "github.com/asim/go-micro/v3/util/registry"
) )
type endpoint struct { type endpoint struct {

View File

@ -6,7 +6,7 @@ import (
"fmt" "fmt"
"strings" "strings"
"github.com/micro/go-micro/v2/logger" "github.com/asim/go-micro/v3/logger"
) )
// InvalidTemplateError indicates that the path template is not valid. // InvalidTemplateError indicates that the path template is not valid.

View File

@ -8,7 +8,7 @@ import (
"reflect" "reflect"
"testing" "testing"
"github.com/micro/go-micro/v2/logger" "github.com/asim/go-micro/v3/logger"
) )
func TestTokenize(t *testing.T) { func TestTokenize(t *testing.T) {

View File

@ -7,7 +7,7 @@ import (
"fmt" "fmt"
"strings" "strings"
"github.com/micro/go-micro/v2/logger" "github.com/asim/go-micro/v3/logger"
) )
var ( var (

View File

@ -7,8 +7,8 @@ import (
"net" "net"
"os" "os"
"github.com/micro/go-micro/v2/api/server/acme" "github.com/asim/go-micro/v3/api/server/acme"
"github.com/micro/go-micro/v2/logger" "github.com/asim/go-micro/v3/logger"
"golang.org/x/crypto/acme/autocert" "golang.org/x/crypto/acme/autocert"
) )

View File

@ -8,10 +8,10 @@ import (
"os" "os"
"sync" "sync"
"github.com/asim/go-micro/v3/api/server"
"github.com/asim/go-micro/v3/api/server/cors"
"github.com/asim/go-micro/v3/logger"
"github.com/gorilla/handlers" "github.com/gorilla/handlers"
"github.com/micro/go-micro/v2/api/server"
"github.com/micro/go-micro/v2/api/server/cors"
"github.com/micro/go-micro/v2/logger"
) )
type httpServer struct { type httpServer struct {

View File

@ -4,8 +4,8 @@ import (
"crypto/tls" "crypto/tls"
"net/http" "net/http"
"github.com/micro/go-micro/v2/api/resolver" "github.com/asim/go-micro/v3/api/resolver"
"github.com/micro/go-micro/v2/api/server/acme" "github.com/asim/go-micro/v3/api/server/acme"
) )
type Option func(o *Options) type Option func(o *Options)

View File

@ -17,14 +17,14 @@ import (
"sync" "sync"
"time" "time"
"github.com/asim/go-micro/v3/codec/json"
merr "github.com/asim/go-micro/v3/errors"
"github.com/asim/go-micro/v3/registry"
"github.com/asim/go-micro/v3/registry/cache"
maddr "github.com/asim/go-micro/v3/util/addr"
mnet "github.com/asim/go-micro/v3/util/net"
mls "github.com/asim/go-micro/v3/util/tls"
"github.com/google/uuid" "github.com/google/uuid"
"github.com/micro/go-micro/v2/codec/json"
merr "github.com/micro/go-micro/v2/errors"
"github.com/micro/go-micro/v2/registry"
"github.com/micro/go-micro/v2/registry/cache"
maddr "github.com/micro/go-micro/v2/util/addr"
mnet "github.com/micro/go-micro/v2/util/net"
mls "github.com/micro/go-micro/v2/util/tls"
"golang.org/x/net/http2" "golang.org/x/net/http2"
) )

View File

@ -5,9 +5,9 @@ import (
"testing" "testing"
"time" "time"
"github.com/asim/go-micro/v3/broker"
"github.com/asim/go-micro/v3/registry"
"github.com/google/uuid" "github.com/google/uuid"
"github.com/micro/go-micro/v2/broker"
"github.com/micro/go-micro/v2/registry"
) )
var ( var (

View File

@ -4,8 +4,8 @@ import (
"context" "context"
"crypto/tls" "crypto/tls"
"github.com/micro/go-micro/v2/codec" "github.com/asim/go-micro/v3/codec"
"github.com/micro/go-micro/v2/registry" "github.com/asim/go-micro/v3/registry"
) )
type Options struct { type Options struct {

View File

@ -4,7 +4,7 @@ import (
"context" "context"
"time" "time"
"github.com/micro/go-micro/v2/util/backoff" "github.com/asim/go-micro/v3/util/backoff"
) )
type BackoffFunc func(ctx context.Context, req Request, attempts int) (time.Duration, error) type BackoffFunc func(ctx context.Context, req Request, attempts int) (time.Duration, error)

View File

@ -7,7 +7,7 @@ import (
"hash/fnv" "hash/fnv"
"time" "time"
"github.com/micro/go-micro/v2/metadata" "github.com/asim/go-micro/v3/metadata"
cache "github.com/patrickmn/go-cache" cache "github.com/patrickmn/go-cache"
) )

View File

@ -5,7 +5,7 @@ import (
"testing" "testing"
"time" "time"
"github.com/micro/go-micro/v2/metadata" "github.com/asim/go-micro/v3/metadata"
) )
func TestCache(t *testing.T) { func TestCache(t *testing.T) {

View File

@ -5,7 +5,7 @@ import (
"context" "context"
"time" "time"
"github.com/micro/go-micro/v2/codec" "github.com/asim/go-micro/v3/codec"
) )
// Client is the interface used to make requests to services. // Client is the interface used to make requests to services.

View File

@ -1,7 +1,7 @@
package client package client
import ( import (
"github.com/micro/go-micro/v2/registry" "github.com/asim/go-micro/v3/registry"
) )
var ( var (

View File

@ -4,11 +4,11 @@ import (
"context" "context"
"time" "time"
"github.com/micro/go-micro/v2/broker" "github.com/asim/go-micro/v3/broker"
"github.com/micro/go-micro/v2/codec" "github.com/asim/go-micro/v3/codec"
"github.com/micro/go-micro/v2/registry" "github.com/asim/go-micro/v3/registry"
"github.com/micro/go-micro/v2/selector" "github.com/asim/go-micro/v3/selector"
"github.com/micro/go-micro/v2/transport" "github.com/asim/go-micro/v3/transport"
) )
type Options struct { type Options struct {

View File

@ -4,7 +4,7 @@ import (
"testing" "testing"
"time" "time"
"github.com/micro/go-micro/v2/transport" "github.com/asim/go-micro/v3/transport"
) )
func TestCallOptions(t *testing.T) { func TestCallOptions(t *testing.T) {

View File

@ -3,7 +3,7 @@ package client
import ( import (
"context" "context"
"github.com/micro/go-micro/v2/errors" "github.com/asim/go-micro/v3/errors"
) )
// note that returning either false or a non-nil error will result in the call not being retried // note that returning either false or a non-nil error will result in the call not being retried

View File

@ -6,18 +6,18 @@ import (
"sync/atomic" "sync/atomic"
"time" "time"
"github.com/asim/go-micro/v3/broker"
"github.com/asim/go-micro/v3/codec"
raw "github.com/asim/go-micro/v3/codec/bytes"
"github.com/asim/go-micro/v3/errors"
"github.com/asim/go-micro/v3/metadata"
"github.com/asim/go-micro/v3/registry"
"github.com/asim/go-micro/v3/selector"
"github.com/asim/go-micro/v3/transport"
"github.com/asim/go-micro/v3/util/buf"
"github.com/asim/go-micro/v3/util/net"
"github.com/asim/go-micro/v3/util/pool"
"github.com/google/uuid" "github.com/google/uuid"
"github.com/micro/go-micro/v2/broker"
"github.com/micro/go-micro/v2/codec"
raw "github.com/micro/go-micro/v2/codec/bytes"
"github.com/micro/go-micro/v2/errors"
"github.com/micro/go-micro/v2/metadata"
"github.com/micro/go-micro/v2/registry"
"github.com/micro/go-micro/v2/selector"
"github.com/micro/go-micro/v2/transport"
"github.com/micro/go-micro/v2/util/buf"
"github.com/micro/go-micro/v2/util/net"
"github.com/micro/go-micro/v2/util/pool"
) )
type rpcClient struct { type rpcClient struct {

View File

@ -5,9 +5,9 @@ import (
"fmt" "fmt"
"testing" "testing"
"github.com/micro/go-micro/v2/errors" "github.com/asim/go-micro/v3/errors"
"github.com/micro/go-micro/v2/registry" "github.com/asim/go-micro/v3/registry"
"github.com/micro/go-micro/v2/selector" "github.com/asim/go-micro/v3/selector"
) )
func newTestRegistry() registry.Registry { func newTestRegistry() registry.Registry {

View File

@ -4,16 +4,16 @@ import (
"bytes" "bytes"
errs "errors" errs "errors"
"github.com/micro/go-micro/v2/codec" "github.com/asim/go-micro/v3/codec"
raw "github.com/micro/go-micro/v2/codec/bytes" raw "github.com/asim/go-micro/v3/codec/bytes"
"github.com/micro/go-micro/v2/codec/grpc" "github.com/asim/go-micro/v3/codec/grpc"
"github.com/micro/go-micro/v2/codec/json" "github.com/asim/go-micro/v3/codec/json"
"github.com/micro/go-micro/v2/codec/jsonrpc" "github.com/asim/go-micro/v3/codec/jsonrpc"
"github.com/micro/go-micro/v2/codec/proto" "github.com/asim/go-micro/v3/codec/proto"
"github.com/micro/go-micro/v2/codec/protorpc" "github.com/asim/go-micro/v3/codec/protorpc"
"github.com/micro/go-micro/v2/errors" "github.com/asim/go-micro/v3/errors"
"github.com/micro/go-micro/v2/registry" "github.com/asim/go-micro/v3/registry"
"github.com/micro/go-micro/v2/transport" "github.com/asim/go-micro/v3/transport"
) )
const ( const (

View File

@ -1,7 +1,7 @@
package client package client
import ( import (
"github.com/micro/go-micro/v2/codec" "github.com/asim/go-micro/v3/codec"
) )
type rpcRequest struct { type rpcRequest struct {

View File

@ -1,8 +1,8 @@
package client package client
import ( import (
"github.com/micro/go-micro/v2/codec" "github.com/asim/go-micro/v3/codec"
"github.com/micro/go-micro/v2/transport" "github.com/asim/go-micro/v3/transport"
) )
type rpcResponse struct { type rpcResponse struct {

View File

@ -5,7 +5,7 @@ import (
"io" "io"
"sync" "sync"
"github.com/micro/go-micro/v2/codec" "github.com/asim/go-micro/v3/codec"
) )
// Implements the streamer interface // Implements the streamer interface

View File

@ -3,7 +3,7 @@ package client
import ( import (
"context" "context"
"github.com/micro/go-micro/v2/registry" "github.com/asim/go-micro/v3/registry"
) )
// CallFunc represents the individual call func // CallFunc represents the individual call func

View File

@ -9,19 +9,19 @@ import (
"github.com/micro/cli/v2" "github.com/micro/cli/v2"
"github.com/micro/go-micro/v2/auth" "github.com/asim/go-micro/v3/auth"
"github.com/micro/go-micro/v2/broker" "github.com/asim/go-micro/v3/broker"
"github.com/micro/go-micro/v2/client" "github.com/asim/go-micro/v3/client"
"github.com/micro/go-micro/v2/config" "github.com/asim/go-micro/v3/config"
"github.com/micro/go-micro/v2/debug/profile" "github.com/asim/go-micro/v3/debug/profile"
"github.com/micro/go-micro/v2/debug/trace" "github.com/asim/go-micro/v3/debug/trace"
"github.com/micro/go-micro/v2/logger" "github.com/asim/go-micro/v3/logger"
"github.com/micro/go-micro/v2/registry" "github.com/asim/go-micro/v3/registry"
"github.com/micro/go-micro/v2/runtime" "github.com/asim/go-micro/v3/runtime"
"github.com/micro/go-micro/v2/selector" "github.com/asim/go-micro/v3/selector"
"github.com/micro/go-micro/v2/server" "github.com/asim/go-micro/v3/server"
"github.com/micro/go-micro/v2/store" "github.com/asim/go-micro/v3/store"
"github.com/micro/go-micro/v2/transport" "github.com/asim/go-micro/v3/transport"
) )
type Cmd interface { type Cmd interface {

View File

@ -3,18 +3,18 @@ package cmd
import ( import (
"context" "context"
"github.com/micro/go-micro/v2/auth" "github.com/asim/go-micro/v3/auth"
"github.com/micro/go-micro/v2/broker" "github.com/asim/go-micro/v3/broker"
"github.com/micro/go-micro/v2/client" "github.com/asim/go-micro/v3/client"
"github.com/micro/go-micro/v2/config" "github.com/asim/go-micro/v3/config"
"github.com/micro/go-micro/v2/debug/profile" "github.com/asim/go-micro/v3/debug/profile"
"github.com/micro/go-micro/v2/debug/trace" "github.com/asim/go-micro/v3/debug/trace"
"github.com/micro/go-micro/v2/registry" "github.com/asim/go-micro/v3/registry"
"github.com/micro/go-micro/v2/runtime" "github.com/asim/go-micro/v3/runtime"
"github.com/micro/go-micro/v2/selector" "github.com/asim/go-micro/v3/selector"
"github.com/micro/go-micro/v2/server" "github.com/asim/go-micro/v3/server"
"github.com/micro/go-micro/v2/store" "github.com/asim/go-micro/v3/store"
"github.com/micro/go-micro/v2/transport" "github.com/asim/go-micro/v3/transport"
) )
type Options struct { type Options struct {

View File

@ -12,9 +12,9 @@ import (
import ( import (
context "context" context "context"
api "github.com/micro/go-micro/v2/api" api "github.com/asim/go-micro/v3/api"
client "github.com/micro/go-micro/v2/client" client "github.com/asim/go-micro/v3/client"
server "github.com/micro/go-micro/v2/server" server "github.com/asim/go-micro/v3/server"
) )
// Reference imports to suppress errors if they are not otherwise used. // Reference imports to suppress errors if they are not otherwise used.

View File

@ -4,6 +4,6 @@ go 1.13
require ( require (
github.com/golang/protobuf v1.3.5 github.com/golang/protobuf v1.3.5
github.com/micro/go-micro/v2 v2.4.1-0.20200414211455-9a5b8ff50d31 github.com/asim/go-micro/v3 v2.4.1-0.20200414211455-9a5b8ff50d31
google.golang.org/genproto v0.0.0-20191216164720-4f79533eabd1 google.golang.org/genproto v0.0.0-20191216164720-4f79533eabd1
) )

View File

@ -253,8 +253,8 @@ github.com/mholt/certmagic v0.9.3/go.mod h1:nu8jbsbtwK4205EDH/ZUMTKsfYpJA1Q7MKXH
github.com/micro/cli/v2 v2.1.2 h1:43J1lChg/rZCC1rvdqZNFSQDrGT7qfMrtp6/ztpIkEM= github.com/micro/cli/v2 v2.1.2 h1:43J1lChg/rZCC1rvdqZNFSQDrGT7qfMrtp6/ztpIkEM=
github.com/micro/cli/v2 v2.1.2/go.mod h1:EguNh6DAoWKm9nmk+k/Rg0H3lQnDxqzu5x5srOtGtYg= github.com/micro/cli/v2 v2.1.2/go.mod h1:EguNh6DAoWKm9nmk+k/Rg0H3lQnDxqzu5x5srOtGtYg=
github.com/micro/go-micro v1.18.0 h1:gP70EZVHpJuUIT0YWth192JmlIci+qMOEByHm83XE9E= github.com/micro/go-micro v1.18.0 h1:gP70EZVHpJuUIT0YWth192JmlIci+qMOEByHm83XE9E=
github.com/micro/go-micro/v2 v2.4.1-0.20200414211455-9a5b8ff50d31 h1:WHma0yvZF/QjH72IxGHV+oYui3AhvgL9Xy5WKK06Fb8= github.com/asim/go-micro/v3 v2.4.1-0.20200414211455-9a5b8ff50d31 h1:WHma0yvZF/QjH72IxGHV+oYui3AhvgL9Xy5WKK06Fb8=
github.com/micro/go-micro/v2 v2.4.1-0.20200414211455-9a5b8ff50d31/go.mod h1:E9E3RGlgxMl5yv7/IITu5jHAxWveL8rLR9kim8EzDJI= github.com/asim/go-micro/v3 v2.4.1-0.20200414211455-9a5b8ff50d31/go.mod h1:E9E3RGlgxMl5yv7/IITu5jHAxWveL8rLR9kim8EzDJI=
github.com/miekg/dns v1.1.15/go.mod h1:W1PPwlIAgtquWBMBEV9nkV9Cazfe8ScdGz/Lj7v3Nrg= github.com/miekg/dns v1.1.15/go.mod h1:W1PPwlIAgtquWBMBEV9nkV9Cazfe8ScdGz/Lj7v3Nrg=
github.com/miekg/dns v1.1.27 h1:aEH/kqUzUxGJ/UHcEKdJY+ugH6WEzsEBBSPa8zuy1aM= github.com/miekg/dns v1.1.27 h1:aEH/kqUzUxGJ/UHcEKdJY+ugH6WEzsEBBSPa8zuy1aM=
github.com/miekg/dns v1.1.27/go.mod h1:KNUDUusw/aVsxyTYZM1oqvCicbwhgbNgztCETuNZ7xM= github.com/miekg/dns v1.1.27/go.mod h1:KNUDUusw/aVsxyTYZM1oqvCicbwhgbNgztCETuNZ7xM=

View File

@ -15,10 +15,10 @@ import (
// Paths for packages used by code generated in this file, // Paths for packages used by code generated in this file,
// relative to the import_prefix of the generator.Generator. // relative to the import_prefix of the generator.Generator.
const ( const (
apiPkgPath = "github.com/micro/go-micro/v2/api" apiPkgPath = "github.com/asim/go-micro/v3/api"
contextPkgPath = "context" contextPkgPath = "context"
clientPkgPath = "github.com/micro/go-micro/v2/client" clientPkgPath = "github.com/asim/go-micro/v3/client"
serverPkgPath = "github.com/micro/go-micro/v2/server" serverPkgPath = "github.com/asim/go-micro/v3/server"
) )
func init() { func init() {

View File

@ -6,7 +6,7 @@ import (
"io" "io"
"io/ioutil" "io/ioutil"
"github.com/micro/go-micro/v2/codec" "github.com/asim/go-micro/v3/codec"
) )
type Codec struct { type Codec struct {

View File

@ -1,7 +1,7 @@
package bytes package bytes
import ( import (
"github.com/micro/go-micro/v2/codec" "github.com/asim/go-micro/v3/codec"
) )
type Marshaler struct{} type Marshaler struct{}

View File

@ -8,8 +8,8 @@ import (
"io" "io"
"strings" "strings"
"github.com/asim/go-micro/v3/codec"
"github.com/golang/protobuf/proto" "github.com/golang/protobuf/proto"
"github.com/micro/go-micro/v2/codec"
) )
type Codec struct { type Codec struct {

View File

@ -5,9 +5,9 @@ import (
"encoding/json" "encoding/json"
"io" "io"
"github.com/asim/go-micro/v3/codec"
"github.com/golang/protobuf/jsonpb" "github.com/golang/protobuf/jsonpb"
"github.com/golang/protobuf/proto" "github.com/golang/protobuf/proto"
"github.com/micro/go-micro/v2/codec"
) )
type Codec struct { type Codec struct {

View File

@ -6,7 +6,7 @@ import (
"io" "io"
"sync" "sync"
"github.com/micro/go-micro/v2/codec" "github.com/asim/go-micro/v3/codec"
) )
type clientCodec struct { type clientCodec struct {

View File

@ -7,7 +7,7 @@ import (
"fmt" "fmt"
"io" "io"
"github.com/micro/go-micro/v2/codec" "github.com/asim/go-micro/v3/codec"
) )
type jsonCodec struct { type jsonCodec struct {

View File

@ -5,7 +5,7 @@ import (
"fmt" "fmt"
"io" "io"
"github.com/micro/go-micro/v2/codec" "github.com/asim/go-micro/v3/codec"
) )
type serverCodec struct { type serverCodec struct {

View File

@ -3,8 +3,8 @@ package proto
import ( import (
"bytes" "bytes"
"github.com/asim/go-micro/v3/codec"
"github.com/golang/protobuf/proto" "github.com/golang/protobuf/proto"
"github.com/micro/go-micro/v2/codec"
"github.com/oxtoacart/bpool" "github.com/oxtoacart/bpool"
) )

View File

@ -5,8 +5,8 @@ import (
"io" "io"
"io/ioutil" "io/ioutil"
"github.com/asim/go-micro/v3/codec"
"github.com/golang/protobuf/proto" "github.com/golang/protobuf/proto"
"github.com/micro/go-micro/v2/codec"
) )
type Codec struct { type Codec struct {

View File

@ -8,8 +8,8 @@ import (
"strconv" "strconv"
"sync" "sync"
"github.com/asim/go-micro/v3/codec"
"github.com/golang/protobuf/proto" "github.com/golang/protobuf/proto"
"github.com/micro/go-micro/v2/codec"
) )
type flusher interface { type flusher interface {

View File

@ -6,7 +6,7 @@ import (
"io" "io"
"io/ioutil" "io/ioutil"
"github.com/micro/go-micro/v2/codec" "github.com/asim/go-micro/v3/codec"
) )
type Codec struct { type Codec struct {

View File

@ -4,10 +4,10 @@ package config
import ( import (
"context" "context"
"github.com/micro/go-micro/v2/config/loader" "github.com/asim/go-micro/v3/config/loader"
"github.com/micro/go-micro/v2/config/reader" "github.com/asim/go-micro/v3/config/reader"
"github.com/micro/go-micro/v2/config/source" "github.com/asim/go-micro/v3/config/source"
"github.com/micro/go-micro/v2/config/source/file" "github.com/asim/go-micro/v3/config/source/file"
) )
// Config is an interface abstraction for dynamic configuration // Config is an interface abstraction for dynamic configuration

View File

@ -5,11 +5,11 @@ import (
"sync" "sync"
"time" "time"
"github.com/micro/go-micro/v2/config/loader" "github.com/asim/go-micro/v3/config/loader"
"github.com/micro/go-micro/v2/config/loader/memory" "github.com/asim/go-micro/v3/config/loader/memory"
"github.com/micro/go-micro/v2/config/reader" "github.com/asim/go-micro/v3/config/reader"
"github.com/micro/go-micro/v2/config/reader/json" "github.com/asim/go-micro/v3/config/reader/json"
"github.com/micro/go-micro/v2/config/source" "github.com/asim/go-micro/v3/config/source"
) )
type config struct { type config struct {

View File

@ -9,10 +9,10 @@ import (
"testing" "testing"
"time" "time"
"github.com/micro/go-micro/v2/config/source" "github.com/asim/go-micro/v3/config/source"
"github.com/micro/go-micro/v2/config/source/env" "github.com/asim/go-micro/v3/config/source/env"
"github.com/micro/go-micro/v2/config/source/file" "github.com/asim/go-micro/v3/config/source/file"
"github.com/micro/go-micro/v2/config/source/memory" "github.com/asim/go-micro/v3/config/source/memory"
) )
func createFileForIssue18(t *testing.T, content string) *os.File { func createFileForIssue18(t *testing.T, content string) *os.File {

View File

@ -3,7 +3,7 @@ package json
import ( import (
"encoding/json" "encoding/json"
"github.com/micro/go-micro/v2/config/encoder" "github.com/asim/go-micro/v3/config/encoder"
) )
type jsonEncoder struct{} type jsonEncoder struct{}

View File

@ -4,8 +4,8 @@ package loader
import ( import (
"context" "context"
"github.com/micro/go-micro/v2/config/reader" "github.com/asim/go-micro/v3/config/reader"
"github.com/micro/go-micro/v2/config/source" "github.com/asim/go-micro/v3/config/source"
) )
// Loader manages loading sources // Loader manages loading sources

View File

@ -9,10 +9,10 @@ import (
"sync" "sync"
"time" "time"
"github.com/micro/go-micro/v2/config/loader" "github.com/asim/go-micro/v3/config/loader"
"github.com/micro/go-micro/v2/config/reader" "github.com/asim/go-micro/v3/config/reader"
"github.com/micro/go-micro/v2/config/reader/json" "github.com/asim/go-micro/v3/config/reader/json"
"github.com/micro/go-micro/v2/config/source" "github.com/asim/go-micro/v3/config/source"
) )
type memory struct { type memory struct {

View File

@ -1,9 +1,9 @@
package memory package memory
import ( import (
"github.com/micro/go-micro/v2/config/loader" "github.com/asim/go-micro/v3/config/loader"
"github.com/micro/go-micro/v2/config/reader" "github.com/asim/go-micro/v3/config/reader"
"github.com/micro/go-micro/v2/config/source" "github.com/asim/go-micro/v3/config/source"
) )
// WithSource appends a source to list of sources // WithSource appends a source to list of sources

View File

@ -1,9 +1,9 @@
package config package config
import ( import (
"github.com/micro/go-micro/v2/config/loader" "github.com/asim/go-micro/v3/config/loader"
"github.com/micro/go-micro/v2/config/reader" "github.com/asim/go-micro/v3/config/reader"
"github.com/micro/go-micro/v2/config/source" "github.com/asim/go-micro/v3/config/source"
) )
// WithLoader sets the loader for manager config // WithLoader sets the loader for manager config

View File

@ -4,11 +4,11 @@ import (
"errors" "errors"
"time" "time"
"github.com/asim/go-micro/v3/config/encoder"
"github.com/asim/go-micro/v3/config/encoder/json"
"github.com/asim/go-micro/v3/config/reader"
"github.com/asim/go-micro/v3/config/source"
"github.com/imdario/mergo" "github.com/imdario/mergo"
"github.com/micro/go-micro/v2/config/encoder"
"github.com/micro/go-micro/v2/config/encoder/json"
"github.com/micro/go-micro/v2/config/reader"
"github.com/micro/go-micro/v2/config/source"
) )
type jsonReader struct { type jsonReader struct {

View File

@ -3,7 +3,7 @@ package json
import ( import (
"testing" "testing"
"github.com/micro/go-micro/v2/config/source" "github.com/asim/go-micro/v3/config/source"
) )
func TestReader(t *testing.T) { func TestReader(t *testing.T) {

View File

@ -7,9 +7,9 @@ import (
"strings" "strings"
"time" "time"
"github.com/asim/go-micro/v3/config/reader"
"github.com/asim/go-micro/v3/config/source"
simple "github.com/bitly/go-simplejson" simple "github.com/bitly/go-simplejson"
"github.com/micro/go-micro/v2/config/reader"
"github.com/micro/go-micro/v2/config/source"
) )
type jsonValues struct { type jsonValues struct {

View File

@ -4,7 +4,7 @@ import (
"reflect" "reflect"
"testing" "testing"
"github.com/micro/go-micro/v2/config/source" "github.com/asim/go-micro/v3/config/source"
) )
func TestValues(t *testing.T) { func TestValues(t *testing.T) {

View File

@ -1,8 +1,8 @@
package reader package reader
import ( import (
"github.com/micro/go-micro/v2/config/encoder" "github.com/asim/go-micro/v3/config/encoder"
"github.com/micro/go-micro/v2/config/encoder/json" "github.com/asim/go-micro/v3/config/encoder/json"
) )
type Options struct { type Options struct {

View File

@ -4,7 +4,7 @@ package reader
import ( import (
"time" "time"
"github.com/micro/go-micro/v2/config/source" "github.com/asim/go-micro/v3/config/source"
) )
// Reader is an interface for merging changesets // Reader is an interface for merging changesets

View File

@ -2,7 +2,7 @@
package box package box
import ( import (
"github.com/micro/go-micro/v2/config/secrets" "github.com/asim/go-micro/v3/config/secrets"
"github.com/pkg/errors" "github.com/pkg/errors"
naclbox "golang.org/x/crypto/nacl/box" naclbox "golang.org/x/crypto/nacl/box"

View File

@ -5,7 +5,7 @@ import (
"reflect" "reflect"
"testing" "testing"
"github.com/micro/go-micro/v2/config/secrets" "github.com/asim/go-micro/v3/config/secrets"
naclbox "golang.org/x/crypto/nacl/box" naclbox "golang.org/x/crypto/nacl/box"
) )

View File

@ -3,7 +3,7 @@
package secretbox package secretbox
import ( import (
"github.com/micro/go-micro/v2/config/secrets" "github.com/asim/go-micro/v3/config/secrets"
"github.com/pkg/errors" "github.com/pkg/errors"
"golang.org/x/crypto/nacl/secretbox" "golang.org/x/crypto/nacl/secretbox"

View File

@ -5,7 +5,7 @@ import (
"reflect" "reflect"
"testing" "testing"
"github.com/micro/go-micro/v2/config/secrets" "github.com/asim/go-micro/v3/config/secrets"
) )
func TestSecretBox(t *testing.T) { func TestSecretBox(t *testing.T) {

View File

@ -7,10 +7,10 @@ import (
"strings" "strings"
"time" "time"
"github.com/asim/go-micro/v3/cmd"
"github.com/asim/go-micro/v3/config/source"
"github.com/imdario/mergo" "github.com/imdario/mergo"
"github.com/micro/cli/v2" "github.com/micro/cli/v2"
"github.com/micro/go-micro/v2/cmd"
"github.com/micro/go-micro/v2/config/source"
) )
type cliSource struct { type cliSource struct {

View File

@ -5,11 +5,11 @@ import (
"os" "os"
"testing" "testing"
"github.com/asim/go-micro/v3"
"github.com/asim/go-micro/v3/cmd"
"github.com/asim/go-micro/v3/config"
"github.com/asim/go-micro/v3/config/source"
"github.com/micro/cli/v2" "github.com/micro/cli/v2"
"github.com/micro/go-micro/v2"
"github.com/micro/go-micro/v2/cmd"
"github.com/micro/go-micro/v2/config"
"github.com/micro/go-micro/v2/config/source"
) )
func TestCliSourceDefault(t *testing.T) { func TestCliSourceDefault(t *testing.T) {

View File

@ -3,8 +3,8 @@ package cli
import ( import (
"context" "context"
"github.com/asim/go-micro/v3/config/source"
"github.com/micro/cli/v2" "github.com/micro/cli/v2"
"github.com/micro/go-micro/v2/config/source"
) )
type contextKey struct{} type contextKey struct{}

View File

@ -6,8 +6,8 @@ import (
"strings" "strings"
"time" "time"
"github.com/asim/go-micro/v3/config/source"
"github.com/imdario/mergo" "github.com/imdario/mergo"
"github.com/micro/go-micro/v2/config/source"
) )
var ( var (

View File

@ -6,7 +6,7 @@ import (
"testing" "testing"
"time" "time"
"github.com/micro/go-micro/v2/config/source" "github.com/asim/go-micro/v3/config/source"
) )
func TestEnv_Read(t *testing.T) { func TestEnv_Read(t *testing.T) {

View File

@ -5,7 +5,7 @@ import (
"strings" "strings"
"github.com/micro/go-micro/v2/config/source" "github.com/asim/go-micro/v3/config/source"
) )
type strippedPrefixKey struct{} type strippedPrefixKey struct{}

View File

@ -1,7 +1,7 @@
package env package env
import ( import (
"github.com/micro/go-micro/v2/config/source" "github.com/asim/go-micro/v3/config/source"
) )
type watcher struct { type watcher struct {

View File

@ -5,7 +5,7 @@ import (
"io/ioutil" "io/ioutil"
"os" "os"
"github.com/micro/go-micro/v2/config/source" "github.com/asim/go-micro/v3/config/source"
) )
type file struct { type file struct {

View File

@ -7,8 +7,8 @@ import (
"testing" "testing"
"time" "time"
"github.com/micro/go-micro/v2/config" "github.com/asim/go-micro/v3/config"
"github.com/micro/go-micro/v2/config/source/file" "github.com/asim/go-micro/v3/config/source/file"
) )
func TestConfig(t *testing.T) { func TestConfig(t *testing.T) {

View File

@ -3,7 +3,7 @@ package file
import ( import (
"strings" "strings"
"github.com/micro/go-micro/v2/config/encoder" "github.com/asim/go-micro/v3/config/encoder"
) )
func format(p string, e encoder.Encoder) string { func format(p string, e encoder.Encoder) string {

View File

@ -3,7 +3,7 @@ package file
import ( import (
"testing" "testing"
"github.com/micro/go-micro/v2/config/source" "github.com/asim/go-micro/v3/config/source"
) )
func TestFormat(t *testing.T) { func TestFormat(t *testing.T) {

View File

@ -3,7 +3,7 @@ package file
import ( import (
"context" "context"
"github.com/micro/go-micro/v2/config/source" "github.com/asim/go-micro/v3/config/source"
) )
type filePathKey struct{} type filePathKey struct{}

View File

@ -5,8 +5,8 @@ package file
import ( import (
"os" "os"
"github.com/asim/go-micro/v3/config/source"
"github.com/fsnotify/fsnotify" "github.com/fsnotify/fsnotify"
"github.com/micro/go-micro/v2/config/source"
) )
type watcher struct { type watcher struct {

View File

@ -5,8 +5,8 @@ package file
import ( import (
"os" "os"
"github.com/asim/go-micro/v3/config/source"
"github.com/fsnotify/fsnotify" "github.com/fsnotify/fsnotify"
"github.com/micro/go-micro/v2/config/source"
) )
type watcher struct { type watcher struct {

View File

@ -3,8 +3,8 @@ package flag
import ( import (
"errors" "errors"
"flag" "flag"
"github.com/asim/go-micro/v3/config/source"
"github.com/imdario/mergo" "github.com/imdario/mergo"
"github.com/micro/go-micro/v2/config/source"
"strings" "strings"
"time" "time"
) )

View File

@ -3,7 +3,7 @@ package flag
import ( import (
"context" "context"
"github.com/micro/go-micro/v2/config/source" "github.com/asim/go-micro/v3/config/source"
) )
type includeUnsetKey struct{} type includeUnsetKey struct{}

View File

@ -5,8 +5,8 @@ import (
"sync" "sync"
"time" "time"
"github.com/asim/go-micro/v3/config/source"
"github.com/google/uuid" "github.com/google/uuid"
"github.com/micro/go-micro/v2/config/source"
) )
type memory struct { type memory struct {

View File

@ -3,7 +3,7 @@ package memory
import ( import (
"context" "context"
"github.com/micro/go-micro/v2/config/source" "github.com/asim/go-micro/v3/config/source"
) )
type changeSetKey struct{} type changeSetKey struct{}

View File

@ -1,7 +1,7 @@
package memory package memory
import ( import (
"github.com/micro/go-micro/v2/config/source" "github.com/asim/go-micro/v3/config/source"
) )
type watcher struct { type watcher struct {

View File

@ -3,9 +3,9 @@ package source
import ( import (
"context" "context"
"github.com/micro/go-micro/v2/client" "github.com/asim/go-micro/v3/client"
"github.com/micro/go-micro/v2/config/encoder" "github.com/asim/go-micro/v3/config/encoder"
"github.com/micro/go-micro/v2/config/encoder/json" "github.com/asim/go-micro/v3/config/encoder/json"
) )
type Options struct { type Options struct {

Some files were not shown because too many files have changed in this diff Show More