Files
SugarDB/internal/config/default.go
Kelvin Clement Mwinuka 000115ceb0 Created "loadmodules" args for loading ".so" modules into EchoVault.
Moved types associated with embedded commands extension into api_admin.go file and deleted types.go file as it's no longer necessary.
Updated docker-compose and Dockerfile.dev to pass .so modules to load on startup.
Volumes folder is no longer ignores except for the nodes subfolder.
2024-04-30 12:17:30 +08:00

39 lines
989 B
Go

package config
import (
"github.com/echovault/echovault/internal/constants"
"time"
)
func DefaultConfig() Config {
return Config{
TLS: false,
MTLS: false,
CertKeyPairs: make([][]string, 0),
ClientCAs: make([]string, 0),
Port: 7480,
ServerID: "",
JoinAddr: "",
BindAddr: "localhost",
RaftBindPort: 7481,
MemberListBindPort: 7946,
InMemory: false,
DataDir: ".",
BootstrapCluster: false,
AclConfig: "",
ForwardCommand: false,
RequirePass: false,
Password: "",
SnapShotThreshold: 1000,
SnapshotInterval: 5 * time.Minute,
RestoreAOF: false,
RestoreSnapshot: false,
AOFSyncStrategy: "everysec",
MaxMemory: 0,
EvictionPolicy: constants.NoEviction,
EvictionSample: 20,
EvictionInterval: 100 * time.Millisecond,
Modules: make([]string, 0),
}
}