conf

package
v0.1.2 Latest Latest
Warning

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

Go to latest
Published: Jul 6, 2022 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

View Source
const (
	DefaultDataSnapshotEntries         = 10000
	DefaultDataCompactionOverhead      = 2500
	DefaultSequenceSnapshotEntries     = 1000
	DefaultSequenceCompactionOverhead  = 250
	DefaultLocksSnapshotEntries        = 1000
	DefaultLocksCompactionOverhead     = 250
	DefaultRemotingHeartbeatInterval   = 10 * time.Second
	DefaultRemotingHeartbeatTimeout    = 5 * time.Second
	DefaultGlobalIngestLimitRowsPerSec = 1000
	DefaultRaftRTTMs                   = 50
	DefaultRaftHeartbeatRTT            = 30
	DefaultRaftElectionRTT             = 300
)
View Source
const (
	BrokerClientTypeUnknown                  = 0
	BrokerClientFake        BrokerClientType = 1
	BrokerClientDefault                      = 2
)

Variables

This section is empty.

Functions

This section is empty.

Types

type BrokerClientType

type BrokerClientType int

type BrokerConfig

type BrokerConfig struct {
	ClientType BrokerClientType  `json:"client-type,omitempty"`
	Properties map[string]string `json:"properties,omitempty"`
}

type BrokerConfigs

type BrokerConfigs map[string]BrokerConfig // Key is broker name which is referred to in the source descriptor

type Config

type Config struct {
	NodeID                           int
	ClusterID                        uint64 // All nodes in a Prana cluster must share the same ClusterID
	RaftAddresses                    []string
	NotifListenAddresses             []string
	NumShards                        int
	ReplicationFactor                int
	DataDir                          string
	TestServer                       bool
	KafkaBrokers                     BrokerConfigs
	DataSnapshotEntries              int
	DataCompactionOverhead           int
	SequenceSnapshotEntries          int
	SequenceCompactionOverhead       int
	LocksSnapshotEntries             int
	LocksCompactionOverhead          int
	RemotingHeartbeatInterval        time.Duration
	RemotingHeartbeatTimeout         time.Duration
	EnableAPIServer                  bool
	APIServerListenAddresses         []string
	EnableSourceStats                bool
	ProtobufDescriptorDir            string `` /* 164-byte string literal not displayed */
	EnableLifecycleEndpoint          bool
	LifeCycleListenAddress           string
	StartupEndpointPath              string
	ReadyEndpointPath                string
	LiveEndpointPath                 string
	MetricsBind                      string `help:"Bind address for Prometheus metrics." default:"localhost:9102" env:"METRICS_BIND"`
	EnableMetrics                    bool
	GlobalIngestLimitRowsPerSec      int
	EnableFailureInjector            bool
	ScreenDragonLogSpam              bool
	DisableShardPlacementSanityCheck bool
	RaftRTTMs                        int
	RaftElectionRTT                  int
	RaftHeartbeatRTT                 int
}

func NewDefaultConfig

func NewDefaultConfig() *Config

func NewTestConfig

func NewTestConfig(fakeKafkaID int64) *Config

func (*Config) Validate

func (c *Config) Validate() error

Jump to

Keyboard shortcuts

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