AWS SDK for C++

AWS SDK for C++ Version 1.11.935

Loading...
Searching...
No Matches
CreateClusterRequest.h
1
6#pragma once
7#include <aws/core/utils/memory/stl/AWSString.h>
8#include <aws/core/utils/memory/stl/AWSVector.h>
9#include <aws/memorydb/MemoryDBRequest.h>
10#include <aws/memorydb/MemoryDB_EXPORTS.h>
11#include <aws/memorydb/model/IpDiscovery.h>
12#include <aws/memorydb/model/NetworkType.h>
13#include <aws/memorydb/model/Tag.h>
14
15#include <utility>
16
17namespace Aws {
18namespace MemoryDB {
19namespace Model {
20
24 public:
25 AWS_MEMORYDB_API CreateClusterRequest() = default;
26
27 // Service request name is the Operation name which will send this request out,
28 // each operation should has unique request name, so that we can get operation's name from this request.
29 // Note: this is not true for response, multiple operations may have the same response name,
30 // so we can not get operation's name from response.
31 inline virtual const char* GetServiceRequestName() const override { return "CreateCluster"; }
32
33 AWS_MEMORYDB_API Aws::String SerializePayload() const override;
34
36
38
42 inline const Aws::String& GetClusterName() const { return m_clusterName; }
43 inline bool ClusterNameHasBeenSet() const { return m_clusterNameHasBeenSet; }
44 template <typename ClusterNameT = Aws::String>
45 void SetClusterName(ClusterNameT&& value) {
46 m_clusterNameHasBeenSet = true;
47 m_clusterName = std::forward<ClusterNameT>(value);
48 }
49 template <typename ClusterNameT = Aws::String>
50 CreateClusterRequest& WithClusterName(ClusterNameT&& value) {
51 SetClusterName(std::forward<ClusterNameT>(value));
52 return *this;
53 }
55
57
60 inline const Aws::String& GetNodeType() const { return m_nodeType; }
61 inline bool NodeTypeHasBeenSet() const { return m_nodeTypeHasBeenSet; }
62 template <typename NodeTypeT = Aws::String>
63 void SetNodeType(NodeTypeT&& value) {
64 m_nodeTypeHasBeenSet = true;
65 m_nodeType = std::forward<NodeTypeT>(value);
66 }
67 template <typename NodeTypeT = Aws::String>
68 CreateClusterRequest& WithNodeType(NodeTypeT&& value) {
69 SetNodeType(std::forward<NodeTypeT>(value));
70 return *this;
71 }
73
75
78 inline const Aws::String& GetMultiRegionClusterName() const { return m_multiRegionClusterName; }
79 inline bool MultiRegionClusterNameHasBeenSet() const { return m_multiRegionClusterNameHasBeenSet; }
80 template <typename MultiRegionClusterNameT = Aws::String>
81 void SetMultiRegionClusterName(MultiRegionClusterNameT&& value) {
82 m_multiRegionClusterNameHasBeenSet = true;
83 m_multiRegionClusterName = std::forward<MultiRegionClusterNameT>(value);
84 }
85 template <typename MultiRegionClusterNameT = Aws::String>
86 CreateClusterRequest& WithMultiRegionClusterName(MultiRegionClusterNameT&& value) {
87 SetMultiRegionClusterName(std::forward<MultiRegionClusterNameT>(value));
88 return *this;
89 }
91
93
96 inline const Aws::String& GetParameterGroupName() const { return m_parameterGroupName; }
97 inline bool ParameterGroupNameHasBeenSet() const { return m_parameterGroupNameHasBeenSet; }
98 template <typename ParameterGroupNameT = Aws::String>
99 void SetParameterGroupName(ParameterGroupNameT&& value) {
100 m_parameterGroupNameHasBeenSet = true;
101 m_parameterGroupName = std::forward<ParameterGroupNameT>(value);
102 }
103 template <typename ParameterGroupNameT = Aws::String>
104 CreateClusterRequest& WithParameterGroupName(ParameterGroupNameT&& value) {
105 SetParameterGroupName(std::forward<ParameterGroupNameT>(value));
106 return *this;
107 }
109
111
114 inline const Aws::String& GetDescription() const { return m_description; }
115 inline bool DescriptionHasBeenSet() const { return m_descriptionHasBeenSet; }
116 template <typename DescriptionT = Aws::String>
117 void SetDescription(DescriptionT&& value) {
118 m_descriptionHasBeenSet = true;
119 m_description = std::forward<DescriptionT>(value);
120 }
121 template <typename DescriptionT = Aws::String>
122 CreateClusterRequest& WithDescription(DescriptionT&& value) {
123 SetDescription(std::forward<DescriptionT>(value));
124 return *this;
125 }
127
129
132 inline int GetNumShards() const { return m_numShards; }
133 inline bool NumShardsHasBeenSet() const { return m_numShardsHasBeenSet; }
134 inline void SetNumShards(int value) {
135 m_numShardsHasBeenSet = true;
136 m_numShards = value;
137 }
139 SetNumShards(value);
140 return *this;
141 }
143
145
149 inline int GetNumReplicasPerShard() const { return m_numReplicasPerShard; }
150 inline bool NumReplicasPerShardHasBeenSet() const { return m_numReplicasPerShardHasBeenSet; }
151 inline void SetNumReplicasPerShard(int value) {
152 m_numReplicasPerShardHasBeenSet = true;
153 m_numReplicasPerShard = value;
154 }
157 return *this;
158 }
160
162
165 inline const Aws::String& GetSubnetGroupName() const { return m_subnetGroupName; }
166 inline bool SubnetGroupNameHasBeenSet() const { return m_subnetGroupNameHasBeenSet; }
167 template <typename SubnetGroupNameT = Aws::String>
168 void SetSubnetGroupName(SubnetGroupNameT&& value) {
169 m_subnetGroupNameHasBeenSet = true;
170 m_subnetGroupName = std::forward<SubnetGroupNameT>(value);
171 }
172 template <typename SubnetGroupNameT = Aws::String>
173 CreateClusterRequest& WithSubnetGroupName(SubnetGroupNameT&& value) {
174 SetSubnetGroupName(std::forward<SubnetGroupNameT>(value));
175 return *this;
176 }
178
180
183 inline const Aws::Vector<Aws::String>& GetSecurityGroupIds() const { return m_securityGroupIds; }
184 inline bool SecurityGroupIdsHasBeenSet() const { return m_securityGroupIdsHasBeenSet; }
185 template <typename SecurityGroupIdsT = Aws::Vector<Aws::String>>
186 void SetSecurityGroupIds(SecurityGroupIdsT&& value) {
187 m_securityGroupIdsHasBeenSet = true;
188 m_securityGroupIds = std::forward<SecurityGroupIdsT>(value);
189 }
190 template <typename SecurityGroupIdsT = Aws::Vector<Aws::String>>
191 CreateClusterRequest& WithSecurityGroupIds(SecurityGroupIdsT&& value) {
192 SetSecurityGroupIds(std::forward<SecurityGroupIdsT>(value));
193 return *this;
194 }
195 template <typename SecurityGroupIdsT = Aws::String>
196 CreateClusterRequest& AddSecurityGroupIds(SecurityGroupIdsT&& value) {
197 m_securityGroupIdsHasBeenSet = true;
198 m_securityGroupIds.emplace_back(std::forward<SecurityGroupIdsT>(value));
199 return *this;
200 }
202
204
214 inline const Aws::String& GetMaintenanceWindow() const { return m_maintenanceWindow; }
215 inline bool MaintenanceWindowHasBeenSet() const { return m_maintenanceWindowHasBeenSet; }
216 template <typename MaintenanceWindowT = Aws::String>
217 void SetMaintenanceWindow(MaintenanceWindowT&& value) {
218 m_maintenanceWindowHasBeenSet = true;
219 m_maintenanceWindow = std::forward<MaintenanceWindowT>(value);
220 }
221 template <typename MaintenanceWindowT = Aws::String>
222 CreateClusterRequest& WithMaintenanceWindow(MaintenanceWindowT&& value) {
223 SetMaintenanceWindow(std::forward<MaintenanceWindowT>(value));
224 return *this;
225 }
227
229
232 inline int GetPort() const { return m_port; }
233 inline bool PortHasBeenSet() const { return m_portHasBeenSet; }
234 inline void SetPort(int value) {
235 m_portHasBeenSet = true;
236 m_port = value;
237 }
238 inline CreateClusterRequest& WithPort(int value) {
239 SetPort(value);
240 return *this;
241 }
243
245
249 inline const Aws::String& GetSnsTopicArn() const { return m_snsTopicArn; }
250 inline bool SnsTopicArnHasBeenSet() const { return m_snsTopicArnHasBeenSet; }
251 template <typename SnsTopicArnT = Aws::String>
252 void SetSnsTopicArn(SnsTopicArnT&& value) {
253 m_snsTopicArnHasBeenSet = true;
254 m_snsTopicArn = std::forward<SnsTopicArnT>(value);
255 }
256 template <typename SnsTopicArnT = Aws::String>
257 CreateClusterRequest& WithSnsTopicArn(SnsTopicArnT&& value) {
258 SetSnsTopicArn(std::forward<SnsTopicArnT>(value));
259 return *this;
260 }
262
264
267 inline bool GetTLSEnabled() const { return m_tLSEnabled; }
268 inline bool TLSEnabledHasBeenSet() const { return m_tLSEnabledHasBeenSet; }
269 inline void SetTLSEnabled(bool value) {
270 m_tLSEnabledHasBeenSet = true;
271 m_tLSEnabled = value;
272 }
274 SetTLSEnabled(value);
275 return *this;
276 }
278
280
283 inline const Aws::String& GetKmsKeyId() const { return m_kmsKeyId; }
284 inline bool KmsKeyIdHasBeenSet() const { return m_kmsKeyIdHasBeenSet; }
285 template <typename KmsKeyIdT = Aws::String>
286 void SetKmsKeyId(KmsKeyIdT&& value) {
287 m_kmsKeyIdHasBeenSet = true;
288 m_kmsKeyId = std::forward<KmsKeyIdT>(value);
289 }
290 template <typename KmsKeyIdT = Aws::String>
291 CreateClusterRequest& WithKmsKeyId(KmsKeyIdT&& value) {
292 SetKmsKeyId(std::forward<KmsKeyIdT>(value));
293 return *this;
294 }
296
298
303 inline const Aws::Vector<Aws::String>& GetSnapshotArns() const { return m_snapshotArns; }
304 inline bool SnapshotArnsHasBeenSet() const { return m_snapshotArnsHasBeenSet; }
305 template <typename SnapshotArnsT = Aws::Vector<Aws::String>>
306 void SetSnapshotArns(SnapshotArnsT&& value) {
307 m_snapshotArnsHasBeenSet = true;
308 m_snapshotArns = std::forward<SnapshotArnsT>(value);
309 }
310 template <typename SnapshotArnsT = Aws::Vector<Aws::String>>
311 CreateClusterRequest& WithSnapshotArns(SnapshotArnsT&& value) {
312 SetSnapshotArns(std::forward<SnapshotArnsT>(value));
313 return *this;
314 }
315 template <typename SnapshotArnsT = Aws::String>
316 CreateClusterRequest& AddSnapshotArns(SnapshotArnsT&& value) {
317 m_snapshotArnsHasBeenSet = true;
318 m_snapshotArns.emplace_back(std::forward<SnapshotArnsT>(value));
319 return *this;
320 }
322
324
328 inline const Aws::String& GetSnapshotName() const { return m_snapshotName; }
329 inline bool SnapshotNameHasBeenSet() const { return m_snapshotNameHasBeenSet; }
330 template <typename SnapshotNameT = Aws::String>
331 void SetSnapshotName(SnapshotNameT&& value) {
332 m_snapshotNameHasBeenSet = true;
333 m_snapshotName = std::forward<SnapshotNameT>(value);
334 }
335 template <typename SnapshotNameT = Aws::String>
336 CreateClusterRequest& WithSnapshotName(SnapshotNameT&& value) {
337 SetSnapshotName(std::forward<SnapshotNameT>(value));
338 return *this;
339 }
341
343
348 inline int GetSnapshotRetentionLimit() const { return m_snapshotRetentionLimit; }
349 inline bool SnapshotRetentionLimitHasBeenSet() const { return m_snapshotRetentionLimitHasBeenSet; }
350 inline void SetSnapshotRetentionLimit(int value) {
351 m_snapshotRetentionLimitHasBeenSet = true;
352 m_snapshotRetentionLimit = value;
353 }
356 return *this;
357 }
359
361
367 inline const Aws::Vector<Tag>& GetTags() const { return m_tags; }
368 inline bool TagsHasBeenSet() const { return m_tagsHasBeenSet; }
369 template <typename TagsT = Aws::Vector<Tag>>
370 void SetTags(TagsT&& value) {
371 m_tagsHasBeenSet = true;
372 m_tags = std::forward<TagsT>(value);
373 }
374 template <typename TagsT = Aws::Vector<Tag>>
376 SetTags(std::forward<TagsT>(value));
377 return *this;
378 }
379 template <typename TagsT = Tag>
381 m_tagsHasBeenSet = true;
382 m_tags.emplace_back(std::forward<TagsT>(value));
383 return *this;
384 }
386
388
394 inline const Aws::String& GetSnapshotWindow() const { return m_snapshotWindow; }
395 inline bool SnapshotWindowHasBeenSet() const { return m_snapshotWindowHasBeenSet; }
396 template <typename SnapshotWindowT = Aws::String>
397 void SetSnapshotWindow(SnapshotWindowT&& value) {
398 m_snapshotWindowHasBeenSet = true;
399 m_snapshotWindow = std::forward<SnapshotWindowT>(value);
400 }
401 template <typename SnapshotWindowT = Aws::String>
402 CreateClusterRequest& WithSnapshotWindow(SnapshotWindowT&& value) {
403 SetSnapshotWindow(std::forward<SnapshotWindowT>(value));
404 return *this;
405 }
407
409
412 inline const Aws::String& GetACLName() const { return m_aCLName; }
413 inline bool ACLNameHasBeenSet() const { return m_aCLNameHasBeenSet; }
414 template <typename ACLNameT = Aws::String>
415 void SetACLName(ACLNameT&& value) {
416 m_aCLNameHasBeenSet = true;
417 m_aCLName = std::forward<ACLNameT>(value);
418 }
419 template <typename ACLNameT = Aws::String>
421 SetACLName(std::forward<ACLNameT>(value));
422 return *this;
423 }
425
427
430 inline const Aws::String& GetEngine() const { return m_engine; }
431 inline bool EngineHasBeenSet() const { return m_engineHasBeenSet; }
432 template <typename EngineT = Aws::String>
433 void SetEngine(EngineT&& value) {
434 m_engineHasBeenSet = true;
435 m_engine = std::forward<EngineT>(value);
436 }
437 template <typename EngineT = Aws::String>
439 SetEngine(std::forward<EngineT>(value));
440 return *this;
441 }
443
445
448 inline const Aws::String& GetEngineVersion() const { return m_engineVersion; }
449 inline bool EngineVersionHasBeenSet() const { return m_engineVersionHasBeenSet; }
450 template <typename EngineVersionT = Aws::String>
451 void SetEngineVersion(EngineVersionT&& value) {
452 m_engineVersionHasBeenSet = true;
453 m_engineVersion = std::forward<EngineVersionT>(value);
454 }
455 template <typename EngineVersionT = Aws::String>
456 CreateClusterRequest& WithEngineVersion(EngineVersionT&& value) {
457 SetEngineVersion(std::forward<EngineVersionT>(value));
458 return *this;
459 }
461
463
467 inline bool GetAutoMinorVersionUpgrade() const { return m_autoMinorVersionUpgrade; }
468 inline bool AutoMinorVersionUpgradeHasBeenSet() const { return m_autoMinorVersionUpgradeHasBeenSet; }
469 inline void SetAutoMinorVersionUpgrade(bool value) {
470 m_autoMinorVersionUpgradeHasBeenSet = true;
471 m_autoMinorVersionUpgrade = value;
472 }
475 return *this;
476 }
478
480
487 inline bool GetDataTiering() const { return m_dataTiering; }
488 inline bool DataTieringHasBeenSet() const { return m_dataTieringHasBeenSet; }
489 inline void SetDataTiering(bool value) {
490 m_dataTieringHasBeenSet = true;
491 m_dataTiering = value;
492 }
494 SetDataTiering(value);
495 return *this;
496 }
498
500
507 inline NetworkType GetNetworkType() const { return m_networkType; }
508 inline bool NetworkTypeHasBeenSet() const { return m_networkTypeHasBeenSet; }
509 inline void SetNetworkType(NetworkType value) {
510 m_networkTypeHasBeenSet = true;
511 m_networkType = value;
512 }
514 SetNetworkType(value);
515 return *this;
516 }
518
520
529 inline IpDiscovery GetIpDiscovery() const { return m_ipDiscovery; }
530 inline bool IpDiscoveryHasBeenSet() const { return m_ipDiscoveryHasBeenSet; }
531 inline void SetIpDiscovery(IpDiscovery value) {
532 m_ipDiscoveryHasBeenSet = true;
533 m_ipDiscovery = value;
534 }
536 SetIpDiscovery(value);
537 return *this;
538 }
540 private:
541 Aws::String m_clusterName;
542
543 Aws::String m_nodeType;
544
545 Aws::String m_multiRegionClusterName;
546
547 Aws::String m_parameterGroupName;
548
549 Aws::String m_description;
550
551 int m_numShards{0};
552
553 int m_numReplicasPerShard{0};
554
555 Aws::String m_subnetGroupName;
556
557 Aws::Vector<Aws::String> m_securityGroupIds;
558
559 Aws::String m_maintenanceWindow;
560
561 int m_port{0};
562
563 Aws::String m_snsTopicArn;
564
565 bool m_tLSEnabled{false};
566
567 Aws::String m_kmsKeyId;
568
569 Aws::Vector<Aws::String> m_snapshotArns;
570
571 Aws::String m_snapshotName;
572
573 int m_snapshotRetentionLimit{0};
574
575 Aws::Vector<Tag> m_tags;
576
577 Aws::String m_snapshotWindow;
578
579 Aws::String m_aCLName;
580
581 Aws::String m_engine;
582
583 Aws::String m_engineVersion;
584
585 bool m_autoMinorVersionUpgrade{false};
586
587 bool m_dataTiering{false};
588
589 NetworkType m_networkType{NetworkType::NOT_SET};
590
591 IpDiscovery m_ipDiscovery{IpDiscovery::NOT_SET};
592 bool m_clusterNameHasBeenSet = false;
593 bool m_nodeTypeHasBeenSet = false;
594 bool m_multiRegionClusterNameHasBeenSet = false;
595 bool m_parameterGroupNameHasBeenSet = false;
596 bool m_descriptionHasBeenSet = false;
597 bool m_numShardsHasBeenSet = false;
598 bool m_numReplicasPerShardHasBeenSet = false;
599 bool m_subnetGroupNameHasBeenSet = false;
600 bool m_securityGroupIdsHasBeenSet = false;
601 bool m_maintenanceWindowHasBeenSet = false;
602 bool m_portHasBeenSet = false;
603 bool m_snsTopicArnHasBeenSet = false;
604 bool m_tLSEnabledHasBeenSet = false;
605 bool m_kmsKeyIdHasBeenSet = false;
606 bool m_snapshotArnsHasBeenSet = false;
607 bool m_snapshotNameHasBeenSet = false;
608 bool m_snapshotRetentionLimitHasBeenSet = false;
609 bool m_tagsHasBeenSet = false;
610 bool m_snapshotWindowHasBeenSet = false;
611 bool m_aCLNameHasBeenSet = false;
612 bool m_engineHasBeenSet = false;
613 bool m_engineVersionHasBeenSet = false;
614 bool m_autoMinorVersionUpgradeHasBeenSet = false;
615 bool m_dataTieringHasBeenSet = false;
616 bool m_networkTypeHasBeenSet = false;
617 bool m_ipDiscoveryHasBeenSet = false;
618};
619
620} // namespace Model
621} // namespace MemoryDB
622} // namespace Aws
const Aws::Vector< Aws::String > & GetSnapshotArns() const
CreateClusterRequest & WithEngine(EngineT &&value)
CreateClusterRequest & AddSnapshotArns(SnapshotArnsT &&value)
CreateClusterRequest & WithAutoMinorVersionUpgrade(bool value)
AWS_MEMORYDB_API Aws::Http::HeaderValueCollection GetRequestSpecificHeaders() const override
CreateClusterRequest & WithDataTiering(bool value)
void SetSecurityGroupIds(SecurityGroupIdsT &&value)
CreateClusterRequest & WithParameterGroupName(ParameterGroupNameT &&value)
CreateClusterRequest & WithSubnetGroupName(SubnetGroupNameT &&value)
CreateClusterRequest & WithMaintenanceWindow(MaintenanceWindowT &&value)
virtual const char * GetServiceRequestName() const override
const Aws::Vector< Tag > & GetTags() const
CreateClusterRequest & WithClusterName(ClusterNameT &&value)
void SetMultiRegionClusterName(MultiRegionClusterNameT &&value)
CreateClusterRequest & WithNodeType(NodeTypeT &&value)
CreateClusterRequest & AddTags(TagsT &&value)
const Aws::Vector< Aws::String > & GetSecurityGroupIds() const
CreateClusterRequest & WithSnapshotName(SnapshotNameT &&value)
void SetParameterGroupName(ParameterGroupNameT &&value)
CreateClusterRequest & WithACLName(ACLNameT &&value)
CreateClusterRequest & WithSnsTopicArn(SnsTopicArnT &&value)
CreateClusterRequest & AddSecurityGroupIds(SecurityGroupIdsT &&value)
CreateClusterRequest & WithPort(int value)
CreateClusterRequest & WithMultiRegionClusterName(MultiRegionClusterNameT &&value)
void SetMaintenanceWindow(MaintenanceWindowT &&value)
CreateClusterRequest & WithSnapshotWindow(SnapshotWindowT &&value)
CreateClusterRequest & WithTags(TagsT &&value)
CreateClusterRequest & WithTLSEnabled(bool value)
CreateClusterRequest & WithNumReplicasPerShard(int value)
CreateClusterRequest & WithSecurityGroupIds(SecurityGroupIdsT &&value)
CreateClusterRequest & WithKmsKeyId(KmsKeyIdT &&value)
CreateClusterRequest & WithDescription(DescriptionT &&value)
CreateClusterRequest & WithNetworkType(NetworkType value)
AWS_MEMORYDB_API CreateClusterRequest()=default
CreateClusterRequest & WithSnapshotRetentionLimit(int value)
CreateClusterRequest & WithSnapshotArns(SnapshotArnsT &&value)
void SetSubnetGroupName(SubnetGroupNameT &&value)
const Aws::String & GetMultiRegionClusterName() const
AWS_MEMORYDB_API Aws::String SerializePayload() const override
void SetSnapshotWindow(SnapshotWindowT &&value)
CreateClusterRequest & WithIpDiscovery(IpDiscovery value)
CreateClusterRequest & WithEngineVersion(EngineVersionT &&value)
const Aws::String & GetParameterGroupName() const
CreateClusterRequest & WithNumShards(int value)
Aws::Map< Aws::String, Aws::String > HeaderValueCollection
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
std::vector< T, Aws::Allocator< T > > Vector