diff --git a/tpl/server.go b/tpl/server.go index e3c77de..988ed7c 100644 --- a/tpl/server.go +++ b/tpl/server.go @@ -5,18 +5,12 @@ var NewFile = ` package server import ( - "context" - "net/http" - "os" - "strings" - "time" {import} - "git.apinb.com/bsm-sdk/core/vars" - "google.golang.org/grpc" - "google.golang.org/grpc/credentials/insecure" - "google.golang.org/grpc/reflection" - "google.golang.org/protobuf/proto" + "context" + gwRuntime "github.com/grpc-ecosystem/grpc-gateway/v2/runtime" + "google.golang.org/grpc" + "google.golang.org/grpc/reflection" ) type Server struct { @@ -30,7 +24,6 @@ func New(addr string) *Server { srv := &Server{ Ctx: context.Background(), Grpc: grpc.NewServer(), - Mux: gwRuntime.NewServeMux(gwRuntime.WithForwardResponseRewriter(responseEnvelope)), grpcConns: make(map[string]*grpc.ClientConn), }