Documentation ¶
Index ¶
Constants ¶
View Source
const ( // MongoDBHost ... MongoDBHost = "MONGODB_HOST" // SaltKey ... SaltKey = "SALT_KEY" // CloudAutoDiscovery ... CloudAutoDiscovery = "CLOUD_AUTO_DISCOVERY" // RecordLogRotationThreshold ... RecordRotationThreshold = "RECORD_ROTATION_THRESHOLD" // NotificationURL ... NotificationURL = "NOTIFICATION_URL" // RecordWebURLTemplate is a customer's pipeline record website URL address template. RecordWebURLTemplate = "RECORD_WEB_URL_TEMPLATE" )
api server env
View Source
const (
DefaultPort = 7099
)
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type APIServer ¶
type APIServer struct { Config *APIServerOptions WorkerOptions *options.WorkerOptions }
APIServer ...
func (*APIServer) PrepareRun ¶
func (s *APIServer) PrepareRun() (*PreparedAPIServer, error)
PrepareRun prepare for apiserver running
type APIServerOptions ¶
type APIServerOptions struct { MongoDBHost string SaltKey string MongoGracePeriod time.Duration CyclonePort int CycloneAddrTemplate string ShowAPIDoc bool CloudAutoDiscovery bool RecordRotationThreshold int NotificationURL string RecordWebURLTemplate string }
APIServerOptions contains all options(config) for api server
func NewAPIServerOptions ¶
func NewAPIServerOptions() *APIServerOptions
NewAPIServerOptions returns a new APIServerOptions
func (*APIServerOptions) AddFlags ¶
func (opts *APIServerOptions) AddFlags(app *cli.App)
AddFlags adds flags to cli.App
type PreparedAPIServer ¶
type PreparedAPIServer struct {
*APIServer
}
PreparedAPIServer is a prepared api server
func (*PreparedAPIServer) Run ¶
func (s *PreparedAPIServer) Run(stopCh <-chan struct{}) error
Run start a api server
Click to show internal directories.
Click to hide internal directories.