Documentation ¶
Index ¶
- Constants
- func HandleError(s *client.Schemas, t HandleFuncWithError) http.Handler
- func Handler(s *Server) http.Handler
- func HostIDFromAttachReq(req *http.Request) (string, error)
- func HostIDFromVolume(man types.VolumeManager) func(req *http.Request) (string, error)
- func NewSchema() *client.Schemas
- func Proxy() http.Handler
- type AttachInput
- type Backup
- type BackupInput
- type BackupVolume
- type BackupsHandlers
- func (bh *BackupsHandlers) Delete(w http.ResponseWriter, req *http.Request) error
- func (bh *BackupsHandlers) Get(w http.ResponseWriter, req *http.Request) error
- func (bh *BackupsHandlers) GetVolume(w http.ResponseWriter, req *http.Request) error
- func (bh *BackupsHandlers) List(w http.ResponseWriter, req *http.Request) error
- func (bh *BackupsHandlers) ListVolume(w http.ResponseWriter, req *http.Request) error
- type BgTask
- type Controller
- type Empty
- type Fwd
- type HandleFuncWithError
- type Host
- type HostIDFunc
- type Instance
- type RecurringInput
- type Replica
- type ReplicaRemoveInput
- type ScheduleInput
- type ScheduleOutput
- type Server
- func (s *Server) AttachVolume(rw http.ResponseWriter, req *http.Request) error
- func (s *Server) BgTaskQueue(rw http.ResponseWriter, req *http.Request) error
- func (s *Server) CreateVolume(rw http.ResponseWriter, req *http.Request) error
- func (s *Server) DeleteVolume(rw http.ResponseWriter, req *http.Request) error
- func (s *Server) DetachVolume(rw http.ResponseWriter, req *http.Request) error
- func (s *Server) GetHost(rw http.ResponseWriter, req *http.Request) error
- func (s *Server) GetVolume(rw http.ResponseWriter, req *http.Request) error
- func (s *Server) ListHost(rw http.ResponseWriter, req *http.Request) error
- func (s *Server) ListVolume(rw http.ResponseWriter, req *http.Request) error
- func (s *Server) ReplicaRemove(rw http.ResponseWriter, req *http.Request) error
- func (s *Server) Schedule(rw http.ResponseWriter, req *http.Request) error
- func (s *Server) UpdateRecurring(rw http.ResponseWriter, req *http.Request) error
- type Setting
- type SettingsHandlers
- type Snapshot
- type SnapshotHandlers
- func (sh *SnapshotHandlers) Backup(w http.ResponseWriter, req *http.Request) error
- func (sh *SnapshotHandlers) Create(w http.ResponseWriter, req *http.Request) error
- func (sh *SnapshotHandlers) Delete(w http.ResponseWriter, req *http.Request) error
- func (sh *SnapshotHandlers) Get(w http.ResponseWriter, req *http.Request) error
- func (sh *SnapshotHandlers) List(w http.ResponseWriter, req *http.Request) error
- func (sh *SnapshotHandlers) Purge(w http.ResponseWriter, req *http.Request) error
- func (sh *SnapshotHandlers) Revert(w http.ResponseWriter, req *http.Request) error
- type SnapshotInput
- type Volume
Constants ¶
View Source
const DefaultPort int = 9500
Variables ¶
This section is empty.
Functions ¶
func HandleError ¶
func HandleError(s *client.Schemas, t HandleFuncWithError) http.Handler
func HostIDFromVolume ¶
Types ¶
type AttachInput ¶
type AttachInput struct {
HostID string `json:"hostId,omitempty"`
}
type BackupInput ¶
type BackupInput struct {
Name string `json:"name,omitempty"`
}
type BackupVolume ¶
type BackupVolume struct { client.Resource types.BackupVolumeInfo }
type BackupsHandlers ¶
type BackupsHandlers struct {
// contains filtered or unexported fields
}
func (*BackupsHandlers) Delete ¶
func (bh *BackupsHandlers) Delete(w http.ResponseWriter, req *http.Request) error
func (*BackupsHandlers) Get ¶
func (bh *BackupsHandlers) Get(w http.ResponseWriter, req *http.Request) error
func (*BackupsHandlers) GetVolume ¶
func (bh *BackupsHandlers) GetVolume(w http.ResponseWriter, req *http.Request) error
func (*BackupsHandlers) List ¶
func (bh *BackupsHandlers) List(w http.ResponseWriter, req *http.Request) error
func (*BackupsHandlers) ListVolume ¶
func (bh *BackupsHandlers) ListVolume(w http.ResponseWriter, req *http.Request) error
type Controller ¶
type Controller struct {
Instance
}
type Fwd ¶
type Fwd struct {
// contains filtered or unexported fields
}
func (*Fwd) Handler ¶
func (f *Fwd) Handler(getHostID HostIDFunc, h HandleFuncWithError) HandleFuncWithError
type HandleFuncWithError ¶
type HandleFuncWithError func(http.ResponseWriter, *http.Request) error
type RecurringInput ¶
type RecurringInput struct {
Jobs []types.RecurringJob `json:"jobs,omitempty"`
}
type ReplicaRemoveInput ¶
type ReplicaRemoveInput struct {
Name string `json:"name"`
}
type ScheduleInput ¶
type ScheduleInput struct { Spec types.ScheduleSpec Item types.ScheduleItem }
type ScheduleOutput ¶
type ScheduleOutput struct {
Instance types.InstanceInfo
}
type Server ¶
type Server struct {
// contains filtered or unexported fields
}
func NewServer ¶
func NewServer(m types.VolumeManager, sl types.ServiceLocator, proxy http.Handler) *Server
func (*Server) AttachVolume ¶
func (*Server) BgTaskQueue ¶
func (*Server) CreateVolume ¶
func (*Server) DeleteVolume ¶
func (*Server) DetachVolume ¶
func (*Server) ListVolume ¶
func (*Server) ReplicaRemove ¶
func (*Server) UpdateRecurring ¶
type SettingsHandlers ¶
type SettingsHandlers struct {
// contains filtered or unexported fields
}
func (*SettingsHandlers) Get ¶
func (s *SettingsHandlers) Get(w http.ResponseWriter, req *http.Request) error
func (*SettingsHandlers) List ¶
func (s *SettingsHandlers) List(w http.ResponseWriter, req *http.Request) error
func (*SettingsHandlers) Set ¶
func (s *SettingsHandlers) Set(w http.ResponseWriter, req *http.Request) error
type SnapshotHandlers ¶
type SnapshotHandlers struct {
// contains filtered or unexported fields
}
func (*SnapshotHandlers) Backup ¶
func (sh *SnapshotHandlers) Backup(w http.ResponseWriter, req *http.Request) error
func (*SnapshotHandlers) Create ¶
func (sh *SnapshotHandlers) Create(w http.ResponseWriter, req *http.Request) error
func (*SnapshotHandlers) Delete ¶
func (sh *SnapshotHandlers) Delete(w http.ResponseWriter, req *http.Request) error
func (*SnapshotHandlers) Get ¶
func (sh *SnapshotHandlers) Get(w http.ResponseWriter, req *http.Request) error
func (*SnapshotHandlers) List ¶
func (sh *SnapshotHandlers) List(w http.ResponseWriter, req *http.Request) error
func (*SnapshotHandlers) Purge ¶
func (sh *SnapshotHandlers) Purge(w http.ResponseWriter, req *http.Request) error
func (*SnapshotHandlers) Revert ¶
func (sh *SnapshotHandlers) Revert(w http.ResponseWriter, req *http.Request) error
type SnapshotInput ¶
type Volume ¶
type Volume struct { client.Resource Name string `json:"name,omitempty"` Size string `json:"size,omitempty"` BaseImage string `json:"baseImage,omitempty"` FromBackup string `json:"fromBackup,omitempty"` NumberOfReplicas int `json:"numberOfReplicas,omitempty"` StaleReplicaTimeout int `json:"staleReplicaTimeout,omitempty"` State string `json:"state,omitempty"` EngineImage string `json:"engineImage,omitempty"` Endpoint string `json:"endpoint,omitemtpy"` Created string `json:"created,omitemtpy"` RecurringJobs []*types.RecurringJob `json:"recurringJobs,omitempty"` Replicas []Replica `json:"replicas,omitempty"` Controller *Controller `json:"controller,omitempty"` }
Click to show internal directories.
Click to hide internal directories.