github.com/huaweicloud/golangsdk@v0.0.0-20210831081626-d823fe11ceba/openstack/dws/cluster/results.go (about) 1 package cluster 2 3 import "github.com/huaweicloud/golangsdk" 4 5 type Cluster struct { 6 Status string `json:"status"` 7 SubStatus string `json:"sub_status"` 8 Updated string `json:"updated"` 9 Endpoints Endpoints `json:"endPoints"` 10 Name string `json:"name"` 11 NumberOfNode int `json:"number_of_node"` 12 AvailabilityZone string `json:"availability_zone"` 13 SubnetID string `json:"subnet_id"` 14 PublicEndpoints PublicEndpoints `json:"public_endpoints"` 15 Created string `json:"created"` 16 SecurityGroupID string `json:"security_group_id"` 17 Port int `json:"port"` 18 NodeType string `json:"node_type"` 19 Version string `json:"version"` 20 PublicIp PublicIp `json:"public_ip"` 21 FailedReasons map[string]FailInfo `json:"failed_reasons"` 22 VpcID string `json:"vpc_id"` 23 TaskStatus string `json:"task_status"` 24 UserName string `json:"user_name"` 25 ID string `json:"id"` 26 } 27 28 type FailInfo struct { 29 ErrorCode string `json:"error_code"` 30 ErrorMsg string `json:"error_msg"` 31 } 32 33 type PublicIp struct { 34 EipID string `json:"eip_id"` 35 PublicBindType string `json:"public_bind_type"` 36 } 37 38 type FailedReasons struct { 39 FailInfo FailInfo `json:"fail_info"` 40 } 41 42 type Endpoints struct { 43 ConnectInfo string `json:"connect_info"` 44 JdbcUrl string `json:"jdbc_url"` 45 } 46 47 type PublicEndpoints struct { 48 PublicConnectInfo string `json:"public_connect_info"` 49 JdbcUrl string `json:"jdbc_url"` 50 } 51 52 type GetResult struct { 53 golangsdk.Result 54 } 55 56 func (r GetResult) Extract() (*Cluster, error) { 57 o := &Cluster{} 58 return o, r.ExtractIntoStructPtr(o, "cluster") 59 } 60 61 type CreateRsp struct { 62 ID string `json:"id"` 63 } 64 65 type CreateResult struct { 66 golangsdk.Result 67 } 68 69 func (r CreateResult) Extract() (*CreateRsp, error) { 70 o := &CreateRsp{} 71 return o, r.ExtractIntoStructPtr(o, "cluster") 72 } 73 74 type DeleteResult struct { 75 golangsdk.ErrResult 76 }