Пример #1
0
func NewConfig() Config {
	return Config{
		MaxWALSize:             DefaultMaxWALSize,
		WALFlushInterval:       toml.Duration(DefaultWALFlushInterval),
		WALPartitionFlushDelay: toml.Duration(DefaultWALPartitionFlushDelay),
	}
}
Пример #2
0
// NewConfig returns an instance of Config with defaults.
func NewConfig() Config {
	return Config{
		WriteTimeout:       toml.Duration(DefaultWriteTimeout),
		ShardWriterTimeout: toml.Duration(DefaultShardWriterTimeout),
		ShardMapperTimeout: toml.Duration(DefaultShardMapperTimeout),
	}
}
Пример #3
0
func NewConfig() Config {
	return Config{
		Enabled:        true,
		MaxSize:        DefaultMaxSize,
		MaxAge:         toml.Duration(DefaultMaxAge),
		RetryRateLimit: DefaultRetryRateLimit,
		RetryInterval:  toml.Duration(DefaultRetryInterval),
	}
}
Пример #4
0
func NewConfig() Config {
	return Config{
		Hostname:            DefaultHostname,
		BindAddress:         DefaultBindAddress,
		RetentionAutoCreate: true,
		ElectionTimeout:     toml.Duration(DefaultElectionTimeout),
		HeartbeatTimeout:    toml.Duration(DefaultHeartbeatTimeout),
		LeaderLeaseTimeout:  toml.Duration(DefaultLeaderLeaseTimeout),
		CommitTimeout:       toml.Duration(DefaultCommitTimeout),
	}
}
Пример #5
0
func NewConfig() Config {
	return Config{Enabled: true, CheckInterval: toml.Duration(10 * time.Minute)}
}