refactor: 重构集群主从节点模式
This commit is contained in:
@@ -2,6 +2,7 @@ package types
|
||||
|
||||
// ConfigManager defines the interface for configuration management
|
||||
type ConfigManager interface {
|
||||
IsMaster() bool
|
||||
GetAuthConfig() AuthConfig
|
||||
GetCORSConfig() CORSConfig
|
||||
GetPerformanceConfig() PerformanceConfig
|
||||
@@ -41,6 +42,7 @@ type SystemSettings struct {
|
||||
type ServerConfig struct {
|
||||
Port int `json:"port"`
|
||||
Host string `json:"host"`
|
||||
IsMaster bool `json:"is_master"`
|
||||
ReadTimeout int `json:"read_timeout"`
|
||||
WriteTimeout int `json:"write_timeout"`
|
||||
IdleTimeout int `json:"idle_timeout"`
|
||||
|
Reference in New Issue
Block a user