buildsv1

package
v0.0.0-...-87fe518 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 30, 2023 License: MIT Imports: 17 Imported by: 0

Documentation

Overview

Package buildsv1 is a reverse proxy.

It translates gRPC into RESTful JSON APIs.

Index

Constants

View Source
const (
	BuildService_AddBuild_FullMethodName   = "/builds.v1.BuildService/AddBuild"
	BuildService_ListBuilds_FullMethodName = "/builds.v1.BuildService/ListBuilds"
)

Variables

View Source
var BuildService_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "builds.v1.BuildService",
	HandlerType: (*BuildServiceServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "AddBuild",
			Handler:    _BuildService_AddBuild_Handler,
		},
	},
	Streams: []grpc.StreamDesc{
		{
			StreamName:    "ListBuilds",
			Handler:       _BuildService_ListBuilds_Handler,
			ServerStreams: true,
		},
	},
	Metadata: "builds/v1/builds.proto",
}

BuildService_ServiceDesc is the grpc.ServiceDesc for BuildService service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)

View Source
var File_builds_v1_builds_proto protoreflect.FileDescriptor

Functions

func RegisterBuildServiceHandler

func RegisterBuildServiceHandler(ctx context.Context, mux *runtime.ServeMux, conn *grpc.ClientConn) error

RegisterBuildServiceHandler registers the http handlers for service BuildService to "mux". The handlers forward requests to the grpc endpoint over "conn".

func RegisterBuildServiceHandlerClient

func RegisterBuildServiceHandlerClient(ctx context.Context, mux *runtime.ServeMux, client BuildServiceClient) error

RegisterBuildServiceHandlerClient registers the http handlers for service BuildService to "mux". The handlers forward requests to the grpc endpoint over the given implementation of "BuildServiceClient". Note: the gRPC framework executes interceptors within the gRPC handler. If the passed in "BuildServiceClient" doesn't go through the normal gRPC flow (creating a gRPC client etc.) then it will be up to the passed in "BuildServiceClient" to call the correct interceptors.

func RegisterBuildServiceHandlerFromEndpoint

func RegisterBuildServiceHandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, opts []grpc.DialOption) (err error)

RegisterBuildServiceHandlerFromEndpoint is same as RegisterBuildServiceHandler but automatically dials to "endpoint" and closes the connection when "ctx" gets done.

func RegisterBuildServiceHandlerServer

func RegisterBuildServiceHandlerServer(ctx context.Context, mux *runtime.ServeMux, server BuildServiceServer) error

RegisterBuildServiceHandlerServer registers the http handlers for service BuildService to "mux". UnaryRPC :call BuildServiceServer directly. StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906. Note that using this registration option will cause many gRPC library features to stop working. Consider using RegisterBuildServiceHandlerFromEndpoint instead.

func RegisterBuildServiceServer

func RegisterBuildServiceServer(s grpc.ServiceRegistrar, srv BuildServiceServer)

Types

type AddBuildRequest

type AddBuildRequest struct {
	Label string `protobuf:"bytes,1,opt,name=label,proto3" json:"label,omitempty"`
	// contains filtered or unexported fields
}

func (*AddBuildRequest) Descriptor deprecated

func (*AddBuildRequest) Descriptor() ([]byte, []int)

Deprecated: Use AddBuildRequest.ProtoReflect.Descriptor instead.

func (*AddBuildRequest) GetLabel

func (x *AddBuildRequest) GetLabel() string

func (*AddBuildRequest) ProtoMessage

func (*AddBuildRequest) ProtoMessage()

func (*AddBuildRequest) ProtoReflect

func (x *AddBuildRequest) ProtoReflect() protoreflect.Message

func (*AddBuildRequest) Reset

func (x *AddBuildRequest) Reset()

func (*AddBuildRequest) String

func (x *AddBuildRequest) String() string

type AddBuildResponse

type AddBuildResponse struct {
	Build *Build `protobuf:"bytes,1,opt,name=build,proto3" json:"build,omitempty"`
	// contains filtered or unexported fields
}

func (*AddBuildResponse) Descriptor deprecated

func (*AddBuildResponse) Descriptor() ([]byte, []int)

Deprecated: Use AddBuildResponse.ProtoReflect.Descriptor instead.

func (*AddBuildResponse) GetBuild

func (x *AddBuildResponse) GetBuild() *Build

func (*AddBuildResponse) ProtoMessage

func (*AddBuildResponse) ProtoMessage()

func (*AddBuildResponse) ProtoReflect

func (x *AddBuildResponse) ProtoReflect() protoreflect.Message

func (*AddBuildResponse) Reset

func (x *AddBuildResponse) Reset()

func (*AddBuildResponse) String

func (x *AddBuildResponse) String() string

type Build

type Build struct {
	Id    string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
	Label string `protobuf:"bytes,2,opt,name=label,proto3" json:"label,omitempty"`
	// contains filtered or unexported fields
}

func (*Build) Descriptor deprecated

func (*Build) Descriptor() ([]byte, []int)

Deprecated: Use Build.ProtoReflect.Descriptor instead.

func (*Build) GetId

func (x *Build) GetId() string

func (*Build) GetLabel

func (x *Build) GetLabel() string

func (*Build) ProtoMessage

func (*Build) ProtoMessage()

func (*Build) ProtoReflect

func (x *Build) ProtoReflect() protoreflect.Message

func (*Build) Reset

func (x *Build) Reset()

func (*Build) String

func (x *Build) String() string

type BuildServiceClient

type BuildServiceClient interface {
	AddBuild(ctx context.Context, in *AddBuildRequest, opts ...grpc.CallOption) (*AddBuildResponse, error)
	ListBuilds(ctx context.Context, in *ListBuildsRequest, opts ...grpc.CallOption) (BuildService_ListBuildsClient, error)
}

BuildServiceClient is the client API for BuildService service.

For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.

type BuildServiceServer

type BuildServiceServer interface {
	AddBuild(context.Context, *AddBuildRequest) (*AddBuildResponse, error)
	ListBuilds(*ListBuildsRequest, BuildService_ListBuildsServer) error
}

BuildServiceServer is the server API for BuildService service. All implementations should embed UnimplementedBuildServiceServer for forward compatibility

type BuildService_ListBuildsClient

type BuildService_ListBuildsClient interface {
	Recv() (*ListBuildsResponse, error)
	grpc.ClientStream
}

type BuildService_ListBuildsServer

type BuildService_ListBuildsServer interface {
	Send(*ListBuildsResponse) error
	grpc.ServerStream
}

type ListBuildsRequest

type ListBuildsRequest struct {
	// contains filtered or unexported fields
}

func (*ListBuildsRequest) Descriptor deprecated

func (*ListBuildsRequest) Descriptor() ([]byte, []int)

Deprecated: Use ListBuildsRequest.ProtoReflect.Descriptor instead.

func (*ListBuildsRequest) ProtoMessage

func (*ListBuildsRequest) ProtoMessage()

func (*ListBuildsRequest) ProtoReflect

func (x *ListBuildsRequest) ProtoReflect() protoreflect.Message

func (*ListBuildsRequest) Reset

func (x *ListBuildsRequest) Reset()

func (*ListBuildsRequest) String

func (x *ListBuildsRequest) String() string

type ListBuildsResponse

type ListBuildsResponse struct {
	Build *Build `protobuf:"bytes,1,opt,name=build,proto3" json:"build,omitempty"`
	// contains filtered or unexported fields
}

func (*ListBuildsResponse) Descriptor deprecated

func (*ListBuildsResponse) Descriptor() ([]byte, []int)

Deprecated: Use ListBuildsResponse.ProtoReflect.Descriptor instead.

func (*ListBuildsResponse) GetBuild

func (x *ListBuildsResponse) GetBuild() *Build

func (*ListBuildsResponse) ProtoMessage

func (*ListBuildsResponse) ProtoMessage()

func (*ListBuildsResponse) ProtoReflect

func (x *ListBuildsResponse) ProtoReflect() protoreflect.Message

func (*ListBuildsResponse) Reset

func (x *ListBuildsResponse) Reset()

func (*ListBuildsResponse) String

func (x *ListBuildsResponse) String() string

type UnimplementedBuildServiceServer

type UnimplementedBuildServiceServer struct {
}

UnimplementedBuildServiceServer should be embedded to have forward compatible implementations.

func (UnimplementedBuildServiceServer) AddBuild

func (UnimplementedBuildServiceServer) ListBuilds

type UnsafeBuildServiceServer

type UnsafeBuildServiceServer interface {
	// contains filtered or unexported methods
}

UnsafeBuildServiceServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to BuildServiceServer will result in compilation errors.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL