Documentation
¶
Overview ¶
Package client is for the external clients that Sheriff-o-Matic needs.
Index ¶
- func BuildersClient(c context.Context) (buildbucketpb.BuildersClient, error)
- func GetGitiles(c context.Context, URL string) ([]byte, error)
- func GetGitilesCached(c context.Context, URL string) ([]byte, error)
- func ListBuildersByBucket(c context.Context, client BBBuildersClient, project string, bucket string) ([]*buildbucketpb.BuilderItem, error)
- func NewBisectionServiceClient(c context.Context, host string) (bisectionpb.AnalysesClient, error)
- func ProdClients(ctx context.Context) (CrBug, Bisection)
- func StagingClients(ctx context.Context) (CrBug, Bisection)
- type BBBuildersClient
- type Bisection
- type BisectionClient
- func (cl *BisectionClient) BatchGetTestAnalyses(c context.Context, req *bisectionpb.BatchGetTestAnalysesRequest) (*bisectionpb.BatchGetTestAnalysesResponse, error)
- func (cl *BisectionClient) QueryBisectionResults(c context.Context, bbid int64, stepName string) (*bisectionpb.QueryAnalysisResponse, error)
- type CrBug
- type CrBugs
- type CrRev
- type Test
- type Writer
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func BuildersClient ¶
func BuildersClient(c context.Context) (buildbucketpb.BuildersClient, error)
BuildersClient returns a buildbucketpb.BuildersClient.
func GetGitiles ¶
GetGitiles fetches gitiles raw text content with required authentication headers. Note that this currently only works from AppEngine due to gaeauth dependencies.
func GetGitilesCached ¶
GetGitilesCached fetches gitiles content through memcache. Note that this currently only works from AppEngine due to memcache and gaeauth dependencies.
func ListBuildersByBucket ¶
func ListBuildersByBucket(c context.Context, client BBBuildersClient, project string, bucket string) ([]*buildbucketpb.BuilderItem, error)
ListBuildersByBucket queries BuildBucket for a list of builders for a bucket.
func NewBisectionServiceClient ¶
func NewBisectionServiceClient(c context.Context, host string) (bisectionpb.AnalysesClient, error)
func ProdClients ¶
ProdClients returns a set of service clients pointed at production.
Types ¶
type BBBuildersClient ¶
type BBBuildersClient interface {
ListBuilders(c context.Context, in *buildbucketpb.ListBuildersRequest, opts ...grpc.CallOption) (*buildbucketpb.ListBuildersResponse, error)
}
BBBuildersClient is for testing purpose.
type Bisection ¶
type Bisection interface { QueryBisectionResults(c context.Context, bbid int64, stepName string) (*bisectionpb.QueryAnalysisResponse, error) BatchGetTestAnalyses(c context.Context, req *bisectionpb.BatchGetTestAnalysesRequest) (*bisectionpb.BatchGetTestAnalysesResponse, error) }
Bisection returns information about failures that LUCI Bisection analyzes
type BisectionClient ¶
type BisectionClient struct {
ServiceClient bisectionpb.AnalysesClient
}
func (*BisectionClient) BatchGetTestAnalyses ¶
func (cl *BisectionClient) BatchGetTestAnalyses(c context.Context, req *bisectionpb.BatchGetTestAnalysesRequest) (*bisectionpb.BatchGetTestAnalysesResponse, error)
func (*BisectionClient) QueryBisectionResults ¶
func (cl *BisectionClient) QueryBisectionResults(c context.Context, bbid int64, stepName string) (*bisectionpb.QueryAnalysisResponse, error)
type CrBug ¶
type CrBug interface { // CrBugItems returns issue matching label. CrbugItems(ctx context.Context, label string) ([]messages.CrbugItem, error) }
CrBug returns bug information.
type CrBugs ¶
type CrBugs struct {
// contains filtered or unexported fields
}
CrBugs is a minimal Monorail client for fetching issues.
type CrRev ¶
type CrRev interface { // GetRedirect gets the redirect for a commit position. GetRedirect(c context.Context, pos string) (map[string]string, error) }
CrRev returns redirects for commit positions.
type Test ¶
type Test struct {
Builders []string `json:"builders"`
}
Test represents information about Tests in a builder group.