From a399590204862e91894478c9c6beec09fe550bdc Mon Sep 17 00:00:00 2001 From: Angira Kekteeva Date: Tue, 18 May 2021 14:10:08 +0300 Subject: [PATCH] Replace s3-gate by s3-gw Signed-off-by: Angira Kekteeva --- api/handler/api.go | 4 ++-- api/handler/copy.go | 4 ++-- api/handler/delete.go | 2 +- api/handler/get.go | 4 ++-- api/handler/head.go | 4 ++-- api/handler/info.go | 2 +- api/handler/list.go | 4 ++-- api/handler/not-support.go | 2 +- api/handler/put.go | 4 ++-- api/handler/unimplemented.go | 2 +- api/layer/container.go | 2 +- api/layer/layer.go | 2 +- api/layer/object.go | 2 +- api/metrics/collector.go | 2 +- api/reqinfo.go | 2 +- api/response.go | 4 ++-- api/router.go | 4 ++-- api/user-auth.go | 2 +- cmd/gate/app-settings.go | 2 +- cmd/gate/app.go | 8 ++++---- go.mod | 2 +- misc/build.go | 2 +- 22 files changed, 33 insertions(+), 33 deletions(-) diff --git a/api/handler/api.go b/api/handler/api.go index 293a27c8..f6eb02ed 100644 --- a/api/handler/api.go +++ b/api/handler/api.go @@ -3,8 +3,8 @@ package handler import ( "errors" - "github.com/nspcc-dev/neofs-s3-gate/api" - "github.com/nspcc-dev/neofs-s3-gate/api/layer" + "github.com/nspcc-dev/neofs-s3-gw/api" + "github.com/nspcc-dev/neofs-s3-gw/api/layer" "go.uber.org/zap" ) diff --git a/api/handler/copy.go b/api/handler/copy.go index 65746596..3468159a 100644 --- a/api/handler/copy.go +++ b/api/handler/copy.go @@ -7,8 +7,8 @@ import ( "time" "github.com/gorilla/mux" - "github.com/nspcc-dev/neofs-s3-gate/api" - "github.com/nspcc-dev/neofs-s3-gate/api/layer" + "github.com/nspcc-dev/neofs-s3-gw/api" + "github.com/nspcc-dev/neofs-s3-gw/api/layer" "go.uber.org/zap" ) diff --git a/api/handler/delete.go b/api/handler/delete.go index 72e2da22..3b59d47d 100644 --- a/api/handler/delete.go +++ b/api/handler/delete.go @@ -5,7 +5,7 @@ import ( "net/http" "github.com/gorilla/mux" - "github.com/nspcc-dev/neofs-s3-gate/api" + "github.com/nspcc-dev/neofs-s3-gw/api" "go.uber.org/zap" "google.golang.org/grpc/status" ) diff --git a/api/handler/get.go b/api/handler/get.go index 7a2adc67..c602a901 100644 --- a/api/handler/get.go +++ b/api/handler/get.go @@ -8,8 +8,8 @@ import ( "sync" "github.com/gorilla/mux" - "github.com/nspcc-dev/neofs-s3-gate/api" - "github.com/nspcc-dev/neofs-s3-gate/api/layer" + "github.com/nspcc-dev/neofs-s3-gw/api" + "github.com/nspcc-dev/neofs-s3-gw/api/layer" "go.uber.org/zap" ) diff --git a/api/handler/head.go b/api/handler/head.go index c805ad97..0b335dad 100644 --- a/api/handler/head.go +++ b/api/handler/head.go @@ -5,8 +5,8 @@ import ( "net/http" "github.com/gorilla/mux" - "github.com/nspcc-dev/neofs-s3-gate/api" - "github.com/nspcc-dev/neofs-s3-gate/api/layer" + "github.com/nspcc-dev/neofs-s3-gw/api" + "github.com/nspcc-dev/neofs-s3-gw/api/layer" "go.uber.org/zap" "google.golang.org/grpc/codes" "google.golang.org/grpc/status" diff --git a/api/handler/info.go b/api/handler/info.go index cf7357e5..ee12a066 100644 --- a/api/handler/info.go +++ b/api/handler/info.go @@ -4,7 +4,7 @@ import ( "net/http" "github.com/gorilla/mux" - "github.com/nspcc-dev/neofs-s3-gate/api" + "github.com/nspcc-dev/neofs-s3-gw/api" "go.uber.org/zap" ) diff --git a/api/handler/list.go b/api/handler/list.go index 452f0f7d..a55d68ce 100644 --- a/api/handler/list.go +++ b/api/handler/list.go @@ -7,8 +7,8 @@ import ( "time" "github.com/nspcc-dev/neofs-api-go/pkg/owner" - "github.com/nspcc-dev/neofs-s3-gate/api" - "github.com/nspcc-dev/neofs-s3-gate/api/layer" + "github.com/nspcc-dev/neofs-s3-gw/api" + "github.com/nspcc-dev/neofs-s3-gw/api/layer" "go.uber.org/zap" ) diff --git a/api/handler/not-support.go b/api/handler/not-support.go index f5795eb0..8f484b8a 100644 --- a/api/handler/not-support.go +++ b/api/handler/not-support.go @@ -4,7 +4,7 @@ import ( "net/http" "github.com/gorilla/mux" - "github.com/nspcc-dev/neofs-s3-gate/api" + "github.com/nspcc-dev/neofs-s3-gw/api" ) func (h *handler) DeleteBucketHandler(w http.ResponseWriter, r *http.Request) { diff --git a/api/handler/put.go b/api/handler/put.go index c65dcee4..644d7fbf 100644 --- a/api/handler/put.go +++ b/api/handler/put.go @@ -4,8 +4,8 @@ import ( "net/http" "github.com/gorilla/mux" - "github.com/nspcc-dev/neofs-s3-gate/api" - "github.com/nspcc-dev/neofs-s3-gate/api/layer" + "github.com/nspcc-dev/neofs-s3-gw/api" + "github.com/nspcc-dev/neofs-s3-gw/api/layer" "go.uber.org/zap" ) diff --git a/api/handler/unimplemented.go b/api/handler/unimplemented.go index 6cda4c6a..716eb34e 100644 --- a/api/handler/unimplemented.go +++ b/api/handler/unimplemented.go @@ -4,7 +4,7 @@ import ( "net/http" "github.com/gorilla/mux" - "github.com/nspcc-dev/neofs-s3-gate/api" + "github.com/nspcc-dev/neofs-s3-gw/api" ) func (h *handler) CopyObjectPartHandler(w http.ResponseWriter, r *http.Request) { diff --git a/api/layer/container.go b/api/layer/container.go index 5138a4d0..439d91dc 100644 --- a/api/layer/container.go +++ b/api/layer/container.go @@ -7,7 +7,7 @@ import ( "github.com/nspcc-dev/neofs-api-go/pkg/container" "github.com/nspcc-dev/neofs-api-go/pkg/owner" - "github.com/nspcc-dev/neofs-s3-gate/api" + "github.com/nspcc-dev/neofs-s3-gw/api" "go.uber.org/zap" ) diff --git a/api/layer/layer.go b/api/layer/layer.go index 46b1144e..4feafded 100644 --- a/api/layer/layer.go +++ b/api/layer/layer.go @@ -12,7 +12,7 @@ import ( "github.com/nspcc-dev/neofs-api-go/pkg/container" "github.com/nspcc-dev/neofs-api-go/pkg/object" "github.com/nspcc-dev/neofs-api-go/pkg/owner" - "github.com/nspcc-dev/neofs-s3-gate/api" + "github.com/nspcc-dev/neofs-s3-gw/api" "github.com/pkg/errors" "go.uber.org/zap" "google.golang.org/grpc/codes" diff --git a/api/layer/object.go b/api/layer/object.go index 406041f7..33713309 100644 --- a/api/layer/object.go +++ b/api/layer/object.go @@ -10,7 +10,7 @@ import ( sdk "github.com/nspcc-dev/cdn-sdk" "github.com/nspcc-dev/neofs-api-go/pkg/container" "github.com/nspcc-dev/neofs-api-go/pkg/object" - "github.com/nspcc-dev/neofs-s3-gate/api" + "github.com/nspcc-dev/neofs-s3-gw/api" "github.com/pkg/errors" "google.golang.org/grpc/codes" "google.golang.org/grpc/status" diff --git a/api/metrics/collector.go b/api/metrics/collector.go index 9064657c..c6f89c32 100644 --- a/api/metrics/collector.go +++ b/api/metrics/collector.go @@ -1,7 +1,7 @@ package metrics import ( - "github.com/nspcc-dev/neofs-s3-gate/misc" + "github.com/nspcc-dev/neofs-s3-gw/misc" "github.com/prometheus/client_golang/prometheus" ) diff --git a/api/reqinfo.go b/api/reqinfo.go index c6594e1f..65d05cc3 100644 --- a/api/reqinfo.go +++ b/api/reqinfo.go @@ -44,7 +44,7 @@ type ( // Key used for Get/SetReqInfo. type contextKeyType string -const ctxRequestInfo = contextKeyType("NeoFS-S3-Gate") +const ctxRequestInfo = contextKeyType("NeoFS-S3-GW") var ( // De-facto standard header keys. diff --git a/api/response.go b/api/response.go index 33b34109..da4b05f1 100644 --- a/api/response.go +++ b/api/response.go @@ -10,7 +10,7 @@ import ( "strconv" "github.com/google/uuid" - "github.com/nspcc-dev/neofs-s3-gate/misc" + "github.com/nspcc-dev/neofs-s3-gw/misc" ) type ( @@ -153,7 +153,7 @@ func errorResponseHandler(w http.ResponseWriter, r *http.Request) { // Write http common headers. func setCommonHeaders(w http.ResponseWriter) { - w.Header().Set(hdrServerInfo, "NeoFS-S3-Gate/"+misc.Version) + w.Header().Set(hdrServerInfo, "NeoFS-S3-GW/"+misc.Version) w.Header().Set(hdrAcceptRanges, "bytes") // Remove sensitive information diff --git a/api/router.go b/api/router.go index 8ae7b65b..ccee6e7f 100644 --- a/api/router.go +++ b/api/router.go @@ -7,8 +7,8 @@ import ( "github.com/google/uuid" "github.com/gorilla/mux" - "github.com/nspcc-dev/neofs-s3-gate/api/auth" - "github.com/nspcc-dev/neofs-s3-gate/api/metrics" + "github.com/nspcc-dev/neofs-s3-gw/api/auth" + "github.com/nspcc-dev/neofs-s3-gw/api/metrics" "go.uber.org/zap" "google.golang.org/grpc/metadata" ) diff --git a/api/user-auth.go b/api/user-auth.go index 4baaffb6..4e00112a 100644 --- a/api/user-auth.go +++ b/api/user-auth.go @@ -5,7 +5,7 @@ import ( "github.com/gorilla/mux" sdk "github.com/nspcc-dev/cdn-sdk" - "github.com/nspcc-dev/neofs-s3-gate/api/auth" + "github.com/nspcc-dev/neofs-s3-gw/api/auth" "go.uber.org/zap" ) diff --git a/cmd/gate/app-settings.go b/cmd/gate/app-settings.go index 5c9b705e..87f9538f 100644 --- a/cmd/gate/app-settings.go +++ b/cmd/gate/app-settings.go @@ -9,7 +9,7 @@ import ( "strings" "time" - "github.com/nspcc-dev/neofs-s3-gate/misc" + "github.com/nspcc-dev/neofs-s3-gw/misc" "github.com/spf13/pflag" "github.com/spf13/viper" "go.uber.org/zap" diff --git a/cmd/gate/app.go b/cmd/gate/app.go index 474bd4ad..2b9c5fc9 100644 --- a/cmd/gate/app.go +++ b/cmd/gate/app.go @@ -11,10 +11,10 @@ import ( "github.com/nspcc-dev/cdn-sdk/creds/hcs" "github.com/nspcc-dev/cdn-sdk/creds/neofs" "github.com/nspcc-dev/cdn-sdk/pool" - "github.com/nspcc-dev/neofs-s3-gate/api" - "github.com/nspcc-dev/neofs-s3-gate/api/auth" - "github.com/nspcc-dev/neofs-s3-gate/api/handler" - "github.com/nspcc-dev/neofs-s3-gate/api/layer" + "github.com/nspcc-dev/neofs-s3-gw/api" + "github.com/nspcc-dev/neofs-s3-gw/api/auth" + "github.com/nspcc-dev/neofs-s3-gw/api/handler" + "github.com/nspcc-dev/neofs-s3-gw/api/layer" "github.com/spf13/viper" "go.uber.org/zap" "google.golang.org/grpc" diff --git a/go.mod b/go.mod index 79111359..82ab100b 100644 --- a/go.mod +++ b/go.mod @@ -1,4 +1,4 @@ -module github.com/nspcc-dev/neofs-s3-gate +module github.com/nspcc-dev/neofs-s3-gw go 1.14 diff --git a/misc/build.go b/misc/build.go index c954d355..a66717c8 100644 --- a/misc/build.go +++ b/misc/build.go @@ -2,7 +2,7 @@ package misc const ( // ApplicationName is gateway name. - ApplicationName = "neofs-s3-gate" + ApplicationName = "neofs-s3-gw" // Prefix is configuration environment variables prefix. Prefix = "S3_GW"