Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
var AboutToRestoreError = errors.New("restore preparation in progress")
var MaintenanceNoLoginError = errors.New("login failed - maintenance in progress")
var RestoreInProgressError = errors.New("restore in progress")
Functions ¶
func DescribeFacades ¶
func DescribeFacades() []params.FacadeVersions
DescribeFacades returns the list of available Facades and their Versions
Types ¶
type EntitiesWatcher ¶
type EntitiesWatcher interface { state.StringsWatcher // MapChanges maps the received strings to their according tag strings. // The EntityFinder interface representing state or a mock has to be // upcasted into the needed sub-interface of state for the real mapping. MapChanges(in []string) ([]string, error) }
EntitiesWatcher defines an interface based on the StringsWatcher but also providing a method for the mapping of the received strings to the tags of the according entities.
type LoginValidator ¶
type LoginValidator func(params.LoginRequest) error
LoginValidator functions are used to decide whether login requests are to be allowed. The validator is called before credentials are checked.
type Pinger ¶
type Pinger interface { Ping() Stop() error }
pinger describes a resource that can be pinged and stopped.
type Server ¶
type Server struct {
// contains filtered or unexported fields
}
Server holds the server side of the API.
func NewServer ¶
NewServer serves the given state by accepting requests on the given listener, using the given certificate and key (in PEM format) for authentication.
The Server will close the listener when it exits, even if returns an error.
func (*Server) ConnectionCount ¶
func (*Server) Dead ¶
func (srv *Server) Dead() <-chan struct{}
Dead returns a channel that signals when the server has exited.
type ServerConfig ¶
type ServerConfig struct { Clock clock.Clock Cert string Key string Tag names.Tag DataDir string LogDir string Validator LoginValidator CertChanged <-chan params.StateServingInfo // AutocertDNSName holds the DNS name for which // official TLS certificates will be obtained. If this is // empty, no certificates will be requested. AutocertDNSName string // AutocertURL holds the URL from which official // TLS certificates will be obtained. By default, // acme.LetsEncryptURL will be used. AutocertURL string // NewObserver is a function which will return an observer. This // is used per-connection to instantiate a new observer to be // notified of key events during API requests. NewObserver observer.ObserverFactory // StatePool only exists to support testing. StatePool *state.StatePool }
ServerConfig holds parameters required to set up an API server.
func (*ServerConfig) Validate ¶
func (c *ServerConfig) Validate() error
type SrvAllWatcher ¶
type SrvAllWatcher struct {
// contains filtered or unexported fields
}
SrvAllWatcher defines the API methods on a state.Multiwatcher. which watches any changes to the state. Each client has its own current set of watchers, stored in resources. It is used by both the AllWatcher and AllModelWatcher facades.
func (*SrvAllWatcher) Next ¶
func (aw *SrvAllWatcher) Next() (params.AllWatcherNextResults, error)
func (*SrvAllWatcher) Stop ¶
func (w *SrvAllWatcher) Stop() error
Source Files ¶
- admin.go
- adminv3.go
- allfacades.go
- apiserver.go
- authcontext.go
- backup.go
- charms.go
- debuglog.go
- debuglog_db.go
- defaulticon.go
- gui.go
- httpcontext.go
- locallogin.go
- logsink.go
- logstream.go
- pinger.go
- registration.go
- restrict_controller.go
- restrict_model.go
- restrict_restore.go
- restrict_upgrades.go
- restricted_root.go
- root.go
- tools.go
- utils.go
- watcher.go
Directories ¶
Path | Synopsis |
---|---|
Package application contains api calls for functionality related to deploying and managing applications and their related charms.
|
Package application contains api calls for functionality related to deploying and managing applications and their related charms. |
Package cloud defines an API end point for functions dealing with the controller's cloud definition, and cloud credentials.
|
Package cloud defines an API end point for functions dealing with the controller's cloud definition, and cloud credentials. |
storagecommon
Package storagecommon provides common storage-related services for API server facades.
|
Package storagecommon provides common storage-related services for API server facades. |
The controller package defines an API end point for functions dealing with controllers as a whole.
|
The controller package defines an API end point for functions dealing with controllers as a whole. |
Package hostkeyreporter implements the API facade used by the hostkeyreporter worker.
|
Package hostkeyreporter implements the API facade used by the hostkeyreporter worker. |
Package httpattachment provides facilities for attaching a streaming blob of data and associated metadata to an HTTP API request, and for reading that blob on the server side.
|
Package httpattachment provides facilities for attaching a streaming blob of data and associated metadata to an HTTP API request, and for reading that blob on the server side. |
The machiner package implements the API interface used by the machiner worker.
|
The machiner package implements the API interface used by the machiner worker. |
machineactions implements the the apiserver side of running actions on machines
|
machineactions implements the the apiserver side of running actions on machines |
Package meterstatus provides the meter status API facade.
|
Package meterstatus provides the meter status API facade. |
Package metricsdebug contains the implementation of an api endpoint for metrics debug functionality.
|
Package metricsdebug contains the implementation of an api endpoint for metrics debug functionality. |
Package metricsender contains functions for sending metrics from a controller to a remote metric collector.
|
Package metricsender contains functions for sending metrics from a controller to a remote metric collector. |
Package metricsmanager contains the implementation of an api endpoint for calling metrics functions in state.
|
Package metricsmanager contains the implementation of an api endpoint for calling metrics functions in state. |
This package defines the API facade for use by the migration master worker when communicating to it's own controller.
|
This package defines the API facade for use by the migration master worker when communicating to it's own controller. |
Package migrationminion defines the API facade for use by the migration minion worker to monitor the progress of, and interact with, model migrations.
|
Package migrationminion defines the API facade for use by the migration minion worker to monitor the progress of, and interact with, model migrations. |
This package defines the API facade for use by the migration master worker when interacting with the target controller during a migration.
|
This package defines the API facade for use by the migration master worker when interacting with the target controller during a migration. |
Package modelmanager defines an API end point for functions dealing with models.
|
Package modelmanager defines an API end point for functions dealing with models. |
The resumer package implements the API interface used by the resumer worker.
|
The resumer package implements the API interface used by the resumer worker. |
Package sshclient implements the API endpoint required for Juju clients that wish to make SSH connections to Juju managed machines.
|
Package sshclient implements the API endpoint required for Juju clients that wish to make SSH connections to Juju managed machines. |
Package storage provides an API server facade for managing storage entities.
|
Package storage provides an API server facade for managing storage entities. |