utils

package
v0.14.0 Latest Latest
Warning

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

Go to latest
Published: Sep 23, 2024 License: Apache-2.0 Imports: 12 Imported by: 8

Documentation

Index

Constants

View Source
const (
	BatchsourceConfigKey    string = "__BATCHSOURCECONFIGS__"
	BatchsourceClassnameKey string = "__BATCHSOURCECLASSNAME__"
)
View Source
const (
	JavaRuntime   = "JAVA"
	PythonRuntime = "PYTHON"
	GoRuntime     = "GO"
)
View Source
const (
	FirstBoundary string = "0x00000000"
	LastBoundary  string = "0xffffffff"
)
View Source
const (
	PUBLICTENANT           = "public"
	DEFAULTNAMESPACE       = "default"
	PARTITIONEDTOPICSUFFIX = "-partition-"
)
View Source
const WindowConfigKey = "__WINDOWCONFIGS__"

Variables

View Source
var Earliest = MessageID{-1, -1, -1, -1}
View Source
var Latest = MessageID{0x7fffffffffffffff, 0x7fffffffffffffff, -1, -1}

Functions

func CheckName

func CheckName(name string) bool

func ConvertSchemaDataToStringLegacy added in v0.13.0

func ConvertSchemaDataToStringLegacy(schemaInfo SchemaInfo) string

func GetConfigPath

func GetConfigPath() string

func HomeDir

func HomeDir() string

HomeDir returns the home directory for the current user. On Windows: 1. the first of %HOME%, %HOMEDRIVE%%HOMEPATH%, %USERPROFILE% containing a `.pulsar\config` file is returned. 2. if none of those locations contain a `.pulsar\config` file, the first of %HOME%, %USERPROFILE%, %HOMEDRIVE%%HOMEPATH% that exists and is writeable is returned. 3. if none of those locations are writeable, the first of %HOME%, %USERPROFILE%, %HOMEDRIVE%%HOMEPATH% that exists is returned. 4. if none of those locations exists, the first of %HOME%, %USERPROFILE%, %HOMEDRIVE%%HOMEPATH% that is set is returned.

func IsNilFixed

func IsNilFixed(i interface{}) bool

func MakeHTTPPath

func MakeHTTPPath(apiVersion string, componentPath string) string

Types

type AllocatorStats

type AllocatorStats struct {
	NumDirectArenas      int              `json:"numDirectArenas"`
	NumHeapArenas        int              `json:"numHeapArenas"`
	NumThreadLocalCaches int              `json:"numThreadLocalCaches"`
	NormalCacheSize      int              `json:"normalCacheSize"`
	SmallCacheSize       int              `json:"smallCacheSize"`
	TinyCacheSize        int              `json:"tinyCacheSize"`
	DirectArenas         []PoolArenaStats `json:"directArenas"`
	HeapArenas           []PoolArenaStats `json:"heapArenas"`
}

type AuthAction

type AuthAction string

func ParseAuthAction

func ParseAuthAction(action string) (AuthAction, error)

func (AuthAction) String

func (a AuthAction) String() string

type AuthPolicies

type AuthPolicies struct {
	NamespaceAuth         map[string][]AuthAction            `json:"namespace_auth"`
	DestinationAuth       map[string]map[string][]AuthAction `json:"destination_auth"`
	SubscriptionAuthRoles map[string][]string                `json:"subscription_auth_roles"`
}

func NewAuthPolicies

func NewAuthPolicies() *AuthPolicies

type AutoFailoverPolicyData

type AutoFailoverPolicyData struct {
	PolicyType AutoFailoverPolicyType `json:"policy_type"`
	Parameters map[string]string      `json:"parameters"`
}

type AutoFailoverPolicyType

type AutoFailoverPolicyType string
const (
	MinAvailable AutoFailoverPolicyType = "min_available"
)

type BacklogQuota

type BacklogQuota struct {
	LimitTime int64           `json:"limitTime"`
	LimitSize int64           `json:"limitSize"`
	Policy    RetentionPolicy `json:"policy"`
}

func NewBacklogQuota

func NewBacklogQuota(limitSize int64, limitTime int64, policy RetentionPolicy) BacklogQuota

type BacklogQuotaType

type BacklogQuotaType string
const (
	DestinationStorage BacklogQuotaType = "destination_storage"
	MessageAge         BacklogQuotaType = "message_age"
)

func ParseBacklogQuotaType

func ParseBacklogQuotaType(str string) (BacklogQuotaType, error)

func (BacklogQuotaType) String

func (b BacklogQuotaType) String() string

type BatchSourceConfig

type BatchSourceConfig struct {
	DiscoveryTriggererClassName string `json:"discoveryTriggererClassName" yaml:"discoveryTriggererClassName"`

	DiscoveryTriggererConfig map[string]interface{} `json:"discoveryTriggererConfig" yaml:"discoveryTriggererConfig"`
}

type BookieAffinityGroupData

type BookieAffinityGroupData struct {
	BookkeeperAffinityGroupPrimary   string `json:"bookkeeperAffinityGroupPrimary"`
	BookkeeperAffinityGroupSecondary string `json:"bookkeeperAffinityGroupSecondary"`
}

type BrokerAssignment

type BrokerAssignment string
const (
	Primary   BrokerAssignment = "primary"
	Secondary BrokerAssignment = "secondary"
	Shared    BrokerAssignment = "shared"
)

type BrokerData

type BrokerData struct {
	URL         string `json:"brokerUrl"`
	ConfigName  string `json:"configName"`
	ConfigValue string `json:"configValue"`
}

type BrokerInfo added in v0.13.0

type BrokerInfo struct {
	BrokerID   string `json:"brokerId"`
	ServiceURL string `json:"serviceUrl"`
}

type BrokerNamespaceIsolationData

type BrokerNamespaceIsolationData struct {
	BrokerName     string   `json:"brokerName"`
	PolicyName     string   `json:"policyName"`
	IsPrimary      bool     `json:"isPrimary"`
	NamespaceRegex []string `json:"namespaceRegex"`
}

type BrokerStatsData

type BrokerStatsData struct {
	Indent bool `json:"indent"`
}

type BundlesData

type BundlesData struct {
	Boundaries []string `json:"boundaries"`
	NumBundles int      `json:"numBundles"`
}

func NewBundlesData

func NewBundlesData(boundaries []string) BundlesData

func NewBundlesDataWithNumBundles

func NewBundlesDataWithNumBundles(numBundles int) *BundlesData

func NewDefaultBoundle

func NewDefaultBoundle() *BundlesData

type ClusterData

type ClusterData struct {
	Name                           string   `json:"-"`
	ServiceURL                     string   `json:"serviceUrl"`
	ServiceURLTls                  string   `json:"serviceUrlTls"`
	BrokerServiceURL               string   `json:"brokerServiceUrl"`
	BrokerServiceURLTls            string   `json:"brokerServiceUrlTls"`
	PeerClusterNames               []string `json:"peerClusterNames"`
	AuthenticationPlugin           string   `json:"authenticationPlugin"`
	AuthenticationParameters       string   `json:"authenticationParameters"`
	BrokerClientTrustCertsFilePath string   `json:"brokerClientTrustCertsFilePath"`
	BrokerClientTLSEnabled         bool     `json:"brokerClientTlsEnabled"`
}

ClusterData information on a cluster

type CompactedLedger

type CompactedLedger struct {
	LedgerID        int64 `json:"ledgerId"`
	Entries         int64 `json:"entries"`
	Size            int64 `json:"size"`
	Offloaded       bool  `json:"offloaded"`
	UnderReplicated bool  `json:"underReplicated"`
}

type ConnectorDefinition

type ConnectorDefinition struct {
	// The name of the connector type
	Name string `json:"name"`

	// Description to be used for user help
	Description string `json:"description"`

	// The class name for the connector source implementation
	// <p>If not defined, it will be assumed this connector cannot act as a data source
	SourceClass string `json:"sourceClass"`

	// The class name for the connector sink implementation
	// <p>If not defined, it will be assumed this connector cannot act as a data sink
	SinkClass string `json:"sinkClass"`
}

Basic information about a Pulsar connector

type ConsumerConfig

type ConsumerConfig struct {
	SchemaType         string            `json:"schemaType,omitempty" yaml:"schemaType"`
	SerdeClassName     string            `json:"serdeClassName,omitempty" yaml:"serdeClassName"`
	RegexPattern       bool              `json:"regexPattern,omitempty" yaml:"regexPattern"`
	ReceiverQueueSize  int               `json:"receiverQueueSize,omitempty" yaml:"receiverQueueSize"`
	SchemaProperties   map[string]string `json:"schemaProperties,omitempty" yaml:"schemaProperties"`
	ConsumerProperties map[string]string `json:"consumerProperties,omitempty" yaml:"consumerProperties"`
	CryptoConfig       *CryptoConfig     `json:"cryptoConfig,omitempty" yaml:"cryptoConfig"`
	PoolMessages       bool              `json:"poolMessages,omitempty" yaml:"poolMessages"`
}

type ConsumerStats

type ConsumerStats struct {
	BlockedConsumerOnUnAckedMsgs bool              `json:"blockedConsumerOnUnackedMsgs"`
	AvailablePermits             int               `json:"availablePermits"`
	UnAckedMessages              int               `json:"unackedMessages"`
	MsgRateOut                   float64           `json:"msgRateOut"`
	MsgThroughputOut             float64           `json:"msgThroughputOut"`
	MsgRateRedeliver             float64           `json:"msgRateRedeliver"`
	ConsumerName                 string            `json:"consumerName"`
	Metadata                     map[string]string `json:"metadata"`
}

type CryptoConfig

type CryptoConfig struct {
	CryptoKeyReaderClassName string                 `json:"cryptoKeyReaderClassName" yaml:"cryptoKeyReaderClassName"`
	CryptoKeyReaderConfig    map[string]interface{} `json:"cryptoKeyReaderConfig" yaml:"cryptoKeyReaderConfig"`

	EncryptionKeys              []string `json:"encryptionKeys" yaml:"encryptionKeys"`
	ProducerCryptoFailureAction string   `json:"producerCryptoFailureAction" yaml:"producerCryptoFailureAction"`
	ConsumerCryptoFailureAction string   `json:"consumerCryptoFailureAction" yaml:"consumerCryptoFailureAction"`
}

type CursorInfo

type CursorInfo struct {
	Version                   int                `json:"version"`
	CreationDate              string             `json:"creationDate"`
	ModificationDate          string             `json:"modificationDate"`
	CursorsLedgerID           int64              `json:"cursorsLedgerId"`
	MarkDelete                PositionInfo       `json:"markDelete"`
	IndividualDeletedMessages []MessageRangeInfo `json:"individualDeletedMessages"`
	Properties                map[string]int64
}

type CursorStats

type CursorStats struct {
	MarkDeletePosition                       string           `json:"markDeletePosition"`
	ReadPosition                             string           `json:"readPosition"`
	WaitingReadOp                            bool             `json:"waitingReadOp"`
	PendingReadOps                           int              `json:"pendingReadOps"`
	MessagesConsumedCounter                  int64            `json:"messagesConsumedCounter"`
	CursorLedger                             int64            `json:"cursorLedger"`
	CursorLedgerLastEntry                    int64            `json:"cursorLedgerLastEntry"`
	IndividuallyDeletedMessages              string           `json:"individuallyDeletedMessages"`
	LastLedgerWitchTimestamp                 string           `json:"lastLedgerWitchTimestamp"`
	State                                    string           `json:"state"`
	NumberOfEntriesSinceFirstNotAckedMessage int64            `json:"numberOfEntriesSinceFirstNotAckedMessage"`
	TotalNonContiguousDeletedMessagesRange   int              `json:"totalNonContiguousDeletedMessagesRange"`
	Properties                               map[string]int64 `json:"properties"`
}

type DelayedDeliveryCmdData

type DelayedDeliveryCmdData struct {
	Enable                 bool   `json:"enable"`
	Disable                bool   `json:"disable"`
	DelayedDeliveryTimeStr string `json:"delayedDeliveryTimeStr"`
}

type DelayedDeliveryData

type DelayedDeliveryData struct {
	TickTime float64 `json:"tickTime"`
	Active   bool    `json:"active"`
}

type DispatchRate

type DispatchRate struct {
	DispatchThrottlingRateInMsg  int   `json:"dispatchThrottlingRateInMsg"`
	DispatchThrottlingRateInByte int64 `json:"dispatchThrottlingRateInByte"`
	RatePeriodInSecond           int   `json:"ratePeriodInSecond"`
}

func NewDispatchRate

func NewDispatchRate() *DispatchRate

type DispatchRateData

type DispatchRateData struct {
	DispatchThrottlingRateInMsg  int64 `json:"dispatchThrottlingRateInMsg"`
	DispatchThrottlingRateInByte int64 `json:"dispatchThrottlingRateInByte"`
	RatePeriodInSecond           int64 `json:"ratePeriodInSecond"`
	RelativeToPublishRate        bool  `json:"relativeToPublishRate"`
}

type ExceptionInformation

type ExceptionInformation struct {
	ExceptionString string `json:"exceptionString"`
	TimestampMs     int64  `json:"timestampMs"`
}

type FailureDomainData

type FailureDomainData struct {
	ClusterName string   `json:"-"`
	DomainName  string   `json:"-"`
	BrokerList  []string `json:"brokers"`
}

Failure Domain information

type FailureDomainMap

type FailureDomainMap map[string]FailureDomainData

type FunctionConfig

type FunctionConfig struct {
	TimeoutMs     *int64  `json:"timeoutMs,omitempty" yaml:"timeoutMs"`
	TopicsPattern *string `json:"topicsPattern,omitempty" yaml:"topicsPattern"`
	// Whether the subscriptions the functions created/used should be deleted when the functions is deleted
	CleanupSubscription          bool   `json:"cleanupSubscription" yaml:"cleanupSubscription"`
	RetainOrdering               bool   `json:"retainOrdering" yaml:"retainOrdering"`
	RetainKeyOrdering            bool   `json:"retainKeyOrdering" yaml:"retainKeyOrdering"`
	BatchBuilder                 string `json:"batchBuilder,omitempty" yaml:"batchBuilder"`
	ForwardSourceMessageProperty bool   `json:"forwardSourceMessageProperty" yaml:"forwardSourceMessageProperty"`
	AutoAck                      bool   `json:"autoAck" yaml:"autoAck"`
	Parallelism                  int    `json:"parallelism,omitempty" yaml:"parallelism"`
	MaxMessageRetries            *int   `json:"maxMessageRetries,omitempty" yaml:"maxMessageRetries"`

	Output string `json:"output,omitempty" yaml:"output"`

	ProducerConfig      *ProducerConfig   `json:"producerConfig,omitempty" yaml:"producerConfig"`
	CustomSchemaOutputs map[string]string `json:"customSchemaOutputs,omitempty" yaml:"customSchemaOutputs"`

	OutputSerdeClassName string `json:"outputSerdeClassName,omitempty" yaml:"outputSerdeClassName"`
	LogTopic             string `json:"logTopic,omitempty" yaml:"logTopic"`
	ProcessingGuarantees string `json:"processingGuarantees,omitempty" yaml:"processingGuarantees"`

	// Represents either a builtin schema type (eg: 'avro', 'json', etc) or the class name for a Schema implementation
	OutputSchemaType    string `json:"outputSchemaType,omitempty" yaml:"outputSchemaType"`
	OutputTypeClassName string `json:"outputTypeClassName,omitempty" yaml:"outputTypeClassName"`

	Runtime         string  `json:"runtime,omitempty" yaml:"runtime"`
	DeadLetterTopic string  `json:"deadLetterTopic,omitempty" yaml:"deadLetterTopic"`
	SubName         string  `json:"subName,omitempty" yaml:"subName"`
	FQFN            string  `json:"fqfn,omitempty" yaml:"fqfn"`
	Jar             *string `json:"jar,omitempty" yaml:"jar"`
	Py              *string `json:"py,omitempty" yaml:"py"`
	Go              *string `json:"go,omitempty" yaml:"go"`
	FunctionType    *string `json:"functionType,omitempty" yaml:"functionType"`
	// Any flags that you want to pass to the runtime.
	// note that in thread mode, these flags will have no impact
	RuntimeFlags string `json:"runtimeFlags,omitempty" yaml:"runtimeFlags"`

	Tenant    string `json:"tenant,omitempty" yaml:"tenant"`
	Namespace string `json:"namespace,omitempty" yaml:"namespace"`
	Name      string `json:"name,omitempty" yaml:"name"`
	ClassName string `json:"className,omitempty" yaml:"className"`

	Resources          *Resources             `json:"resources,omitempty" yaml:"resources"`
	WindowConfig       *WindowConfig          `json:"windowConfig,omitempty" yaml:"windowConfig"`
	Inputs             []string               `json:"inputs,omitempty" yaml:"inputs"`
	UserConfig         map[string]interface{} `json:"userConfig,omitempty" yaml:"userConfig"`
	CustomSerdeInputs  map[string]string      `json:"customSerdeInputs,omitempty" yaml:"customSerdeInputs"`
	CustomSchemaInputs map[string]string      `json:"customSchemaInputs,omitempty" yaml:"customSchemaInputs"`

	// A generalized way of specifying inputs
	InputSpecs         map[string]ConsumerConfig `json:"inputSpecs,omitempty" yaml:"inputSpecs"`
	InputTypeClassName string                    `json:"inputTypeClassName,omitempty" yaml:"inputTypeClassName"`

	CustomRuntimeOptions string `json:"customRuntimeOptions,omitempty" yaml:"customRuntimeOptions"`

	// This is a map of secretName(aka how the secret is going to be
	// accessed in the function via context) to an object that
	// encapsulates how the secret is fetched by the underlying
	// secrets provider. The type of an value here can be found by the
	// SecretProviderConfigurator.getSecretObjectType() method.
	Secrets map[string]interface{} `json:"secrets,omitempty" yaml:"secrets"`

	MaxPendingAsyncRequests int `json:"maxPendingAsyncRequests,omitempty" yaml:"maxPendingAsyncRequests"`
	//nolint
	ExposePulsarAdminClientEnabled bool   `json:"exposePulsarAdminClientEnabled" yaml:"exposePulsarAdminClientEnabled"`
	SkipToLatest                   bool   `json:"skipToLatest" yaml:"skipToLatest"`
	SubscriptionPosition           string `json:"subscriptionPosition,omitempty" yaml:"subscriptionPosition"`
}

type FunctionData

type FunctionData struct {
	UpdateAuthData       bool `json:"updateAuthData"`
	RetainOrdering       bool `json:"retainOrdering"`
	Watch                bool `json:"watch"`
	AutoAck              bool `json:"autoAck"`
	Parallelism          int  `json:"parallelism"`
	WindowLengthCount    int  `json:"windowLengthCount"`
	SlidingIntervalCount int  `json:"slidingIntervalCount"`
	MaxMessageRetries    int  `json:"maxMessageRetries"`

	TimeoutMs                 int64   `json:"timeoutMs"`
	SlidingIntervalDurationMs int64   `json:"slidingIntervalDurationMs"`
	WindowLengthDurationMs    int64   `json:"windowLengthDurationMs"`
	RAM                       int64   `json:"ram"`
	Disk                      int64   `json:"disk"`
	CPU                       float64 `json:"cpu"`
	SubsName                  string  `json:"subsName"`
	DeadLetterTopic           string  `json:"deadLetterTopic"`
	Key                       string  `json:"key"`
	State                     string  `json:"state"`
	TriggerValue              string  `json:"triggerValue"`
	TriggerFile               string  `json:"triggerFile"`
	Topic                     string  `json:"topic"`

	UserCodeFile                 string          `json:"-"`
	FQFN                         string          `json:"fqfn"`
	Tenant                       string          `json:"tenant"`
	Namespace                    string          `json:"namespace"`
	FuncName                     string          `json:"functionName"`
	InstanceID                   string          `json:"instance_id"`
	ClassName                    string          `json:"className"`
	FunctionType                 string          `json:"functionType"`
	CleanupSubscription          bool            `json:"cleanupSubscription"`
	Jar                          string          `json:"jarFile"`
	Py                           string          `json:"pyFile"`
	Go                           string          `json:"goFile"`
	Inputs                       string          `json:"inputs"`
	TopicsPattern                string          `json:"topicsPattern"`
	Output                       string          `json:"output"`
	ProducerConfig               string          `json:"producerConfig"`
	LogTopic                     string          `json:"logTopic"`
	SchemaType                   string          `json:"schemaType"`
	CustomSerDeInputs            string          `json:"customSerdeInputString"`
	CustomSchemaInput            string          `json:"customSchemaInputString"`
	CustomSchemaOutput           string          `json:"customSchemaOutputString"`
	InputSpecs                   string          `json:"inputSpecs"`
	InputTypeClassName           string          `json:"inputTypeClassName"`
	OutputSerDeClassName         string          `json:"outputSerdeClassName"`
	OutputTypeClassName          string          `json:"outputTypeClassName"`
	FunctionConfigFile           string          `json:"fnConfigFile"`
	ProcessingGuarantees         string          `json:"processingGuarantees"`
	UserConfig                   string          `json:"userConfigString"`
	RetainKeyOrdering            bool            `json:"retainKeyOrdering"`
	BatchBuilder                 string          `json:"batchBuilder"`
	ForwardSourceMessageProperty bool            `json:"forwardSourceMessageProperty"`
	SubsPosition                 string          `json:"subsPosition"`
	SkipToLatest                 bool            `json:"skipToLatest"`
	CustomRuntimeOptions         string          `json:"customRuntimeOptions"`
	Secrets                      string          `json:"secretsString"`
	DestinationFile              string          `json:"destinationFile"`
	Path                         string          `json:"path"`
	RuntimeFlags                 string          `json:"runtimeFlags,omitempty"`
	FuncConf                     *FunctionConfig `json:"-"`
}

FunctionData information for a Pulsar Function

type FunctionInstanceStats

type FunctionInstanceStats struct {
	FunctionInstanceStatsDataBase

	InstanceID int64 `json:"instanceId"`

	Metrics FunctionInstanceStatsData `json:"metrics"`
}

type FunctionInstanceStatsData

type FunctionInstanceStatsData struct {
	OneMin FunctionInstanceStatsDataBase `json:"oneMin"`

	// Timestamp of when the function was last invoked for instance
	LastInvocation int64 `json:"lastInvocation"`

	// Map of user defined metrics
	UserMetrics map[string]float64 `json:"userMetrics"`

	FunctionInstanceStatsDataBase
}

type FunctionInstanceStatsDataBase

type FunctionInstanceStatsDataBase struct {
	// Total number of records function received from source for instance
	ReceivedTotal int64 `json:"receivedTotal"`

	// Total number of records successfully processed by user function for instance
	ProcessedSuccessfullyTotal int64 `json:"processedSuccessfullyTotal"`

	// Total number of system exceptions thrown for instance
	SystemExceptionsTotal int64 `json:"systemExceptionsTotal"`

	// Total number of user exceptions thrown for instance
	UserExceptionsTotal int64 `json:"userExceptionsTotal"`

	// Average process latency for function for instance
	AvgProcessLatency float64 `json:"avgProcessLatency"`
}

type FunctionInstanceStatus

type FunctionInstanceStatus struct {
	InstanceID int                        `json:"instanceId"`
	Status     FunctionInstanceStatusData `json:"status"`
}

type FunctionInstanceStatusData

type FunctionInstanceStatusData struct {
	Running                  bool                   `json:"running"`
	Err                      string                 `json:"error"`
	NumRestarts              int64                  `json:"numRestarts"`
	NumReceived              int64                  `json:"numReceived"`
	NumSuccessfullyProcessed int64                  `json:"numSuccessfullyProcessed"`
	NumUserExceptions        int64                  `json:"numUserExceptions"`
	LatestUserExceptions     []ExceptionInformation `json:"latestUserExceptions"`
	NumSystemExceptions      int64                  `json:"numSystemExceptions"`
	LatestSystemExceptions   []ExceptionInformation `json:"latestSystemExceptions"`
	AverageLatency           float64                `json:"averageLatency"`
	LastInvocationTime       int64                  `json:"lastInvocationTime"`
	WorkerID                 string                 `json:"workerId"`
}

type FunctionState

type FunctionState struct {
	Key         string `json:"key"`
	StringValue string `json:"stringValue,omitempty"`
	ByteValue   []byte `json:"byteValue,omitempty"`
	NumValue    int64  `json:"numberValue,omitempty"`
	Version     int64  `json:"version,omitempty"`
}

type FunctionStats

type FunctionStats struct {
	// Overall total number of records function received from source
	ReceivedTotal int64 `json:"receivedTotal"`

	// Overall total number of records successfully processed by user function
	ProcessedSuccessfullyTotal int64 `json:"processedSuccessfullyTotal"`

	// Overall total number of system exceptions thrown
	SystemExceptionsTotal int64 `json:"systemExceptionsTotal"`

	// Overall total number of user exceptions thrown
	UserExceptionsTotal int64 `json:"userExceptionsTotal"`

	// Average process latency for function
	AvgProcessLatency float64 `json:"avgProcessLatency"`

	// Timestamp of when the function was last invoked by any instance
	LastInvocation int64 `json:"lastInvocation"`

	OneMin FunctionInstanceStatsDataBase `json:"oneMin"`

	Instances []FunctionInstanceStats `json:"instances"`

	FunctionInstanceStats
}

func (*FunctionStats) AddInstance

func (fs *FunctionStats) AddInstance(functionInstanceStats FunctionInstanceStats)

func (*FunctionStats) CalculateOverall

func (fs *FunctionStats) CalculateOverall() *FunctionStats

type FunctionStatus

type FunctionStatus struct {
	NumInstances int                      `json:"numInstances"`
	NumRunning   int                      `json:"numRunning"`
	Instances    []FunctionInstanceStatus `json:"instances"`
}

type GetSchemaResponse

type GetSchemaResponse struct {
	Version    int64             `json:"version"`
	Type       string            `json:"type"`
	Timestamp  int64             `json:"timestamp"`
	Data       string            `json:"data"`
	Properties map[string]string `json:"properties"`
}

type GetStatsOptions added in v0.13.0

type GetStatsOptions struct {
	GetPreciseBacklog        bool `json:"get_precise_backlog"`
	SubscriptionBacklogSize  bool `json:"subscription_backlog_size"`
	GetEarliestTimeInBacklog bool `json:"get_earliest_time_in_backlog"`
	ExcludePublishers        bool `json:"exclude_publishers"`
	ExcludeConsumers         bool `json:"exclude_consumers"`
}

type InactiveTopicDeleteMode

type InactiveTopicDeleteMode string
const (
	// The topic can be deleted when no subscriptions and no active producers.
	DeleteWhenNoSubscriptions InactiveTopicDeleteMode = "delete_when_no_subscriptions"
	// The topic can be deleted when all subscriptions catchup and no active producers/consumers.
	DeleteWhenSubscriptionsCaughtUp InactiveTopicDeleteMode = "delete_when_subscriptions_caught_up"
)

func ParseInactiveTopicDeleteMode

func ParseInactiveTopicDeleteMode(str string) (InactiveTopicDeleteMode, error)

func (InactiveTopicDeleteMode) String

func (i InactiveTopicDeleteMode) String() string

type InactiveTopicPolicies

type InactiveTopicPolicies struct {
	InactiveTopicDeleteMode    *InactiveTopicDeleteMode `json:"inactiveTopicDeleteMode"`
	MaxInactiveDurationSeconds int                      `json:"maxInactiveDurationSeconds"`
	DeleteWhileInactive        bool                     `json:"deleteWhileInactive"`
}

func NewInactiveTopicPolicies

func NewInactiveTopicPolicies(inactiveTopicDeleteMode *InactiveTopicDeleteMode, maxInactiveDurationSeconds int,
	deleteWhileInactive bool) InactiveTopicPolicies

type InternalConfigurationData

type InternalConfigurationData struct {
	ZookeeperServers          string `json:"zookeeperServers"`
	ConfigurationStoreServers string `json:"configurationStoreServers"`
	LedgersRootPath           string `json:"ledgersRootPath"`
	StateStorageServiceURL    string `json:"stateStorageServiceUrl"`
}

type IsCompatibility added in v0.13.0

type IsCompatibility struct {
	IsCompatibility             bool                        `json:"compatibility"`
	SchemaCompatibilityStrategy SchemaCompatibilityStrategy `json:"schemaCompatibilityStrategy"`
}

type KeyValue

type KeyValue struct {
	Key                  *string  `protobuf:"bytes,1,req,name=key" json:"key,omitempty"`
	Value                *string  `protobuf:"bytes,2,req,name=value" json:"value,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

nolint

func (*KeyValue) ProtoMessage

func (*KeyValue) ProtoMessage()

func (*KeyValue) Reset

func (m *KeyValue) Reset()

func (*KeyValue) String

func (m *KeyValue) String() string

type LedgerInfo

type LedgerInfo struct {
	LedgerID        int64  `json:"ledgerId"`
	Entries         int64  `json:"entries"`
	Size            int64  `json:"size"`
	Timestamp       int64  `json:"timestamp"`
	Offloaded       bool   `json:"offloaded"`
	MetaData        string `json:"metadata"`
	UnderReplicated bool   `json:"underReplicated"`
}

type LocalBrokerData

type LocalBrokerData struct {
	// URLs to satisfy contract of ServiceLookupData (used by NamespaceService).
	WebServiceURL              string `json:"webServiceUrl"`
	WebServiceURLTLS           string `json:"webServiceUrlTls"`
	PulsarServiceURL           string `json:"pulsarServiceUrl"`
	PulsarServiceURLTLS        string `json:"pulsarServiceUrlTls"`
	PersistentTopicsEnabled    bool   `json:"persistentTopicsEnabled"`
	NonPersistentTopicsEnabled bool   `json:"nonPersistentTopicsEnabled"`

	// Most recently available system resource usage.
	CPU          ResourceUsage `json:"cpu"`
	Memory       ResourceUsage `json:"memory"`
	DirectMemory ResourceUsage `json:"directMemory"`
	BandwidthIn  ResourceUsage `json:"bandwidthIn"`
	BandwidthOut ResourceUsage `json:"bandwidthOut"`

	// Message data from the most recent namespace bundle stats.
	MsgThroughputIn  float64 `json:"msgThroughputIn"`
	MsgThroughputOut float64 `json:"msgThroughputOut"`
	MsgRateIn        float64 `json:"msgRateIn"`
	MsgRateOut       float64 `json:"msgRateOut"`

	// Timestamp of last update.
	LastUpdate int64 `json:"lastUpdate"`

	// The stats given in the most recent invocation of update.
	LastStats    map[string]*NamespaceBundleStats `json:"lastStats"`
	NumTopics    int                              `json:"numTopics"`
	NumBundles   int                              `json:"numBundles"`
	NumConsumers int                              `json:"numConsumers"`
	NumProducers int                              `json:"numProducers"`

	// All bundles belonging to this broker.
	Bundles []string `json:"bundles"`

	// The bundles gained since the last invocation of update.
	LastBundleGains []string `json:"lastBundleGains"`

	// The bundles lost since the last invocation of update.
	LastBundleLosses []string `json:"lastBundleLosses"`

	// The version string that this broker is running, obtained from the Maven build artifact in the POM
	BrokerVersionString string `json:"brokerVersionString"`

	// This place-holder requires to identify correct LoadManagerReport type while deserializing
	LoadReportType string `json:"loadReportType"`

	// the external protocol data advertised by protocol handlers.
	Protocols map[string]string `json:"protocols"`
}

func NewLocalBrokerData

func NewLocalBrokerData() LocalBrokerData

type LongRunningProcessStatus

type LongRunningProcessStatus struct {
	Status    Status `json:"status"`
	LastError string `json:"lastError"`
}

type LookupData

type LookupData struct {
	BrokerURL    string `json:"brokerUrl"`
	BrokerURLTLS string `json:"brokerUrlTls"`
	HTTPURL      string `json:"httpUrl"`
	HTTPURLTLS   string `json:"httpUrlTls"`
}

type ManagedLedgerInfo

type ManagedLedgerInfo struct {
	Version            int                           `json:"version"`
	CreationDate       string                        `json:"creationDate"`
	ModificationData   string                        `json:"modificationData"`
	Ledgers            []ManagedLedgerInfoLedgerInfo `json:"ledgers"`
	TerminatedPosition PositionInfo                  `json:"terminatedPosition"`
	Cursors            map[string]CursorInfo         `json:"cursors"`
}

type ManagedLedgerInfoLedgerInfo

type ManagedLedgerInfoLedgerInfo struct {
	LedgerID             int64  `json:"ledgerId"`
	Entries              int64  `json:"entries"`
	Size                 int64  `json:"size"`
	Timestamp            int64  `json:"timestamp"`
	Offloaded            bool   `json:"isOffloaded"`
	OffloadedContextUUID string `json:"offloadedContextUuid"`
}

type Message

type Message struct {
	MessageID  MessageID
	Payload    []byte
	Topic      string
	Properties map[string]string
}

func NewMessage

func NewMessage(topic string, id MessageID, payload []byte, properties map[string]string) *Message

func (*Message) GetMessageID

func (m *Message) GetMessageID() MessageID

func (*Message) GetPayload

func (m *Message) GetPayload() []byte

func (*Message) GetProperties

func (m *Message) GetProperties() map[string]string

type MessageID

type MessageID struct {
	LedgerID       int64 `json:"ledgerId"`
	EntryID        int64 `json:"entryId"`
	PartitionIndex int   `json:"partitionIndex"`
	BatchIndex     int   `json:"-"`
}

func ParseMessageID

func ParseMessageID(str string) (*MessageID, error)

func ParseMessageIDWithPartitionIndex added in v0.14.0

func ParseMessageIDWithPartitionIndex(str string, index int) (*MessageID, error)

func (MessageID) String

func (m MessageID) String() string

type MessageRangeInfo

type MessageRangeInfo struct {
	From      PositionInfo `json:"from"`
	To        PositionInfo `json:"to"`
	Offloaded bool         `json:"offloaded"`
}

type Metrics

type Metrics struct {
	Metrics    map[string]interface{} `json:"metrics"`
	Dimensions map[string]string      `json:"dimensions"`
}

func NewMetrics

func NewMetrics(dimensionMap map[string]string) *Metrics

type NameSpaceName

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

func GetNameSpaceName

func GetNameSpaceName(tenant, namespace string) (*NameSpaceName, error)

func GetNamespaceName

func GetNamespaceName(completeName string) (*NameSpaceName, error)

func (*NameSpaceName) String

func (n *NameSpaceName) String() string

type NamespaceBundleStats

type NamespaceBundleStats struct {
	MsgRateIn        float64 `json:"msgRateIn"`
	MsgThroughputIn  float64 `json:"msgThroughputIn"`
	MsgRateOut       float64 `json:"msgRateOut"`
	MsgThroughputOut float64 `json:"msgThroughputOut"`
	ConsumerCount    int     `json:"consumerCount"`
	ProducerCount    int     `json:"producerCount"`
	TopicsNum        int64   `json:"topics"`
	CacheSize        int64   `json:"cacheSize"`

	// Consider the throughput equal if difference is less than 100 KB/s
	ThroughputDifferenceThreshold float64 `json:"throughputDifferenceThreshold"`
	// Consider the msgRate equal if the difference is less than 100
	MsgRateDifferenceThreshold float64 `json:"msgRateDifferenceThreshold"`
	// Consider the total topics/producers/consumers equal if the difference is less than 500
	TopicConnectionDifferenceThreshold int64 `json:"topicConnectionDifferenceThreshold"`
	// Consider the cache size equal if the difference is less than 100 kb
	CacheSizeDifferenceThreshold int64 `json:"cacheSizeDifferenceThreshold"`
}

func NewNamespaceBundleStats

func NewNamespaceBundleStats() *NamespaceBundleStats

type NamespaceIsolationData

type NamespaceIsolationData struct {
	Namespaces         []string               `json:"namespaces"`
	Primary            []string               `json:"primary"`
	Secondary          []string               `json:"secondary"`
	AutoFailoverPolicy AutoFailoverPolicyData `json:"auto_failover_policy"`
}

func CreateNamespaceIsolationData

func CreateNamespaceIsolationData(namespaces, primary, secondry []string, autoFailoverPolicyTypeName string,
	autoFailoverPolicyParams map[string]string) (*NamespaceIsolationData, error)

type NamespaceOwnershipStatus

type NamespaceOwnershipStatus struct {
	BrokerAssignment BrokerAssignment `json:"broker_assignment"`
	IsControlled     bool             `json:"is_controlled"`
	IsActive         bool             `json:"is_active"`
}

type NamespacesData

type NamespacesData struct {
	Enable                         bool     `json:"enable"`
	Unload                         bool     `json:"unload"`
	NumBundles                     int      `json:"numBundles"`
	BookkeeperEnsemble             int      `json:"bookkeeperEnsemble"`
	BookkeeperWriteQuorum          int      `json:"bookkeeperWriteQuorum"`
	MessageTTL                     int      `json:"messageTTL"`
	BookkeeperAckQuorum            int      `json:"bookkeeperAckQuorum"`
	ManagedLedgerMaxMarkDeleteRate float64  `json:"managedLedgerMaxMarkDeleteRate"`
	ClusterIds                     string   `json:"clusterIds"`
	RetentionTimeStr               string   `json:"retentionTimeStr"`
	LimitStr                       string   `json:"limitStr"`
	LimitTime                      int64    `json:"limitTime"`
	PolicyStr                      string   `json:"policyStr"`
	BacklogQuotaType               string   `json:"backlogQuotaType"`
	AntiAffinityGroup              string   `json:"antiAffinityGroup"`
	Tenant                         string   `json:"tenant"`
	Cluster                        string   `json:"cluster"`
	Bundle                         string   `json:"bundle"`
	Clusters                       []string `json:"clusters"`
}

type NsIsolationPoliciesData

type NsIsolationPoliciesData struct {
	Namespaces                 []string `json:"namespaces"`
	Primary                    []string `json:"primary"`
	Secondary                  []string `json:"secondary"`
	AutoFailoverPolicyTypeName string   `json:"autoFailoverPolicyTypeName"`
	AutoFailoverPolicyParams   string   `json:"autoFailoverPolicyParams"`
}

type OffloadProcessStatus

type OffloadProcessStatus struct {
	Status                  Status    `json:"status"`
	LastError               string    `json:"lastError"`
	FirstUnOffloadedMessage MessageID `json:"firstUnoffloadedMessage"`
}

type PackageMetadata

type PackageMetadata struct {
	Description      string            `json:"description,omitempty" yaml:"description"`
	Contact          string            `json:"contact,omitempty" yaml:"contact"`
	CreateTime       int64             `json:"createTime,omitempty" yaml:"createTime"`
	ModificationTime int64             `json:"modificationTime,omitempty" yaml:"modificationTime"`
	Properties       map[string]string `json:"properties,omitempty" yaml:"properties"`
}

type PackageName

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

func GetPackageName

func GetPackageName(completeName string) (*PackageName, error)

func GetPackageNameWithComponents

func GetPackageNameWithComponents(packageType PackageType,
	tenant, namespace, name, version string) (*PackageName, error)

func (*PackageName) GetCompleteName

func (p *PackageName) GetCompleteName() string

func (*PackageName) GetName

func (p *PackageName) GetName() string

func (*PackageName) GetNamespace

func (p *PackageName) GetNamespace() string

func (*PackageName) GetTenant

func (p *PackageName) GetTenant() string

func (*PackageName) GetType

func (p *PackageName) GetType() PackageType

func (*PackageName) GetVersion

func (p *PackageName) GetVersion() string

func (*PackageName) String

func (p *PackageName) String() string

type PackageType

type PackageType string
const (
	PackageTypeFunction PackageType = "function"
	PackageTypeSink     PackageType = "sink"
	PackageTypeSource   PackageType = "source"
)

func (PackageType) String

func (p PackageType) String() string

type PartitionedTopicMetadata

type PartitionedTopicMetadata struct {
	Partitions int `json:"partitions"`
}

Topic data

type PartitionedTopicStats

type PartitionedTopicStats struct {
	MsgRateIn           float64                      `json:"msgRateIn"`
	MsgRateOut          float64                      `json:"msgRateOut"`
	MsgThroughputIn     float64                      `json:"msgThroughputIn"`
	MsgThroughputOut    float64                      `json:"msgThroughputOut"`
	AverageMsgSize      float64                      `json:"averageMsgSize"`
	StorageSize         int64                        `json:"storageSize"`
	Publishers          []PublisherStats             `json:"publishers"`
	Subscriptions       map[string]SubscriptionStats `json:"subscriptions"`
	Replication         map[string]ReplicatorStats   `json:"replication"`
	DeDuplicationStatus string                       `json:"deduplicationStatus"`
	Metadata            PartitionedTopicMetadata     `json:"metadata"`
	Partitions          map[string]TopicStats        `json:"partitions"`
}

type PersistenceData

type PersistenceData struct {
	BookkeeperEnsemble             int64   `json:"bookkeeperEnsemble"`
	BookkeeperWriteQuorum          int64   `json:"bookkeeperWriteQuorum"`
	BookkeeperAckQuorum            int64   `json:"bookkeeperAckQuorum"`
	ManagedLedgerMaxMarkDeleteRate float64 `json:"managedLedgerMaxMarkDeleteRate"`
}

type PersistencePolicies

type PersistencePolicies struct {
	BookkeeperEnsemble             int     `json:"bookkeeperEnsemble"`
	BookkeeperWriteQuorum          int     `json:"bookkeeperWriteQuorum"`
	BookkeeperAckQuorum            int     `json:"bookkeeperAckQuorum"`
	ManagedLedgerMaxMarkDeleteRate float64 `json:"managedLedgerMaxMarkDeleteRate"`
}

func NewPersistencePolicies

func NewPersistencePolicies(bookkeeperEnsemble, bookkeeperWriteQuorum, bookkeeperAckQuorum int,
	managedLedgerMaxMarkDeleteRate float64) PersistencePolicies

type PersistentTopicInternalStats

type PersistentTopicInternalStats struct {
	WaitingCursorsCount                int                    `json:"waitingCursorsCount"`
	PendingAddEntriesCount             int                    `json:"pendingAddEntriesCount"`
	EntriesAddedCounter                int64                  `json:"entriesAddedCounter"`
	NumberOfEntries                    int64                  `json:"numberOfEntries"`
	TotalSize                          int64                  `json:"totalSize"`
	CurrentLedgerEntries               int64                  `json:"currentLedgerEntries"`
	CurrentLedgerSize                  int64                  `json:"currentLedgerSize"`
	LastLedgerCreatedTimestamp         string                 `json:"lastLedgerCreatedTimestamp"`
	LastLedgerCreationFailureTimestamp string                 `json:"lastLedgerCreationFailureTimestamp"`
	LastConfirmedEntry                 string                 `json:"lastConfirmedEntry"`
	State                              string                 `json:"state"`
	Ledgers                            []LedgerInfo           `json:"ledgers"`
	Cursors                            map[string]CursorStats `json:"cursors"`
	SchemaLedgers                      []SchemaLedger         `json:"schemaLedgers"`
	CompactedLedger                    CompactedLedger        `json:"compactedLedger"`
}

type Policies

type Policies struct {
	Bundles                     *BundlesData                      `json:"bundles"`
	Persistence                 *PersistencePolicies              `json:"persistence"`
	RetentionPolicies           *RetentionPolicies                `json:"retention_policies"`
	SchemaValidationEnforced    bool                              `json:"schema_validation_enforced"`
	DeduplicationEnabled        *bool                             `json:"deduplicationEnabled"`
	Deleted                     bool                              `json:"deleted"`
	EncryptionRequired          bool                              `json:"encryption_required"`
	MessageTTLInSeconds         *int                              `json:"message_ttl_in_seconds"`
	MaxProducersPerTopic        *int                              `json:"max_producers_per_topic"`
	MaxConsumersPerTopic        *int                              `json:"max_consumers_per_topic"`
	MaxConsumersPerSubscription *int                              `json:"max_consumers_per_subscription"`
	CompactionThreshold         *int64                            `json:"compaction_threshold"`
	OffloadThreshold            int64                             `json:"offload_threshold"`
	OffloadDeletionLagMs        *int64                            `json:"offload_deletion_lag_ms"`
	AntiAffinityGroup           string                            `json:"antiAffinityGroup"`
	ReplicationClusters         []string                          `json:"replication_clusters"`
	LatencyStatsSampleRate      map[string]int                    `json:"latency_stats_sample_rate"`
	BacklogQuotaMap             map[BacklogQuotaType]BacklogQuota `json:"backlog_quota_map"`
	TopicDispatchRate           map[string]DispatchRate           `json:"topicDispatchRate"`
	SubscriptionDispatchRate    map[string]DispatchRate           `json:"subscriptionDispatchRate"`
	ReplicatorDispatchRate      map[string]DispatchRate           `json:"replicatorDispatchRate"`
	PublishMaxMessageRate       map[string]PublishRate            `json:"publishMaxMessageRate"`
	ClusterSubscribeRate        map[string]SubscribeRate          `json:"clusterSubscribeRate"`
	TopicAutoCreationConfig     *TopicAutoCreationConfig          `json:"autoTopicCreationOverride"`
	SchemaCompatibilityStrategy SchemaCompatibilityStrategy       `json:"schema_auto_update_compatibility_strategy"`
	AuthPolicies                AuthPolicies                      `json:"auth_policies"`
	SubscriptionAuthMode        SubscriptionAuthMode              `json:"subscription_auth_mode"`
	IsAllowAutoUpdateSchema     *bool                             `json:"is_allow_auto_update_schema"`
}

func NewDefaultPolicies

func NewDefaultPolicies() *Policies

type PoolArenaStats

type PoolArenaStats struct {
	NumTinySubpages            int                  `json:"numTinySubpages"`
	NumSmallSubpages           int                  `json:"numSmallSubpages"`
	NumChunkLists              int                  `json:"numChunkLists"`
	TinySubpages               []PoolSubpageStats   `json:"tinySubpages"`
	SmallSubpages              []PoolSubpageStats   `json:"smallSubpages"`
	ChunkLists                 []PoolChunkListStats `json:"chunkLists"`
	NumAllocations             int64                `json:"numAllocations"`
	NumTinyAllocations         int64                `json:"numTinyAllocations"`
	NumSmallAllocations        int64                `json:"numSmallAllocations"`
	NumNormalAllocations       int64                `json:"numNormalAllocations"`
	NumHugeAllocations         int64                `json:"numHugeAllocations"`
	NumDeallocations           int64                `json:"numDeallocations"`
	NumTinyDeallocations       int64                `json:"numTinyDeallocations"`
	NumSmallDeallocations      int64                `json:"numSmallDeallocations"`
	NumNormalDeallocations     int64                `json:"numNormalDeallocations"`
	NumHugeDeallocations       int64                `json:"numHugeDeallocations"`
	NumActiveAllocations       int64                `json:"numActiveAllocations"`
	NumActiveTinyAllocations   int64                `json:"numActiveTinyAllocations"`
	NumActiveSmallAllocations  int64                `json:"numActiveSmallAllocations"`
	NumActiveNormalAllocations int64                `json:"numActiveNormalAllocations"`
	NumActiveHugeAllocations   int64                `json:"numActiveHugeAllocations"`
}

type PoolChunkListStats

type PoolChunkListStats struct {
	MinUsage int              `json:"minUsage"`
	MaxUsage int              `json:"maxUsage"`
	Chunks   []PoolChunkStats `json:"chunks"`
}

type PoolChunkStats

type PoolChunkStats struct {
	Usage     int `json:"usage"`
	ChunkSize int `json:"chunkSize"`
	FreeBytes int `json:"freeBytes"`
}

type PoolSubpageStats

type PoolSubpageStats struct {
	MaxNumElements int `json:"maxNumElements"`
	NumAvailable   int `json:"numAvailable"`
	ElementSize    int `json:"elementSize"`
	PageSize       int `json:"pageSize"`
}

type PositionInfo

type PositionInfo struct {
	LedgerID int64 `json:"ledgerId"`
	EntryID  int64 `json:"entryId"`
}

type PostSchemaPayload

type PostSchemaPayload struct {
	SchemaType string            `json:"type"`
	Schema     string            `json:"schema"`
	Properties map[string]string `json:"properties"`
}

Payload with information about a schema

func ConvertSchemaInfoToPostSchemaPayload added in v0.13.0

func ConvertSchemaInfoToPostSchemaPayload(schemaInfo SchemaInfo) PostSchemaPayload

type ProducerConfig

type ProducerConfig struct {
	MaxPendingMessages int `json:"maxPendingMessages" yaml:"maxPendingMessages"`
	//nolint
	MaxPendingMessagesAcrossPartitions int `json:"maxPendingMessagesAcrossPartitions" yaml:"maxPendingMessagesAcrossPartitions"`

	UseThreadLocalProducers bool          `json:"useThreadLocalProducers" yaml:"useThreadLocalProducers"`
	CryptoConfig            *CryptoConfig `json:"cryptoConfig" yaml:"cryptoConfig"`
	BatchBuilder            string        `json:"batchBuilder" yaml:"batchBuilder"`
	CompressionType         string        `json:"compressionType" yaml:"compressionType"`
}

type PublishRate

type PublishRate struct {
	PublishThrottlingRateInMsg  int   `json:"publishThrottlingRateInMsg"`
	PublishThrottlingRateInByte int64 `json:"publishThrottlingRateInByte"`
}

func NewPublishRate

func NewPublishRate() *PublishRate

type PublishRateData

type PublishRateData struct {
	PublishThrottlingRateInMsg  int64 `json:"publishThrottlingRateInMsg"`
	PublishThrottlingRateInByte int64 `json:"publishThrottlingRateInByte"`
}

type PublisherStats

type PublisherStats struct {
	ProducerID      int64             `json:"producerId"`
	MsgRateIn       float64           `json:"msgRateIn"`
	MsgThroughputIn float64           `json:"msgThroughputIn"`
	AverageMsgSize  float64           `json:"averageMsgSize"`
	Metadata        map[string]string `json:"metadata"`
}

type ReplicatorStats

type ReplicatorStats struct {
	Connected                 bool    `json:"connected"`
	MsgRateIn                 float64 `json:"msgRateIn"`
	MsgRateOut                float64 `json:"msgRateOut"`
	MsgThroughputIn           float64 `json:"msgThroughputIn"`
	MsgThroughputOut          float64 `json:"msgThroughputOut"`
	MsgRateExpired            float64 `json:"msgRateExpired"`
	ReplicationBacklog        int64   `json:"replicationBacklog"`
	ReplicationDelayInSeconds int64   `json:"replicationDelayInSeconds"`
	InboundConnection         string  `json:"inboundConnection"`
	InboundConnectedSince     string  `json:"inboundConnectedSince"`
	OutboundConnection        string  `json:"outboundConnection"`
	OutboundConnectedSince    string  `json:"outboundConnectedSince"`
}

type ResourceQuota

type ResourceQuota struct {
	// messages published per second
	MsgRateIn float64 `json:"msgRateIn"`
	// messages consumed per second
	MsgRateOut float64 `json:"msgRateOut"`
	// incoming bytes per second
	BandwidthIn float64 `json:"bandwidthIn"`
	// outgoing bytes per second
	BandwidthOut float64 `json:"bandwidthOut"`
	// used memory in Mbytes
	Memory float64 `json:"memory"`
	// allow the quota be dynamically re-calculated according to real traffic
	Dynamic bool `json:"dynamic"`
}

func NewResourceQuota

func NewResourceQuota() *ResourceQuota

type ResourceQuotaData

type ResourceQuotaData struct {
	Names        string `json:"names"`
	Bundle       string `json:"bundle"`
	MsgRateIn    int64  `json:"msgRateIn"`
	MsgRateOut   int64  `json:"msgRateOut"`
	BandwidthIn  int64  `json:"bandwidthIn"`
	BandwidthOut int64  `json:"bandwidthOut"`
	Memory       int64  `json:"memory"`
	Dynamic      bool   `json:"dynamic"`
}

type ResourceUsage

type ResourceUsage struct {
	Usage float64 `json:"usage"`
	Limit float64 `json:"limit"`
}

func (*ResourceUsage) CompareTo

func (ru *ResourceUsage) CompareTo(o *ResourceUsage) int

func (*ResourceUsage) PercentUsage

func (ru *ResourceUsage) PercentUsage() float32

func (*ResourceUsage) Reset

func (ru *ResourceUsage) Reset()

type Resources

type Resources struct {
	CPU  float64 `json:"cpu"`
	Disk int64   `json:"disk"`
	RAM  int64   `json:"ram"`
}

func NewDefaultResources

func NewDefaultResources() *Resources

type RetentionPolicies

type RetentionPolicies struct {
	RetentionTimeInMinutes int   `json:"retentionTimeInMinutes"`
	RetentionSizeInMB      int64 `json:"retentionSizeInMB"`
}

func NewRetentionPolicies

func NewRetentionPolicies(retentionTimeInMinutes int, retentionSizeInMB int) RetentionPolicies

type RetentionPolicy

type RetentionPolicy string
const (
	ProducerRequestHold     RetentionPolicy = "producer_request_hold"
	ProducerException       RetentionPolicy = "producer_exception"
	ConsumerBacklogEviction RetentionPolicy = "consumer_backlog_eviction"
)

func ParseRetentionPolicy

func ParseRetentionPolicy(str string) (RetentionPolicy, error)

func (RetentionPolicy) String

func (s RetentionPolicy) String() string

type SchemaCompatibilityStrategy

type SchemaCompatibilityStrategy string
const (
	AutoUpdateDisabled SchemaCompatibilityStrategy = "AutoUpdateDisabled"
	Backward           SchemaCompatibilityStrategy = "Backward"
	Forward            SchemaCompatibilityStrategy = "Forward"
	Full               SchemaCompatibilityStrategy = "Full"
	AlwaysCompatible   SchemaCompatibilityStrategy = "AlwaysCompatible"
	BackwardTransitive SchemaCompatibilityStrategy = "BackwardTransitive"
	ForwardTransitive  SchemaCompatibilityStrategy = "ForwardTransitive"
	FullTransitive     SchemaCompatibilityStrategy = "FullTransitive"
)

func ParseSchemaAutoUpdateCompatibilityStrategy

func ParseSchemaAutoUpdateCompatibilityStrategy(str string) (SchemaCompatibilityStrategy, error)

func (SchemaCompatibilityStrategy) String

type SchemaData

type SchemaData struct {
	Version         int64  `json:"version"`
	Filename        string `json:"filename"`
	Jar             string `json:"jar"`
	Type            string `json:"type"`
	Classname       string `json:"classname"`
	AlwaysAllowNull bool   `json:"alwaysAllowNull"`
	DryRun          bool   `json:"dryRun"`
}

type SchemaInfo

type SchemaInfo struct {
	Name       string            `json:"name"`
	Schema     []byte            `json:"schema"`
	Type       string            `json:"type"`
	Properties map[string]string `json:"properties"`
}

func ConvertGetSchemaResponseToSchemaInfo

func ConvertGetSchemaResponseToSchemaInfo(tn *TopicName, response GetSchemaResponse) *SchemaInfo

type SchemaInfoWithVersion

type SchemaInfoWithVersion struct {
	Version    int64       `json:"version"`
	SchemaInfo *SchemaInfo `json:"schemaInfo"`
}

func ConvertGetSchemaResponseToSchemaInfoWithVersion

func ConvertGetSchemaResponseToSchemaInfoWithVersion(tn *TopicName, response GetSchemaResponse) *SchemaInfoWithVersion

type SchemaLedger

type SchemaLedger struct {
	LedgerID    int64 `json:"ledgerId"`
	Entries     int64 `json:"entries"`
	Size        int64 `json:"size"`
	Timestamp   int64 `json:"timestamp"`
	IsOffloaded bool  `json:"isOffloaded"`
}

type SingleMessageMetadata

type SingleMessageMetadata struct {
	Properties   []*KeyValue `protobuf:"bytes,1,rep,name=properties" json:"properties,omitempty"`
	PartitionKey *string     `protobuf:"bytes,2,opt,name=partition_key,json=partitionKey" json:"partition_key,omitempty"`
	PayloadSize  *int32      `protobuf:"varint,3,req,name=payload_size,json=payloadSize" json:"payload_size,omitempty"`
	CompactedOut *bool       `protobuf:"varint,4,opt,name=compacted_out,json=compactedOut,def=0" json:"compacted_out,omitempty"`
	// the timestamp that this event occurs. it is typically set by applications.
	// if this field is omitted, `publish_time` can be used for the purpose of `event_time`.
	EventTime              *uint64 `protobuf:"varint,5,opt,name=event_time,json=eventTime,def=0" json:"event_time,omitempty"`
	PartitionKeyB64Encoded *bool   `` /* 131-byte string literal not displayed */
	// Specific a key to overwrite the message key which used for ordering dispatch in Key_Shared mode.
	OrderingKey          []byte   `protobuf:"bytes,7,opt,name=ordering_key,json=orderingKey" json:"ordering_key,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

nolint

func (*SingleMessageMetadata) GetPayloadSize

func (m *SingleMessageMetadata) GetPayloadSize() int32

func (*SingleMessageMetadata) ProtoMessage

func (*SingleMessageMetadata) ProtoMessage()

func (*SingleMessageMetadata) Reset

func (m *SingleMessageMetadata) Reset()

func (*SingleMessageMetadata) String

func (m *SingleMessageMetadata) String() string

type SinkConfig

type SinkConfig struct {
	TopicsPattern *string    `json:"topicsPattern,omitempty" yaml:"topicsPattern"`
	Resources     *Resources `json:"resources,omitempty" yaml:"resources"`
	TimeoutMs     *int64     `json:"timeoutMs,omitempty" yaml:"timeoutMs"`

	// Whether the subscriptions the functions created/used should be deleted when the functions is deleted
	CleanupSubscription bool `json:"cleanupSubscription" yaml:"cleanupSubscription"`

	RetainOrdering    bool   `json:"retainOrdering" yaml:"retainOrdering"`
	RetainKeyOrdering bool   `json:"retainKeyOrdering" yaml:"retainKeyOrdering"`
	AutoAck           bool   `json:"autoAck" yaml:"autoAck"`
	Parallelism       int    `json:"parallelism,omitempty" yaml:"parallelism"`
	Tenant            string `json:"tenant,omitempty" yaml:"tenant"`
	Namespace         string `json:"namespace,omitempty" yaml:"namespace"`
	Name              string `json:"name,omitempty" yaml:"name"`
	ClassName         string `json:"className,omitempty" yaml:"className"`

	SinkType                   string `json:"sinkType,omitempty" yaml:"sinkType"`
	Archive                    string `json:"archive,omitempty" yaml:"archive"`
	ProcessingGuarantees       string `json:"processingGuarantees,omitempty" yaml:"processingGuarantees"`
	SourceSubscriptionName     string `json:"sourceSubscriptionName,omitempty" yaml:"sourceSubscriptionName"`
	SourceSubscriptionPosition string `json:"sourceSubscriptionPosition,omitempty" yaml:"sourceSubscriptionPosition"`
	RuntimeFlags               string `json:"runtimeFlags,omitempty" yaml:"runtimeFlags"`

	Inputs                []string                  `json:"inputs,omitempty" yaml:"inputs"`
	TopicToSerdeClassName map[string]string         `json:"topicToSerdeClassName,omitempty" yaml:"topicToSerdeClassName"`
	TopicToSchemaType     map[string]string         `json:"topicToSchemaType,omitempty" yaml:"topicToSchemaType"`
	InputSpecs            map[string]ConsumerConfig `json:"inputSpecs,omitempty" yaml:"inputSpecs"`
	Configs               map[string]interface{}    `json:"configs,omitempty" yaml:"configs"`

	TopicToSchemaProperties map[string]string `json:"topicToSchemaProperties,omitempty" yaml:"topicToSchemaProperties"`

	CustomRuntimeOptions string `json:"customRuntimeOptions,omitempty" yaml:"customRuntimeOptions"`

	// This is a map of secretName(aka how the secret is going to be
	// accessed in the function via context) to an object that
	// encapsulates how the secret is fetched by the underlying
	// secrets provider. The type of an value here can be found by the
	// SecretProviderConfigurator.getSecretObjectType() method.
	Secrets map[string]interface{} `json:"secrets,omitempty" yaml:"secrets"`

	MaxMessageRetries            int    `json:"maxMessageRetries,omitempty" yaml:"maxMessageRetries"`
	DeadLetterTopic              string `json:"deadLetterTopic,omitempty" yaml:"deadLetterTopic"`
	NegativeAckRedeliveryDelayMs int64  `json:"negativeAckRedeliveryDelayMs,omitempty" yaml:"negativeAckRedeliveryDelayMs"`
	TransformFunction            string `json:"transformFunction,omitempty" yaml:"transformFunction"`
	TransformFunctionClassName   string `json:"transformFunctionClassName,omitempty" yaml:"transformFunctionClassName"`
	TransformFunctionConfig      string `json:"transformFunctionConfig,omitempty" yaml:"transformFunctionConfig"`
}

type SinkData

type SinkData struct {
	UpdateAuthData               bool        `json:"updateAuthData,omitempty"`
	RetainOrdering               bool        `json:"retainOrdering,omitempty"`
	AutoAck                      bool        `json:"autoAck,omitempty"`
	Parallelism                  int         `json:"parallelism,omitempty"`
	RAM                          int64       `json:"ram,omitempty"`
	Disk                         int64       `json:"disk,omitempty"`
	TimeoutMs                    int64       `json:"timeoutMs,omitempty"`
	CPU                          float64     `json:"cpu,omitempty"`
	Tenant                       string      `json:"tenant,omitempty"`
	Namespace                    string      `json:"namespace,omitempty"`
	Name                         string      `json:"name,omitempty"`
	SinkType                     string      `json:"sinkType,omitempty"`
	CleanupSubscription          bool        `json:"cleanupSubscription"`
	Inputs                       string      `json:"inputs,omitempty"`
	TopicsPattern                string      `json:"topicsPattern,omitempty"`
	SubsName                     string      `json:"subsName,omitempty"`
	SubsPosition                 string      `json:"subsPosition,omitempty"`
	CustomSerdeInputString       string      `json:"customSerdeInputString,omitempty"`
	CustomSchemaInputString      string      `json:"customSchemaInputString,omitempty"`
	InputSpecs                   string      `json:"inputSpecs,omitempty"`
	MaxMessageRetries            int         `json:"maxMessageRetries,omitempty"`
	DeadLetterTopic              string      `json:"deadLetterTopic,omitempty"`
	ProcessingGuarantees         string      `json:"processingGuarantees,omitempty"`
	RetainKeyOrdering            bool        `json:"retainKeyOrdering,omitempty"`
	Archive                      string      `json:"archive,omitempty"`
	ClassName                    string      `json:"className,omitempty"`
	SinkConfigFile               string      `json:"sinkConfigFile,omitempty"`
	SinkConfigString             string      `json:"sinkConfigString,omitempty"`
	NegativeAckRedeliveryDelayMs int64       `json:"negativeAckRedeliveryDelayMs,omitempty"`
	CustomRuntimeOptions         string      `json:"customRuntimeOptions,omitempty"`
	Secrets                      string      `json:"secretsString,omitempty"`
	InstanceID                   string      `json:"instanceId,omitempty"`
	TransformFunction            string      `json:"transformFunction,omitempty"`
	TransformFunctionClassName   string      `json:"transformFunctionClassName,omitempty"`
	TransformFunctionConfig      string      `json:"transformFunctionConfig,omitempty"`
	RuntimeFlags                 string      `json:"runtimeFlags,omitempty"`
	SinkConf                     *SinkConfig `json:"-,omitempty"`
}

type SinkInstanceStatus

type SinkInstanceStatus struct {
	InstanceID int                    `json:"instanceId"`
	Status     SinkInstanceStatusData `json:"status"`
}

type SinkInstanceStatusData

type SinkInstanceStatusData struct {
	// Is this instance running?
	Running bool `json:"running"`

	// Do we have any error while running this instance
	Err string `json:"error"`

	// Number of times this instance has restarted
	NumRestarts int64 `json:"numRestarts"`

	// Number of messages read from Pulsar
	NumReadFromPulsar int64 `json:"numReadFromPulsar"`

	// Number of times there was a system exception handling messages
	NumSystemExceptions int64 `json:"numSystemExceptions"`

	// A list of the most recent system exceptions
	LatestSystemExceptions []ExceptionInformation `json:"latestSystemExceptions"`

	// Number of times there was a sink exception
	NumSinkExceptions int64 `json:"numSinkExceptions"`

	// A list of the most recent sink exceptions
	LatestSinkExceptions []ExceptionInformation `json:"latestSinkExceptions"`

	// Number of messages written to sink
	NumWrittenToSink int64 `json:"numWrittenToSink"`

	// When was the last time we received a Message from Pulsar
	LastReceivedTime int64 `json:"lastReceivedTime"`

	WorkerID string `json:"workerId"`
}

type SinkStatus

type SinkStatus struct {
	// The total number of sink instances that ought to be running
	NumInstances int `json:"numInstances"`

	// The number of source instances that are actually running
	NumRunning int `json:"numRunning"`

	Instances []*SinkInstanceStatus `json:"instances"`
}

type SourceConfig

type SourceConfig struct {
	Tenant    string `json:"tenant,omitempty" yaml:"tenant"`
	Namespace string `json:"namespace,omitempty" yaml:"namespace"`
	Name      string `json:"name,omitempty" yaml:"name"`
	ClassName string `json:"className,omitempty" yaml:"className"`

	ProducerConfig *ProducerConfig `json:"producerConfig,omitempty" yaml:"producerConfig"`

	TopicName      string `json:"topicName,omitempty" yaml:"topicName"`
	SerdeClassName string `json:"serdeClassName,omitempty" yaml:"serdeClassName"`
	SchemaType     string `json:"schemaType,omitempty" yaml:"schemaType"`

	Configs map[string]interface{} `json:"configs,omitempty" yaml:"configs"`

	// This is a map of secretName(aka how the secret is going to be
	// accessed in the function via context) to an object that
	// encapsulates how the secret is fetched by the underlying
	// secrets provider. The type of an value here can be found by the
	// SecretProviderConfigurator.getSecretObjectType() method.
	Secrets map[string]interface{} `json:"secrets,omitempty" yaml:"secrets"`

	Parallelism          int        `json:"parallelism,omitempty" yaml:"parallelism"`
	ProcessingGuarantees string     `json:"processingGuarantees,omitempty" yaml:"processingGuarantees"`
	Resources            *Resources `json:"resources,omitempty" yaml:"resources"`
	Archive              string     `json:"archive,omitempty" yaml:"archive"`
	// Any flags that you want to pass to the runtime.
	RuntimeFlags string `json:"runtimeFlags,omitempty" yaml:"runtimeFlags"`

	CustomRuntimeOptions string `json:"customRuntimeOptions,omitempty" yaml:"customRuntimeOptions"`

	BatchSourceConfig *BatchSourceConfig `json:"batchSourceConfig,omitempty" yaml:"batchSourceConfig"`
	BatchBuilder      string             `json:"batchBuilder,omitempty" yaml:"batchBuilder"`
}

type SourceData

type SourceData struct {
	Tenant                   string  `json:"tenant,omitempty"`
	Namespace                string  `json:"namespace,omitempty"`
	Name                     string  `json:"name,omitempty"`
	SourceType               string  `json:"sourceType,omitempty"`
	ProcessingGuarantees     string  `json:"processingGuarantees,omitempty"`
	DestinationTopicName     string  `json:"destinationTopicName,omitempty"`
	ProducerConfig           string  `json:"producerConfig,omitempty"`
	BatchBuilder             string  `json:"batchBuilder,omitempty"`
	DeserializationClassName string  `json:"deserializationClassName,omitempty"`
	SchemaType               string  `json:"schemaType,omitempty"`
	Parallelism              int     `json:"parallelism,omitempty"`
	Archive                  string  `json:"archive,omitempty"`
	ClassName                string  `json:"className,omitempty"`
	SourceConfigFile         string  `json:"sourceConfigFile,omitempty"`
	CPU                      float64 `json:"cpu,omitempty"`
	RAM                      int64   `json:"ram,omitempty"`
	Disk                     int64   `json:"disk,omitempty"`
	SourceConfigString       string  `json:"sourceConfigString,omitempty"`
	BatchSourceConfigString  string  `json:"batchSourceConfigString,omitempty"`
	CustomRuntimeOptions     string  `json:"customRuntimeOptions,omitempty"`
	Secrets                  string  `json:"secretsString,omitempty"`

	SourceConf *SourceConfig `json:"-,omitempty"`
	InstanceID string        `json:"instanceId,omitempty"`

	UpdateAuthData bool   `json:"updateAuthData,omitempty"`
	RuntimeFlags   string `json:"runtimeFlags,omitempty"`
}

type SourceInstanceStatus

type SourceInstanceStatus struct {
	InstanceID int                      `json:"instanceId"`
	Status     SourceInstanceStatusData `json:"status"`
}

type SourceInstanceStatusData

type SourceInstanceStatusData struct {
	Running                bool                   `json:"running"`
	Err                    string                 `json:"error"`
	NumRestarts            int64                  `json:"numRestarts"`
	NumReceivedFromSource  int64                  `json:"numReceivedFromSource"`
	NumSystemExceptions    int64                  `json:"numSystemExceptions"`
	LatestSystemExceptions []ExceptionInformation `json:"latestSystemExceptions"`
	NumSourceExceptions    int64                  `json:"numSourceExceptions"`
	LatestSourceExceptions []ExceptionInformation `json:"latestSourceExceptions"`
	NumWritten             int64                  `json:"numWritten"`
	LastReceivedTime       int64                  `json:"lastReceivedTime"`
	WorkerID               string                 `json:"workerId"`
}

type SourceStatus

type SourceStatus struct {
	NumInstances int                     `json:"numInstances"`
	NumRunning   int                     `json:"numRunning"`
	Instances    []*SourceInstanceStatus `json:"instances"`
}

type Status

type Status string
const (
	NOTRUN  Status = "NOT_RUN"
	RUNNING Status = "RUNNING"
	SUCCESS Status = "SUCCESS"
	ERROR   Status = "ERROR"
)

func (Status) String

func (s Status) String() string

type SubscribeRate

type SubscribeRate struct {
	SubscribeThrottlingRatePerConsumer int `json:"subscribeThrottlingRatePerConsumer"`
	RatePeriodInSecond                 int `json:"ratePeriodInSecond"`
}

func NewSubscribeRate

func NewSubscribeRate() *SubscribeRate

type SubscriptionAuthMode

type SubscriptionAuthMode string
const (
	None   SubscriptionAuthMode = "None"
	Prefix SubscriptionAuthMode = "Prefix"
)

func ParseSubscriptionAuthMode

func ParseSubscriptionAuthMode(s string) (SubscriptionAuthMode, error)

func (SubscriptionAuthMode) String

func (s SubscriptionAuthMode) String() string

type SubscriptionStats

type SubscriptionStats struct {
	BlockedSubscriptionOnUnackedMsgs bool            `json:"blockedSubscriptionOnUnackedMsgs"`
	IsReplicated                     bool            `json:"isReplicated"`
	LastConsumedFlowTimestamp        int64           `json:"lastConsumedFlowTimestamp"`
	LastConsumedTimestamp            int64           `json:"lastConsumedTimestamp"`
	LastAckedTimestamp               int64           `json:"lastAckedTimestamp"`
	MsgRateOut                       float64         `json:"msgRateOut"`
	MsgThroughputOut                 float64         `json:"msgThroughputOut"`
	MsgRateRedeliver                 float64         `json:"msgRateRedeliver"`
	MsgRateExpired                   float64         `json:"msgRateExpired"`
	MsgBacklog                       int64           `json:"msgBacklog"`
	MsgBacklogNoDelayed              int64           `json:"msgBacklogNoDelayed"`
	MsgDelayed                       int64           `json:"msgDelayed"`
	UnAckedMessages                  int64           `json:"unackedMessages"`
	SubType                          string          `json:"type"`
	ActiveConsumerName               string          `json:"activeConsumerName"`
	Consumers                        []ConsumerStats `json:"consumers"`
}

type TenantData

type TenantData struct {
	Name            string   `json:"-"`
	AdminRoles      []string `json:"adminRoles"`
	AllowedClusters []string `json:"allowedClusters"`
}

Tenant args

type TopicAutoCreationConfig

type TopicAutoCreationConfig struct {
	Allow      bool      `json:"allowAutoTopicCreation"`
	Type       TopicType `json:"topicType"`
	Partitions *int      `json:"defaultNumPartitions"`
}

type TopicDomain

type TopicDomain string

func ParseTopicDomain

func ParseTopicDomain(domain string) (TopicDomain, error)

func (TopicDomain) String

func (t TopicDomain) String() string

type TopicName

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

func GetTopicName

func GetTopicName(completeName string) (*TopicName, error)

The topic name can be in two different forms, one is fully qualified topic name, the other one is short topic name

func (*TopicName) GetDomain

func (t *TopicName) GetDomain() TopicDomain

func (*TopicName) GetEncodedTopic

func (t *TopicName) GetEncodedTopic() string

func (*TopicName) GetLocalName

func (t *TopicName) GetLocalName() string

func (*TopicName) GetNamespace

func (t *TopicName) GetNamespace() string

func (*TopicName) GetPartition

func (t *TopicName) GetPartition(index int) (*TopicName, error)

func (*TopicName) GetPartitionIndex added in v0.14.0

func (t *TopicName) GetPartitionIndex() int

func (*TopicName) GetRestPath

func (t *TopicName) GetRestPath() string

func (*TopicName) GetTenant

func (t *TopicName) GetTenant() string

func (*TopicName) IsPersistent

func (t *TopicName) IsPersistent() bool

func (*TopicName) String

func (t *TopicName) String() string

type TopicStats

type TopicStats struct {
	BacklogSize         int64                        `json:"backlogSize"`
	MsgCounterIn        int64                        `json:"msgInCounter"`
	MsgCounterOut       int64                        `json:"msgOutCounter"`
	MsgRateIn           float64                      `json:"msgRateIn"`
	MsgRateOut          float64                      `json:"msgRateOut"`
	MsgThroughputIn     float64                      `json:"msgThroughputIn"`
	MsgThroughputOut    float64                      `json:"msgThroughputOut"`
	AverageMsgSize      float64                      `json:"averageMsgSize"`
	StorageSize         int64                        `json:"storageSize"`
	Publishers          []PublisherStats             `json:"publishers"`
	Subscriptions       map[string]SubscriptionStats `json:"subscriptions"`
	Replication         map[string]ReplicatorStats   `json:"replication"`
	DeDuplicationStatus string                       `json:"deduplicationStatus"`
}

type TopicStatsStream

type TopicStatsStream struct {
	TopicsMap map[string]map[string]map[string]TopicStats `json:"topicStatsBuf"`
}

type TopicType

type TopicType string
const (
	Partitioned    TopicType = "partitioned"
	NonPartitioned TopicType = "non-partitioned"
)

func ParseTopicType

func ParseTopicType(topicType string) (TopicType, error)

func (TopicType) String

func (t TopicType) String() string

type TopicVersion added in v0.13.0

type TopicVersion string
const (
	TopicVersionV1 TopicVersion = "V1"
	TopicVersionV2 TopicVersion = "V2"
)

func (TopicVersion) String added in v0.13.0

func (t TopicVersion) String() string

type UpdateOptions

type UpdateOptions struct {
	UpdateAuthData bool
}

Options while updating the sink

func NewUpdateOptions

func NewUpdateOptions() *UpdateOptions

type WindowConfig

type WindowConfig struct {
	WindowLengthCount             *int    `json:"windowLengthCount" yaml:"windowLengthCount"`
	WindowLengthDurationMs        *int64  `json:"windowLengthDurationMs" yaml:"windowLengthDurationMs"`
	SlidingIntervalCount          *int    `json:"slidingIntervalCount" yaml:"slidingIntervalCount"`
	SlidingIntervalDurationMs     *int64  `json:"slidingIntervalDurationMs" yaml:"slidingIntervalDurationMs"`
	LateDataTopic                 *string `json:"lateDataTopic" yaml:"lateDataTopic"`
	MaxLagMs                      *int64  `json:"maxLagMs" yaml:"maxLagMs"`
	WatermarkEmitIntervalMs       *int64  `json:"watermarkEmitIntervalMs" yaml:"watermarkEmitIntervalMs"`
	TimestampExtractorClassName   *string `json:"timestampExtractorClassName" yaml:"timestampExtractorClassName"`
	ActualWindowFunctionClassName *string `json:"actualWindowFunctionClassName" yaml:"actualWindowFunctionClassName"`
	ProcessingGuarantees          *string `json:"processingGuarantees" yaml:"processingGuarantees"`
}

func NewDefaultWindowConfing

func NewDefaultWindowConfing() *WindowConfig

type WorkerFunctionInstanceStats

type WorkerFunctionInstanceStats struct {
	Name    string                    `json:"name"`
	Metrics FunctionInstanceStatsData `json:"metrics"`
}

type WorkerInfo

type WorkerInfo struct {
	WorkerID       string `json:"workerId"`
	WorkerHostname string `json:"workerHostname"`
	Port           int    `json:"port"`
}

Jump to

Keyboard shortcuts

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