import "go.chromium.org/luci/logdog/api/endpoints/coordinator/registration/v1"
Package logdog contains Version 1 of the LogDog Coordinator stream registration interface.
The package name here must match the protobuf package name, as the generated files will reside in the same directory.
gen.go pb.discovery.go registrationserver_dec.go service.pb.go util.go
func FileDescriptorSet() *descriptor.FileDescriptorSet
FileDescriptorSet returns a descriptor set for this proto package, which includes all defined services, and all transitive dependencies.
Will not return nil.
Do NOT modify the returned descriptor.
func RegisterRegistrationServer(s prpc.Registrar, srv RegistrationServer)
type DecoratedRegistration struct { // Service is the service to decorate. Service RegistrationServer // Prelude is called for each method before forwarding the call to Service. // If Prelude returns an error, then the call is skipped and the error is // processed via the Postlude (if one is defined), or it is returned directly. Prelude func(c context.Context, methodName string, req proto.Message) (context.Context, error) // Postlude is called for each method after Service has processed the call, or // after the Prelude has returned an error. This takes the the Service's // response proto (which may be nil) and/or any error. The decorated // service will return the response (possibly mutated) and error that Postlude // returns. Postlude func(c context.Context, methodName string, rsp proto.Message, err error) error }
func (s *DecoratedRegistration) RegisterPrefix(c context.Context, req *RegisterPrefixRequest) (rsp *RegisterPrefixResponse, err error)
type RegisterPrefixRequest struct { // The log stream's project. Project string `protobuf:"bytes,1,opt,name=project,proto3" json:"project,omitempty"` // The log stream prefix to register. Prefix string `protobuf:"bytes,2,opt,name=prefix,proto3" json:"prefix,omitempty"` // Optional information about the registering agent. SourceInfo []string `protobuf:"bytes,3,rep,name=source_info,json=sourceInfo,proto3" json:"source_info,omitempty"` // Optional nonce to allow retries of this RPC. ALL CLIENTS SHOULD PROVIDE // THIS. The client should generate the nonce once while preparing the request // message, and then re-use the same nonce for retries of the request. // // The nonce should be 32 bytes of random data. // The nonce must not be reused between different requests (only for retries // of the same request). // // NOTE: This is currently optional, but once all clients have upgraded to // this scheme, it will become mandatory. During the transition if this is // omitted, then NO RETRIES will be allowed for this request, if the server // processes it correctly but the client fails to get the response from the // server. OpNonce []byte `protobuf:"bytes,4,opt,name=op_nonce,json=opNonce,proto3" json:"op_nonce,omitempty"` // The prefix expiration time. If <= 0, the project's default prefix // expiration period will be applied. // // The prefix will be closed by the Coordinator after its expiration period. // Once closed, new stream registration requests will no longer be accepted. // // If supplied, this value should exceed the timeout of the local task, else // some of the task's streams may be dropped due to failing registration. Expiration *duration.Duration `protobuf:"bytes,10,opt,name=expiration,proto3" json:"expiration,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
RegisterPrefixRequest registers a new Prefix with the Coordinator.
func (*RegisterPrefixRequest) Descriptor() ([]byte, []int)
func (m *RegisterPrefixRequest) GetExpiration() *duration.Duration
func (req *RegisterPrefixRequest) GetMessageProject() string
GetMessageProject implements ProjectBoundMessage.
func (m *RegisterPrefixRequest) GetOpNonce() []byte
func (m *RegisterPrefixRequest) GetPrefix() string
func (m *RegisterPrefixRequest) GetProject() string
func (m *RegisterPrefixRequest) GetSourceInfo() []string
func (*RegisterPrefixRequest) ProtoMessage()
func (m *RegisterPrefixRequest) Reset()
func (m *RegisterPrefixRequest) String() string
func (m *RegisterPrefixRequest) XXX_DiscardUnknown()
func (m *RegisterPrefixRequest) XXX_Merge(src proto.Message)
func (m *RegisterPrefixRequest) XXX_Size() int
func (m *RegisterPrefixRequest) XXX_Unmarshal(b []byte) error
type RegisterPrefixResponse struct { // Secret is the prefix's secret. This must be included verbatim in Butler // bundles to assert ownership of this prefix. Secret []byte `protobuf:"bytes,1,opt,name=secret,proto3" json:"secret,omitempty"` // The name of the Pub/Sub topic to publish butlerproto-formatted Butler log // bundles to. LogBundleTopic string `protobuf:"bytes,2,opt,name=log_bundle_topic,json=logBundleTopic,proto3" json:"log_bundle_topic,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
The response message for the RegisterPrefix RPC.
func (*RegisterPrefixResponse) Descriptor() ([]byte, []int)
func (m *RegisterPrefixResponse) GetLogBundleTopic() string
func (m *RegisterPrefixResponse) GetSecret() []byte
func (*RegisterPrefixResponse) ProtoMessage()
func (m *RegisterPrefixResponse) Reset()
func (m *RegisterPrefixResponse) String() string
func (m *RegisterPrefixResponse) XXX_DiscardUnknown()
func (m *RegisterPrefixResponse) XXX_Merge(src proto.Message)
func (m *RegisterPrefixResponse) XXX_Size() int
func (m *RegisterPrefixResponse) XXX_Unmarshal(b []byte) error
type RegistrationClient interface { // RegisterStream allows a Butler instance to register a log stream with the // Coordinator. Upon success, the Coordinator will return registration // information and streaming parameters to the Butler. // // This should be called by a Butler instance to gain the ability to publish // to a prefix space. The caller must have WRITE access to its project's // stream space. If WRITE access is not present, this will fail with the // "PermissionDenied" gRPC code. // // A stream prefix may be registered at most once. Additional registration // requests will fail with the "AlreadyExists" gRPC code. RegisterPrefix(ctx context.Context, in *RegisterPrefixRequest, opts ...grpc.CallOption) (*RegisterPrefixResponse, error) }
RegistrationClient is the client API for Registration service.
For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.
func NewRegistrationClient(cc *grpc.ClientConn) RegistrationClient
func NewRegistrationPRPCClient(client *prpc.Client) RegistrationClient
type RegistrationServer interface { // RegisterStream allows a Butler instance to register a log stream with the // Coordinator. Upon success, the Coordinator will return registration // information and streaming parameters to the Butler. // // This should be called by a Butler instance to gain the ability to publish // to a prefix space. The caller must have WRITE access to its project's // stream space. If WRITE access is not present, this will fail with the // "PermissionDenied" gRPC code. // // A stream prefix may be registered at most once. Additional registration // requests will fail with the "AlreadyExists" gRPC code. RegisterPrefix(context.Context, *RegisterPrefixRequest) (*RegisterPrefixResponse, error) }
RegistrationServer is the server API for Registration service.
Package logdog imports 9 packages (graph) and is imported by 6 packages. Updated 2019-02-22. Refresh now. Tools for package owners.