Documentation ¶
Index ¶
- Constants
- type Client
- func (c *Client) Create(ctx context.Context, req CreateRequest) (string, error)
- func (c *Client) Delete(ctx context.Context, req DeleteRequest) (string, error)
- func (c *Client) Find(ctx context.Context, req FindRequest) ([]map[string]interface{}, error)
- func (c *Client) In(ctx context.Context, req InRequest) error
- func (c *Client) Index(ctx context.Context, req IndexRequest) (map[string]interface{}, error)
- func (c *Client) OsddetailsMetadata(ctx context.Context, req OsddetailsMetadataRequest) (OsddetailsMetadataResponse, error)
- func (c *Client) OsdvolumeLvInfo(ctx context.Context, req OsdvolumeLvInfoRequest) (OsdvolumeLvInfoResponse, error)
- func (c *Client) Out(ctx context.Context, req OutRequest) error
- func (c *Client) Scrub(ctx context.Context, req ScrubRequest) error
- type CreateRequest
- type DeleteRequest
- type Devices
- type DevicesDevice
- type FindRequest
- type HTTPClient
- type InRequest
- type IndexRequest
- type Osd
- type OsddetailsMetadataRequest
- type OsddetailsMetadataResponse
- type OsdvolumeLvInfoRequest
- type OsdvolumeLvInfoResponse
- type OutRequest
- type ScrubRequest
- type Type
Constants ¶
View Source
const ( DevicesDevice_BLOCK DevicesDevice = "block" DevicesDevice_DB DevicesDevice = "db" DevicesDevice_WAL DevicesDevice = "wal" Type_BLOCK Type = "block" Type_DB Type = "db" Type_WAL Type = "wal" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
func New ¶
func New(c HTTPClient) *Client
func (*Client) OsddetailsMetadata ¶ added in v0.2.0
func (c *Client) OsddetailsMetadata(ctx context.Context, req OsddetailsMetadataRequest) (OsddetailsMetadataResponse, error)
OsddetailsMetadata Get OSD details
func (*Client) OsdvolumeLvInfo ¶ added in v0.2.0
func (c *Client) OsdvolumeLvInfo(ctx context.Context, req OsdvolumeLvInfoRequest) (OsdvolumeLvInfoResponse, error)
OsdvolumeLvInfo Get OSD volume details
type CreateRequest ¶
type CreateRequest struct { Dev string `url:"dev" json:"dev"` // Block device name. Node string `url:"node" json:"node"` // The cluster node name. // The following parameters are optional CrushDeviceClass *string `url:"crush-device-class,omitempty" json:"crush-device-class,omitempty"` // Set the device class of the OSD in crush. DbDev *string `url:"db_dev,omitempty" json:"db_dev,omitempty"` // Block device name for block.db. DbDevSize *float64 `url:"db_dev_size,omitempty" json:"db_dev_size,omitempty"` // Size in GiB for block.db. Encrypted *util.PVEBool `url:"encrypted,omitempty" json:"encrypted,omitempty"` // Enables encryption of the OSD. WalDev *string `url:"wal_dev,omitempty" json:"wal_dev,omitempty"` // Block device name for block.wal. WalDevSize *float64 `url:"wal_dev_size,omitempty" json:"wal_dev_size,omitempty"` // Size in GiB for block.wal. }
type DeleteRequest ¶
type Devices ¶ added in v0.2.0
type Devices struct { DevNode string `url:"dev_node" json:"dev_node"` // Device node Device DevicesDevice `url:"device" json:"device"` // Kind of OSD device Devices string `url:"devices" json:"devices"` // Physical disks used Size int `url:"size" json:"size"` // Size in bytes SupportDiscard util.PVEBool `url:"support_discard" json:"support_discard"` // Discard support of the physical device Type string `url:"type" json:"type"` // Type of device. For example, hdd or ssd }
type DevicesDevice ¶ added in v0.2.0
type DevicesDevice string
func PtrDevicesDevice ¶ added in v0.2.0
func PtrDevicesDevice(i DevicesDevice) *DevicesDevice
type FindRequest ¶ added in v0.2.0
type HTTPClient ¶
type IndexRequest ¶
type IndexRequest struct {
Node string `url:"node" json:"node"` // The cluster node name.
}
type Osd ¶ added in v0.2.0
type Osd struct { BackAddr string `url:"back_addr" json:"back_addr"` // Address and port used to talk to other OSDs. FrontAddr string `url:"front_addr" json:"front_addr"` // Address and port used to talk to clients and monitors. HbBackAddr string `url:"hb_back_addr" json:"hb_back_addr"` // Heartbeat address and port for other OSDs. HbFrontAddr string `url:"hb_front_addr" json:"hb_front_addr"` // Heartbeat address and port for clients and monitors. Hostname string `url:"hostname" json:"hostname"` // Name of the host containing the OSD. Id int `url:"id" json:"id"` // ID of the OSD. MemUsage int `url:"mem_usage" json:"mem_usage"` // Memory usage of the OSD service. OsdData string `url:"osd_data" json:"osd_data"` // Path to the OSD's data directory. OsdObjectstore string `url:"osd_objectstore" json:"osd_objectstore"` // The type of object store used. Pid int `url:"pid" json:"pid"` // OSD process ID. Version string `url:"version" json:"version"` // Ceph version of the OSD service. }
General information about the OSD
type OsddetailsMetadataRequest ¶ added in v0.2.0
type OsddetailsMetadataResponse ¶ added in v0.2.0
type OsdvolumeLvInfoRequest ¶ added in v0.2.0
type OsdvolumeLvInfoResponse ¶ added in v0.2.0
type OsdvolumeLvInfoResponse struct { CreationTime string `url:"creation_time" json:"creation_time"` // Creation time as reported by `lvs`. LvName string `url:"lv_name" json:"lv_name"` // Name of the logical volume (LV). LvPath string `url:"lv_path" json:"lv_path"` // Path to the logical volume (LV). LvSize int `url:"lv_size" json:"lv_size"` // Size of the logical volume (LV). LvUuid string `url:"lv_uuid" json:"lv_uuid"` // UUID of the logical volume (LV). VgName string `url:"vg_name" json:"vg_name"` // Name of the volume group (VG). }
type OutRequest ¶
type ScrubRequest ¶
type ScrubRequest struct { Node string `url:"node" json:"node"` // The cluster node name. Osdid int `url:"osdid" json:"osdid"` // OSD ID // The following parameters are optional Deep *util.PVEBool `url:"deep,omitempty" json:"deep,omitempty"` // If set, instructs a deep scrub instead of a normal one. }
Click to show internal directories.
Click to hide internal directories.