v1

package
v0.0.0-...-2c7bdca Latest Latest
Warning

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

Go to latest
Published: Nov 21, 2024 License: BSD-3-Clause Imports: 8 Imported by: 0

Documentation

Index

Constants

View Source
const (
	CulpritService_PersistCulprit_FullMethodName      = "/culprit.v1.CulpritService/PersistCulprit"
	CulpritService_GetCulprit_FullMethodName          = "/culprit.v1.CulpritService/GetCulprit"
	CulpritService_NotifyUserOfAnomaly_FullMethodName = "/culprit.v1.CulpritService/NotifyUserOfAnomaly"
	CulpritService_NotifyUserOfCulprit_FullMethodName = "/culprit.v1.CulpritService/NotifyUserOfCulprit"
)

Variables

View Source
var CulpritService_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "culprit.v1.CulpritService",
	HandlerType: (*CulpritServiceServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "PersistCulprit",
			Handler:    _CulpritService_PersistCulprit_Handler,
		},
		{
			MethodName: "GetCulprit",
			Handler:    _CulpritService_GetCulprit_Handler,
		},
		{
			MethodName: "NotifyUserOfAnomaly",
			Handler:    _CulpritService_NotifyUserOfAnomaly_Handler,
		},
		{
			MethodName: "NotifyUserOfCulprit",
			Handler:    _CulpritService_NotifyUserOfCulprit_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "culprit_service.proto",
}

CulpritService_ServiceDesc is the grpc.ServiceDesc for CulpritService 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_culprit_service_proto protoreflect.FileDescriptor

Functions

func RegisterCulpritServiceServer

func RegisterCulpritServiceServer(s grpc.ServiceRegistrar, srv CulpritServiceServer)

Types

type Anomaly

type Anomaly struct {

	// the start commit position of the detected anomaly
	StartCommit int64 `protobuf:"varint,1,opt,name=start_commit,json=startCommit,proto3" json:"start_commit,omitempty"`
	// the end commit position of the detected anomaly
	EndCommit int64 `protobuf:"varint,2,opt,name=end_commit,json=endCommit,proto3" json:"end_commit,omitempty"`
	// the paramset from the regression detected in Skia. The parameters
	// are used in Skia alerts to define which tests to apply the deteciton
	// rules.
	// In chromeperf's context, it should include the following keys:
	//   - bot:
	//     the name of the bot (a.k.a, 'builder' in waterfall, and
	//     'configuration' in pinpoint job page.)
	//   - benchmark:
	//     the name of the benchmark
	//   - story:
	//     the name of the story (a.k.a., test)
	//   - measurement:
	//     the metric to look at. (a.k.a., 'test' in skia query ui,
	//     and 'chart' in pinpoint job page)
	//   - stat:
	//     the aggregation method on the data points
	Paramset map[string]string `` /* 157-byte string literal not displayed */
	// indicate the direction towards which the change should be
	// considered as regression.
	// The possible values are: UP, DOWN or UNKNOWN
	ImprovementDirection string `protobuf:"bytes,4,opt,name=improvement_direction,json=improvementDirection,proto3" json:"improvement_direction,omitempty"`
	// contains filtered or unexported fields
}

Anomaly detected in a test Note: This is (right now) same as Anomaly object in anomalygroup_service.proto. But this has been duplicated because the two protos are used in two different service(culprit & anomlaygroup), and these services can evolve independently

func (*Anomaly) Descriptor deprecated

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

Deprecated: Use Anomaly.ProtoReflect.Descriptor instead.

func (*Anomaly) GetEndCommit

func (x *Anomaly) GetEndCommit() int64

func (*Anomaly) GetImprovementDirection

func (x *Anomaly) GetImprovementDirection() string

func (*Anomaly) GetParamset

func (x *Anomaly) GetParamset() map[string]string

func (*Anomaly) GetStartCommit

func (x *Anomaly) GetStartCommit() int64

func (*Anomaly) ProtoMessage

func (*Anomaly) ProtoMessage()

func (*Anomaly) ProtoReflect

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

func (*Anomaly) Reset

func (x *Anomaly) Reset()

func (*Anomaly) String

func (x *Anomaly) String() string

type Commit

type Commit struct {

	// Repo host e.g. chromium.googlesource.com
	Host string `protobuf:"bytes,1,opt,name=host,proto3" json:"host,omitempty"`
	// Project inside the repo e.g. chromium/src
	Project string `protobuf:"bytes,2,opt,name=project,proto3" json:"project,omitempty"`
	// Repo ref e.g. "refs/heads/main
	Ref string `protobuf:"bytes,3,opt,name=ref,proto3" json:"ref,omitempty"`
	// Commit Hash
	Revision string `protobuf:"bytes,4,opt,name=revision,proto3" json:"revision,omitempty"`
	// contains filtered or unexported fields
}

Represents a commit which has been identified as a culprit.

func (*Commit) Descriptor deprecated

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

Deprecated: Use Commit.ProtoReflect.Descriptor instead.

func (*Commit) GetHost

func (x *Commit) GetHost() string

func (*Commit) GetProject

func (x *Commit) GetProject() string

func (*Commit) GetRef

func (x *Commit) GetRef() string

func (*Commit) GetRevision

func (x *Commit) GetRevision() string

func (*Commit) ProtoMessage

func (*Commit) ProtoMessage()

func (*Commit) ProtoReflect

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

func (*Commit) Reset

func (x *Commit) Reset()

func (*Commit) String

func (x *Commit) String() string

type Culprit

type Culprit struct {
	Id              string            `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
	Commit          *Commit           `protobuf:"bytes,2,opt,name=commit,proto3" json:"commit,omitempty"`
	AnomalyGroupIds []string          `protobuf:"bytes,3,rep,name=anomaly_group_ids,json=anomalyGroupIds,proto3" json:"anomaly_group_ids,omitempty"`
	IssueIds        []string          `protobuf:"bytes,4,rep,name=issue_ids,json=issueIds,proto3" json:"issue_ids,omitempty"`
	GroupIssueMap   map[string]string `` /* 190-byte string literal not displayed */
	// contains filtered or unexported fields
}

Represents the change which has been identified as a culprit. TODO(wenbinzhang): remove anomaly group ids and issue ids as we have the info needed the group issue map

func (*Culprit) Descriptor deprecated

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

Deprecated: Use Culprit.ProtoReflect.Descriptor instead.

func (*Culprit) GetAnomalyGroupIds

func (x *Culprit) GetAnomalyGroupIds() []string

func (*Culprit) GetCommit

func (x *Culprit) GetCommit() *Commit

func (*Culprit) GetGroupIssueMap

func (x *Culprit) GetGroupIssueMap() map[string]string

func (*Culprit) GetId

func (x *Culprit) GetId() string

func (*Culprit) GetIssueIds

func (x *Culprit) GetIssueIds() []string

func (*Culprit) ProtoMessage

func (*Culprit) ProtoMessage()

func (*Culprit) ProtoReflect

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

func (*Culprit) Reset

func (x *Culprit) Reset()

func (*Culprit) String

func (x *Culprit) String() string

type CulpritServiceClient

type CulpritServiceClient interface {
	// Stores commits identified as culprits in persistent storage.
	PersistCulprit(ctx context.Context, in *PersistCulpritRequest, opts ...grpc.CallOption) (*PersistCulpritResponse, error)
	// Fetches a given culprit by id
	GetCulprit(ctx context.Context, in *GetCulpritRequest, opts ...grpc.CallOption) (*GetCulpritResponse, error)
	// Takes necessary actions to inform users about the anomalies.
	NotifyUserOfAnomaly(ctx context.Context, in *NotifyUserOfAnomalyRequest, opts ...grpc.CallOption) (*NotifyUserOfAnomalyResponse, error)
	// Takes necessary actions to inform users about the culprits.
	NotifyUserOfCulprit(ctx context.Context, in *NotifyUserOfCulpritRequest, opts ...grpc.CallOption) (*NotifyUserOfCulpritResponse, error)
}

CulpritServiceClient is the client API for CulpritService 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 CulpritServiceServer

type CulpritServiceServer interface {
	// Stores commits identified as culprits in persistent storage.
	PersistCulprit(context.Context, *PersistCulpritRequest) (*PersistCulpritResponse, error)
	// Fetches a given culprit by id
	GetCulprit(context.Context, *GetCulpritRequest) (*GetCulpritResponse, error)
	// Takes necessary actions to inform users about the anomalies.
	NotifyUserOfAnomaly(context.Context, *NotifyUserOfAnomalyRequest) (*NotifyUserOfAnomalyResponse, error)
	// Takes necessary actions to inform users about the culprits.
	NotifyUserOfCulprit(context.Context, *NotifyUserOfCulpritRequest) (*NotifyUserOfCulpritResponse, error)
	// contains filtered or unexported methods
}

CulpritServiceServer is the server API for CulpritService service. All implementations must embed UnimplementedCulpritServiceServer for forward compatibility

type GetCulpritRequest

type GetCulpritRequest struct {
	CulpritIds []string `protobuf:"bytes,1,rep,name=culprit_ids,json=culpritIds,proto3" json:"culprit_ids,omitempty"`
	// contains filtered or unexported fields
}

Request object for GetCulprit rpc.

func (*GetCulpritRequest) Descriptor deprecated

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

Deprecated: Use GetCulpritRequest.ProtoReflect.Descriptor instead.

func (*GetCulpritRequest) GetCulpritIds

func (x *GetCulpritRequest) GetCulpritIds() []string

func (*GetCulpritRequest) ProtoMessage

func (*GetCulpritRequest) ProtoMessage()

func (*GetCulpritRequest) ProtoReflect

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

func (*GetCulpritRequest) Reset

func (x *GetCulpritRequest) Reset()

func (*GetCulpritRequest) String

func (x *GetCulpritRequest) String() string

type GetCulpritResponse

type GetCulpritResponse struct {
	Culprits []*Culprit `protobuf:"bytes,1,rep,name=culprits,proto3" json:"culprits,omitempty"`
	// contains filtered or unexported fields
}

Response object for GetCulprit rpc.

func (*GetCulpritResponse) Descriptor deprecated

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

Deprecated: Use GetCulpritResponse.ProtoReflect.Descriptor instead.

func (*GetCulpritResponse) GetCulprits

func (x *GetCulpritResponse) GetCulprits() []*Culprit

func (*GetCulpritResponse) ProtoMessage

func (*GetCulpritResponse) ProtoMessage()

func (*GetCulpritResponse) ProtoReflect

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

func (*GetCulpritResponse) Reset

func (x *GetCulpritResponse) Reset()

func (*GetCulpritResponse) String

func (x *GetCulpritResponse) String() string

type NotifyUserOfAnomalyRequest

type NotifyUserOfAnomalyRequest struct {
	AnomalyGroupId string     `protobuf:"bytes,1,opt,name=anomaly_group_id,json=anomalyGroupId,proto3" json:"anomaly_group_id,omitempty"`
	Anomaly        []*Anomaly `protobuf:"bytes,2,rep,name=anomaly,proto3" json:"anomaly,omitempty"`
	// contains filtered or unexported fields
}

Request object for NotifyUserOfAnomaly rpc.

func (*NotifyUserOfAnomalyRequest) Descriptor deprecated

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

Deprecated: Use NotifyUserOfAnomalyRequest.ProtoReflect.Descriptor instead.

func (*NotifyUserOfAnomalyRequest) GetAnomaly

func (x *NotifyUserOfAnomalyRequest) GetAnomaly() []*Anomaly

func (*NotifyUserOfAnomalyRequest) GetAnomalyGroupId

func (x *NotifyUserOfAnomalyRequest) GetAnomalyGroupId() string

func (*NotifyUserOfAnomalyRequest) ProtoMessage

func (*NotifyUserOfAnomalyRequest) ProtoMessage()

func (*NotifyUserOfAnomalyRequest) ProtoReflect

func (*NotifyUserOfAnomalyRequest) Reset

func (x *NotifyUserOfAnomalyRequest) Reset()

func (*NotifyUserOfAnomalyRequest) String

func (x *NotifyUserOfAnomalyRequest) String() string

type NotifyUserOfAnomalyResponse

type NotifyUserOfAnomalyResponse struct {

	// Id of issue created
	IssueId string `protobuf:"bytes,1,opt,name=issue_id,json=issueId,proto3" json:"issue_id,omitempty"`
	// contains filtered or unexported fields
}

Response object for NotifyUserOfAnomaly rpc.

func (*NotifyUserOfAnomalyResponse) Descriptor deprecated

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

Deprecated: Use NotifyUserOfAnomalyResponse.ProtoReflect.Descriptor instead.

func (*NotifyUserOfAnomalyResponse) GetIssueId

func (x *NotifyUserOfAnomalyResponse) GetIssueId() string

func (*NotifyUserOfAnomalyResponse) ProtoMessage

func (*NotifyUserOfAnomalyResponse) ProtoMessage()

func (*NotifyUserOfAnomalyResponse) ProtoReflect

func (*NotifyUserOfAnomalyResponse) Reset

func (x *NotifyUserOfAnomalyResponse) Reset()

func (*NotifyUserOfAnomalyResponse) String

func (x *NotifyUserOfAnomalyResponse) String() string

type NotifyUserOfCulpritRequest

type NotifyUserOfCulpritRequest struct {

	// List of culprit ids.
	CulpritIds []string `protobuf:"bytes,1,rep,name=culprit_ids,json=culpritIds,proto3" json:"culprit_ids,omitempty"`
	// ID of the anomaly group corresponding to the bisection.
	AnomalyGroupId string `protobuf:"bytes,2,opt,name=anomaly_group_id,json=anomalyGroupId,proto3" json:"anomaly_group_id,omitempty"`
	// contains filtered or unexported fields
}

Request object for NotifyUserOfCulprit rpc.

func (*NotifyUserOfCulpritRequest) Descriptor deprecated

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

Deprecated: Use NotifyUserOfCulpritRequest.ProtoReflect.Descriptor instead.

func (*NotifyUserOfCulpritRequest) GetAnomalyGroupId

func (x *NotifyUserOfCulpritRequest) GetAnomalyGroupId() string

func (*NotifyUserOfCulpritRequest) GetCulpritIds

func (x *NotifyUserOfCulpritRequest) GetCulpritIds() []string

func (*NotifyUserOfCulpritRequest) ProtoMessage

func (*NotifyUserOfCulpritRequest) ProtoMessage()

func (*NotifyUserOfCulpritRequest) ProtoReflect

func (*NotifyUserOfCulpritRequest) Reset

func (x *NotifyUserOfCulpritRequest) Reset()

func (*NotifyUserOfCulpritRequest) String

func (x *NotifyUserOfCulpritRequest) String() string

type NotifyUserOfCulpritResponse

type NotifyUserOfCulpritResponse struct {

	// List of issue ids created
	IssueIds []string `protobuf:"bytes,1,rep,name=issue_ids,json=issueIds,proto3" json:"issue_ids,omitempty"`
	// contains filtered or unexported fields
}

Response object for NotifyUserOfCulprit rpc.

func (*NotifyUserOfCulpritResponse) Descriptor deprecated

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

Deprecated: Use NotifyUserOfCulpritResponse.ProtoReflect.Descriptor instead.

func (*NotifyUserOfCulpritResponse) GetIssueIds

func (x *NotifyUserOfCulpritResponse) GetIssueIds() []string

func (*NotifyUserOfCulpritResponse) ProtoMessage

func (*NotifyUserOfCulpritResponse) ProtoMessage()

func (*NotifyUserOfCulpritResponse) ProtoReflect

func (*NotifyUserOfCulpritResponse) Reset

func (x *NotifyUserOfCulpritResponse) Reset()

func (*NotifyUserOfCulpritResponse) String

func (x *NotifyUserOfCulpritResponse) String() string

type PersistCulpritRequest

type PersistCulpritRequest struct {

	// List of commits identified as culprits.
	Commits []*Commit `protobuf:"bytes,1,rep,name=commits,proto3" json:"commits,omitempty"`
	// ID of the anomaly group corresponding to the bisection.
	AnomalyGroupId string `protobuf:"bytes,2,opt,name=anomaly_group_id,json=anomalyGroupId,proto3" json:"anomaly_group_id,omitempty"`
	// contains filtered or unexported fields
}

Request object for PersistCulprit rpc.

func (*PersistCulpritRequest) Descriptor deprecated

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

Deprecated: Use PersistCulpritRequest.ProtoReflect.Descriptor instead.

func (*PersistCulpritRequest) GetAnomalyGroupId

func (x *PersistCulpritRequest) GetAnomalyGroupId() string

func (*PersistCulpritRequest) GetCommits

func (x *PersistCulpritRequest) GetCommits() []*Commit

func (*PersistCulpritRequest) ProtoMessage

func (*PersistCulpritRequest) ProtoMessage()

func (*PersistCulpritRequest) ProtoReflect

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

func (*PersistCulpritRequest) Reset

func (x *PersistCulpritRequest) Reset()

func (*PersistCulpritRequest) String

func (x *PersistCulpritRequest) String() string

type PersistCulpritResponse

type PersistCulpritResponse struct {

	// List of culprit ids created.
	CulpritIds []string `protobuf:"bytes,1,rep,name=culprit_ids,json=culpritIds,proto3" json:"culprit_ids,omitempty"`
	// contains filtered or unexported fields
}

Response object for PersistCulprit rpc.

func (*PersistCulpritResponse) Descriptor deprecated

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

Deprecated: Use PersistCulpritResponse.ProtoReflect.Descriptor instead.

func (*PersistCulpritResponse) GetCulpritIds

func (x *PersistCulpritResponse) GetCulpritIds() []string

func (*PersistCulpritResponse) ProtoMessage

func (*PersistCulpritResponse) ProtoMessage()

func (*PersistCulpritResponse) ProtoReflect

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

func (*PersistCulpritResponse) Reset

func (x *PersistCulpritResponse) Reset()

func (*PersistCulpritResponse) String

func (x *PersistCulpritResponse) String() string

type UnimplementedCulpritServiceServer

type UnimplementedCulpritServiceServer struct {
}

UnimplementedCulpritServiceServer must be embedded to have forward compatible implementations.

func (UnimplementedCulpritServiceServer) GetCulprit

func (UnimplementedCulpritServiceServer) NotifyUserOfAnomaly

func (UnimplementedCulpritServiceServer) NotifyUserOfCulprit

func (UnimplementedCulpritServiceServer) PersistCulprit

type UnsafeCulpritServiceServer

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

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

Directories

Path Synopsis
Code generated by mockery v0.0.0-dev.
Code generated by mockery v0.0.0-dev.

Jump to

Keyboard shortcuts

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