github.com/huaweicloud/golangsdk@v0.0.0-20210831081626-d823fe11ceba/openstack/geminidb/v3/instances/testing/fixtures.go (about) 1 package testing 2 3 const CreateRequest = ` 4 { 5 "name": "test-cassandra-01", 6 "datastore": { 7 "type": "GeminiDB-Cassandra", 8 "version": "3.11", 9 "storage_engine": "rocksDB" 10 }, 11 "region": "aaa", 12 "availability_zone": "bbb", 13 "vpc_id": "674e9b42-cd8d-4d25-a2e6-5abcc565b961", 14 "subnet_id": "f1df08c5-71d1-406a-aff0-de435a51007b", 15 "security_group_id": "7aa51dbf-5b63-40db-9724-dad3c4828b58", 16 "password": "Test@123", 17 "mode": "Cluster", 18 "flavor": [ 19 { 20 "num": "3", 21 "size": 500, 22 "storage": "ULTRAHIGH", 23 "spec_code": "nosql.cassandra.4xlarge.4" 24 } 25 ], 26 "backup_strategy": { 27 "start_time": "08:15-09:15", 28 "keep_days": "8" 29 }, 30 "enterprise_project_id": "0" 31 }` 32 33 const CreateResponse = ` 34 { 35 "id": "39b6a1a278844ac48119d86512e0000bin06", 36 "name": "test-cassandra-01", 37 "datastore": { 38 "type": "GeminiDB-Cassandra", 39 "version": "3.11", 40 "storage_engine": "rocksDB" 41 }, 42 "status": "creating", 43 "region": "aaa", 44 "availability_zone": "bbb", 45 "vpc_id": "674e9b42-cd8d-4d25-a2e6-5abcc565b961", 46 "subnet_id": "f1df08c5-71d1-406a-aff0-de435a51007b", 47 "security_group_id": "7aa51dbf-5b63-40db-9724-dad3c4828b58", 48 "mode": "Cluster", 49 "flavor": [ 50 { 51 "num": "3", 52 "size": "500", 53 "storage": "ULTRAHIGH", 54 "spec_code": "nosql.cassandra.4xlarge.4" 55 } 56 ], 57 "backup_strategy": { 58 "start_time": "08:15-09:15", 59 "keep_days": "8" 60 } , 61 "job_id": "c010abd0-48cf-4fa8-8cbc-090f093eaa2f", 62 "enterprise_project_id": "0" 63 } 64 ` 65 const AllInstancesResponse = ` 66 { 67 "instances": [ 68 { 69 "id": "8436a91546294036b75931e879882200in06", 70 "name": "GeminiDB-efa6", 71 "status": "normal", 72 "port": "8635", 73 "mode": " Cluster", 74 "region": "aaa", 75 "datastore": { 76 "type": "GeminiDB-Cassandra", 77 "version": "3.11" 78 }, 79 "engine": " rocksDB ", 80 "created": "2019-01-17T07:05:52", 81 "updated": "2019-01-17T07:05:47", 82 "db_user_name": "rwuser", 83 "vpc_id": "674e9b42-cd8d-4d25-a2e6-5abcc565b961", 84 "subnet_id": "f1df08c5-71d1-406a-aff0-de435a51007b", 85 "security_group_id": "7aa51dbf-5b63-40db-9724-dad3c4828b58", 86 "backup_strategy": { 87 "start_time": "16:00-17:00", 88 "keep_days": 7 89 }, 90 "pay_mode": "0", 91 "maintenance_window": "02:00-06:00", 92 "groups": [ 93 { 94 "id": "0b0ff12541794e1084f6827e424be2d6gr06", 95 "status": "creating", 96 "volume": { 97 "size": "100", 98 "used": "0.003" 99 }, 100 "nodes": [ 101 { 102 "id": "233eaac9c6f245c0bb9c2d21eea12d1bno06", 103 "name": "GeminiDB-efa6_priam_node_2", 104 "status": "normal", 105 "private_ip": "192.168.0.174", 106 "spec_code": "nosql.cassandra.xlarge.4", 107 "availability_zone": "bbb" 108 }, 109 { 110 "id": "d57d76d6320a4a7b86db82c317550c4ano02", 111 "name": "GeminiDB-efa6_priam_node_1", 112 "status": "normal", 113 "private_ip": "192.168.0.39", 114 "spec_code": "nosql.cassandra.xlarge.4", 115 "availability_zone": "bbb" 116 }, 117 { 118 "id": "f46b0a1cf4d9400e9fd7af17f8742d37no02", 119 "name": "GeminiDB-efa6_prima_node_3", 120 "status": "normal", 121 "private_ip": "192.168.0.176", 122 "spec_code": "nosql.cassandra.xlarge.4", 123 "availability_zone": "bbb" 124 } 125 ] 126 } 127 ], 128 "enterprise_project_id": "0", 129 "time_zone": "", 130 "actions": [ 131 "CREATE" 132 ] 133 }, 134 { 135 "id": "1236a91546294036b75931e879882200in06", 136 "name": "GeminiDB-efa7", 137 "status": "normal", 138 "port": "8635", 139 "mode": " Cluster ", 140 "region": "aaa", 141 "datastore": { 142 "type": "GeminiDB-Cassandra", 143 "version": "3.11" 144 }, 145 "engine": " rocksDB ", 146 "created": "2019-01-17T07:05:52", 147 "updated": "2019-01-17T07:05:47", 148 "db_user_name": "rwuser", 149 "vpc_id": "674e9b42-cd8d-4d25-a2e6-5abcc565b961", 150 "subnet_id": "f1df08c5-71d1-406a-aff0-de435a51007b", 151 "security_group_id": "7aa51dbf-5b63-40db-9724-dad3c4828b58", 152 "backup_strategy": { 153 "start_time": "16:00-17:00", 154 "keep_days": 7 155 }, 156 "pay_mode": "0", 157 "maintenance_window": "02:00-06:00", 158 "groups": [ 159 { 160 "id": "0b0ff12541794e1084f6827e424be2d1gr07", 161 "status": "creating", 162 "volume": { 163 "size": "100", 164 "used": "0.003" 165 }, 166 "nodes": [ 167 { 168 "id": "233eaac9c6f245c0bb9c2d21eea12d1bno06", 169 "name": "GeminiDB-efa7_priam_node_2", 170 "status": "normal", 171 "private_ip": "192.168.0.174", 172 "spec_code": "nosql.cassandra.xlarge.4", 173 "availability_zone": "bbb" 174 }, 175 { 176 "id": "d57d76d6320a4a7b86db82c317550c4ano02", 177 "name": "GeminiDB-efa7_priam_node_1", 178 "status": "normal", 179 "private_ip": "192.168.0.39", 180 "spec_code": "nosql.cassandra.xlarge.4", 181 "availability_zone": "bbb" 182 }, 183 { 184 "id": "f46b0a1cf4d9400e9fd7af17f8742d37no02", 185 "name": "GeminiDB-efa7_prima_node_3", 186 "status": "normal", 187 "private_ip": "192.168.0.176", 188 "spec_code": "nosql.cassandra.xlarge.4", 189 "availability_zone": "bbb" 190 } 191 ] 192 } 193 ], 194 "enterprise_project_id": "0", 195 "time_zone": "", 196 "actions": [ 197 "CREATE" 198 ] 199 } 200 ], 201 "total_count": 2 202 } 203 `