Documentation

Index

Constants

This section is empty.

Variables

View Source
var File_go_chromium_org_luci_luci_notify_api_config_notify_proto protoreflect.FileDescriptor
View Source
var File_go_chromium_org_luci_luci_notify_api_config_settings_proto protoreflect.FileDescriptor

Functions

This section is empty.

Types

type Builder

type Builder struct {

	// Bucket is the buildbucket bucket that the builder is a part of.
	//
	// Required.
	Bucket string `protobuf:"bytes,1,opt,name=bucket,proto3" json:"bucket,omitempty"`
	// Name is the name of the buildbucket builder.
	//
	// Required.
	Name string `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"`
	// Repository is the git repository associated with this particular builder.
	//
	// The repository should look like a URL, e.g.
	// https://chromium.googlesource.com/src
	//
	// Currently, luci-notify only supports Gerrit-like URLs since it checks
	// against gitiles commits, so the URL's path (e.g. "src" in the above
	// example) should map directly to a Gerrit project.
	//
	// Builds attached to the history of this repository will use this
	// repository's git history to determine the order between two builds for the
	// OnChange notification.
	//
	// Optional.
	//
	// If not set, OnChange notifications will derive their notion of
	// "previous" build solely from build creation time, which is potentially
	// less reliable.
	Repository string `protobuf:"bytes,3,opt,name=repository,proto3" json:"repository,omitempty"`
	// contains filtered or unexported fields
}

    Builder references a buildbucket builder in the current project.

    func (*Builder) Descriptor

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

      Deprecated: Use Builder.ProtoReflect.Descriptor instead.

      func (*Builder) GetBucket

      func (x *Builder) GetBucket() string

      func (*Builder) GetName

      func (x *Builder) GetName() string

      func (*Builder) GetRepository

      func (x *Builder) GetRepository() string

      func (*Builder) ProtoMessage

      func (*Builder) ProtoMessage()

      func (*Builder) ProtoReflect

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

      func (*Builder) Reset

      func (x *Builder) Reset()

      func (*Builder) String

      func (x *Builder) String() string

      type GitilesCommits

      type GitilesCommits struct {
      
      	// The Gitiles commits in this collection.
      	Commits []*proto.GitilesCommit `protobuf:"bytes,1,rep,name=commits,proto3" json:"commits,omitempty"`
      	// contains filtered or unexported fields
      }

        A collection of landed Git commits hosted on Gitiles.

        func (*GitilesCommits) Descriptor

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

          Deprecated: Use GitilesCommits.ProtoReflect.Descriptor instead.

          func (*GitilesCommits) FromProperty

          func (p *GitilesCommits) FromProperty(prop datastore.Property) error

            FromProperty implements datastore.PropertyConverter. It parses a '[]byte' into an embedded 'GitilesCommits' when used with the "go.chromium.org/luci/gae" library.

            func (*GitilesCommits) GetCommits

            func (x *GitilesCommits) GetCommits() []*proto.GitilesCommit

            func (*GitilesCommits) ProtoMessage

            func (*GitilesCommits) ProtoMessage()

            func (*GitilesCommits) ProtoReflect

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

            func (*GitilesCommits) Reset

            func (x *GitilesCommits) Reset()

            func (*GitilesCommits) String

            func (x *GitilesCommits) String() string

            func (*GitilesCommits) ToProperty

            func (p *GitilesCommits) ToProperty() (prop datastore.Property, err error)

              ToProperty implements datastore.PropertyConverter. It causes an embedded 'GitilesCommits' to serialize to an unindexed '[]byte' when used with the "go.chromium.org/luci/gae" library.

              type Notification

              type Notification struct {
              
              	// Deprecated. Notify on each build success.
              	OnSuccess bool `protobuf:"varint,1,opt,name=on_success,json=onSuccess,proto3" json:"on_success,omitempty"`
              	// Deprecated. Notify on each build failure.
              	OnFailure bool `protobuf:"varint,2,opt,name=on_failure,json=onFailure,proto3" json:"on_failure,omitempty"`
              	// Deprecated. Notify on each build status different than the previous one.
              	OnChange bool `protobuf:"varint,3,opt,name=on_change,json=onChange,proto3" json:"on_change,omitempty"`
              	// Deprecated. Notify on each build failure unless the previous build was a
              	// failure.
              	OnNewFailure bool `protobuf:"varint,7,opt,name=on_new_failure,json=onNewFailure,proto3" json:"on_new_failure,omitempty"`
              	// Notify on each build with a specified status.
              	OnOccurrence []proto.Status `` /* 132-byte string literal not displayed */
              	// Notify on each build with a specified status different than the previous
              	// one.
              	OnNewStatus []proto.Status `` /* 132-byte string literal not displayed */
              	// Notify only on builds which had a failing step matching this regular
              	// expression. Mutually exclusive with "on_new_status".
              	FailedStepRegexp string `protobuf:"bytes,11,opt,name=failed_step_regexp,json=failedStepRegexp,proto3" json:"failed_step_regexp,omitempty"`
              	// Notify only on builds which don't have a failing step matching this regular
              	// expression. May be combined with "failed_step_regexp", in which case it
              	// must also have a failed step matching that regular expression. Mutually
              	// exclusive with "on_new_status".
              	FailedStepRegexpExclude string `` /* 135-byte string literal not displayed */
              	// Email is the set of email addresses to notify.
              	//
              	// Optional.
              	Email *Notification_Email `protobuf:"bytes,4,opt,name=email,proto3" json:"email,omitempty"`
              	// Refers to which project template name to use to format this email.
              	// If not present, "default" will be used.
              	//
              	// Optional.
              	Template string `protobuf:"bytes,5,opt,name=template,proto3" json:"template,omitempty"`
              	// NotifyBlamelist specifies whether to notify the computed blamelist for a
              	// given build.
              	//
              	// If set, this notification will be sent to the blamelist of a build. Note
              	// that if this is set in multiple notifications pertaining to the same
              	// builder, the blamelist may receive multiple emails.
              	//
              	// Optional.
              	NotifyBlamelist *Notification_Blamelist `protobuf:"bytes,6,opt,name=notify_blamelist,json=notifyBlamelist,proto3" json:"notify_blamelist,omitempty"`
              	// contains filtered or unexported fields
              }

                Notification specifies the triggers to watch for and send notifications on. It also specifies email recipients.

                Next ID: 13.

                func (*Notification) Descriptor

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

                  Deprecated: Use Notification.ProtoReflect.Descriptor instead.

                  func (*Notification) GetEmail

                  func (x *Notification) GetEmail() *Notification_Email

                  func (*Notification) GetFailedStepRegexp

                  func (x *Notification) GetFailedStepRegexp() string

                  func (*Notification) GetFailedStepRegexpExclude

                  func (x *Notification) GetFailedStepRegexpExclude() string

                  func (*Notification) GetNotifyBlamelist

                  func (x *Notification) GetNotifyBlamelist() *Notification_Blamelist

                  func (*Notification) GetOnChange

                  func (x *Notification) GetOnChange() bool

                  func (*Notification) GetOnFailure

                  func (x *Notification) GetOnFailure() bool

                  func (*Notification) GetOnNewFailure

                  func (x *Notification) GetOnNewFailure() bool

                  func (*Notification) GetOnNewStatus

                  func (x *Notification) GetOnNewStatus() []proto.Status

                  func (*Notification) GetOnOccurrence

                  func (x *Notification) GetOnOccurrence() []proto.Status

                  func (*Notification) GetOnSuccess

                  func (x *Notification) GetOnSuccess() bool

                  func (*Notification) GetTemplate

                  func (x *Notification) GetTemplate() string

                  func (*Notification) ProtoMessage

                  func (*Notification) ProtoMessage()

                  func (*Notification) ProtoReflect

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

                  func (*Notification) Reset

                  func (x *Notification) Reset()

                  func (*Notification) String

                  func (x *Notification) String() string

                  type Notification_Blamelist

                  type Notification_Blamelist struct {
                  
                  	// A list of repositories which we are allowed to be included as part of the
                  	// blamelist. If unset, a blamelist will be computed based on a Builder's
                  	// repository field. If set, however luci-notify computes the blamelist for
                  	// all commits related to a build (which may span multiple repositories)
                  	// which are part of repository in this repository allowlist.
                  	//
                  	// Repositories should be valid Gerrit/Gitiles repository URLs, such as
                  	// https://chromium.googlesource.com/chromium/src
                  	// Optional
                  	RepositoryAllowlist []string `protobuf:"bytes,2,rep,name=repository_allowlist,json=repositoryAllowlist,proto3" json:"repository_allowlist,omitempty"`
                  	// contains filtered or unexported fields
                  }

                    Blamelist is a message representing configuration for notifying the blamelist.

                    func (*Notification_Blamelist) Descriptor

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

                      Deprecated: Use Notification_Blamelist.ProtoReflect.Descriptor instead.

                      func (*Notification_Blamelist) GetRepositoryAllowlist

                      func (x *Notification_Blamelist) GetRepositoryAllowlist() []string

                      func (*Notification_Blamelist) ProtoMessage

                      func (*Notification_Blamelist) ProtoMessage()

                      func (*Notification_Blamelist) ProtoReflect

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

                      func (*Notification_Blamelist) Reset

                      func (x *Notification_Blamelist) Reset()

                      func (*Notification_Blamelist) String

                      func (x *Notification_Blamelist) String() string

                      type Notification_Email

                      type Notification_Email struct {
                      
                      	// Recipients is a list of email addresses to notify.
                      	Recipients []string `protobuf:"bytes,1,rep,name=recipients,proto3" json:"recipients,omitempty"`
                      	// A list of rotations, for each of which we should notify the currently
                      	// active member.
                      	RotationUrls []string `protobuf:"bytes,3,rep,name=rotation_urls,json=rotationUrls,proto3" json:"rotation_urls,omitempty"`
                      	// contains filtered or unexported fields
                      }

                        Email is a message representing a set of mail recipients.

                        func (*Notification_Email) Descriptor

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

                          Deprecated: Use Notification_Email.ProtoReflect.Descriptor instead.

                          func (*Notification_Email) GetRecipients

                          func (x *Notification_Email) GetRecipients() []string

                          func (*Notification_Email) GetRotationUrls

                          func (x *Notification_Email) GetRotationUrls() []string

                          func (*Notification_Email) ProtoMessage

                          func (*Notification_Email) ProtoMessage()

                          func (*Notification_Email) ProtoReflect

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

                          func (*Notification_Email) Reset

                          func (x *Notification_Email) Reset()

                          func (*Notification_Email) String

                          func (x *Notification_Email) String() string

                          type Notifications

                          type Notifications struct {
                          
                          	// Notifications is a list of notification configurations.
                          	Notifications []*Notification `protobuf:"bytes,1,rep,name=notifications,proto3" json:"notifications,omitempty"`
                          	// contains filtered or unexported fields
                          }

                            Notifications encapsulates a list of notifications as a proto so code for storing it in the datastore may be generated.

                            func (*Notifications) Descriptor

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

                              Deprecated: Use Notifications.ProtoReflect.Descriptor instead.

                              func (*Notifications) FromProperty

                              func (p *Notifications) FromProperty(prop datastore.Property) error

                                FromProperty implements datastore.PropertyConverter. It parses a '[]byte' into an embedded 'Notifications' when used with the "go.chromium.org/luci/gae" library.

                                func (*Notifications) GetNotifications

                                func (x *Notifications) GetNotifications() []*Notification

                                func (*Notifications) ProtoMessage

                                func (*Notifications) ProtoMessage()

                                func (*Notifications) ProtoReflect

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

                                func (*Notifications) Reset

                                func (x *Notifications) Reset()

                                func (*Notifications) String

                                func (x *Notifications) String() string

                                func (*Notifications) ToProperty

                                func (p *Notifications) ToProperty() (prop datastore.Property, err error)

                                  ToProperty implements datastore.PropertyConverter. It causes an embedded 'Notifications' to serialize to an unindexed '[]byte' when used with the "go.chromium.org/luci/gae" library.

                                  type Notifier

                                  type Notifier struct {
                                  
                                  	// Name is an identifier for the notifier which must be unique within a
                                  	// project.
                                  	//
                                  	// Name must additionally match ^[a-z\-]+$, meaning it must only
                                  	// use an alphabet of lowercase characters and hyphens.
                                  	//
                                  	// Required.
                                  	Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
                                  	// Notifications is a list of notification configurations.
                                  	Notifications []*Notification `protobuf:"bytes,2,rep,name=notifications,proto3" json:"notifications,omitempty"`
                                  	// Builders is a list of buildbucket builders this Notifier should watch.
                                  	Builders []*Builder `protobuf:"bytes,3,rep,name=builders,proto3" json:"builders,omitempty"`
                                  	// A list of tree closing rules to execute for this notifier.
                                  	TreeClosers []*TreeCloser `protobuf:"bytes,4,rep,name=tree_closers,json=treeClosers,proto3" json:"tree_closers,omitempty"`
                                  	// contains filtered or unexported fields
                                  }

                                    Notifier contains a set of notification configurations (which specify triggers to send notifications on) and a set of builders that will be watched for these triggers.

                                    func (*Notifier) Descriptor

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

                                      Deprecated: Use Notifier.ProtoReflect.Descriptor instead.

                                      func (*Notifier) GetBuilders

                                      func (x *Notifier) GetBuilders() []*Builder

                                      func (*Notifier) GetName

                                      func (x *Notifier) GetName() string

                                      func (*Notifier) GetNotifications

                                      func (x *Notifier) GetNotifications() []*Notification

                                      func (*Notifier) GetTreeClosers

                                      func (x *Notifier) GetTreeClosers() []*TreeCloser

                                      func (*Notifier) ProtoMessage

                                      func (*Notifier) ProtoMessage()

                                      func (*Notifier) ProtoReflect

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

                                      func (*Notifier) Reset

                                      func (x *Notifier) Reset()

                                      func (*Notifier) String

                                      func (x *Notifier) String() string

                                      type ProjectConfig

                                      type ProjectConfig struct {
                                      
                                      	// Notifiers is a list of Notifiers which watch builders and send
                                      	// notifications for this project.
                                      	Notifiers []*Notifier `protobuf:"bytes,1,rep,name=notifiers,proto3" json:"notifiers,omitempty"`
                                      	// If false, then LUCI-Notify won't actually close trees, only log what
                                      	// actions it would have taken.
                                      	TreeClosingEnabled bool `protobuf:"varint,2,opt,name=tree_closing_enabled,json=treeClosingEnabled,proto3" json:"tree_closing_enabled,omitempty"`
                                      	// contains filtered or unexported fields
                                      }

                                        ProjectConfig is a luci-notify configuration for a particular project.

                                        func (*ProjectConfig) Descriptor

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

                                          Deprecated: Use ProjectConfig.ProtoReflect.Descriptor instead.

                                          func (*ProjectConfig) GetNotifiers

                                          func (x *ProjectConfig) GetNotifiers() []*Notifier

                                          func (*ProjectConfig) GetTreeClosingEnabled

                                          func (x *ProjectConfig) GetTreeClosingEnabled() bool

                                          func (*ProjectConfig) ProtoMessage

                                          func (*ProjectConfig) ProtoMessage()

                                          func (*ProjectConfig) ProtoReflect

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

                                          func (*ProjectConfig) Reset

                                          func (x *ProjectConfig) Reset()

                                          func (*ProjectConfig) String

                                          func (x *ProjectConfig) String() string

                                          type Settings

                                          type Settings struct {
                                          
                                          	// MiloHost is the hostname of the Milo instance luci-notify queries for
                                          	// additional build information.
                                          	//
                                          	// Required.
                                          	MiloHost string `protobuf:"bytes,1,opt,name=milo_host,json=miloHost,proto3" json:"milo_host,omitempty"`
                                          	// contains filtered or unexported fields
                                          }

                                            Settings is the top-level configuration message.

                                            func (*Settings) Descriptor

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

                                              Deprecated: Use Settings.ProtoReflect.Descriptor instead.

                                              func (*Settings) GetMiloHost

                                              func (x *Settings) GetMiloHost() string

                                              func (*Settings) ProtoMessage

                                              func (*Settings) ProtoMessage()

                                              func (*Settings) ProtoReflect

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

                                              func (*Settings) Reset

                                              func (x *Settings) Reset()

                                              func (*Settings) String

                                              func (x *Settings) String() string

                                              type TemplateInput

                                              type TemplateInput struct {
                                              
                                              	// Buildbucket hostname, e.g. "cr-buildbucket.appspot.com".
                                              	BuildbucketHostname string `protobuf:"bytes,1,opt,name=buildbucket_hostname,json=buildbucketHostname,proto3" json:"buildbucket_hostname,omitempty"`
                                              	// The completed build.
                                              	Build *proto.Build `protobuf:"bytes,2,opt,name=build,proto3" json:"build,omitempty"`
                                              	// State of the previous build in this builder.
                                              	OldStatus proto.Status `protobuf:"varint,3,opt,name=old_status,json=oldStatus,proto3,enum=buildbucket.v2.Status" json:"old_status,omitempty"`
                                              	// The failed steps that passed the given regexes (see the fields
                                              	// "failed_step_regexp" and "failed_step_regexp_exclude" above). If that field
                                              	// wasn't supplied, this will be empty.
                                              	MatchingFailedSteps []*proto.Step `protobuf:"bytes,4,rep,name=matching_failed_steps,json=matchingFailedSteps,proto3" json:"matching_failed_steps,omitempty"`
                                              	// contains filtered or unexported fields
                                              }

                                                Input to an email template.

                                                func (*TemplateInput) Descriptor

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

                                                  Deprecated: Use TemplateInput.ProtoReflect.Descriptor instead.

                                                  func (*TemplateInput) GetBuild

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

                                                  func (*TemplateInput) GetBuildbucketHostname

                                                  func (x *TemplateInput) GetBuildbucketHostname() string

                                                  func (*TemplateInput) GetMatchingFailedSteps

                                                  func (x *TemplateInput) GetMatchingFailedSteps() []*proto.Step

                                                  func (*TemplateInput) GetOldStatus

                                                  func (x *TemplateInput) GetOldStatus() proto.Status

                                                  func (*TemplateInput) ProtoMessage

                                                  func (*TemplateInput) ProtoMessage()

                                                  func (*TemplateInput) ProtoReflect

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

                                                  func (*TemplateInput) Reset

                                                  func (x *TemplateInput) Reset()

                                                  func (*TemplateInput) String

                                                  func (x *TemplateInput) String() string

                                                  type TreeCloser

                                                  type TreeCloser struct {
                                                  
                                                  	// The hostname of the tree-status instance which this rule opens and closes.
                                                  	TreeStatusHost string `protobuf:"bytes,1,opt,name=tree_status_host,json=treeStatusHost,proto3" json:"tree_status_host,omitempty"`
                                                  	// Close the tree only on builds which had a failing step matching this
                                                  	// regular expression.
                                                  	FailedStepRegexp string `protobuf:"bytes,2,opt,name=failed_step_regexp,json=failedStepRegexp,proto3" json:"failed_step_regexp,omitempty"`
                                                  	// Close the tree only on builds which don't have a failing step matching this
                                                  	// regular expression. May be combined with "failed_step_regexp", in which
                                                  	// case it must also have a failed step matching that regular expression.
                                                  	FailedStepRegexpExclude string `` /* 134-byte string literal not displayed */
                                                  	// Refers to which project template name to use to format this email.
                                                  	// If not present, "default_tree_status" will be used.
                                                  	Template string `protobuf:"bytes,4,opt,name=template,proto3" json:"template,omitempty"`
                                                  	// contains filtered or unexported fields
                                                  }

                                                    TreeCloser represents an action which closes a tree, by interfacing with an instance of the tree-status app.

                                                    func (*TreeCloser) Descriptor

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

                                                      Deprecated: Use TreeCloser.ProtoReflect.Descriptor instead.

                                                      func (*TreeCloser) FromProperty

                                                      func (p *TreeCloser) FromProperty(prop datastore.Property) error

                                                        FromProperty implements datastore.PropertyConverter. It parses a '[]byte' into an embedded 'TreeCloser' when used with the "go.chromium.org/luci/gae" library.

                                                        func (*TreeCloser) GetFailedStepRegexp

                                                        func (x *TreeCloser) GetFailedStepRegexp() string

                                                        func (*TreeCloser) GetFailedStepRegexpExclude

                                                        func (x *TreeCloser) GetFailedStepRegexpExclude() string

                                                        func (*TreeCloser) GetTemplate

                                                        func (x *TreeCloser) GetTemplate() string

                                                        func (*TreeCloser) GetTreeStatusHost

                                                        func (x *TreeCloser) GetTreeStatusHost() string

                                                        func (*TreeCloser) ProtoMessage

                                                        func (*TreeCloser) ProtoMessage()

                                                        func (*TreeCloser) ProtoReflect

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

                                                        func (*TreeCloser) Reset

                                                        func (x *TreeCloser) Reset()

                                                        func (*TreeCloser) String

                                                        func (x *TreeCloser) String() string

                                                        func (*TreeCloser) ToProperty

                                                        func (p *TreeCloser) ToProperty() (prop datastore.Property, err error)

                                                          ToProperty implements datastore.PropertyConverter. It causes an embedded 'TreeCloser' to serialize to an unindexed '[]byte' when used with the "go.chromium.org/luci/gae" library.