Documentation ¶
Index ¶
- Constants
- func InvokeRestApi(method string, url string, requestBody []byte, debug bool) (*http.Response, []byte, error)
- func LogHttpRequest(request *http.Request, requestBody []byte)
- func LogHttpResponse(response *http.Response, responseBody []byte)
- type Backend
- type GetBackendResponse
- type GetStorageClassResponse
- type MultipleBackendResponse
- type MultipleStorageClassResponse
- type MultipleVolumeResponse
- type StorageClass
- type VersionResponse
Constants ¶
View Source
const HTTP_TIMEOUT = time.Second * 30
Variables ¶
This section is empty.
Functions ¶
func InvokeRestApi ¶
func LogHttpRequest ¶
func LogHttpResponse ¶
Types ¶
type Backend ¶
type Backend struct { Name string `json:"name"` Config struct { Version int `json:"version"` StorageDriverName string `json:"storageDriverName"` StoragePrefix string `json:"storagePrefix"` SerialNumbers []string `json:"serialNumbers"` } `json:"config"` Storage interface{} `json:"storage"` Online bool `json:"online"` Volumes []string `json:"volumes"` }
type GetBackendResponse ¶
type GetStorageClassResponse ¶
type GetStorageClassResponse struct { StorageClass `json:"storageClass"` Error string `json:"error"` }
type MultipleBackendResponse ¶
type MultipleBackendResponse struct {
Items []Backend `json:"items"`
}
type MultipleStorageClassResponse ¶
type MultipleStorageClassResponse struct {
Items []StorageClass `json:"items"`
}
type MultipleVolumeResponse ¶
type MultipleVolumeResponse struct {
Items []storage.VolumeExternal `json:"items"`
}
type StorageClass ¶
type VersionResponse ¶
type VersionResponse struct { Server struct { Version string `json:"version"` MajorVersion uint `json:"majorVersion"` MinorVersion uint `json:"minorVersion"` PatchVersion uint `json:"patchVersion"` PreRelease string `json:"preRelease"` BuildMetadata string `json:"buildMetadata"` APIVersion string `json:"apiVersion"` } `json:"server"` Client struct { Version string `json:"version"` MajorVersion uint `json:"majorVersion"` MinorVersion uint `json:"minorVersion"` PatchVersion uint `json:"patchVersion"` PreRelease string `json:"preRelease"` BuildMetadata string `json:"buildMetadata"` APIVersion string `json:"apiVersion"` } `json:"client"` }
Click to show internal directories.
Click to hide internal directories.