listenerpb

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

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

Go to latest
Published: May 4, 2024 License: Apache-2.0 Imports: 17 Imported by: 0

Documentation

Overview

Package listenerpb controls the settings for LUCI CV listener.

Index

Constants

This section is empty.

Variables

View Source
var (
	Settings_GerritSubscription_MessageFormat_name = map[int32]string{
		0: "MESSAGE_FORMAT_UNSPECIFIED",
		1: "JSON",
		2: "PROTO_BINARY",
	}
	Settings_GerritSubscription_MessageFormat_value = map[string]int32{
		"MESSAGE_FORMAT_UNSPECIFIED": 0,
		"JSON":                       1,
		"PROTO_BINARY":               2,
	}
)

Enum value maps for Settings_GerritSubscription_MessageFormat.

View Source
var File_go_chromium_org_luci_cv_settings_listener_settings_proto protoreflect.FileDescriptor

Functions

This section is empty.

Types

type Settings

type Settings struct {

	// Subscriptions for the Gerrit hosts that have enabled Gerrit Pub/Sub.
	//
	// To enable Gerrit pub/sub for a given LUCI project, the subscription of
	// all the Gerrit hosts listed in the project config must be added in this
	// field. If not, the config validation will fail.
	GerritSubscriptions []*Settings_GerritSubscription `protobuf:"bytes,1,rep,name=gerrit_subscriptions,json=gerritSubscriptions,proto3" json:"gerrit_subscriptions,omitempty"`
	// If a LUCI Project matches any of the regexps, CV will use the pubsub
	// listener to find changes in the Gerrit hosts listed in the project config.
	//
	// If not, CV will use the incremental poller to find changes in the Gerrit
	// hosts.
	//
	// Deprecated: Marked as deprecated in go.chromium.org/luci/cv/settings/listener/settings.proto.
	EnabledProjectRegexps []string `` /* 126-byte string literal not displayed */
	// If a LUCI Project matches any of the regexps, CV will not use the pubsub
	// listener to find changes in the Gerrit hosts listed in the project config.
	//
	// Instead, CV will use the incremental poller to find changes from the Gerrit
	// hosts.
	DisabledProjectRegexps []string `` /* 129-byte string literal not displayed */
	// contains filtered or unexported fields
}

Settings defines fields for configuring listener settings.

func (*Settings) Descriptor deprecated

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

Deprecated: Use Settings.ProtoReflect.Descriptor instead.

func (*Settings) GetDisabledProjectRegexps

func (x *Settings) GetDisabledProjectRegexps() []string

func (*Settings) GetEnabledProjectRegexps deprecated

func (x *Settings) GetEnabledProjectRegexps() []string

Deprecated: Marked as deprecated in go.chromium.org/luci/cv/settings/listener/settings.proto.

func (*Settings) GetGerritSubscriptions

func (x *Settings) GetGerritSubscriptions() []*Settings_GerritSubscription

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

func (*Settings) Validate

func (m *Settings) Validate() error

Validate checks the field values on Settings with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*Settings) ValidateAll

func (m *Settings) ValidateAll() error

ValidateAll checks the field values on Settings with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in SettingsMultiError, or nil if none found.

type SettingsMultiError

type SettingsMultiError []error

SettingsMultiError is an error wrapping multiple validation errors returned by Settings.ValidateAll() if the designated constraints aren't met.

func (SettingsMultiError) AllErrors

func (m SettingsMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (SettingsMultiError) Error

func (m SettingsMultiError) Error() string

Error returns a concatenation of all the error messages it wraps.

type SettingsValidationError

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

SettingsValidationError is the validation error returned by Settings.Validate if the designated constraints aren't met.

func (SettingsValidationError) Cause

func (e SettingsValidationError) Cause() error

Cause function returns cause value.

func (SettingsValidationError) Error

func (e SettingsValidationError) Error() string

Error satisfies the builtin error interface

func (SettingsValidationError) ErrorName

func (e SettingsValidationError) ErrorName() string

ErrorName returns error name.

func (SettingsValidationError) Field

func (e SettingsValidationError) Field() string

Field function returns field value.

func (SettingsValidationError) Key

func (e SettingsValidationError) Key() bool

Key function returns key value.

func (SettingsValidationError) Reason

func (e SettingsValidationError) Reason() string

Reason function returns reason value.

type Settings_GerritSubscription

type Settings_GerritSubscription struct {

	// The Gerrit host w/o scheme.
	// For example, chromium-review.googlesource.com
	Host string `protobuf:"bytes,1,opt,name=host,proto3" json:"host,omitempty"`
	// The subscription ID of the host. If unset, `host` is the subscription ID.
	//
	// Note that this is subscription ID, not subscription name.
	// Subscription name is the full path of a subscription in the format of
	// projects/$project/subscription/$sub_id.
	SubscriptionId string `protobuf:"bytes,2,opt,name=subscription_id,json=subscriptionId,proto3" json:"subscription_id,omitempty"`
	// Configuration for the pubsub receive function.
	ReceiveSettings *Settings_ReceiveSettings `protobuf:"bytes,3,opt,name=receive_settings,json=receiveSettings,proto3" json:"receive_settings,omitempty"`
	// The format of the pubsub payload.
	//
	// Must not be MESSAGE_FORMAT_UNSPECIFIED.
	MessageFormat Settings_GerritSubscription_MessageFormat `` /* 157-byte string literal not displayed */
	// contains filtered or unexported fields
}

func (*Settings_GerritSubscription) Descriptor deprecated

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

Deprecated: Use Settings_GerritSubscription.ProtoReflect.Descriptor instead.

func (*Settings_GerritSubscription) GetHost

func (x *Settings_GerritSubscription) GetHost() string

func (*Settings_GerritSubscription) GetMessageFormat

func (*Settings_GerritSubscription) GetReceiveSettings

func (x *Settings_GerritSubscription) GetReceiveSettings() *Settings_ReceiveSettings

func (*Settings_GerritSubscription) GetSubscriptionId

func (x *Settings_GerritSubscription) GetSubscriptionId() string

func (*Settings_GerritSubscription) ProtoMessage

func (*Settings_GerritSubscription) ProtoMessage()

func (*Settings_GerritSubscription) ProtoReflect

func (*Settings_GerritSubscription) Reset

func (x *Settings_GerritSubscription) Reset()

func (*Settings_GerritSubscription) String

func (x *Settings_GerritSubscription) String() string

func (*Settings_GerritSubscription) Validate

func (m *Settings_GerritSubscription) Validate() error

Validate checks the field values on Settings_GerritSubscription with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*Settings_GerritSubscription) ValidateAll

func (m *Settings_GerritSubscription) ValidateAll() error

ValidateAll checks the field values on Settings_GerritSubscription with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in Settings_GerritSubscriptionMultiError, or nil if none found.

type Settings_GerritSubscriptionMultiError

type Settings_GerritSubscriptionMultiError []error

Settings_GerritSubscriptionMultiError is an error wrapping multiple validation errors returned by Settings_GerritSubscription.ValidateAll() if the designated constraints aren't met.

func (Settings_GerritSubscriptionMultiError) AllErrors

AllErrors returns a list of validation violation errors.

func (Settings_GerritSubscriptionMultiError) Error

Error returns a concatenation of all the error messages it wraps.

type Settings_GerritSubscriptionValidationError

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

Settings_GerritSubscriptionValidationError is the validation error returned by Settings_GerritSubscription.Validate if the designated constraints aren't met.

func (Settings_GerritSubscriptionValidationError) Cause

Cause function returns cause value.

func (Settings_GerritSubscriptionValidationError) Error

Error satisfies the builtin error interface

func (Settings_GerritSubscriptionValidationError) ErrorName

ErrorName returns error name.

func (Settings_GerritSubscriptionValidationError) Field

Field function returns field value.

func (Settings_GerritSubscriptionValidationError) Key

Key function returns key value.

func (Settings_GerritSubscriptionValidationError) Reason

Reason function returns reason value.

type Settings_GerritSubscription_MessageFormat

type Settings_GerritSubscription_MessageFormat int32
const (
	Settings_GerritSubscription_MESSAGE_FORMAT_UNSPECIFIED Settings_GerritSubscription_MessageFormat = 0
	Settings_GerritSubscription_JSON                       Settings_GerritSubscription_MessageFormat = 1
	Settings_GerritSubscription_PROTO_BINARY               Settings_GerritSubscription_MessageFormat = 2
)

func (Settings_GerritSubscription_MessageFormat) Descriptor

func (Settings_GerritSubscription_MessageFormat) Enum

func (Settings_GerritSubscription_MessageFormat) EnumDescriptor deprecated

func (Settings_GerritSubscription_MessageFormat) EnumDescriptor() ([]byte, []int)

Deprecated: Use Settings_GerritSubscription_MessageFormat.Descriptor instead.

func (Settings_GerritSubscription_MessageFormat) Number

func (Settings_GerritSubscription_MessageFormat) String

func (Settings_GerritSubscription_MessageFormat) Type

type Settings_ReceiveSettings

type Settings_ReceiveSettings struct {

	// The number of goroutines that Listener will spawn for the subscription.
	//
	// 10, if unset.
	//
	// This doesn't limit the number of buffered messages that are waiting to
	// be processed or are being processed.
	//
	// Use max_outstanding_messages to limit he number of buffered messages.
	NumGoroutines uint64 `protobuf:"varint,1,opt,name=num_goroutines,json=numGoroutines,proto3" json:"num_goroutines,omitempty"`
	// The maximum number of unacknowledged but not yet expired messages.
	//
	// 1000, if unset.
	// If < 0, there will be no limit.
	MaxOutstandingMessages int64 `` /* 130-byte string literal not displayed */
	// contains filtered or unexported fields
}

func (*Settings_ReceiveSettings) Descriptor deprecated

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

Deprecated: Use Settings_ReceiveSettings.ProtoReflect.Descriptor instead.

func (*Settings_ReceiveSettings) GetMaxOutstandingMessages

func (x *Settings_ReceiveSettings) GetMaxOutstandingMessages() int64

func (*Settings_ReceiveSettings) GetNumGoroutines

func (x *Settings_ReceiveSettings) GetNumGoroutines() uint64

func (*Settings_ReceiveSettings) ProtoMessage

func (*Settings_ReceiveSettings) ProtoMessage()

func (*Settings_ReceiveSettings) ProtoReflect

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

func (*Settings_ReceiveSettings) Reset

func (x *Settings_ReceiveSettings) Reset()

func (*Settings_ReceiveSettings) String

func (x *Settings_ReceiveSettings) String() string

func (*Settings_ReceiveSettings) Validate

func (m *Settings_ReceiveSettings) Validate() error

Validate checks the field values on Settings_ReceiveSettings with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*Settings_ReceiveSettings) ValidateAll

func (m *Settings_ReceiveSettings) ValidateAll() error

ValidateAll checks the field values on Settings_ReceiveSettings with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in Settings_ReceiveSettingsMultiError, or nil if none found.

type Settings_ReceiveSettingsMultiError

type Settings_ReceiveSettingsMultiError []error

Settings_ReceiveSettingsMultiError is an error wrapping multiple validation errors returned by Settings_ReceiveSettings.ValidateAll() if the designated constraints aren't met.

func (Settings_ReceiveSettingsMultiError) AllErrors

func (m Settings_ReceiveSettingsMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (Settings_ReceiveSettingsMultiError) Error

Error returns a concatenation of all the error messages it wraps.

type Settings_ReceiveSettingsValidationError

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

Settings_ReceiveSettingsValidationError is the validation error returned by Settings_ReceiveSettings.Validate if the designated constraints aren't met.

func (Settings_ReceiveSettingsValidationError) Cause

Cause function returns cause value.

func (Settings_ReceiveSettingsValidationError) Error

Error satisfies the builtin error interface

func (Settings_ReceiveSettingsValidationError) ErrorName

ErrorName returns error name.

func (Settings_ReceiveSettingsValidationError) Field

Field function returns field value.

func (Settings_ReceiveSettingsValidationError) Key

Key function returns key value.

func (Settings_ReceiveSettingsValidationError) Reason

Reason function returns reason value.

Jump to

Keyboard shortcuts

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