diff --git a/.travis.yml b/.travis.yml index d52eb1d..069975a 100644 --- a/.travis.yml +++ b/.travis.yml @@ -5,7 +5,7 @@ go: - 1.6.3 - 1.7 -go_import_path: go4.org/grpc +go_import_path: grpc.go4.org before_install: - if [[ $TRAVIS_GO_VERSION != 1.5* ]]; then go get github.com/golang/lint/golint; fi diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 461b953..8f83ff7 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -9,8 +9,8 @@ and information about how to do so. 1. Check out the code: - $ go get go4.org/grpc - $ cd $GOPATH/src/go4.org/grpc + $ go get grpc.go4.org + $ cd $GOPATH/src/grpc.go4.org 1. Create a fork of the grpc-go repository. 1. Add your fork as a remote: diff --git a/Documentation/grpc-metadata.md b/Documentation/grpc-metadata.md index 4db8a83..9d1465d 100644 --- a/Documentation/grpc-metadata.md +++ b/Documentation/grpc-metadata.md @@ -16,7 +16,7 @@ And concept of [metadata](http://www.grpc.io/docs/guides/concepts.html#metadata) ## Constructing metadata -A metadata can be created using package [metadata](https://godoc.org/go4.org/grpc/metadata). +A metadata can be created using package [metadata](https://godoc.org/grpc.go4.org/metadata). The type MD is actually a map from string to a list of strings: ```go @@ -102,7 +102,7 @@ Metadata that a client can receive includes header and trailer. #### Unary call -Header and trailer sent along with a unary call can be retrieved using function [Header](https://godoc.org/go4.org/grpc#Header) and [Trailer](https://godoc.org/google.golang.org/grpc#Trailer) in [CallOption](https://godoc.org/google.golang.org/grpc#CallOption): +Header and trailer sent along with a unary call can be retrieved using function [Header](https://godoc.org/grpc.go4.org#Header) and [Trailer](https://godoc.org/grpc.go4.org#Trailer) in [CallOption](https://godoc.org/grpc.go4.org#CallOption): ```go var header, trailer metadata.MD // variable to store header and trailer @@ -124,7 +124,7 @@ For streaming calls including: - Client streaming RPC - Bidirectional streaming RPC -Header and trailer can be retrieved from the returned stream using function `Header` and `Trailer` in interface [ClientStream](https://godoc.org/go4.org/grpc#ClientStream): +Header and trailer can be retrieved from the returned stream using function `Header` and `Trailer` in interface [ClientStream](https://godoc.org/grpc.go4.org#ClientStream): ```go stream, err := client.SomeStreamingRPC(ctx) @@ -170,7 +170,7 @@ func (s *server) SomeStreamingRPC(stream pb.Service_SomeStreamingRPCServer) erro #### Unary call -To send header and trailer to client in unary call, the server can call [SendHeader](https://godoc.org/go4.org/grpc#SendHeader) and [SetTrailer](https://godoc.org/google.golang.org/grpc#SetTrailer) functions in module [grpc](https://godoc.org/google.golang.org/grpc). +To send header and trailer to client in unary call, the server can call [SendHeader](https://godoc.org/grpc.go4.org#SendHeader) and [SetTrailer](https://godoc.org/grpc.go4.org#SetTrailer) functions in module [grpc](https://godoc.org/grpc.go4.org). These two functions take a context as the first parameter. It should be the RPC handler's context or one derived from it: @@ -187,7 +187,7 @@ func (s *server) SomeRPC(ctx context.Context, in *pb.someRequest) (*pb.someRespo #### Streaming call -For streaming calls, header and trailer can be sent using function `SendHeader` and `SetTrailer` in interface [ServerStream](https://godoc.org/go4.org/grpc#ServerStream): +For streaming calls, header and trailer can be sent using function `SendHeader` and `SetTrailer` in interface [ServerStream](https://godoc.org/grpc.go4.org#ServerStream): ```go func (s *server) SomeStreamingRPC(stream pb.Service_SomeStreamingRPCServer) error { diff --git a/Documentation/server-reflection-tutorial.md b/Documentation/server-reflection-tutorial.md index ded15f3..5ea8fb0 100644 --- a/Documentation/server-reflection-tutorial.md +++ b/Documentation/server-reflection-tutorial.md @@ -17,9 +17,9 @@ For example, to enable server reflection in `example/helloworld`, we need to mak +++ b/examples/helloworld/greeter_server/main.go @@ -40,6 +40,7 @@ import ( "context" - "go4.org/grpc" - pb "go4.org/grpc/examples/helloworld/helloworld" -+ "go4.org/grpc/reflection" + "grpc.go4.org" + pb "grpc.go4.org/examples/helloworld/helloworld" ++ "grpc.go4.org/reflection" ) const ( diff --git a/Makefile b/Makefile index eafe5cf..7e8ee95 100644 --- a/Makefile +++ b/Makefile @@ -1,19 +1,19 @@ all: test testrace deps: - go get -d -v go4.org/grpc/... + go get -d -v grpc.go4.org/... updatedeps: - go get -d -v -u -f go4.org/grpc/... + go get -d -v -u -f grpc.go4.org/... testdeps: - go get -d -v -t go4.org/grpc/... + go get -d -v -t grpc.go4.org/... updatetestdeps: - go get -d -v -t -u -f go4.org/grpc/... + go get -d -v -t -u -f grpc.go4.org/... build: deps - go build go4.org/grpc/... + go build grpc.go4.org/... proto: @ if ! which protoc > /dev/null; then \ @@ -27,13 +27,13 @@ proto: done test: testdeps - go test -v -cpu 1,4 go4.org/grpc/... + go test -v -cpu 1,4 grpc.go4.org/... testrace: testdeps - go test -v -race -cpu 1,4 go4.org/grpc/... + go test -v -race -cpu 1,4 grpc.go4.org/... clean: - go clean -i go4.org/grpc/... + go clean -i grpc.go4.org/... coverage: testdeps ./coverage.sh --coveralls diff --git a/README.md b/README.md index 95d80e3..f6d5662 100644 --- a/README.md +++ b/README.md @@ -8,7 +8,7 @@ Go's native HTTP/2 implementation. (Preliminary prototypes suggest most of it.) Installation ------------ -`go install go4.org/grpc` +`go install grpc.go4.org` Prerequisites ------------- diff --git a/benchmark/benchmark.go b/benchmark/benchmark.go index 5df221d..b75be32 100644 --- a/benchmark/benchmark.go +++ b/benchmark/benchmark.go @@ -42,9 +42,9 @@ import ( "net" "context" - "go4.org/grpc" - testpb "go4.org/grpc/benchmark/grpc_testing" - "go4.org/grpc/grpclog" + "grpc.go4.org" + testpb "grpc.go4.org/benchmark/grpc_testing" + "grpc.go4.org/grpclog" ) func newPayload(t testpb.PayloadType, size int) *testpb.Payload { diff --git a/benchmark/benchmark_test.go b/benchmark/benchmark_test.go index 9f8480f..0165f79 100644 --- a/benchmark/benchmark_test.go +++ b/benchmark/benchmark_test.go @@ -7,10 +7,10 @@ import ( "time" "context" - "go4.org/grpc" - testpb "go4.org/grpc/benchmark/grpc_testing" - "go4.org/grpc/benchmark/stats" - "go4.org/grpc/grpclog" + "grpc.go4.org" + testpb "grpc.go4.org/benchmark/grpc_testing" + "grpc.go4.org/benchmark/stats" + "grpc.go4.org/grpclog" ) func runUnary(b *testing.B, maxConcurrentCalls int) { diff --git a/benchmark/client/main.go b/benchmark/client/main.go index da686f4..2df9e3b 100644 --- a/benchmark/client/main.go +++ b/benchmark/client/main.go @@ -10,11 +10,11 @@ import ( "time" "context" - "go4.org/grpc" - "go4.org/grpc/benchmark" - testpb "go4.org/grpc/benchmark/grpc_testing" - "go4.org/grpc/benchmark/stats" - "go4.org/grpc/grpclog" + "grpc.go4.org" + "grpc.go4.org/benchmark" + testpb "grpc.go4.org/benchmark/grpc_testing" + "grpc.go4.org/benchmark/stats" + "grpc.go4.org/grpclog" ) var ( diff --git a/benchmark/grpc_testing/services.pb.go b/benchmark/grpc_testing/services.pb.go index b380135..22d22d4 100644 --- a/benchmark/grpc_testing/services.pb.go +++ b/benchmark/grpc_testing/services.pb.go @@ -10,7 +10,7 @@ import math "math" import ( context "context" - grpc "go4.org/grpc" + grpc "grpc.go4.org" ) // Reference imports to suppress errors if they are not otherwise used. diff --git a/benchmark/server/main.go b/benchmark/server/main.go index ba7c7d3..73c169a 100644 --- a/benchmark/server/main.go +++ b/benchmark/server/main.go @@ -8,8 +8,8 @@ import ( _ "net/http/pprof" "time" - "go4.org/grpc/benchmark" - "go4.org/grpc/grpclog" + "grpc.go4.org/benchmark" + "grpc.go4.org/grpclog" ) var ( diff --git a/benchmark/worker/benchmark_client.go b/benchmark/worker/benchmark_client.go index fbeacc4..a2a14c0 100644 --- a/benchmark/worker/benchmark_client.go +++ b/benchmark/worker/benchmark_client.go @@ -40,13 +40,13 @@ import ( "time" "context" - "go4.org/grpc" - "go4.org/grpc/benchmark" - testpb "go4.org/grpc/benchmark/grpc_testing" - "go4.org/grpc/benchmark/stats" - "go4.org/grpc/codes" - "go4.org/grpc/credentials" - "go4.org/grpc/grpclog" + "grpc.go4.org" + "grpc.go4.org/benchmark" + testpb "grpc.go4.org/benchmark/grpc_testing" + "grpc.go4.org/benchmark/stats" + "grpc.go4.org/codes" + "grpc.go4.org/credentials" + "grpc.go4.org/grpclog" ) var ( diff --git a/benchmark/worker/benchmark_server.go b/benchmark/worker/benchmark_server.go index 51b8192..014dcd4 100644 --- a/benchmark/worker/benchmark_server.go +++ b/benchmark/worker/benchmark_server.go @@ -40,16 +40,16 @@ import ( "sync" "time" - "go4.org/grpc" - "go4.org/grpc/benchmark" - testpb "go4.org/grpc/benchmark/grpc_testing" - "go4.org/grpc/codes" - "go4.org/grpc/credentials" - "go4.org/grpc/grpclog" + "grpc.go4.org" + "grpc.go4.org/benchmark" + testpb "grpc.go4.org/benchmark/grpc_testing" + "grpc.go4.org/codes" + "grpc.go4.org/credentials" + "grpc.go4.org/grpclog" ) var ( - // File path related to go4.org/grpc. + // File path related to grpc.go4.org. certFile = "benchmark/server/testdata/server1.pem" keyFile = "benchmark/server/testdata/server1.key" ) diff --git a/benchmark/worker/main.go b/benchmark/worker/main.go index e6e80c2..3cffba8 100644 --- a/benchmark/worker/main.go +++ b/benchmark/worker/main.go @@ -43,10 +43,10 @@ import ( "time" "context" - "go4.org/grpc" - testpb "go4.org/grpc/benchmark/grpc_testing" - "go4.org/grpc/codes" - "go4.org/grpc/grpclog" + "grpc.go4.org" + testpb "grpc.go4.org/benchmark/grpc_testing" + "grpc.go4.org/codes" + "grpc.go4.org/grpclog" ) var ( diff --git a/benchmark/worker/util.go b/benchmark/worker/util.go index 04babd3..7e36cf0 100644 --- a/benchmark/worker/util.go +++ b/benchmark/worker/util.go @@ -39,15 +39,15 @@ import ( ) // abs returns the absolute path the given relative file or directory path, -// relative to the go4.org/grpc directory in the user's GOPATH. +// relative to the grpc.go4.org directory in the user's GOPATH. // If rel is already absolute, it is returned unmodified. func abs(rel string) string { if filepath.IsAbs(rel) { return rel } - v, err := goPackagePath("go4.org/grpc") + v, err := goPackagePath("grpc.go4.org") if err != nil { - log.Fatalf("Error finding go4.org/grpc/testdata directory: %v", err) + log.Fatalf("Error finding grpc.go4.org/testdata directory: %v", err) } return filepath.Join(v, rel) } diff --git a/call.go b/call.go index 677f67f..8346f4b 100644 --- a/call.go +++ b/call.go @@ -41,9 +41,9 @@ import ( "time" "context" - "go4.org/grpc/codes" - "go4.org/grpc/metadata" - "go4.org/grpc/stats" + "grpc.go4.org/codes" + "grpc.go4.org/metadata" + "grpc.go4.org/stats" "golang.org/x/net/trace" ) diff --git a/call_test.go b/call_test.go index 0696b1b..1834bef 100644 --- a/call_test.go +++ b/call_test.go @@ -45,8 +45,8 @@ import ( "time" "context" - "go4.org/grpc/codes" - "go4.org/grpc/transport" + "grpc.go4.org/codes" + "grpc.go4.org/transport" ) var ( diff --git a/clientconn.go b/clientconn.go index 4e308dc..a18480b 100644 --- a/clientconn.go +++ b/clientconn.go @@ -39,8 +39,8 @@ import ( "fmt" "net/http" - "go4.org/grpc/credentials" - "go4.org/grpc/stats" + "grpc.go4.org/credentials" + "grpc.go4.org/stats" ) var ( diff --git a/clientconn_test.go b/clientconn_test.go index 0cdc2b0..142fc75 100644 --- a/clientconn_test.go +++ b/clientconn_test.go @@ -40,7 +40,7 @@ import ( "context" - "go4.org/grpc/credentials" + "grpc.go4.org/credentials" ) const tlsDir = "testdata/" diff --git a/codes/codes.go b/codes/codes.go index 8020afd..a211e8d 100644 --- a/codes/codes.go +++ b/codes/codes.go @@ -33,7 +33,7 @@ // Package codes defines the canonical error codes used by gRPC. It is // consistent across various languages. -package codes // import "go4.org/grpc/codes" +package codes // import "grpc.go4.org/codes" // A Code is an unsigned 32-bit error code as defined in the gRPC spec. type Code uint32 diff --git a/coverage.sh b/coverage.sh index 34f12b7..b13a15b 100755 --- a/coverage.sh +++ b/coverage.sh @@ -6,14 +6,14 @@ set -e workdir=.cover profile="$workdir/cover.out" mode=set -end2endtest="go4.org/grpc/test" +end2endtest="grpc.go4.org/test" generate_cover_data() { rm -rf "$workdir" mkdir "$workdir" for pkg in "$@"; do - if [ $pkg == "go4.org/grpc" -o $pkg == "google.golang.org/grpc/transport" -o $pkg == "google.golang.org/grpc/metadata" -o $pkg == "google.golang.org/grpc/credentials" ] + if [ $pkg == "grpc.go4.org" -o $pkg == "grpc.go4.org/transport" -o $pkg == "grpc.go4.org/metadata" -o $pkg == "grpc.go4.org/credentials" ] then f="$workdir/$(echo $pkg | tr / -)" go test -covermode="$mode" -coverprofile="$f.cover" "$pkg" diff --git a/credentials/credentials.go b/credentials/credentials.go index 197c9bf..8a66a0a 100644 --- a/credentials/credentials.go +++ b/credentials/credentials.go @@ -35,7 +35,7 @@ // which encapsulate all the state needed by a client to authenticate with a // server and make various assertions, e.g., about the client's identity, role, // or whether it is authorized to make a particular call. -package credentials // import "go4.org/grpc/credentials" +package credentials // import "grpc.go4.org/credentials" import ( "crypto/tls" diff --git a/credentials/oauth/oauth.go b/credentials/oauth/oauth.go index 8fb803d..e60579b 100644 --- a/credentials/oauth/oauth.go +++ b/credentials/oauth/oauth.go @@ -39,7 +39,7 @@ import ( "io/ioutil" "context" - "go4.org/grpc/credentials" + "grpc.go4.org/credentials" "golang.org/x/oauth2" "golang.org/x/oauth2/google" "golang.org/x/oauth2/jwt" diff --git a/doc.go b/doc.go index 76b49fd..b22e7b9 100644 --- a/doc.go +++ b/doc.go @@ -9,4 +9,4 @@ https://github.com/grpc/grpc-go. For information about this experimental version, see https://github.com/go4org/grpc */ -package grpc // import "go4.org/grpc" +package grpc // import "grpc.go4.org" diff --git a/examples/README.md b/examples/README.md index c776806..094d0cc 100644 --- a/examples/README.md +++ b/examples/README.md @@ -21,8 +21,8 @@ INSTALL ------- ``` -$ go get -u go4.org/grpc/examples/helloworld/greeter_client -$ go get -u go4.org/grpc/examples/helloworld/greeter_server +$ go get -u grpc.go4.org/examples/helloworld/greeter_client +$ go get -u grpc.go4.org/examples/helloworld/greeter_server ``` TRY IT! diff --git a/examples/gotutorial.md b/examples/gotutorial.md index 36780c1..721d66e 100644 --- a/examples/gotutorial.md +++ b/examples/gotutorial.md @@ -20,12 +20,12 @@ With gRPC we can define our service once in a .proto file and implement clients The example code for our tutorial is in [grpc/grpc-go/examples/route_guide](https://github.com/grpc/grpc-go/tree/master/examples/route_guide). To download the example, clone the `grpc-go` repository by running the following command: ```shell -$ go get go4.org/grpc +$ go get grpc.go4.org ``` Then change your current directory to `grpc-go/examples/route_guide`: ```shell -$ cd $GOPATH/src/go4.org/grpc/examples/route_guide +$ cd $GOPATH/src/grpc.go4.org/examples/route_guide ``` You also should have the relevant tools installed to generate the server and client interface code - if you don't already, follow the setup instructions in [the Go quick start guide](https://github.com/grpc/grpc-go/tree/master/examples/). @@ -417,7 +417,7 @@ The syntax for reading and writing here is very similar to our client-side strea ## Try it out! To compile and run the server, assuming you are in the folder -`$GOPATH/src/go4.org/grpc/examples/route_guide`, simply: +`$GOPATH/src/grpc.go4.org/examples/route_guide`, simply: ```sh $ go run server/server.go diff --git a/examples/helloworld/greeter_client/main.go b/examples/helloworld/greeter_client/main.go index ecc7002..4745b4c 100644 --- a/examples/helloworld/greeter_client/main.go +++ b/examples/helloworld/greeter_client/main.go @@ -38,8 +38,8 @@ import ( "os" "context" - "go4.org/grpc" - pb "go4.org/grpc/examples/helloworld/helloworld" + "grpc.go4.org" + pb "grpc.go4.org/examples/helloworld/helloworld" ) const ( diff --git a/examples/helloworld/greeter_server/main.go b/examples/helloworld/greeter_server/main.go index 2d19f7a..2c2e7cd 100644 --- a/examples/helloworld/greeter_server/main.go +++ b/examples/helloworld/greeter_server/main.go @@ -38,9 +38,9 @@ import ( "net" "context" - "go4.org/grpc" - pb "go4.org/grpc/examples/helloworld/helloworld" - "go4.org/grpc/reflection" + "grpc.go4.org" + pb "grpc.go4.org/examples/helloworld/helloworld" + "grpc.go4.org/reflection" ) const ( diff --git a/examples/helloworld/helloworld/helloworld.pb.go b/examples/helloworld/helloworld/helloworld.pb.go index e01a248..932cc37 100644 --- a/examples/helloworld/helloworld/helloworld.pb.go +++ b/examples/helloworld/helloworld/helloworld.pb.go @@ -20,7 +20,7 @@ import math "math" import ( context "context" - grpc "go4.org/grpc" + grpc "grpc.go4.org" ) // Reference imports to suppress errors if they are not otherwise used. diff --git a/examples/route_guide/client/client.go b/examples/route_guide/client/client.go index e7aa30d..62b6c4a 100644 --- a/examples/route_guide/client/client.go +++ b/examples/route_guide/client/client.go @@ -44,10 +44,10 @@ import ( "time" "context" - "go4.org/grpc" - "go4.org/grpc/credentials" - pb "go4.org/grpc/examples/route_guide/routeguide" - "go4.org/grpc/grpclog" + "grpc.go4.org" + "grpc.go4.org/credentials" + pb "grpc.go4.org/examples/route_guide/routeguide" + "grpc.go4.org/grpclog" ) var ( diff --git a/examples/route_guide/routeguide/route_guide.pb.go b/examples/route_guide/routeguide/route_guide.pb.go index 03c6148..2624dac 100644 --- a/examples/route_guide/routeguide/route_guide.pb.go +++ b/examples/route_guide/routeguide/route_guide.pb.go @@ -23,7 +23,7 @@ import math "math" import ( context "context" - grpc "go4.org/grpc" + grpc "grpc.go4.org" ) // Reference imports to suppress errors if they are not otherwise used. diff --git a/examples/route_guide/server/server.go b/examples/route_guide/server/server.go index 696904b..28009de 100644 --- a/examples/route_guide/server/server.go +++ b/examples/route_guide/server/server.go @@ -48,14 +48,14 @@ import ( "time" "context" - "go4.org/grpc" + "grpc.go4.org" - "go4.org/grpc/credentials" - "go4.org/grpc/grpclog" + "grpc.go4.org/credentials" + "grpc.go4.org/grpclog" "github.com/golang/protobuf/proto" - pb "go4.org/grpc/examples/route_guide/routeguide" + pb "grpc.go4.org/examples/route_guide/routeguide" ) var ( diff --git a/grpclb/grpc_lb_v1/grpclb.pb.go b/grpclb/grpc_lb_v1/grpclb.pb.go index 0f74b4a..907ebbb 100644 --- a/grpclb/grpc_lb_v1/grpclb.pb.go +++ b/grpclb/grpc_lb_v1/grpclb.pb.go @@ -26,7 +26,7 @@ import math "math" import ( context "context" - grpc "go4.org/grpc" + grpc "grpc.go4.org" ) // Reference imports to suppress errors if they are not otherwise used. diff --git a/grpclb/grpclb.go b/grpclb/grpclb.go index 561346d..50a512b 100644 --- a/grpclb/grpclb.go +++ b/grpclb/grpclb.go @@ -43,12 +43,12 @@ import ( "time" "context" - "go4.org/grpc" - "go4.org/grpc/codes" - lbpb "go4.org/grpc/grpclb/grpc_lb_v1" - "go4.org/grpc/grpclog" - "go4.org/grpc/metadata" - "go4.org/grpc/naming" + "grpc.go4.org" + "grpc.go4.org/codes" + lbpb "grpc.go4.org/grpclb/grpc_lb_v1" + "grpc.go4.org/grpclog" + "grpc.go4.org/metadata" + "grpc.go4.org/naming" ) // AddressType indicates the address type returned by name resolution. diff --git a/grpclb/grpclb_test.go b/grpclb/grpclb_test.go index 69c5282..f924cf9 100644 --- a/grpclb/grpclb_test.go +++ b/grpclb/grpclb_test.go @@ -44,13 +44,13 @@ import ( "time" "context" - "go4.org/grpc" - "go4.org/grpc/codes" - "go4.org/grpc/credentials" - hwpb "go4.org/grpc/examples/helloworld/helloworld" - lbpb "go4.org/grpc/grpclb/grpc_lb_v1" - "go4.org/grpc/metadata" - "go4.org/grpc/naming" + "grpc.go4.org" + "grpc.go4.org/codes" + "grpc.go4.org/credentials" + hwpb "grpc.go4.org/examples/helloworld/helloworld" + lbpb "grpc.go4.org/grpclb/grpc_lb_v1" + "grpc.go4.org/metadata" + "grpc.go4.org/naming" ) var ( diff --git a/grpclog/glogger/glogger.go b/grpclog/glogger/glogger.go index 5fbf09e..17bcd72 100644 --- a/grpclog/glogger/glogger.go +++ b/grpclog/glogger/glogger.go @@ -40,7 +40,7 @@ import ( "fmt" "github.com/golang/glog" - "go4.org/grpc/grpclog" + "grpc.go4.org/grpclog" ) func init() { diff --git a/grpclog/logger.go b/grpclog/logger.go index a4b3869..e4fc6ae 100644 --- a/grpclog/logger.go +++ b/grpclog/logger.go @@ -34,7 +34,7 @@ /* Package grpclog defines logging for grpc. */ -package grpclog // import "go4.org/grpc/grpclog" +package grpclog // import "grpc.go4.org/grpclog" import ( "log" diff --git a/health/grpc_health_v1/health.pb.go b/health/grpc_health_v1/health.pb.go index ec3d677..b8acc29 100644 --- a/health/grpc_health_v1/health.pb.go +++ b/health/grpc_health_v1/health.pb.go @@ -20,7 +20,7 @@ import math "math" import ( context "context" - grpc "go4.org/grpc" + grpc "grpc.go4.org" ) // Reference imports to suppress errors if they are not otherwise used. diff --git a/health/health.go b/health/health.go index de879b4..98b945b 100644 --- a/health/health.go +++ b/health/health.go @@ -6,9 +6,9 @@ import ( "sync" "context" - "go4.org/grpc" - "go4.org/grpc/codes" - healthpb "go4.org/grpc/health/grpc_health_v1" + "grpc.go4.org" + "grpc.go4.org/codes" + healthpb "grpc.go4.org/health/grpc_health_v1" ) // Server implements `service Health`. diff --git a/interop/client/client.go b/interop/client/client.go index d0fbaeb..5b348eb 100644 --- a/interop/client/client.go +++ b/interop/client/client.go @@ -38,12 +38,12 @@ import ( "net" "strconv" - "go4.org/grpc" - "go4.org/grpc/credentials" - "go4.org/grpc/credentials/oauth" - "go4.org/grpc/grpclog" - "go4.org/grpc/interop" - testpb "go4.org/grpc/interop/grpc_testing" + "grpc.go4.org" + "grpc.go4.org/credentials" + "grpc.go4.org/credentials/oauth" + "grpc.go4.org/grpclog" + "grpc.go4.org/interop" + testpb "grpc.go4.org/interop/grpc_testing" ) var ( diff --git a/interop/grpc_testing/test.pb.go b/interop/grpc_testing/test.pb.go index f96bd14..4a55083 100755 --- a/interop/grpc_testing/test.pb.go +++ b/interop/grpc_testing/test.pb.go @@ -28,7 +28,7 @@ import math "math" import ( context "context" - grpc "go4.org/grpc" + grpc "grpc.go4.org" ) // Reference imports to suppress errors if they are not otherwise used. diff --git a/interop/server/server.go b/interop/server/server.go index a3f9769..2f238e7 100644 --- a/interop/server/server.go +++ b/interop/server/server.go @@ -38,11 +38,11 @@ import ( "net" "strconv" - "go4.org/grpc" - "go4.org/grpc/credentials" - "go4.org/grpc/grpclog" - "go4.org/grpc/interop" - testpb "go4.org/grpc/interop/grpc_testing" + "grpc.go4.org" + "grpc.go4.org/credentials" + "grpc.go4.org/grpclog" + "grpc.go4.org/interop" + testpb "grpc.go4.org/interop/grpc_testing" ) var ( diff --git a/interop/test_utils.go b/interop/test_utils.go index 3a5a404..ea9d93e 100644 --- a/interop/test_utils.go +++ b/interop/test_utils.go @@ -42,11 +42,11 @@ import ( "context" "github.com/golang/protobuf/proto" - "go4.org/grpc" - "go4.org/grpc/codes" - "go4.org/grpc/grpclog" - testpb "go4.org/grpc/interop/grpc_testing" - "go4.org/grpc/metadata" + "grpc.go4.org" + "grpc.go4.org/codes" + "grpc.go4.org/grpclog" + testpb "grpc.go4.org/interop/grpc_testing" + "grpc.go4.org/metadata" "golang.org/x/oauth2" "golang.org/x/oauth2/google" ) diff --git a/metadata/metadata.go b/metadata/metadata.go index ed4e6c6..8203069 100644 --- a/metadata/metadata.go +++ b/metadata/metadata.go @@ -32,7 +32,7 @@ */ // Package metadata define the structure of the metadata supported by gRPC library. -package metadata // import "go4.org/grpc/metadata" +package metadata // import "grpc.go4.org/metadata" import ( "encoding/base64" diff --git a/peer/peer.go b/peer/peer.go index e20ce08..8ed6205 100644 --- a/peer/peer.go +++ b/peer/peer.go @@ -39,7 +39,7 @@ import ( "net" "context" - "go4.org/grpc/credentials" + "grpc.go4.org/credentials" ) // Peer contains the information of the peer for an RPC. diff --git a/reflection/README.md b/reflection/README.md index d1d2bdc..7d8f14a 100644 --- a/reflection/README.md +++ b/reflection/README.md @@ -6,7 +6,7 @@ The service implemented is defined in: https://github.com/grpc/grpc/blob/master/ To register server reflection on a gRPC server: ```go -import "go4.org/grpc/reflection" +import "grpc.go4.org/reflection" s := grpc.NewServer() pb.RegisterYourOwnServer(s, &server{}) diff --git a/reflection/grpc_reflection_v1alpha/reflection.pb.go b/reflection/grpc_reflection_v1alpha/reflection.pb.go index bf93a64..1942652 100644 --- a/reflection/grpc_reflection_v1alpha/reflection.pb.go +++ b/reflection/grpc_reflection_v1alpha/reflection.pb.go @@ -26,7 +26,7 @@ import math "math" import ( context "context" - grpc "go4.org/grpc" + grpc "grpc.go4.org" ) // Reference imports to suppress errors if they are not otherwise used. diff --git a/reflection/grpc_testing/test.pb.go b/reflection/grpc_testing/test.pb.go index 42ba5f1..7ad958c 100644 --- a/reflection/grpc_testing/test.pb.go +++ b/reflection/grpc_testing/test.pb.go @@ -10,7 +10,7 @@ import math "math" import ( context "context" - grpc "go4.org/grpc" + grpc "grpc.go4.org" ) // Reference imports to suppress errors if they are not otherwise used. diff --git a/reflection/serverreflection.go b/reflection/serverreflection.go index b795b33..d76f08f 100644 --- a/reflection/serverreflection.go +++ b/reflection/serverreflection.go @@ -38,7 +38,7 @@ The service implemented is defined in: https://github.com/grpc/grpc/blob/master/src/proto/grpc/reflection/v1alpha/reflection.proto. To register server reflection on a gRPC server: - import "go4.org/grpc/reflection" + import "grpc.go4.org/reflection" s := grpc.NewServer() pb.RegisterYourOwnServer(s, &server{}) @@ -49,7 +49,7 @@ To register server reflection on a gRPC server: s.Serve(lis) */ -package reflection // import "go4.org/grpc/reflection" +package reflection // import "grpc.go4.org/reflection" import ( "bytes" @@ -62,9 +62,9 @@ import ( "github.com/golang/protobuf/proto" dpb "github.com/golang/protobuf/protoc-gen-go/descriptor" - "go4.org/grpc" - "go4.org/grpc/codes" - rpb "go4.org/grpc/reflection/grpc_reflection_v1alpha" + "grpc.go4.org" + "grpc.go4.org/codes" + rpb "grpc.go4.org/reflection/grpc_reflection_v1alpha" ) type serverReflectionServer struct { diff --git a/reflection/serverreflection_test.go b/reflection/serverreflection_test.go index c2adea1..e98b0f9 100644 --- a/reflection/serverreflection_test.go +++ b/reflection/serverreflection_test.go @@ -43,9 +43,9 @@ import ( "context" "github.com/golang/protobuf/proto" dpb "github.com/golang/protobuf/protoc-gen-go/descriptor" - "go4.org/grpc" - rpb "go4.org/grpc/reflection/grpc_reflection_v1alpha" - pb "go4.org/grpc/reflection/grpc_testing" + "grpc.go4.org" + rpb "grpc.go4.org/reflection/grpc_reflection_v1alpha" + pb "grpc.go4.org/reflection/grpc_testing" ) var ( diff --git a/rpc_util.go b/rpc_util.go index 96914bb..98687a3 100644 --- a/rpc_util.go +++ b/rpc_util.go @@ -46,10 +46,10 @@ import ( "context" "github.com/golang/protobuf/proto" - "go4.org/grpc/codes" - "go4.org/grpc/metadata" - "go4.org/grpc/stats" - "go4.org/grpc/transport" + "grpc.go4.org/codes" + "grpc.go4.org/metadata" + "grpc.go4.org/stats" + "grpc.go4.org/transport" ) // Codec defines the interface gRPC uses to encode and decode messages. diff --git a/rpc_util_test.go b/rpc_util_test.go index 80b2b92..af63a17 100644 --- a/rpc_util_test.go +++ b/rpc_util_test.go @@ -42,9 +42,9 @@ import ( "context" "github.com/golang/protobuf/proto" - "go4.org/grpc/codes" - perfpb "go4.org/grpc/test/codec_perf" - "go4.org/grpc/transport" + "grpc.go4.org/codes" + perfpb "grpc.go4.org/test/codec_perf" + "grpc.go4.org/transport" ) func TestSimpleParsing(t *testing.T) { diff --git a/server.go b/server.go index 7ada2e0..e4a42b2 100644 --- a/server.go +++ b/server.go @@ -47,14 +47,14 @@ import ( "time" "context" - "go4.org/grpc/codes" - "go4.org/grpc/credentials" - "go4.org/grpc/grpclog" - "go4.org/grpc/internal" - "go4.org/grpc/metadata" - "go4.org/grpc/stats" - "go4.org/grpc/tap" - "go4.org/grpc/transport" + "grpc.go4.org/codes" + "grpc.go4.org/credentials" + "grpc.go4.org/grpclog" + "grpc.go4.org/internal" + "grpc.go4.org/metadata" + "grpc.go4.org/stats" + "grpc.go4.org/tap" + "grpc.go4.org/transport" "golang.org/x/net/http2" "golang.org/x/net/trace" ) diff --git a/stats/grpc_testing/test.pb.go b/stats/grpc_testing/test.pb.go index 6007f39..5519ef1 100644 --- a/stats/grpc_testing/test.pb.go +++ b/stats/grpc_testing/test.pb.go @@ -20,7 +20,7 @@ import math "math" import ( context "context" - grpc "go4.org/grpc" + grpc "grpc.go4.org" ) // Reference imports to suppress errors if they are not otherwise used. diff --git a/stats/stats.go b/stats/stats.go index 485a238..fd8fcbc 100644 --- a/stats/stats.go +++ b/stats/stats.go @@ -34,7 +34,7 @@ // Package stats is for collecting and reporting various network and RPC stats. // This package is for monitoring purpose only. All fields are read-only. // All APIs are experimental. -package stats // import "go4.org/grpc/stats" +package stats // import "grpc.go4.org/stats" import ( "net" diff --git a/stats/stats_test.go b/stats/stats_test.go index a6191b3..45a9369 100644 --- a/stats/stats_test.go +++ b/stats/stats_test.go @@ -44,10 +44,10 @@ import ( "context" "github.com/golang/protobuf/proto" - "go4.org/grpc" - "go4.org/grpc/metadata" - "go4.org/grpc/stats" - testpb "go4.org/grpc/stats/grpc_testing" + "grpc.go4.org" + "grpc.go4.org/metadata" + "grpc.go4.org/stats" + testpb "grpc.go4.org/stats/grpc_testing" ) func init() { diff --git a/stream.go b/stream.go index a2b2f8b..2db6118 100644 --- a/stream.go +++ b/stream.go @@ -40,10 +40,10 @@ import ( "time" "context" - "go4.org/grpc/codes" - "go4.org/grpc/metadata" - "go4.org/grpc/stats" - "go4.org/grpc/transport" + "grpc.go4.org/codes" + "grpc.go4.org/metadata" + "grpc.go4.org/stats" + "grpc.go4.org/transport" "golang.org/x/net/trace" ) diff --git a/stress/client/main.go b/stress/client/main.go index 6898e34..c7c4348 100644 --- a/stress/client/main.go +++ b/stress/client/main.go @@ -45,13 +45,13 @@ import ( "time" "context" - "go4.org/grpc" - "go4.org/grpc/codes" - "go4.org/grpc/credentials" - "go4.org/grpc/grpclog" - "go4.org/grpc/interop" - testpb "go4.org/grpc/interop/grpc_testing" - metricspb "go4.org/grpc/stress/grpc_testing" + "grpc.go4.org" + "grpc.go4.org/codes" + "grpc.go4.org/credentials" + "grpc.go4.org/grpclog" + "grpc.go4.org/interop" + testpb "grpc.go4.org/interop/grpc_testing" + metricspb "grpc.go4.org/stress/grpc_testing" ) var ( diff --git a/stress/grpc_testing/metrics.pb.go b/stress/grpc_testing/metrics.pb.go index 0bf9f69..10e2dae 100644 --- a/stress/grpc_testing/metrics.pb.go +++ b/stress/grpc_testing/metrics.pb.go @@ -21,7 +21,7 @@ import math "math" import ( context "context" - grpc "go4.org/grpc" + grpc "grpc.go4.org" ) // Reference imports to suppress errors if they are not otherwise used. diff --git a/stress/metrics_client/main.go b/stress/metrics_client/main.go index 2e4d5c5..0178e84 100644 --- a/stress/metrics_client/main.go +++ b/stress/metrics_client/main.go @@ -39,9 +39,9 @@ import ( "io" "context" - "go4.org/grpc" - "go4.org/grpc/grpclog" - metricspb "go4.org/grpc/stress/grpc_testing" + "grpc.go4.org" + "grpc.go4.org/grpclog" + metricspb "grpc.go4.org/stress/grpc_testing" ) var ( diff --git a/temp.go b/temp.go index 498b6b9..0e87086 100644 --- a/temp.go +++ b/temp.go @@ -34,7 +34,7 @@ package grpc -import "go4.org/grpc/naming" +import "grpc.go4.org/naming" // Deprecated: don't use for now. type Balancer struct{} diff --git a/test/end2end_test.go b/test/end2end_test.go index ce05809..c9763d8 100644 --- a/test/end2end_test.go +++ b/test/end2end_test.go @@ -55,17 +55,17 @@ import ( "context" "github.com/golang/protobuf/proto" - "go4.org/grpc" - "go4.org/grpc/codes" - "go4.org/grpc/credentials" - "go4.org/grpc/grpclog" - "go4.org/grpc/health" - healthpb "go4.org/grpc/health/grpc_health_v1" - "go4.org/grpc/internal" - "go4.org/grpc/metadata" - "go4.org/grpc/peer" - "go4.org/grpc/tap" - testpb "go4.org/grpc/test/grpc_testing" + "grpc.go4.org" + "grpc.go4.org/codes" + "grpc.go4.org/credentials" + "grpc.go4.org/grpclog" + "grpc.go4.org/health" + healthpb "grpc.go4.org/health/grpc_health_v1" + "grpc.go4.org/internal" + "grpc.go4.org/metadata" + "grpc.go4.org/peer" + "grpc.go4.org/tap" + testpb "grpc.go4.org/test/grpc_testing" "golang.org/x/net/http2" ) diff --git a/test/grpc_testing/test.pb.go b/test/grpc_testing/test.pb.go index 0bae4f9..089c8a2 100644 --- a/test/grpc_testing/test.pb.go +++ b/test/grpc_testing/test.pb.go @@ -27,7 +27,7 @@ import math "math" import ( context "context" - grpc "go4.org/grpc" + grpc "grpc.go4.org" ) // Reference imports to suppress errors if they are not otherwise used. diff --git a/transport/handler_server.go b/transport/handler_server.go index a47dc26..1121a45 100644 --- a/transport/handler_server.go +++ b/transport/handler_server.go @@ -48,10 +48,10 @@ import ( "time" "context" - "go4.org/grpc/codes" - "go4.org/grpc/credentials" - "go4.org/grpc/metadata" - "go4.org/grpc/peer" + "grpc.go4.org/codes" + "grpc.go4.org/credentials" + "grpc.go4.org/metadata" + "grpc.go4.org/peer" "golang.org/x/net/http2" ) diff --git a/transport/handler_server_test.go b/transport/handler_server_test.go index 79106dc..c2a2e99 100644 --- a/transport/handler_server_test.go +++ b/transport/handler_server_test.go @@ -44,8 +44,8 @@ import ( "time" "context" - "go4.org/grpc/codes" - "go4.org/grpc/metadata" + "grpc.go4.org/codes" + "grpc.go4.org/metadata" ) func TestHandlerTransport_NewServerHandlerTransport(t *testing.T) { diff --git a/transport/http_util.go b/transport/http_util.go index 93b3a3e..45c67df 100644 --- a/transport/http_util.go +++ b/transport/http_util.go @@ -44,9 +44,9 @@ import ( "sync/atomic" "time" - "go4.org/grpc/codes" - "go4.org/grpc/grpclog" - "go4.org/grpc/metadata" + "grpc.go4.org/codes" + "grpc.go4.org/grpclog" + "grpc.go4.org/metadata" "golang.org/x/net/http2" "golang.org/x/net/http2/hpack" ) diff --git a/transport/transport.go b/transport/transport.go index 510810b..7f8d159 100644 --- a/transport/transport.go +++ b/transport/transport.go @@ -35,7 +35,7 @@ Package transport defines and implements message oriented communication channel to complete various transactions (e.g., an RPC). */ -package transport // import "go4.org/grpc/transport" +package transport // import "grpc.go4.org/transport" import ( "bytes" @@ -46,11 +46,11 @@ import ( "sync" "context" - "go4.org/grpc/codes" - "go4.org/grpc/credentials" - "go4.org/grpc/metadata" - "go4.org/grpc/stats" - "go4.org/grpc/tap" + "grpc.go4.org/codes" + "grpc.go4.org/credentials" + "grpc.go4.org/metadata" + "grpc.go4.org/stats" + "grpc.go4.org/tap" ) // recvMsg represents the received msg from the transport. All transport