From 9302d46de916dbbf07c5d958cda47092b2a578f5 Mon Sep 17 00:00:00 2001 From: Yingchun Lai Date: Wed, 25 May 2022 23:54:15 +0800 Subject: [PATCH] use apache/thrift --- go-client/docs/how_to_add_new_interface.md | 2 +- go-client/go.mod | 2 +- go-client/go.sum | 4 ++-- go-client/idl/admin/admin-consts.go | 2 +- go-client/idl/admin/admin.go | 2 +- go-client/idl/base/blob.go | 2 +- go-client/idl/base/error_code.go | 2 +- go-client/idl/base/gpid.go | 2 +- go-client/idl/base/gpid_test.go | 2 +- go-client/idl/base/rpc_address.go | 2 +- go-client/idl/cmd/cmd-consts.go | 2 +- go-client/idl/cmd/cmd.go | 2 +- go-client/idl/radmin/radmin-consts.go | 2 +- go-client/idl/radmin/radmin.go | 2 +- go-client/idl/replication/replication-consts.go | 2 +- go-client/idl/replication/replication.go | 2 +- go-client/idl/rrdb/rrdb-consts.go | 2 +- go-client/idl/rrdb/rrdb.go | 2 +- go-client/session/codec.go | 2 +- go-client/session/session_test.go | 2 +- 20 files changed, 21 insertions(+), 21 deletions(-) diff --git a/go-client/docs/how_to_add_new_interface.md b/go-client/docs/how_to_add_new_interface.md index 713b8b61bc..0fa7b84fb4 100644 --- a/go-client/docs/how_to_add_new_interface.md +++ b/go-client/docs/how_to_add_new_interface.md @@ -40,7 +40,7 @@ you can follow [the building manual of thrift](https://thrift.apache.org/docs/Bu 3. Compile thrift files to generate go code. ```sh -thrift -I idl -out idl --gen go:thrift_import='github.com/pegasus-kv/thrift/lib/go/thrift',package_prefix='github.com/XiaoMi/pegasus-go-client/idl/' idl/admin.thrift +thrift -I idl -out idl --gen go:thrift_import='github.com/apache/thrift/lib/go/thrift',package_prefix='github.com/XiaoMi/pegasus-go-client/idl/' idl/admin.thrift gofmt -w **/*.go goimports -w */**.go ``` diff --git a/go-client/go.mod b/go-client/go.mod index 5e53bceb55..38d50d74a3 100644 --- a/go-client/go.mod +++ b/go-client/go.mod @@ -22,9 +22,9 @@ go 1.13 require ( github.com/BurntSushi/toml v0.3.1 // indirect github.com/agiledragon/gomonkey v2.0.2+incompatible + github.com/apache/thrift v0.13.0 github.com/cenkalti/backoff/v4 v4.1.0 github.com/fortytw2/leaktest v1.3.0 - github.com/pegasus-kv/thrift v0.13.0 github.com/sirupsen/logrus v1.4.2 github.com/stretchr/testify v1.4.0 golang.org/x/net v0.0.0-20191105084925-a882066a44e0 // indirect diff --git a/go-client/go.sum b/go-client/go.sum index 4c1b579a98..82fcf63d26 100644 --- a/go-client/go.sum +++ b/go-client/go.sum @@ -60,8 +60,8 @@ github.com/onsi/ginkgo v1.6.0/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+W github.com/onsi/ginkgo v1.10.1/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE= github.com/onsi/gomega v0.0.0-20170829124025-dcabb60a477c/go.mod h1:C1qb7wdrVGGVU+Z6iS04AVkA3Q65CEZX59MT0QO5uiA= github.com/onsi/gomega v1.7.0/go.mod h1:ex+gbHU/CVuBBDIJjb2X0qEXbFg53c61hWP/1CpauHY= -github.com/pegasus-kv/thrift v0.13.0 h1:4ESwaNoHImfbHa9RUGJiJZ4hrxorihZHk5aarYwY8d4= -github.com/pegasus-kv/thrift v0.13.0/go.mod h1:Gl9NT/WHG6ABm6NsrbfE8LiJN0sAyneCrvB4qN4NPqQ= +github.com/apache/thrift v0.13.0 h1:5hryIiq9gtn+MiLVn0wP37kb/uTeRZgN08WoCsAhIhI= +github.com/apache/thrift v0.13.0/go.mod h1:cp2SuWMxlEZw2r+iP2GNCdIi4C1qmUzdZFSVb+bacwQ= github.com/pmezard/go-difflib v0.0.0-20151028094244-d8ed2627bdf0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4= github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM= github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4= diff --git a/go-client/idl/admin/admin-consts.go b/go-client/idl/admin/admin-consts.go index c681065cdb..37e5b4c51c 100644 --- a/go-client/idl/admin/admin-consts.go +++ b/go-client/idl/admin/admin-consts.go @@ -8,7 +8,7 @@ import ( "context" "fmt" "github.com/XiaoMi/pegasus-go-client/idl/base" - "github.com/pegasus-kv/thrift/lib/go/thrift" + "github.com/apache/thrift/lib/go/thrift" "reflect" ) diff --git a/go-client/idl/admin/admin.go b/go-client/idl/admin/admin.go index 4696827e49..4fa011333c 100644 --- a/go-client/idl/admin/admin.go +++ b/go-client/idl/admin/admin.go @@ -10,7 +10,7 @@ import ( "errors" "fmt" "github.com/XiaoMi/pegasus-go-client/idl/base" - "github.com/pegasus-kv/thrift/lib/go/thrift" + "github.com/apache/thrift/lib/go/thrift" "reflect" ) diff --git a/go-client/idl/base/blob.go b/go-client/idl/base/blob.go index 2f659ccc71..e4d0521913 100644 --- a/go-client/idl/base/blob.go +++ b/go-client/idl/base/blob.go @@ -22,7 +22,7 @@ package base import ( "fmt" - "github.com/pegasus-kv/thrift/lib/go/thrift" + "github.com/apache/thrift/lib/go/thrift" ) type Blob struct { diff --git a/go-client/idl/base/error_code.go b/go-client/idl/base/error_code.go index 624dc7f56b..f1d0e1ea05 100644 --- a/go-client/idl/base/error_code.go +++ b/go-client/idl/base/error_code.go @@ -22,7 +22,7 @@ package base import ( "fmt" - "github.com/pegasus-kv/thrift/lib/go/thrift" + "github.com/apache/thrift/lib/go/thrift" ) /// Primitive for Pegasus thrift framework. diff --git a/go-client/idl/base/gpid.go b/go-client/idl/base/gpid.go index 898334f908..6c06520c5a 100644 --- a/go-client/idl/base/gpid.go +++ b/go-client/idl/base/gpid.go @@ -22,7 +22,7 @@ package base import ( "fmt" - "github.com/pegasus-kv/thrift/lib/go/thrift" + "github.com/apache/thrift/lib/go/thrift" ) type Gpid struct { diff --git a/go-client/idl/base/gpid_test.go b/go-client/idl/base/gpid_test.go index 3d6349d9eb..d8e0511659 100644 --- a/go-client/idl/base/gpid_test.go +++ b/go-client/idl/base/gpid_test.go @@ -4,7 +4,7 @@ import ( "testing" "github.com/XiaoMi/pegasus-go-client/pegalog" - "github.com/pegasus-kv/thrift/lib/go/thrift" + "github.com/apache/thrift/lib/go/thrift" "github.com/stretchr/testify/assert" ) diff --git a/go-client/idl/base/rpc_address.go b/go-client/idl/base/rpc_address.go index 3f9d6f3f8f..9121cd5cde 100644 --- a/go-client/idl/base/rpc_address.go +++ b/go-client/idl/base/rpc_address.go @@ -24,7 +24,7 @@ import ( "fmt" "net" - "github.com/pegasus-kv/thrift/lib/go/thrift" + "github.com/apache/thrift/lib/go/thrift" ) type RPCAddress struct { diff --git a/go-client/idl/cmd/cmd-consts.go b/go-client/idl/cmd/cmd-consts.go index 5fdc03cd61..431604c8bc 100644 --- a/go-client/idl/cmd/cmd-consts.go +++ b/go-client/idl/cmd/cmd-consts.go @@ -9,7 +9,7 @@ import ( "fmt" "reflect" - "github.com/pegasus-kv/thrift/lib/go/thrift" + "github.com/apache/thrift/lib/go/thrift" ) // (needed to ensure safety because of naive import list construction.) diff --git a/go-client/idl/cmd/cmd.go b/go-client/idl/cmd/cmd.go index 2e09a2d3f0..4f4f821288 100644 --- a/go-client/idl/cmd/cmd.go +++ b/go-client/idl/cmd/cmd.go @@ -9,7 +9,7 @@ import ( "fmt" "reflect" - "github.com/pegasus-kv/thrift/lib/go/thrift" + "github.com/apache/thrift/lib/go/thrift" ) // (needed to ensure safety because of naive import list construction.) diff --git a/go-client/idl/radmin/radmin-consts.go b/go-client/idl/radmin/radmin-consts.go index 159af7d892..6dfec694fe 100644 --- a/go-client/idl/radmin/radmin-consts.go +++ b/go-client/idl/radmin/radmin-consts.go @@ -8,7 +8,7 @@ import ( "context" "fmt" "github.com/XiaoMi/pegasus-go-client/idl/base" - "github.com/pegasus-kv/thrift/lib/go/thrift" + "github.com/apache/thrift/lib/go/thrift" "reflect" ) diff --git a/go-client/idl/radmin/radmin.go b/go-client/idl/radmin/radmin.go index 848de86ae4..98cf27edd7 100644 --- a/go-client/idl/radmin/radmin.go +++ b/go-client/idl/radmin/radmin.go @@ -8,7 +8,7 @@ import ( "context" "fmt" "github.com/XiaoMi/pegasus-go-client/idl/base" - "github.com/pegasus-kv/thrift/lib/go/thrift" + "github.com/apache/thrift/lib/go/thrift" "reflect" ) diff --git a/go-client/idl/replication/replication-consts.go b/go-client/idl/replication/replication-consts.go index cebd74e9fd..c8a6aa4d11 100644 --- a/go-client/idl/replication/replication-consts.go +++ b/go-client/idl/replication/replication-consts.go @@ -8,7 +8,7 @@ import ( "context" "fmt" "github.com/XiaoMi/pegasus-go-client/idl/base" - "github.com/pegasus-kv/thrift/lib/go/thrift" + "github.com/apache/thrift/lib/go/thrift" "reflect" ) diff --git a/go-client/idl/replication/replication.go b/go-client/idl/replication/replication.go index 572cf33596..7e6fe90315 100644 --- a/go-client/idl/replication/replication.go +++ b/go-client/idl/replication/replication.go @@ -8,7 +8,7 @@ import ( "context" "fmt" "github.com/XiaoMi/pegasus-go-client/idl/base" - "github.com/pegasus-kv/thrift/lib/go/thrift" + "github.com/apache/thrift/lib/go/thrift" "reflect" ) diff --git a/go-client/idl/rrdb/rrdb-consts.go b/go-client/idl/rrdb/rrdb-consts.go index 7e08a4ea46..6092b0739d 100644 --- a/go-client/idl/rrdb/rrdb-consts.go +++ b/go-client/idl/rrdb/rrdb-consts.go @@ -9,7 +9,7 @@ import ( "fmt" "github.com/XiaoMi/pegasus-go-client/idl/base" "github.com/XiaoMi/pegasus-go-client/idl/replication" - "github.com/pegasus-kv/thrift/lib/go/thrift" + "github.com/apache/thrift/lib/go/thrift" "reflect" ) diff --git a/go-client/idl/rrdb/rrdb.go b/go-client/idl/rrdb/rrdb.go index 5b71c45b65..424645149d 100644 --- a/go-client/idl/rrdb/rrdb.go +++ b/go-client/idl/rrdb/rrdb.go @@ -11,7 +11,7 @@ import ( "fmt" "github.com/XiaoMi/pegasus-go-client/idl/base" "github.com/XiaoMi/pegasus-go-client/idl/replication" - "github.com/pegasus-kv/thrift/lib/go/thrift" + "github.com/apache/thrift/lib/go/thrift" "reflect" ) diff --git a/go-client/session/codec.go b/go-client/session/codec.go index 5caf0e9e74..ca3e32d37a 100644 --- a/go-client/session/codec.go +++ b/go-client/session/codec.go @@ -34,7 +34,7 @@ import ( "github.com/XiaoMi/pegasus-go-client/idl/rrdb" "github.com/XiaoMi/pegasus-go-client/pegalog" "github.com/XiaoMi/pegasus-go-client/rpc" - "github.com/pegasus-kv/thrift/lib/go/thrift" + "github.com/apache/thrift/lib/go/thrift" ) type PegasusCodec struct { diff --git a/go-client/session/session_test.go b/go-client/session/session_test.go index 1995026578..1de1a56c65 100644 --- a/go-client/session/session_test.go +++ b/go-client/session/session_test.go @@ -34,7 +34,7 @@ import ( "github.com/XiaoMi/pegasus-go-client/pegalog" "github.com/XiaoMi/pegasus-go-client/rpc" "github.com/fortytw2/leaktest" - "github.com/pegasus-kv/thrift/lib/go/thrift" + "github.com/apache/thrift/lib/go/thrift" "github.com/stretchr/testify/assert" )