| Index: common/api/logdog_coordinator/registration/v1/registrationserver_dec.go
|
| diff --git a/common/api/logdog_coordinator/admin/v1/adminserver_dec.go b/common/api/logdog_coordinator/registration/v1/registrationserver_dec.go
|
| similarity index 61%
|
| copy from common/api/logdog_coordinator/admin/v1/adminserver_dec.go
|
| copy to common/api/logdog_coordinator/registration/v1/registrationserver_dec.go
|
| index f4d13b46b9c3940ddfd6a2c0e93601162e4e839f..b6c9d9f092945028c0b539138825bebd2db5303b 100644
|
| --- a/common/api/logdog_coordinator/admin/v1/adminserver_dec.go
|
| +++ b/common/api/logdog_coordinator/registration/v1/registrationserver_dec.go
|
| @@ -5,22 +5,20 @@ package logdog
|
| import (
|
| proto "github.com/golang/protobuf/proto"
|
| context "golang.org/x/net/context"
|
| -
|
| - google_protobuf "github.com/luci/luci-go/common/proto/google"
|
| )
|
|
|
| -type DecoratedAdmin struct {
|
| +type DecoratedRegistration struct {
|
| // Service is the service to decorate.
|
| - Service AdminServer
|
| + Service RegistrationServer
|
| // Prelude is called in each method before forwarding the call to Service.
|
| // If Prelude returns an error, it is returned without forwarding the call.
|
| Prelude func(c context.Context, methodName string, req proto.Message) (context.Context, error)
|
| }
|
|
|
| -func (s *DecoratedAdmin) SetConfig(c context.Context, req *SetConfigRequest) (*google_protobuf.Empty, error) {
|
| - c, err := s.Prelude(c, "SetConfig", req)
|
| +func (s *DecoratedRegistration) RegisterPrefix(c context.Context, req *RegisterPrefixRequest) (*RegisterPrefixResponse, error) {
|
| + c, err := s.Prelude(c, "RegisterPrefix", req)
|
| if err != nil {
|
| return nil, err
|
| }
|
| - return s.Service.SetConfig(c, req)
|
| + return s.Service.RegisterPrefix(c, req)
|
| }
|
|
|