Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func List ¶
func List(client *golangsdk.ServiceClient, ops ListOptsBuilder) pagination.Pager
List all the replications
Types ¶
type CreateOps ¶
type CreateOps struct { // The name of the EVS replication pair. // The name can contain a maximum of 255 bytes. Name string `json:"name,omitempty"` // The description of the EVS replication pair. // The description can contain a maximum of 255 bytes. Description string `json:"description,omitempty"` // The IDs of the EVS disks used to create the EVS replication pair. VolumeIDs []string `json:"volume_ids" required:"true"` // The primary AZ of the EVS replication pair. // That is the AZ where the production disk belongs. PriorityStation string `json:"priority_station" required:"true"` // The type of the EVS replication pair. // Currently only type hypermetro is supported. ReplicationModel string `json:"replication_model" required:"true"` }
CreateOps is a struct that contains all the parameters.
func (CreateOps) ToReplicationCreateMap ¶
ToReplicationCreateMap is used for type convert
type CreateOpsBuilder ¶
CreateOpsBuilder is used for creating replication parameters. any struct providing the parameters should implement this interface
type CreateResult ¶
type CreateResult struct {
golangsdk.Result
}
CreateResult is a struct that contains all the return parameters of creation
func Create ¶
func Create(client *golangsdk.ServiceClient, ops CreateOpsBuilder) (r CreateResult)
Create a replication with given parameters.
func (CreateResult) Extract ¶
func (r CreateResult) Extract() (*ReplicationCreate, error)
Extract from CreateResult
type DeleteResult ¶
type DeleteResult struct {
golangsdk.ErrResult
}
DeleteResult is a struct which contains the result of deletion
func Delete ¶
func Delete(client *golangsdk.ServiceClient, id string) (r DeleteResult)
Delete a replication by id
type GetResult ¶
type GetResult struct {
golangsdk.Result
}
GetResult contains the body of getting detailed
func (GetResult) Extract ¶
func (r GetResult) Extract() (*Replication, error)
Extract from GetResult
type ListOpts ¶
type ListOpts struct { Marker string `q:"marker"` Limit int `q:"limit"` SortKey string `q:"sort_key"` SortDir string `q:"sort_dir"` Offset int `q:"offset"` ChangesSince string `q:"changes-since"` Name string `q:"name"` Status string `q:"status"` ReplicationConsistencyGroupID string `q:"replication_consistency_group_id"` VolumeIDs string `q:"volume_ids"` VolumeID string `q:"volume_id"` PriorityStation string `q:"priority_station"` }
ListOpts is a struct that contains all the parameters.
func (ListOpts) ToReplicationListQuery ¶
ToReplicationListQuery formats a ListOpts into a query string.
type ListOptsBuilder ¶
ListOptsBuilder is an interface by which can be able to build the query string of the list function
type Replication ¶
type Replication struct { ID string `json:"id"` Name string `json:"name"` Description string `json:"description"` Status string `json:"status"` ReplicationConsistencyGroupID string `json:"replication_consistency_group_id"` VolumeIDs string `json:"volume_ids"` PriorityStation string `json:"priority_station"` CreatedAt string `json:"created_at"` UpdatedAt string `json:"updated_at"` ReplicationModel string `json:"replication_model"` ReplicationStatus string `json:"replication_status"` Progress string `json:"progress"` FailureDetail string `json:"failure_detail"` // RecordMetadata includes volume_type and multiattach currently. RecordMetadata json.RawMessage `json:"record_metadata"` FaultLevel string `json:"fault_level"` }
Replication response
func ExtractReplications ¶
func ExtractReplications(r pagination.Page) ([]Replication, error)
ExtractReplications from List
type ReplicationCreate ¶
type ReplicationCreate struct { ID string `json:"id"` Name string `json:"name"` Description string `json:"description"` Status string `json:"status"` ReplicationConsistencyGroupID string `json:"replication_consistency_group_id"` VolumeIDs string `json:"volume_ids"` PriorityStation string `json:"priority_station"` CreatedAt string `json:"created_at"` UpdatedAt string `json:"updated_at"` }
ReplicationCreate response
type ReplicationPage ¶
type ReplicationPage struct {
pagination.SinglePageBase
}
ReplicationPage may be embedded in a Page that contains all of the results from an operation at once.
func (ReplicationPage) IsEmpty ¶
func (r ReplicationPage) IsEmpty() (bool, error)
IsEmpty returns true if a ListResult contains no replications.