milopb

package
v0.0.0-...-8be5f70 Latest Latest
Warning

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

Go to latest
Published: Nov 28, 2024 License: Apache-2.0 Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var File_go_chromium_org_luci_milo_proto_v1_rpc_proto protoreflect.FileDescriptor

Functions

func FileDescriptorSet

func FileDescriptorSet() *descriptorpb.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 RegisterMiloInternalServer

func RegisterMiloInternalServer(s prpc.Registrar, srv MiloInternalServer)

Types

type BatchCheckPermissionsRequest

type BatchCheckPermissionsRequest struct {

	// Required. The realm to check the permissions against.
	Realm string `protobuf:"bytes,1,opt,name=realm,proto3" json:"realm,omitempty"`
	// String representation of the permissions.
	//
	// Permissions must have the following format: `<service>.<subject>.<verb>`.
	//
	// N.B. Only permissions registered [here][1] are allowed.
	//
	// [1]: https://source.corp.google.com/h/github/googlesource/codesearch/+/master:luci/luci-go/milo/rpc/batch_check_permissions.go;l=26;drc=e952557609eade6037c66866ebc00c506d8800a8
	Permissions []string `protobuf:"bytes,2,rep,name=permissions,proto3" json:"permissions,omitempty"`
	// contains filtered or unexported fields
}

A request message for `BatchCheckPermissions` RPC.

func (*BatchCheckPermissionsRequest) Descriptor deprecated

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

Deprecated: Use BatchCheckPermissionsRequest.ProtoReflect.Descriptor instead.

func (*BatchCheckPermissionsRequest) GetPermissions

func (x *BatchCheckPermissionsRequest) GetPermissions() []string

func (*BatchCheckPermissionsRequest) GetRealm

func (x *BatchCheckPermissionsRequest) GetRealm() string

func (*BatchCheckPermissionsRequest) ProtoMessage

func (*BatchCheckPermissionsRequest) ProtoMessage()

func (*BatchCheckPermissionsRequest) ProtoReflect

func (*BatchCheckPermissionsRequest) Reset

func (x *BatchCheckPermissionsRequest) Reset()

func (*BatchCheckPermissionsRequest) String

type BatchCheckPermissionsResponse

type BatchCheckPermissionsResponse struct {

	// A map of permission check results.
	//
	// The key is the permission name and the value is whether the user has the
	// permission.
	Results map[string]bool `` /* 156-byte string literal not displayed */
	// contains filtered or unexported fields
}

A response message for `BatchCheckPermissions` RPC.

func (*BatchCheckPermissionsResponse) Descriptor deprecated

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

Deprecated: Use BatchCheckPermissionsResponse.ProtoReflect.Descriptor instead.

func (*BatchCheckPermissionsResponse) GetResults

func (x *BatchCheckPermissionsResponse) GetResults() map[string]bool

func (*BatchCheckPermissionsResponse) ProtoMessage

func (*BatchCheckPermissionsResponse) ProtoMessage()

func (*BatchCheckPermissionsResponse) ProtoReflect

func (*BatchCheckPermissionsResponse) Reset

func (x *BatchCheckPermissionsResponse) Reset()

func (*BatchCheckPermissionsResponse) String

type BuilderSnapshot

type BuilderSnapshot struct {

	// The builder this snapshot belongs to.
	Builder *proto.BuilderID `protobuf:"bytes,1,opt,name=builder,proto3" json:"builder,omitempty"`
	// The latest build associated with the builder at the time the snapshot is
	// taken. Nil if there's no associated build.
	Build *proto.Build `protobuf:"bytes,2,opt,name=build,proto3" json:"build,omitempty"`
	// contains filtered or unexported fields
}

func (*BuilderSnapshot) Descriptor deprecated

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

Deprecated: Use BuilderSnapshot.ProtoReflect.Descriptor instead.

func (*BuilderSnapshot) GetBuild

func (x *BuilderSnapshot) GetBuild() *proto.Build

func (*BuilderSnapshot) GetBuilder

func (x *BuilderSnapshot) GetBuilder() *proto.BuilderID

func (*BuilderSnapshot) ProtoMessage

func (*BuilderSnapshot) ProtoMessage()

func (*BuilderSnapshot) ProtoReflect

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

func (*BuilderSnapshot) Reset

func (x *BuilderSnapshot) Reset()

func (*BuilderSnapshot) String

func (x *BuilderSnapshot) String() string

type BuilderStats

type BuilderStats struct {

	// The builder that the stats belongs to.
	Builder *proto.BuilderID `protobuf:"bytes,1,opt,name=builder,proto3" json:"builder,omitempty"`
	// The number of pending builds associated with the builder.
	PendingBuildsCount int32 `protobuf:"varint,2,opt,name=pending_builds_count,json=pendingBuildsCount,proto3" json:"pending_builds_count,omitempty"`
	// The number of running builds associated with the builder.
	RunningBuildsCount int32 `protobuf:"varint,3,opt,name=running_builds_count,json=runningBuildsCount,proto3" json:"running_builds_count,omitempty"`
	// contains filtered or unexported fields
}

A message that contains some basic stats of a builder.

func (*BuilderStats) Descriptor deprecated

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

Deprecated: Use BuilderStats.ProtoReflect.Descriptor instead.

func (*BuilderStats) GetBuilder

func (x *BuilderStats) GetBuilder() *proto.BuilderID

func (*BuilderStats) GetPendingBuildsCount

func (x *BuilderStats) GetPendingBuildsCount() int32

func (*BuilderStats) GetRunningBuildsCount

func (x *BuilderStats) GetRunningBuildsCount() int32

func (*BuilderStats) ProtoMessage

func (*BuilderStats) ProtoMessage()

func (*BuilderStats) ProtoReflect

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

func (*BuilderStats) Reset

func (x *BuilderStats) Reset()

func (*BuilderStats) String

func (x *BuilderStats) String() string

type ConsolePredicate

type ConsolePredicate struct {

	// A console must belong to this project.
	Project string `protobuf:"bytes,2,opt,name=project,proto3" json:"project,omitempty"`
	// A console must include this builder.
	Builder *proto.BuilderID `protobuf:"bytes,1,opt,name=builder,proto3" json:"builder,omitempty"`
	// contains filtered or unexported fields
}

Represents a function Console -> bool. Empty message matches all consoles.

func (*ConsolePredicate) Descriptor deprecated

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

Deprecated: Use ConsolePredicate.ProtoReflect.Descriptor instead.

func (*ConsolePredicate) GetBuilder

func (x *ConsolePredicate) GetBuilder() *proto.BuilderID

func (*ConsolePredicate) GetProject

func (x *ConsolePredicate) GetProject() string

func (*ConsolePredicate) ProtoMessage

func (*ConsolePredicate) ProtoMessage()

func (*ConsolePredicate) ProtoReflect

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

func (*ConsolePredicate) Reset

func (x *ConsolePredicate) Reset()

func (*ConsolePredicate) String

func (x *ConsolePredicate) String() string

type ConsoleSnapshot

type ConsoleSnapshot struct {

	// The console this snapshot belongs to.
	Console *projectconfig.Console `protobuf:"bytes,1,opt,name=console,proto3" json:"console,omitempty"`
	// The snapshots of all the builders in the console.
	// In the same order as `console.builders`.
	BuilderSnapshots []*BuilderSnapshot `protobuf:"bytes,2,rep,name=builder_snapshots,json=builderSnapshots,proto3" json:"builder_snapshots,omitempty"`
	// contains filtered or unexported fields
}

func (*ConsoleSnapshot) Descriptor deprecated

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

Deprecated: Use ConsoleSnapshot.ProtoReflect.Descriptor instead.

func (*ConsoleSnapshot) GetBuilderSnapshots

func (x *ConsoleSnapshot) GetBuilderSnapshots() []*BuilderSnapshot

func (*ConsoleSnapshot) GetConsole

func (x *ConsoleSnapshot) GetConsole() *projectconfig.Console

func (*ConsoleSnapshot) ProtoMessage

func (*ConsoleSnapshot) ProtoMessage()

func (*ConsoleSnapshot) ProtoReflect

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

func (*ConsoleSnapshot) Reset

func (x *ConsoleSnapshot) Reset()

func (*ConsoleSnapshot) String

func (x *ConsoleSnapshot) String() string

type DecoratedMiloInternal

type DecoratedMiloInternal struct {
	// Service is the service to decorate.
	Service MiloInternalServer
	// 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(ctx 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 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(ctx context.Context, methodName string, rsp proto.Message, err error) error
}

func (*DecoratedMiloInternal) BatchCheckPermissions

func (*DecoratedMiloInternal) GetProjectCfg

func (s *DecoratedMiloInternal) GetProjectCfg(ctx context.Context, req *GetProjectCfgRequest) (rsp *projectconfig.Project, err error)

func (*DecoratedMiloInternal) ListBuilders

func (s *DecoratedMiloInternal) ListBuilders(ctx context.Context, req *ListBuildersRequest) (rsp *ListBuildersResponse, err error)

func (*DecoratedMiloInternal) ListProjects

func (s *DecoratedMiloInternal) ListProjects(ctx context.Context, req *ListProjectsRequest) (rsp *ListProjectsResponse, err error)

func (*DecoratedMiloInternal) ProxyGitilesLog

func (s *DecoratedMiloInternal) ProxyGitilesLog(ctx context.Context, req *ProxyGitilesLogRequest) (rsp *gitiles.LogResponse, err error)

func (*DecoratedMiloInternal) QueryBlamelist

func (*DecoratedMiloInternal) QueryBuilderStats

func (s *DecoratedMiloInternal) QueryBuilderStats(ctx context.Context, req *QueryBuilderStatsRequest) (rsp *BuilderStats, err error)

func (*DecoratedMiloInternal) QueryConsoleSnapshots

func (*DecoratedMiloInternal) QueryConsoles

func (s *DecoratedMiloInternal) QueryConsoles(ctx context.Context, req *QueryConsolesRequest) (rsp *QueryConsolesResponse, err error)

func (*DecoratedMiloInternal) QueryRecentBuilds

type GetProjectCfgRequest

type GetProjectCfgRequest struct {

	// The project name.
	Project string `protobuf:"bytes,1,opt,name=project,proto3" json:"project,omitempty"`
	// contains filtered or unexported fields
}

func (*GetProjectCfgRequest) Descriptor deprecated

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

Deprecated: Use GetProjectCfgRequest.ProtoReflect.Descriptor instead.

func (*GetProjectCfgRequest) GetProject

func (x *GetProjectCfgRequest) GetProject() string

func (*GetProjectCfgRequest) ProtoMessage

func (*GetProjectCfgRequest) ProtoMessage()

func (*GetProjectCfgRequest) ProtoReflect

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

func (*GetProjectCfgRequest) Reset

func (x *GetProjectCfgRequest) Reset()

func (*GetProjectCfgRequest) String

func (x *GetProjectCfgRequest) String() string

type ListBuildersPageToken

type ListBuildersPageToken struct {

	// The index of the next builder from all cached builders from buildbucket.
	//
	// Should not coexist with `NextMiloBuilderIndex`.
	NextBuildbucketBuilderIndex int32 `` /* 147-byte string literal not displayed */
	// The index of the next builder from Milo project definition.
	//
	// Should not coexist with `NextBuildbucketBuilderIndex`.
	NextMiloBuilderIndex int32 `` /* 126-byte string literal not displayed */
	// contains filtered or unexported fields
}

A stateless page token for `ListBuilders` RPC.

func (*ListBuildersPageToken) Descriptor deprecated

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

Deprecated: Use ListBuildersPageToken.ProtoReflect.Descriptor instead.

func (*ListBuildersPageToken) GetNextBuildbucketBuilderIndex

func (x *ListBuildersPageToken) GetNextBuildbucketBuilderIndex() int32

func (*ListBuildersPageToken) GetNextMiloBuilderIndex

func (x *ListBuildersPageToken) GetNextMiloBuilderIndex() int32

func (*ListBuildersPageToken) ProtoMessage

func (*ListBuildersPageToken) ProtoMessage()

func (*ListBuildersPageToken) ProtoReflect

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

func (*ListBuildersPageToken) Reset

func (x *ListBuildersPageToken) Reset()

func (*ListBuildersPageToken) String

func (x *ListBuildersPageToken) String() string

type ListBuildersRequest

type ListBuildersRequest struct {

	// Required only when `group` is specified. The project to query the builders
	// from.
	//
	// When specified, query all builders in the project as well as any external
	// builders  referenced by the consoles in the project.
	// When omitted, query all builders in any project.
	Project string `protobuf:"bytes,1,opt,name=project,proto3" json:"project,omitempty"`
	// Optional. The group/console to query the builders from.
	//
	// When omitted, all builders from the project is returned. Including all
	// builders defined in the consoles, builder groups, and buildbucket.
	Group string `protobuf:"bytes,2,opt,name=group,proto3" json:"group,omitempty"`
	// Optional. The maxium number of builders to return.
	//
	// The service may return fewer than this value.
	// If unspecified, at most 100 builders will be returned.
	// The maximum value is 10000; values above 10000 will be coerced to 10000.
	PageSize int32 `protobuf:"varint,3,opt,name=page_size,json=pageSize,proto3" json:"page_size,omitempty"`
	// Optional. A page token, received from a previous `ListBuilders`
	// call. Provide this to retrieve the subsequent page.
	//
	// When paginating, all parameters provided to `ListBuilders`, with the
	// exception of page_size and page_token, must match the call that provided
	// the page token.
	PageToken string `protobuf:"bytes,4,opt,name=page_token,json=pageToken,proto3" json:"page_token,omitempty"`
	// contains filtered or unexported fields
}

A request message for `ListBuilders` RPC.

func (*ListBuildersRequest) Descriptor deprecated

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

Deprecated: Use ListBuildersRequest.ProtoReflect.Descriptor instead.

func (*ListBuildersRequest) GetGroup

func (x *ListBuildersRequest) GetGroup() string

func (*ListBuildersRequest) GetPageSize

func (x *ListBuildersRequest) GetPageSize() int32

func (*ListBuildersRequest) GetPageToken

func (x *ListBuildersRequest) GetPageToken() string

func (*ListBuildersRequest) GetProject

func (x *ListBuildersRequest) GetProject() string

func (*ListBuildersRequest) ProtoMessage

func (*ListBuildersRequest) ProtoMessage()

func (*ListBuildersRequest) ProtoReflect

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

func (*ListBuildersRequest) Reset

func (x *ListBuildersRequest) Reset()

func (*ListBuildersRequest) String

func (x *ListBuildersRequest) String() string

type ListBuildersResponse

type ListBuildersResponse struct {

	// A list of matched builders.
	//
	// Builders are ordered by their canonical string ID
	// (i.e. "{project}/{bucket}/{builder}") with the exception that builders from
	// `ListBuildersRequest.project` always come before builders from other
	// projects.
	// Only builder IDs are populated for now.
	Builders []*proto.BuilderItem `protobuf:"bytes,1,rep,name=builders,proto3" json:"builders,omitempty"`
	// A token that can be sent as `page_token` to retrieve the next page.
	// If this field is omitted, there are no subsequent pages.
	NextPageToken string `protobuf:"bytes,2,opt,name=next_page_token,json=nextPageToken,proto3" json:"next_page_token,omitempty"`
	// contains filtered or unexported fields
}

A response message for `ListBuilders` RPC.

func (*ListBuildersResponse) Descriptor deprecated

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

Deprecated: Use ListBuildersResponse.ProtoReflect.Descriptor instead.

func (*ListBuildersResponse) GetBuilders

func (x *ListBuildersResponse) GetBuilders() []*proto.BuilderItem

func (*ListBuildersResponse) GetNextPageToken

func (x *ListBuildersResponse) GetNextPageToken() string

func (*ListBuildersResponse) ProtoMessage

func (*ListBuildersResponse) ProtoMessage()

func (*ListBuildersResponse) ProtoReflect

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

func (*ListBuildersResponse) Reset

func (x *ListBuildersResponse) Reset()

func (*ListBuildersResponse) String

func (x *ListBuildersResponse) String() string

type ListProjectsPageToken

type ListProjectsPageToken struct {

	// The index of the next project from all projects.
	NextProjectIndex int32 `protobuf:"varint,3,opt,name=next_project_index,json=nextProjectIndex,proto3" json:"next_project_index,omitempty"`
	// contains filtered or unexported fields
}

A stateless page token for `ListProjects` RPC.

func (*ListProjectsPageToken) Descriptor deprecated

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

Deprecated: Use ListProjectsPageToken.ProtoReflect.Descriptor instead.

func (*ListProjectsPageToken) GetNextProjectIndex

func (x *ListProjectsPageToken) GetNextProjectIndex() int32

func (*ListProjectsPageToken) ProtoMessage

func (*ListProjectsPageToken) ProtoMessage()

func (*ListProjectsPageToken) ProtoReflect

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

func (*ListProjectsPageToken) Reset

func (x *ListProjectsPageToken) Reset()

func (*ListProjectsPageToken) String

func (x *ListProjectsPageToken) String() string

type ListProjectsRequest

type ListProjectsRequest struct {

	// Optional. The maxium number of projects to return.
	//
	// The service may return fewer than this value.
	// If unspecified, at most 100 projects will be returned.
	// The maximum value is 10000; values above 10000 will be coerced to 10000.
	PageSize int32 `protobuf:"varint,1,opt,name=page_size,json=pageSize,proto3" json:"page_size,omitempty"`
	// Optional. A page token, received from a previous `ListProjects`
	// call. Provide this to retrieve the subsequent page.
	//
	// When paginating, all parameters provided to `ListProjects`, with the
	// exception of page_size and page_token, must match the call that provided
	// the page token.
	PageToken string `protobuf:"bytes,2,opt,name=page_token,json=pageToken,proto3" json:"page_token,omitempty"`
	// contains filtered or unexported fields
}

A request message for `ListProjects` RPC.

func (*ListProjectsRequest) Descriptor deprecated

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

Deprecated: Use ListProjectsRequest.ProtoReflect.Descriptor instead.

func (*ListProjectsRequest) GetPageSize

func (x *ListProjectsRequest) GetPageSize() int32

func (*ListProjectsRequest) GetPageToken

func (x *ListProjectsRequest) GetPageToken() string

func (*ListProjectsRequest) ProtoMessage

func (*ListProjectsRequest) ProtoMessage()

func (*ListProjectsRequest) ProtoReflect

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

func (*ListProjectsRequest) Reset

func (x *ListProjectsRequest) Reset()

func (*ListProjectsRequest) String

func (x *ListProjectsRequest) String() string

type ListProjectsResponse

type ListProjectsResponse struct {

	// A list of matched projects.
	//
	// Projects are ordered by their string ID
	Projects []*ProjectListItem `protobuf:"bytes,1,rep,name=projects,proto3" json:"projects,omitempty"`
	// A token that can be sent as `page_token` to retrieve the next page.
	// If this field is omitted, there are no subsequent pages.
	NextPageToken string `protobuf:"bytes,2,opt,name=next_page_token,json=nextPageToken,proto3" json:"next_page_token,omitempty"`
	// contains filtered or unexported fields
}

A response message for `ListProjects` RPC.

func (*ListProjectsResponse) Descriptor deprecated

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

Deprecated: Use ListProjectsResponse.ProtoReflect.Descriptor instead.

func (*ListProjectsResponse) GetNextPageToken

func (x *ListProjectsResponse) GetNextPageToken() string

func (*ListProjectsResponse) GetProjects

func (x *ListProjectsResponse) GetProjects() []*ProjectListItem

func (*ListProjectsResponse) ProtoMessage

func (*ListProjectsResponse) ProtoMessage()

func (*ListProjectsResponse) ProtoReflect

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

func (*ListProjectsResponse) Reset

func (x *ListProjectsResponse) Reset()

func (*ListProjectsResponse) String

func (x *ListProjectsResponse) String() string

type MiloInternalClient

type MiloInternalClient interface {
	// Query logs from a gitiles host.
	//
	// This avoids CORS issue at the cost of small overhead to proxy the requests.
	// Rationales can be found at b/349503219#comment11.
	//
	// The request/response structure is designed in a way that we can easily
	// switch the clients to query gitiles directly in the future if needed.
	ProxyGitilesLog(ctx context.Context, in *ProxyGitilesLogRequest, opts ...grpc.CallOption) (*gitiles.LogResponse, error)
	// Retrieves blamelist of a build.
	//
	// The blamelist of a build is defined as [end_commit, start_commit)
	// end_commit is the Gitiles commit of the build (specified in gitiles
	// buildset tag).
	// start_commit is the closest ancestor commit with an associated build that
	// is from the same builder and is not expired, cancelled, or infra-failed.
	QueryBlamelist(ctx context.Context, in *QueryBlamelistRequest, opts ...grpc.CallOption) (*QueryBlamelistResponse, error)
	// Retrieves a list of projects.
	ListProjects(ctx context.Context, in *ListProjectsRequest, opts ...grpc.CallOption) (*ListProjectsResponse, error)
	// Gets the project config.
	//
	// Return the config of the project.
	GetProjectCfg(ctx context.Context, in *GetProjectCfgRequest, opts ...grpc.CallOption) (*projectconfig.Project, error)
	// Retrieves the recent, finished builds of a builder.
	QueryRecentBuilds(ctx context.Context, in *QueryRecentBuildsRequest, opts ...grpc.CallOption) (*QueryRecentBuildsResponse, error)
	// Retrieves a list of builders in a project or a builder group.
	ListBuilders(ctx context.Context, in *ListBuildersRequest, opts ...grpc.CallOption) (*ListBuildersResponse, error)
	// Get the statistics associated with a builder.
	QueryBuilderStats(ctx context.Context, in *QueryBuilderStatsRequest, opts ...grpc.CallOption) (*BuilderStats, error)
	// Check whether the users has the specified permissions in the given realm.
	//
	// N.B. Only permissions registered [here][1] can be checked.
	//
	// [1]: https://source.corp.google.com/h/github/googlesource/codesearch/+/master:luci/luci-go/milo/rpc/batch_check_permissions.go;l=26;drc=e952557609eade6037c66866ebc00c506d8800a8
	BatchCheckPermissions(ctx context.Context, in *BatchCheckPermissionsRequest, opts ...grpc.CallOption) (*BatchCheckPermissionsResponse, error)
	// Retrieves a list of consoles.
	QueryConsoles(ctx context.Context, in *QueryConsolesRequest, opts ...grpc.CallOption) (*QueryConsolesResponse, error)
	// Retrieves a list of consoles with latest snapshots.
	QueryConsoleSnapshots(ctx context.Context, in *QueryConsoleSnapshotsRequest, opts ...grpc.CallOption) (*QueryConsoleSnapshotsResponse, error)
}

MiloInternalClient is the client API for MiloInternal service.

For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.

func NewMiloInternalPRPCClient

func NewMiloInternalPRPCClient(client *prpc.Client) MiloInternalClient

type MiloInternalServer

type MiloInternalServer interface {
	// Query logs from a gitiles host.
	//
	// This avoids CORS issue at the cost of small overhead to proxy the requests.
	// Rationales can be found at b/349503219#comment11.
	//
	// The request/response structure is designed in a way that we can easily
	// switch the clients to query gitiles directly in the future if needed.
	ProxyGitilesLog(context.Context, *ProxyGitilesLogRequest) (*gitiles.LogResponse, error)
	// Retrieves blamelist of a build.
	//
	// The blamelist of a build is defined as [end_commit, start_commit)
	// end_commit is the Gitiles commit of the build (specified in gitiles
	// buildset tag).
	// start_commit is the closest ancestor commit with an associated build that
	// is from the same builder and is not expired, cancelled, or infra-failed.
	QueryBlamelist(context.Context, *QueryBlamelistRequest) (*QueryBlamelistResponse, error)
	// Retrieves a list of projects.
	ListProjects(context.Context, *ListProjectsRequest) (*ListProjectsResponse, error)
	// Gets the project config.
	//
	// Return the config of the project.
	GetProjectCfg(context.Context, *GetProjectCfgRequest) (*projectconfig.Project, error)
	// Retrieves the recent, finished builds of a builder.
	QueryRecentBuilds(context.Context, *QueryRecentBuildsRequest) (*QueryRecentBuildsResponse, error)
	// Retrieves a list of builders in a project or a builder group.
	ListBuilders(context.Context, *ListBuildersRequest) (*ListBuildersResponse, error)
	// Get the statistics associated with a builder.
	QueryBuilderStats(context.Context, *QueryBuilderStatsRequest) (*BuilderStats, error)
	// Check whether the users has the specified permissions in the given realm.
	//
	// N.B. Only permissions registered [here][1] can be checked.
	//
	// [1]: https://source.corp.google.com/h/github/googlesource/codesearch/+/master:luci/luci-go/milo/rpc/batch_check_permissions.go;l=26;drc=e952557609eade6037c66866ebc00c506d8800a8
	BatchCheckPermissions(context.Context, *BatchCheckPermissionsRequest) (*BatchCheckPermissionsResponse, error)
	// Retrieves a list of consoles.
	QueryConsoles(context.Context, *QueryConsolesRequest) (*QueryConsolesResponse, error)
	// Retrieves a list of consoles with latest snapshots.
	QueryConsoleSnapshots(context.Context, *QueryConsoleSnapshotsRequest) (*QueryConsoleSnapshotsResponse, error)
}

MiloInternalServer is the server API for MiloInternal service.

type ProjectListItem

type ProjectListItem struct {

	// The project id.
	Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
	// The url of the project logo.
	LogoUrl string `protobuf:"bytes,2,opt,name=logo_url,json=logoUrl,proto3" json:"logo_url,omitempty"`
	// contains filtered or unexported fields
}

A single project in a ListProjectsResponse.

func (*ProjectListItem) Descriptor deprecated

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

Deprecated: Use ProjectListItem.ProtoReflect.Descriptor instead.

func (*ProjectListItem) GetId

func (x *ProjectListItem) GetId() string

func (*ProjectListItem) GetLogoUrl

func (x *ProjectListItem) GetLogoUrl() string

func (*ProjectListItem) ProtoMessage

func (*ProjectListItem) ProtoMessage()

func (*ProjectListItem) ProtoReflect

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

func (*ProjectListItem) Reset

func (x *ProjectListItem) Reset()

func (*ProjectListItem) String

func (x *ProjectListItem) String() string

type ProxyGitilesLogRequest

type ProxyGitilesLogRequest struct {

	// The host to send the gitiles Log request to.
	Host string `protobuf:"bytes,1,opt,name=host,proto3" json:"host,omitempty"`
	// The gitiles Log request.
	Request *gitiles.LogRequest `protobuf:"bytes,2,opt,name=request,proto3" json:"request,omitempty"`
	// contains filtered or unexported fields
}

A request message for `ProxyGitilesLog` RPC.

func (*ProxyGitilesLogRequest) Descriptor deprecated

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

Deprecated: Use ProxyGitilesLogRequest.ProtoReflect.Descriptor instead.

func (*ProxyGitilesLogRequest) GetHost

func (x *ProxyGitilesLogRequest) GetHost() string

func (*ProxyGitilesLogRequest) GetRequest

func (x *ProxyGitilesLogRequest) GetRequest() *gitiles.LogRequest

func (*ProxyGitilesLogRequest) ProtoMessage

func (*ProxyGitilesLogRequest) ProtoMessage()

func (*ProxyGitilesLogRequest) ProtoReflect

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

func (*ProxyGitilesLogRequest) Reset

func (x *ProxyGitilesLogRequest) Reset()

func (*ProxyGitilesLogRequest) String

func (x *ProxyGitilesLogRequest) String() string

type QueryBlamelistPageToken

type QueryBlamelistPageToken struct {

	// The first commit in the next page.
	NextCommitId string `protobuf:"bytes,2,opt,name=next_commit_id,json=nextCommitId,proto3" json:"next_commit_id,omitempty"`
	// contains filtered or unexported fields
}

A stateless page token for QueryBlamelist RPC.

func (*QueryBlamelistPageToken) Descriptor deprecated

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

Deprecated: Use QueryBlamelistPageToken.ProtoReflect.Descriptor instead.

func (*QueryBlamelistPageToken) GetNextCommitId

func (x *QueryBlamelistPageToken) GetNextCommitId() string

func (*QueryBlamelistPageToken) ProtoMessage

func (*QueryBlamelistPageToken) ProtoMessage()

func (*QueryBlamelistPageToken) ProtoReflect

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

func (*QueryBlamelistPageToken) Reset

func (x *QueryBlamelistPageToken) Reset()

func (*QueryBlamelistPageToken) String

func (x *QueryBlamelistPageToken) String() string

type QueryBlamelistRequest

type QueryBlamelistRequest struct {

	// The Gitiles commit of the build.
	//
	// This defines the end_commit of the blamelist.
	// It should be set to the output Gitiles commit of the build.
	// Input Gitiles commit should be used when output gitiles commit is not
	// available.
	GitilesCommit *proto.GitilesCommit `protobuf:"bytes,1,opt,name=gitiles_commit,json=gitilesCommit,proto3" json:"gitiles_commit,omitempty"`
	// The context builder of the blamelist.
	//
	// The start commit of the blamelist is the closest ancestor commit with an
	// associated build that is from the same builder and is not expired,
	// cancelled, or infra-failed.
	Builder *proto.BuilderID `protobuf:"bytes,2,opt,name=builder,proto3" json:"builder,omitempty"`
	// Optional. The maximum number of commits to return.
	//
	// The service may return fewer than this value.
	// If unspecified, at most 100 commits will be returned.
	// The maximum value is 1000; values above 1000 will be coerced to 1000.
	PageSize int32 `protobuf:"varint,3,opt,name=page_size,json=pageSize,proto3" json:"page_size,omitempty"`
	// Optional. A page token, received from a previous `QueryBlamelist` call.
	// Provide this to retrieve the subsequent page.
	//
	// When paginating, all parameters provided to `QueryBlamelist`, with the
	// exception of page_size and page_token, must match the call that provided
	// the page token.
	PageToken string `protobuf:"bytes,4,opt,name=page_token,json=pageToken,proto3" json:"page_token,omitempty"`
	// This field is unused.
	//
	// TODO(crbugs/1047893): remove this field in the once no clients depends on
	// this.
	MultiProjectSupport bool `protobuf:"varint,5,opt,name=multi_project_support,json=multiProjectSupport,proto3" json:"multi_project_support,omitempty"`
	// contains filtered or unexported fields
}

A request message for `QueryBlamelist` RPC.

func (*QueryBlamelistRequest) Descriptor deprecated

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

Deprecated: Use QueryBlamelistRequest.ProtoReflect.Descriptor instead.

func (*QueryBlamelistRequest) GetBuilder

func (x *QueryBlamelistRequest) GetBuilder() *proto.BuilderID

func (*QueryBlamelistRequest) GetGitilesCommit

func (x *QueryBlamelistRequest) GetGitilesCommit() *proto.GitilesCommit

func (*QueryBlamelistRequest) GetMultiProjectSupport

func (x *QueryBlamelistRequest) GetMultiProjectSupport() bool

func (*QueryBlamelistRequest) GetPageSize

func (x *QueryBlamelistRequest) GetPageSize() int32

func (*QueryBlamelistRequest) GetPageToken

func (x *QueryBlamelistRequest) GetPageToken() string

func (*QueryBlamelistRequest) ProtoMessage

func (*QueryBlamelistRequest) ProtoMessage()

func (*QueryBlamelistRequest) ProtoReflect

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

func (*QueryBlamelistRequest) Reset

func (x *QueryBlamelistRequest) Reset()

func (*QueryBlamelistRequest) String

func (x *QueryBlamelistRequest) String() string

type QueryBlamelistResponse

type QueryBlamelistResponse struct {

	// The commits from the blamelist of the build, in reverse chronological
	// order.
	Commits []*git.Commit `protobuf:"bytes,1,rep,name=commits,proto3" json:"commits,omitempty"`
	// A token that can be sent as `page_token` to retrieve the next page.
	// If this field is omitted, there are no subsequent pages.
	NextPageToken string `protobuf:"bytes,2,opt,name=next_page_token,json=nextPageToken,proto3" json:"next_page_token,omitempty"`
	// The repo commit immediately preceding |commits|. Useful for creating
	// git log queries, which are exclusive of the first commit.
	// Unset when |commits| includes the first commit in the repository.
	PrecedingCommit *git.Commit `protobuf:"bytes,3,opt,name=preceding_commit,json=precedingCommit,proto3" json:"preceding_commit,omitempty"`
	// contains filtered or unexported fields
}

A response message for QueryBlamelist RPC.

func (*QueryBlamelistResponse) Descriptor deprecated

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

Deprecated: Use QueryBlamelistResponse.ProtoReflect.Descriptor instead.

func (*QueryBlamelistResponse) GetCommits

func (x *QueryBlamelistResponse) GetCommits() []*git.Commit

func (*QueryBlamelistResponse) GetNextPageToken

func (x *QueryBlamelistResponse) GetNextPageToken() string

func (*QueryBlamelistResponse) GetPrecedingCommit

func (x *QueryBlamelistResponse) GetPrecedingCommit() *git.Commit

func (*QueryBlamelistResponse) ProtoMessage

func (*QueryBlamelistResponse) ProtoMessage()

func (*QueryBlamelistResponse) ProtoReflect

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

func (*QueryBlamelistResponse) Reset

func (x *QueryBlamelistResponse) Reset()

func (*QueryBlamelistResponse) String

func (x *QueryBlamelistResponse) String() string

type QueryBuilderStatsRequest

type QueryBuilderStatsRequest struct {

	// The builder to query the stats from.
	Builder *proto.BuilderID `protobuf:"bytes,1,opt,name=builder,proto3" json:"builder,omitempty"`
	// contains filtered or unexported fields
}

A request message for `QueryBuilderStats` RPC.

func (*QueryBuilderStatsRequest) Descriptor deprecated

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

Deprecated: Use QueryBuilderStatsRequest.ProtoReflect.Descriptor instead.

func (*QueryBuilderStatsRequest) GetBuilder

func (x *QueryBuilderStatsRequest) GetBuilder() *proto.BuilderID

func (*QueryBuilderStatsRequest) ProtoMessage

func (*QueryBuilderStatsRequest) ProtoMessage()

func (*QueryBuilderStatsRequest) ProtoReflect

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

func (*QueryBuilderStatsRequest) Reset

func (x *QueryBuilderStatsRequest) Reset()

func (*QueryBuilderStatsRequest) String

func (x *QueryBuilderStatsRequest) String() string

type QueryConsoleSnapshotsRequest

type QueryConsoleSnapshotsRequest struct {

	// A console in the response must satisfy this predicate.
	// `predicate.project` is required.
	Predicate *ConsolePredicate `protobuf:"bytes,1,opt,name=predicate,proto3" json:"predicate,omitempty"`
	// Optional. The maximum number of consoles to return.
	//
	// The service may return fewer than this value.
	// If unspecified, at most 25 consoles will be returned.
	// The maximum value is 100; values above 100 will be coerced to 100.
	PageSize int32 `protobuf:"varint,2,opt,name=page_size,json=pageSize,proto3" json:"page_size,omitempty"`
	// Optional. A page token, received from a previous `QueryConsoleSnapshots`
	// call. Provide this to retrieve the subsequent page.
	//
	// When paginating, all parameters provided to `QueryConsoleSnapshots`, with
	// the exception of page_size and page_token, must match the call that
	// provided the page token.
	PageToken string `protobuf:"bytes,3,opt,name=page_token,json=pageToken,proto3" json:"page_token,omitempty"`
	// contains filtered or unexported fields
}

func (*QueryConsoleSnapshotsRequest) Descriptor deprecated

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

Deprecated: Use QueryConsoleSnapshotsRequest.ProtoReflect.Descriptor instead.

func (*QueryConsoleSnapshotsRequest) GetPageSize

func (x *QueryConsoleSnapshotsRequest) GetPageSize() int32

func (*QueryConsoleSnapshotsRequest) GetPageToken

func (x *QueryConsoleSnapshotsRequest) GetPageToken() string

func (*QueryConsoleSnapshotsRequest) GetPredicate

func (*QueryConsoleSnapshotsRequest) ProtoMessage

func (*QueryConsoleSnapshotsRequest) ProtoMessage()

func (*QueryConsoleSnapshotsRequest) ProtoReflect

func (*QueryConsoleSnapshotsRequest) Reset

func (x *QueryConsoleSnapshotsRequest) Reset()

func (*QueryConsoleSnapshotsRequest) String

type QueryConsoleSnapshotsResponse

type QueryConsoleSnapshotsResponse struct {

	// A list of matched consoles.
	Snapshots []*ConsoleSnapshot `protobuf:"bytes,1,rep,name=snapshots,proto3" json:"snapshots,omitempty"`
	// A token that can be sent as `page_token` to retrieve the next page.
	// If this field is omitted, there are no subsequent pages.
	NextPageToken string `protobuf:"bytes,2,opt,name=next_page_token,json=nextPageToken,proto3" json:"next_page_token,omitempty"`
	// contains filtered or unexported fields
}

func (*QueryConsoleSnapshotsResponse) Descriptor deprecated

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

Deprecated: Use QueryConsoleSnapshotsResponse.ProtoReflect.Descriptor instead.

func (*QueryConsoleSnapshotsResponse) GetNextPageToken

func (x *QueryConsoleSnapshotsResponse) GetNextPageToken() string

func (*QueryConsoleSnapshotsResponse) GetSnapshots

func (x *QueryConsoleSnapshotsResponse) GetSnapshots() []*ConsoleSnapshot

func (*QueryConsoleSnapshotsResponse) ProtoMessage

func (*QueryConsoleSnapshotsResponse) ProtoMessage()

func (*QueryConsoleSnapshotsResponse) ProtoReflect

func (*QueryConsoleSnapshotsResponse) Reset

func (x *QueryConsoleSnapshotsResponse) Reset()

func (*QueryConsoleSnapshotsResponse) String

type QueryConsolesRequest

type QueryConsolesRequest struct {

	// A console in the response must satisfy this predicate.
	Predicate *ConsolePredicate `protobuf:"bytes,1,opt,name=predicate,proto3" json:"predicate,omitempty"`
	// Optional. The maxium number of consoles to return.
	//
	// The service may return fewer than this value.
	// If unspecified, at most 25 consoles will be returned.
	// The maximum value is 100; values above 100 will be coerced to 100.
	PageSize int32 `protobuf:"varint,2,opt,name=page_size,json=pageSize,proto3" json:"page_size,omitempty"`
	// Optional. A page token, received from a previous `ListBuilders`
	// call. Provide this to retrieve the subsequent page.
	//
	// When paginating, all parameters provided to `ListBuilders`, with the
	// exception of page_size and page_token, must match the call that provided
	// the page token.
	PageToken string `protobuf:"bytes,3,opt,name=page_token,json=pageToken,proto3" json:"page_token,omitempty"`
	// contains filtered or unexported fields
}

func (*QueryConsolesRequest) Descriptor deprecated

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

Deprecated: Use QueryConsolesRequest.ProtoReflect.Descriptor instead.

func (*QueryConsolesRequest) GetPageSize

func (x *QueryConsolesRequest) GetPageSize() int32

func (*QueryConsolesRequest) GetPageToken

func (x *QueryConsolesRequest) GetPageToken() string

func (*QueryConsolesRequest) GetPredicate

func (x *QueryConsolesRequest) GetPredicate() *ConsolePredicate

func (*QueryConsolesRequest) ProtoMessage

func (*QueryConsolesRequest) ProtoMessage()

func (*QueryConsolesRequest) ProtoReflect

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

func (*QueryConsolesRequest) Reset

func (x *QueryConsolesRequest) Reset()

func (*QueryConsolesRequest) String

func (x *QueryConsolesRequest) String() string

type QueryConsolesResponse

type QueryConsolesResponse struct {

	// A list of matched consoles.
	Consoles []*projectconfig.Console `protobuf:"bytes,1,rep,name=consoles,proto3" json:"consoles,omitempty"`
	// A token that can be sent as `page_token` to retrieve the next page.
	// If this field is omitted, there are no subsequent pages.
	NextPageToken string `protobuf:"bytes,2,opt,name=next_page_token,json=nextPageToken,proto3" json:"next_page_token,omitempty"`
	// contains filtered or unexported fields
}

func (*QueryConsolesResponse) Descriptor deprecated

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

Deprecated: Use QueryConsolesResponse.ProtoReflect.Descriptor instead.

func (*QueryConsolesResponse) GetConsoles

func (x *QueryConsolesResponse) GetConsoles() []*projectconfig.Console

func (*QueryConsolesResponse) GetNextPageToken

func (x *QueryConsolesResponse) GetNextPageToken() string

func (*QueryConsolesResponse) ProtoMessage

func (*QueryConsolesResponse) ProtoMessage()

func (*QueryConsolesResponse) ProtoReflect

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

func (*QueryConsolesResponse) Reset

func (x *QueryConsolesResponse) Reset()

func (*QueryConsolesResponse) String

func (x *QueryConsolesResponse) String() string

type QueryRecentBuildsRequest

type QueryRecentBuildsRequest struct {

	// The builder to query the build history from.
	Builder *proto.BuilderID `protobuf:"bytes,1,opt,name=builder,proto3" json:"builder,omitempty"`
	// Optional. The maxium number of builds to return.
	//
	// The service may return fewer than this value.
	// If unspecified, at most 25 builds will be returned.
	// The maximum value is 100; values above 100 will be coerced to 100.
	PageSize int32 `protobuf:"varint,2,opt,name=page_size,json=pageSize,proto3" json:"page_size,omitempty"`
	// Optional. A page token, received from a previous `QueryRecentBuilds`
	// call. Provide this to retrieve the subsequent page.
	//
	// When paginating, all parameters provided to `QueryRecentBuilds`, with
	// the exception of page_size and page_token, must match the call that
	// provided the page token.
	PageToken string `protobuf:"bytes,3,opt,name=page_token,json=pageToken,proto3" json:"page_token,omitempty"`
	// contains filtered or unexported fields
}

A request message for `QueryRecentBuilds` RPC.

func (*QueryRecentBuildsRequest) Descriptor deprecated

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

Deprecated: Use QueryRecentBuildsRequest.ProtoReflect.Descriptor instead.

func (*QueryRecentBuildsRequest) GetBuilder

func (x *QueryRecentBuildsRequest) GetBuilder() *proto.BuilderID

func (*QueryRecentBuildsRequest) GetPageSize

func (x *QueryRecentBuildsRequest) GetPageSize() int32

func (*QueryRecentBuildsRequest) GetPageToken

func (x *QueryRecentBuildsRequest) GetPageToken() string

func (*QueryRecentBuildsRequest) ProtoMessage

func (*QueryRecentBuildsRequest) ProtoMessage()

func (*QueryRecentBuildsRequest) ProtoReflect

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

func (*QueryRecentBuildsRequest) Reset

func (x *QueryRecentBuildsRequest) Reset()

func (*QueryRecentBuildsRequest) String

func (x *QueryRecentBuildsRequest) String() string

type QueryRecentBuildsResponse

type QueryRecentBuildsResponse struct {

	// Recent builds. Ordered by `CreateTime`.
	// Only Id, Builder, Number, CreateTime, Status, Critical are populated.
	Builds []*proto.Build `protobuf:"bytes,1,rep,name=builds,proto3" json:"builds,omitempty"`
	// A token that can be sent as `page_token` to retrieve the next page.
	// If this field is omitted, there are no subsequent pages.
	NextPageToken string `protobuf:"bytes,2,opt,name=next_page_token,json=nextPageToken,proto3" json:"next_page_token,omitempty"`
	// contains filtered or unexported fields
}

A response message for `QueryRecentBuilds` RPC.

func (*QueryRecentBuildsResponse) Descriptor deprecated

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

Deprecated: Use QueryRecentBuildsResponse.ProtoReflect.Descriptor instead.

func (*QueryRecentBuildsResponse) GetBuilds

func (x *QueryRecentBuildsResponse) GetBuilds() []*proto.Build

func (*QueryRecentBuildsResponse) GetNextPageToken

func (x *QueryRecentBuildsResponse) GetNextPageToken() string

func (*QueryRecentBuildsResponse) ProtoMessage

func (*QueryRecentBuildsResponse) ProtoMessage()

func (*QueryRecentBuildsResponse) ProtoReflect

func (*QueryRecentBuildsResponse) Reset

func (x *QueryRecentBuildsResponse) Reset()

func (*QueryRecentBuildsResponse) String

func (x *QueryRecentBuildsResponse) String() string

type UnimplementedMiloInternalServer

type UnimplementedMiloInternalServer struct {
}

UnimplementedMiloInternalServer can be embedded to have forward compatible implementations.

func (*UnimplementedMiloInternalServer) GetProjectCfg

func (*UnimplementedMiloInternalServer) ListBuilders

func (*UnimplementedMiloInternalServer) ListProjects

func (*UnimplementedMiloInternalServer) ProxyGitilesLog

func (*UnimplementedMiloInternalServer) QueryBlamelist

func (*UnimplementedMiloInternalServer) QueryBuilderStats

func (*UnimplementedMiloInternalServer) QueryConsoles

func (*UnimplementedMiloInternalServer) QueryRecentBuilds

Jump to

Keyboard shortcuts

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