Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func MustGetFreePort ¶
func MustGetFreePort() int
Types ¶
type PortProvider ¶
type PortProvider struct {
// contains filtered or unexported fields
}
func NewPortProvider ¶
func NewPortProvider() *PortProvider
func (*PortProvider) Close ¶
func (p *PortProvider) Close() error
func (*PortProvider) GetFreePort ¶
func (p *PortProvider) GetFreePort() (int, error)
GetFreePort asks the kernel for a free open port that is ready to use.
func (*PortProvider) MustGetFreePort ¶
func (p *PortProvider) MustGetFreePort() int
type Server ¶
type Server struct {
// contains filtered or unexported fields
}
func Start ¶
func Start(options StartOptions) (*Server, error)
type StartOptions ¶
type StartOptions struct {
// Required fields
FrontendIP string
FrontendPort int
Namespaces []string
ClusterID string
MasterClusterName string
CurrentClusterName string
InitialFailoverVersion int
Logger *slog.Logger
LogLevel slog.Level
// Optional fields
UIIP string // Empty means no UI
UIPort int // Required if UIIP is non-empty
UIAssetPath string
UICodecEndpoint string
DatabaseFile string
MetricsPort int
PProfPort int
SqlitePragmas map[string]string
FrontendHTTPPort int
EnableGlobalNamespace bool
DynamicConfigValues map[string]any
LogConfig func([]byte)
GRPCInterceptors []grpc.UnaryServerInterceptor
}
Click to show internal directories.
Click to hide internal directories.