Documentation ¶
Index ¶
- type DataPlaneAPI
- func (o *DataPlaneAPI) AuthenticatorsFor(schemes map[string]spec.SecurityScheme) map[string]runtime.Authenticator
- func (o *DataPlaneAPI) Authorizer() runtime.Authorizer
- func (o *DataPlaneAPI) ConsumersFor(mediaTypes []string) map[string]runtime.Consumer
- func (o *DataPlaneAPI) Context() *middleware.Context
- func (o *DataPlaneAPI) DefaultConsumes() string
- func (o *DataPlaneAPI) DefaultProduces() string
- func (o *DataPlaneAPI) Formats() strfmt.Registry
- func (o *DataPlaneAPI) HandlerFor(method, path string) (http.Handler, bool)
- func (o *DataPlaneAPI) Init()
- func (o *DataPlaneAPI) ProducersFor(mediaTypes []string) map[string]runtime.Producer
- func (o *DataPlaneAPI) RegisterConsumer(mediaType string, consumer runtime.Consumer)
- func (o *DataPlaneAPI) RegisterFormat(name string, format strfmt.Format, validator strfmt.Validator)
- func (o *DataPlaneAPI) RegisterProducer(mediaType string, producer runtime.Producer)
- func (o *DataPlaneAPI) Serve(builder middleware.Builder) http.Handler
- func (o *DataPlaneAPI) ServeErrorFor(operationID string) func(http.ResponseWriter, *http.Request, error)
- func (o *DataPlaneAPI) SetDefaultConsumes(mediaType string)
- func (o *DataPlaneAPI) SetDefaultProduces(mediaType string)
- func (o *DataPlaneAPI) SetSpec(spec *loads.Document)
- func (o *DataPlaneAPI) Validate() error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type DataPlaneAPI ¶
type DataPlaneAPI struct { Middleware func(middleware.Builder) http.Handler // BasicAuthenticator generates a runtime.Authenticator from the supplied basic auth function. // It has a default implementation in the security package, however you can replace it for your particular usage. BasicAuthenticator func(security.UserPassAuthentication) runtime.Authenticator // APIKeyAuthenticator generates a runtime.Authenticator from the supplied token auth function. // It has a default implementation in the security package, however you can replace it for your particular usage. APIKeyAuthenticator func(string, string, security.TokenAuthentication) runtime.Authenticator // BearerAuthenticator generates a runtime.Authenticator from the supplied bearer token auth function. // It has a default implementation in the security package, however you can replace it for your particular usage. BearerAuthenticator func(string, security.ScopedTokenAuthentication) runtime.Authenticator // JSONConsumer registers a consumer for a "application/json" mime type JSONConsumer runtime.Consumer // TxtConsumer registers a consumer for a "text/plain" mime type TxtConsumer runtime.Consumer // JSONProducer registers a producer for a "application/json" mime type JSONProducer runtime.Producer // TxtProducer registers a producer for a "text/plain" mime type TxtProducer runtime.Producer // BasicAuthAuth registers a function that takes username and password and returns a principal // it performs authentication with basic auth BasicAuthAuth func(string, string) (interface{}, error) // APIAuthorizer provides access control (ACL/RBAC/ABAC) by providing access to the request and authenticated principal APIAuthorizer runtime.Authorizer // TransactionsCommitTransactionHandler sets the operation handler for the commit transaction operation TransactionsCommitTransactionHandler transactions.CommitTransactionHandler // ACLCreateACLHandler sets the operation handler for the create Acl operation ACLCreateACLHandler acl.CreateACLHandler // BackendCreateBackendHandler sets the operation handler for the create backend operation BackendCreateBackendHandler backend.CreateBackendHandler // BackendSwitchingRuleCreateBackendSwitchingRuleHandler sets the operation handler for the create backend switching rule operation BackendSwitchingRuleCreateBackendSwitchingRuleHandler backend_switching_rule.CreateBackendSwitchingRuleHandler // BindCreateBindHandler sets the operation handler for the create bind operation BindCreateBindHandler bind.CreateBindHandler // FilterCreateFilterHandler sets the operation handler for the create filter operation FilterCreateFilterHandler filter.CreateFilterHandler // FrontendCreateFrontendHandler sets the operation handler for the create frontend operation FrontendCreateFrontendHandler frontend.CreateFrontendHandler // HTTPRequestRuleCreateHTTPRequestRuleHandler sets the operation handler for the create HTTP request rule operation HTTPRequestRuleCreateHTTPRequestRuleHandler http_request_rule.CreateHTTPRequestRuleHandler // HTTPResponseRuleCreateHTTPResponseRuleHandler sets the operation handler for the create HTTP response rule operation HTTPResponseRuleCreateHTTPResponseRuleHandler http_response_rule.CreateHTTPResponseRuleHandler // LogTargetCreateLogTargetHandler sets the operation handler for the create log target operation LogTargetCreateLogTargetHandler log_target.CreateLogTargetHandler // ServerCreateServerHandler sets the operation handler for the create server operation ServerCreateServerHandler server.CreateServerHandler // ServerSwitchingRuleCreateServerSwitchingRuleHandler sets the operation handler for the create server switching rule operation ServerSwitchingRuleCreateServerSwitchingRuleHandler server_switching_rule.CreateServerSwitchingRuleHandler // SitesCreateSiteHandler sets the operation handler for the create site operation SitesCreateSiteHandler sites.CreateSiteHandler // StickRuleCreateStickRuleHandler sets the operation handler for the create stick rule operation StickRuleCreateStickRuleHandler stick_rule.CreateStickRuleHandler // TCPRequestRuleCreateTCPRequestRuleHandler sets the operation handler for the create TCP request rule operation TCPRequestRuleCreateTCPRequestRuleHandler tcp_request_rule.CreateTCPRequestRuleHandler // TCPResponseRuleCreateTCPResponseRuleHandler sets the operation handler for the create TCP response rule operation TCPResponseRuleCreateTCPResponseRuleHandler tcp_response_rule.CreateTCPResponseRuleHandler // ACLDeleteACLHandler sets the operation handler for the delete Acl operation ACLDeleteACLHandler acl.DeleteACLHandler // BackendDeleteBackendHandler sets the operation handler for the delete backend operation BackendDeleteBackendHandler backend.DeleteBackendHandler // BackendSwitchingRuleDeleteBackendSwitchingRuleHandler sets the operation handler for the delete backend switching rule operation BackendSwitchingRuleDeleteBackendSwitchingRuleHandler backend_switching_rule.DeleteBackendSwitchingRuleHandler // BindDeleteBindHandler sets the operation handler for the delete bind operation BindDeleteBindHandler bind.DeleteBindHandler // FilterDeleteFilterHandler sets the operation handler for the delete filter operation FilterDeleteFilterHandler filter.DeleteFilterHandler // FrontendDeleteFrontendHandler sets the operation handler for the delete frontend operation FrontendDeleteFrontendHandler frontend.DeleteFrontendHandler // HTTPRequestRuleDeleteHTTPRequestRuleHandler sets the operation handler for the delete HTTP request rule operation HTTPRequestRuleDeleteHTTPRequestRuleHandler http_request_rule.DeleteHTTPRequestRuleHandler // HTTPResponseRuleDeleteHTTPResponseRuleHandler sets the operation handler for the delete HTTP response rule operation HTTPResponseRuleDeleteHTTPResponseRuleHandler http_response_rule.DeleteHTTPResponseRuleHandler // LogTargetDeleteLogTargetHandler sets the operation handler for the delete log target operation LogTargetDeleteLogTargetHandler log_target.DeleteLogTargetHandler // ServerDeleteServerHandler sets the operation handler for the delete server operation ServerDeleteServerHandler server.DeleteServerHandler // ServerSwitchingRuleDeleteServerSwitchingRuleHandler sets the operation handler for the delete server switching rule operation ServerSwitchingRuleDeleteServerSwitchingRuleHandler server_switching_rule.DeleteServerSwitchingRuleHandler // SitesDeleteSiteHandler sets the operation handler for the delete site operation SitesDeleteSiteHandler sites.DeleteSiteHandler // StickRuleDeleteStickRuleHandler sets the operation handler for the delete stick rule operation StickRuleDeleteStickRuleHandler stick_rule.DeleteStickRuleHandler // TCPRequestRuleDeleteTCPRequestRuleHandler sets the operation handler for the delete TCP request rule operation TCPRequestRuleDeleteTCPRequestRuleHandler tcp_request_rule.DeleteTCPRequestRuleHandler // TCPResponseRuleDeleteTCPResponseRuleHandler sets the operation handler for the delete TCP response rule operation TCPResponseRuleDeleteTCPResponseRuleHandler tcp_response_rule.DeleteTCPResponseRuleHandler // TransactionsDeleteTransactionHandler sets the operation handler for the delete transaction operation TransactionsDeleteTransactionHandler transactions.DeleteTransactionHandler // DiscoveryGetAPIEndpointsHandler sets the operation handler for the get API endpoints operation DiscoveryGetAPIEndpointsHandler discovery.GetAPIEndpointsHandler // ACLGetACLHandler sets the operation handler for the get Acl operation ACLGetACLHandler acl.GetACLHandler // ACLGetAclsHandler sets the operation handler for the get acls operation ACLGetAclsHandler acl.GetAclsHandler // BackendGetBackendHandler sets the operation handler for the get backend operation BackendGetBackendHandler backend.GetBackendHandler // BackendSwitchingRuleGetBackendSwitchingRuleHandler sets the operation handler for the get backend switching rule operation BackendSwitchingRuleGetBackendSwitchingRuleHandler backend_switching_rule.GetBackendSwitchingRuleHandler // BackendSwitchingRuleGetBackendSwitchingRulesHandler sets the operation handler for the get backend switching rules operation BackendSwitchingRuleGetBackendSwitchingRulesHandler backend_switching_rule.GetBackendSwitchingRulesHandler // BackendGetBackendsHandler sets the operation handler for the get backends operation BackendGetBackendsHandler backend.GetBackendsHandler // BindGetBindHandler sets the operation handler for the get bind operation BindGetBindHandler bind.GetBindHandler // BindGetBindsHandler sets the operation handler for the get binds operation BindGetBindsHandler bind.GetBindsHandler // DiscoveryGetConfigurationEndpointsHandler sets the operation handler for the get configuration endpoints operation DiscoveryGetConfigurationEndpointsHandler discovery.GetConfigurationEndpointsHandler // DefaultsGetDefaultsHandler sets the operation handler for the get defaults operation DefaultsGetDefaultsHandler defaults.GetDefaultsHandler // FilterGetFilterHandler sets the operation handler for the get filter operation FilterGetFilterHandler filter.GetFilterHandler // FilterGetFiltersHandler sets the operation handler for the get filters operation FilterGetFiltersHandler filter.GetFiltersHandler // FrontendGetFrontendHandler sets the operation handler for the get frontend operation FrontendGetFrontendHandler frontend.GetFrontendHandler // FrontendGetFrontendsHandler sets the operation handler for the get frontends operation FrontendGetFrontendsHandler frontend.GetFrontendsHandler // GlobalGetGlobalHandler sets the operation handler for the get global operation GlobalGetGlobalHandler global.GetGlobalHandler // ConfigurationGetHAProxyConfigurationHandler sets the operation handler for the get h a proxy configuration operation ConfigurationGetHAProxyConfigurationHandler configuration.GetHAProxyConfigurationHandler // HTTPRequestRuleGetHTTPRequestRuleHandler sets the operation handler for the get HTTP request rule operation HTTPRequestRuleGetHTTPRequestRuleHandler http_request_rule.GetHTTPRequestRuleHandler // HTTPRequestRuleGetHTTPRequestRulesHandler sets the operation handler for the get HTTP request rules operation HTTPRequestRuleGetHTTPRequestRulesHandler http_request_rule.GetHTTPRequestRulesHandler // HTTPResponseRuleGetHTTPResponseRuleHandler sets the operation handler for the get HTTP response rule operation HTTPResponseRuleGetHTTPResponseRuleHandler http_response_rule.GetHTTPResponseRuleHandler // HTTPResponseRuleGetHTTPResponseRulesHandler sets the operation handler for the get HTTP response rules operation HTTPResponseRuleGetHTTPResponseRulesHandler http_response_rule.GetHTTPResponseRulesHandler // DiscoveryGetHaproxyEndpointsHandler sets the operation handler for the get haproxy endpoints operation DiscoveryGetHaproxyEndpointsHandler discovery.GetHaproxyEndpointsHandler // InformationGetHaproxyProcessInfoHandler sets the operation handler for the get haproxy process info operation InformationGetHaproxyProcessInfoHandler information.GetHaproxyProcessInfoHandler // InformationGetInfoHandler sets the operation handler for the get info operation InformationGetInfoHandler information.GetInfoHandler // LogTargetGetLogTargetHandler sets the operation handler for the get log target operation LogTargetGetLogTargetHandler log_target.GetLogTargetHandler // LogTargetGetLogTargetsHandler sets the operation handler for the get log targets operation LogTargetGetLogTargetsHandler log_target.GetLogTargetsHandler // ReloadsGetReloadHandler sets the operation handler for the get reload operation ReloadsGetReloadHandler reloads.GetReloadHandler // ReloadsGetReloadsHandler sets the operation handler for the get reloads operation ReloadsGetReloadsHandler reloads.GetReloadsHandler // ServerGetServerHandler sets the operation handler for the get server operation ServerGetServerHandler server.GetServerHandler // ServerSwitchingRuleGetServerSwitchingRuleHandler sets the operation handler for the get server switching rule operation ServerSwitchingRuleGetServerSwitchingRuleHandler server_switching_rule.GetServerSwitchingRuleHandler // ServerSwitchingRuleGetServerSwitchingRulesHandler sets the operation handler for the get server switching rules operation ServerSwitchingRuleGetServerSwitchingRulesHandler server_switching_rule.GetServerSwitchingRulesHandler // ServerGetServersHandler sets the operation handler for the get servers operation ServerGetServersHandler server.GetServersHandler // DiscoveryGetServicesEndpointsHandler sets the operation handler for the get services endpoints operation DiscoveryGetServicesEndpointsHandler discovery.GetServicesEndpointsHandler // SitesGetSiteHandler sets the operation handler for the get site operation SitesGetSiteHandler sites.GetSiteHandler // SitesGetSitesHandler sets the operation handler for the get sites operation SitesGetSitesHandler sites.GetSitesHandler // SpecificationGetSpecificationHandler sets the operation handler for the get specification operation SpecificationGetSpecificationHandler specification.GetSpecificationHandler // StatsGetStatsHandler sets the operation handler for the get stats operation StatsGetStatsHandler stats.GetStatsHandler // DiscoveryGetStatsEndpointsHandler sets the operation handler for the get stats endpoints operation DiscoveryGetStatsEndpointsHandler discovery.GetStatsEndpointsHandler // StickRuleGetStickRuleHandler sets the operation handler for the get stick rule operation StickRuleGetStickRuleHandler stick_rule.GetStickRuleHandler // StickRuleGetStickRulesHandler sets the operation handler for the get stick rules operation StickRuleGetStickRulesHandler stick_rule.GetStickRulesHandler // TCPRequestRuleGetTCPRequestRuleHandler sets the operation handler for the get TCP request rule operation TCPRequestRuleGetTCPRequestRuleHandler tcp_request_rule.GetTCPRequestRuleHandler // TCPRequestRuleGetTCPRequestRulesHandler sets the operation handler for the get TCP request rules operation TCPRequestRuleGetTCPRequestRulesHandler tcp_request_rule.GetTCPRequestRulesHandler // TCPResponseRuleGetTCPResponseRuleHandler sets the operation handler for the get TCP response rule operation TCPResponseRuleGetTCPResponseRuleHandler tcp_response_rule.GetTCPResponseRuleHandler // TCPResponseRuleGetTCPResponseRulesHandler sets the operation handler for the get TCP response rules operation TCPResponseRuleGetTCPResponseRulesHandler tcp_response_rule.GetTCPResponseRulesHandler // TransactionsGetTransactionHandler sets the operation handler for the get transaction operation TransactionsGetTransactionHandler transactions.GetTransactionHandler // TransactionsGetTransactionsHandler sets the operation handler for the get transactions operation TransactionsGetTransactionsHandler transactions.GetTransactionsHandler // ConfigurationPostHAProxyConfigurationHandler sets the operation handler for the post h a proxy configuration operation ConfigurationPostHAProxyConfigurationHandler configuration.PostHAProxyConfigurationHandler // ACLReplaceACLHandler sets the operation handler for the replace Acl operation ACLReplaceACLHandler acl.ReplaceACLHandler // BackendReplaceBackendHandler sets the operation handler for the replace backend operation BackendReplaceBackendHandler backend.ReplaceBackendHandler // BackendSwitchingRuleReplaceBackendSwitchingRuleHandler sets the operation handler for the replace backend switching rule operation BackendSwitchingRuleReplaceBackendSwitchingRuleHandler backend_switching_rule.ReplaceBackendSwitchingRuleHandler // BindReplaceBindHandler sets the operation handler for the replace bind operation BindReplaceBindHandler bind.ReplaceBindHandler // DefaultsReplaceDefaultsHandler sets the operation handler for the replace defaults operation DefaultsReplaceDefaultsHandler defaults.ReplaceDefaultsHandler // FilterReplaceFilterHandler sets the operation handler for the replace filter operation FilterReplaceFilterHandler filter.ReplaceFilterHandler // FrontendReplaceFrontendHandler sets the operation handler for the replace frontend operation FrontendReplaceFrontendHandler frontend.ReplaceFrontendHandler // GlobalReplaceGlobalHandler sets the operation handler for the replace global operation GlobalReplaceGlobalHandler global.ReplaceGlobalHandler // HTTPRequestRuleReplaceHTTPRequestRuleHandler sets the operation handler for the replace HTTP request rule operation HTTPRequestRuleReplaceHTTPRequestRuleHandler http_request_rule.ReplaceHTTPRequestRuleHandler // HTTPResponseRuleReplaceHTTPResponseRuleHandler sets the operation handler for the replace HTTP response rule operation HTTPResponseRuleReplaceHTTPResponseRuleHandler http_response_rule.ReplaceHTTPResponseRuleHandler // LogTargetReplaceLogTargetHandler sets the operation handler for the replace log target operation LogTargetReplaceLogTargetHandler log_target.ReplaceLogTargetHandler // ServerReplaceServerHandler sets the operation handler for the replace server operation ServerReplaceServerHandler server.ReplaceServerHandler // ServerSwitchingRuleReplaceServerSwitchingRuleHandler sets the operation handler for the replace server switching rule operation ServerSwitchingRuleReplaceServerSwitchingRuleHandler server_switching_rule.ReplaceServerSwitchingRuleHandler // SitesReplaceSiteHandler sets the operation handler for the replace site operation SitesReplaceSiteHandler sites.ReplaceSiteHandler // StickRuleReplaceStickRuleHandler sets the operation handler for the replace stick rule operation StickRuleReplaceStickRuleHandler stick_rule.ReplaceStickRuleHandler // TCPRequestRuleReplaceTCPRequestRuleHandler sets the operation handler for the replace TCP request rule operation TCPRequestRuleReplaceTCPRequestRuleHandler tcp_request_rule.ReplaceTCPRequestRuleHandler // TCPResponseRuleReplaceTCPResponseRuleHandler sets the operation handler for the replace TCP response rule operation TCPResponseRuleReplaceTCPResponseRuleHandler tcp_response_rule.ReplaceTCPResponseRuleHandler // TransactionsStartTransactionHandler sets the operation handler for the start transaction operation TransactionsStartTransactionHandler transactions.StartTransactionHandler // ServeError is called when an error is received, there is a default handler // but you can set your own with this ServeError func(http.ResponseWriter, *http.Request, error) // ServerShutdown is called when the HTTP(S) server is shut down and done // handling all active connections and does not accept connections any more ServerShutdown func() // Custom command line argument groups with their descriptions CommandLineOptionsGroups []swag.CommandLineOptionsGroup // User defined logger function. Logger func(string, ...interface{}) // contains filtered or unexported fields }
DataPlaneAPI API for editing and managing haproxy instances. Provides process information, configuration management, haproxy stats and logs.
func NewDataPlaneAPI ¶
func NewDataPlaneAPI(spec *loads.Document) *DataPlaneAPI
NewDataPlaneAPI creates a new DataPlane instance
func (*DataPlaneAPI) AuthenticatorsFor ¶
func (o *DataPlaneAPI) AuthenticatorsFor(schemes map[string]spec.SecurityScheme) map[string]runtime.Authenticator
AuthenticatorsFor gets the authenticators for the specified security schemes
func (*DataPlaneAPI) Authorizer ¶
func (o *DataPlaneAPI) Authorizer() runtime.Authorizer
Authorizer returns the registered authorizer
func (*DataPlaneAPI) ConsumersFor ¶
func (o *DataPlaneAPI) ConsumersFor(mediaTypes []string) map[string]runtime.Consumer
ConsumersFor gets the consumers for the specified media types
func (*DataPlaneAPI) Context ¶
func (o *DataPlaneAPI) Context() *middleware.Context
Context returns the middleware context for the data plane API
func (*DataPlaneAPI) DefaultConsumes ¶
func (o *DataPlaneAPI) DefaultConsumes() string
DefaultConsumes returns the default consumes media type
func (*DataPlaneAPI) DefaultProduces ¶
func (o *DataPlaneAPI) DefaultProduces() string
DefaultProduces returns the default produces media type
func (*DataPlaneAPI) Formats ¶
func (o *DataPlaneAPI) Formats() strfmt.Registry
Formats returns the registered string formats
func (*DataPlaneAPI) HandlerFor ¶
func (o *DataPlaneAPI) HandlerFor(method, path string) (http.Handler, bool)
HandlerFor gets a http.Handler for the provided operation method and path
func (*DataPlaneAPI) Init ¶
func (o *DataPlaneAPI) Init()
Init allows you to just initialize the handler cache, you can then recompose the middleware as you see fit
func (*DataPlaneAPI) ProducersFor ¶
func (o *DataPlaneAPI) ProducersFor(mediaTypes []string) map[string]runtime.Producer
ProducersFor gets the producers for the specified media types
func (*DataPlaneAPI) RegisterConsumer ¶
func (o *DataPlaneAPI) RegisterConsumer(mediaType string, consumer runtime.Consumer)
RegisterConsumer allows you to add (or override) a consumer for a media type.
func (*DataPlaneAPI) RegisterFormat ¶
func (o *DataPlaneAPI) RegisterFormat(name string, format strfmt.Format, validator strfmt.Validator)
RegisterFormat registers a custom format validator
func (*DataPlaneAPI) RegisterProducer ¶
func (o *DataPlaneAPI) RegisterProducer(mediaType string, producer runtime.Producer)
RegisterProducer allows you to add (or override) a producer for a media type.
func (*DataPlaneAPI) Serve ¶
func (o *DataPlaneAPI) Serve(builder middleware.Builder) http.Handler
Serve creates a http handler to serve the API over HTTP can be used directly in http.ListenAndServe(":8000", api.Serve(nil))
func (*DataPlaneAPI) ServeErrorFor ¶
func (o *DataPlaneAPI) ServeErrorFor(operationID string) func(http.ResponseWriter, *http.Request, error)
ServeErrorFor gets a error handler for a given operation id
func (*DataPlaneAPI) SetDefaultConsumes ¶
func (o *DataPlaneAPI) SetDefaultConsumes(mediaType string)
SetDefaultConsumes returns the default consumes media type
func (*DataPlaneAPI) SetDefaultProduces ¶
func (o *DataPlaneAPI) SetDefaultProduces(mediaType string)
SetDefaultProduces sets the default produces media type
func (*DataPlaneAPI) SetSpec ¶
func (o *DataPlaneAPI) SetSpec(spec *loads.Document)
SetSpec sets a spec that will be served for the clients.
func (*DataPlaneAPI) Validate ¶
func (o *DataPlaneAPI) Validate() error
Validate validates the registrations in the DataPlaneAPI