Documentation ¶
Overview ¶
Package rest provides a REST server for the Coherence Operator.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetServerHostAndPort ¶
func GetServerHostAndPort() string
GetServerHostAndPort obtains the host and port that the REST server is listening on of empty string if the server is not started.
Types ¶
type Server ¶
type Server interface { // GetAddress returns the address that this server is listening on. GetAddress() net.Addr // GetPort returns the port that this server is listening on. GetPort() int32 // Close closes this server's listener Close() error // GetHostAndPort returns the address that the REST server should be reached on by external processes GetHostAndPort() string // Start the REST server Start(ctx context.Context) error // SetupWithManager will configure the server to run when the manager starts SetupWithManager(mgr ctrl.Manager) error // Running closes when the server is running Running() <-chan struct{} }
Server is the Operator REST server.
func NewServer ¶
func NewServer(c kubernetes.Interface) Server
NewServer will create a new REST server
func NewServerWithEndpoints ¶
func NewServerWithEndpoints(c kubernetes.Interface, endpoints map[string]func(w http.ResponseWriter, r *http.Request)) Server
NewServerWithEndpoints will create a new REST server with additional endpoints
Click to show internal directories.
Click to hide internal directories.