AWS SDK for C++

AWS SDK for C++ Version 1.11.606

Loading...
Searching...
No Matches
CreateNodegroupRequest.h
1
6#pragma once
7#include <aws/eks/EKS_EXPORTS.h>
8#include <aws/eks/EKSRequest.h>
9#include <aws/core/utils/memory/stl/AWSString.h>
10#include <aws/eks/model/NodegroupScalingConfig.h>
11#include <aws/core/utils/memory/stl/AWSVector.h>
12#include <aws/eks/model/AMITypes.h>
13#include <aws/eks/model/RemoteAccessConfig.h>
14#include <aws/core/utils/memory/stl/AWSMap.h>
15#include <aws/eks/model/LaunchTemplateSpecification.h>
16#include <aws/eks/model/NodegroupUpdateConfig.h>
17#include <aws/eks/model/NodeRepairConfig.h>
18#include <aws/eks/model/CapacityTypes.h>
19#include <aws/eks/model/Taint.h>
20#include <utility>
21#include <aws/core/utils/UUID.h>
22
23namespace Aws
24{
25namespace EKS
26{
27namespace Model
28{
29
33 {
34 public:
35 AWS_EKS_API CreateNodegroupRequest() = default;
36
37 // Service request name is the Operation name which will send this request out,
38 // each operation should has unique request name, so that we can get operation's name from this request.
39 // Note: this is not true for response, multiple operations may have the same response name,
40 // so we can not get operation's name from response.
41 inline virtual const char* GetServiceRequestName() const override { return "CreateNodegroup"; }
42
43 AWS_EKS_API Aws::String SerializePayload() const override;
44
45
47
50 inline const Aws::String& GetClusterName() const { return m_clusterName; }
51 inline bool ClusterNameHasBeenSet() const { return m_clusterNameHasBeenSet; }
52 template<typename ClusterNameT = Aws::String>
53 void SetClusterName(ClusterNameT&& value) { m_clusterNameHasBeenSet = true; m_clusterName = std::forward<ClusterNameT>(value); }
54 template<typename ClusterNameT = Aws::String>
55 CreateNodegroupRequest& WithClusterName(ClusterNameT&& value) { SetClusterName(std::forward<ClusterNameT>(value)); return *this;}
57
59
62 inline const Aws::String& GetNodegroupName() const { return m_nodegroupName; }
63 inline bool NodegroupNameHasBeenSet() const { return m_nodegroupNameHasBeenSet; }
64 template<typename NodegroupNameT = Aws::String>
65 void SetNodegroupName(NodegroupNameT&& value) { m_nodegroupNameHasBeenSet = true; m_nodegroupName = std::forward<NodegroupNameT>(value); }
66 template<typename NodegroupNameT = Aws::String>
67 CreateNodegroupRequest& WithNodegroupName(NodegroupNameT&& value) { SetNodegroupName(std::forward<NodegroupNameT>(value)); return *this;}
69
71
75 inline const NodegroupScalingConfig& GetScalingConfig() const { return m_scalingConfig; }
76 inline bool ScalingConfigHasBeenSet() const { return m_scalingConfigHasBeenSet; }
77 template<typename ScalingConfigT = NodegroupScalingConfig>
78 void SetScalingConfig(ScalingConfigT&& value) { m_scalingConfigHasBeenSet = true; m_scalingConfig = std::forward<ScalingConfigT>(value); }
79 template<typename ScalingConfigT = NodegroupScalingConfig>
80 CreateNodegroupRequest& WithScalingConfig(ScalingConfigT&& value) { SetScalingConfig(std::forward<ScalingConfigT>(value)); return *this;}
82
84
93 inline int GetDiskSize() const { return m_diskSize; }
94 inline bool DiskSizeHasBeenSet() const { return m_diskSizeHasBeenSet; }
95 inline void SetDiskSize(int value) { m_diskSizeHasBeenSet = true; m_diskSize = value; }
96 inline CreateNodegroupRequest& WithDiskSize(int value) { SetDiskSize(value); return *this;}
98
100
109 inline const Aws::Vector<Aws::String>& GetSubnets() const { return m_subnets; }
110 inline bool SubnetsHasBeenSet() const { return m_subnetsHasBeenSet; }
111 template<typename SubnetsT = Aws::Vector<Aws::String>>
112 void SetSubnets(SubnetsT&& value) { m_subnetsHasBeenSet = true; m_subnets = std::forward<SubnetsT>(value); }
113 template<typename SubnetsT = Aws::Vector<Aws::String>>
114 CreateNodegroupRequest& WithSubnets(SubnetsT&& value) { SetSubnets(std::forward<SubnetsT>(value)); return *this;}
115 template<typename SubnetsT = Aws::String>
116 CreateNodegroupRequest& AddSubnets(SubnetsT&& value) { m_subnetsHasBeenSet = true; m_subnets.emplace_back(std::forward<SubnetsT>(value)); return *this; }
118
120
137 inline const Aws::Vector<Aws::String>& GetInstanceTypes() const { return m_instanceTypes; }
138 inline bool InstanceTypesHasBeenSet() const { return m_instanceTypesHasBeenSet; }
139 template<typename InstanceTypesT = Aws::Vector<Aws::String>>
140 void SetInstanceTypes(InstanceTypesT&& value) { m_instanceTypesHasBeenSet = true; m_instanceTypes = std::forward<InstanceTypesT>(value); }
141 template<typename InstanceTypesT = Aws::Vector<Aws::String>>
142 CreateNodegroupRequest& WithInstanceTypes(InstanceTypesT&& value) { SetInstanceTypes(std::forward<InstanceTypesT>(value)); return *this;}
143 template<typename InstanceTypesT = Aws::String>
144 CreateNodegroupRequest& AddInstanceTypes(InstanceTypesT&& value) { m_instanceTypesHasBeenSet = true; m_instanceTypes.emplace_back(std::forward<InstanceTypesT>(value)); return *this; }
146
148
159 inline AMITypes GetAmiType() const { return m_amiType; }
160 inline bool AmiTypeHasBeenSet() const { return m_amiTypeHasBeenSet; }
161 inline void SetAmiType(AMITypes value) { m_amiTypeHasBeenSet = true; m_amiType = value; }
162 inline CreateNodegroupRequest& WithAmiType(AMITypes value) { SetAmiType(value); return *this;}
164
166
175 inline const RemoteAccessConfig& GetRemoteAccess() const { return m_remoteAccess; }
176 inline bool RemoteAccessHasBeenSet() const { return m_remoteAccessHasBeenSet; }
177 template<typename RemoteAccessT = RemoteAccessConfig>
178 void SetRemoteAccess(RemoteAccessT&& value) { m_remoteAccessHasBeenSet = true; m_remoteAccess = std::forward<RemoteAccessT>(value); }
179 template<typename RemoteAccessT = RemoteAccessConfig>
180 CreateNodegroupRequest& WithRemoteAccess(RemoteAccessT&& value) { SetRemoteAccess(std::forward<RemoteAccessT>(value)); return *this;}
182
184
200 inline const Aws::String& GetNodeRole() const { return m_nodeRole; }
201 inline bool NodeRoleHasBeenSet() const { return m_nodeRoleHasBeenSet; }
202 template<typename NodeRoleT = Aws::String>
203 void SetNodeRole(NodeRoleT&& value) { m_nodeRoleHasBeenSet = true; m_nodeRole = std::forward<NodeRoleT>(value); }
204 template<typename NodeRoleT = Aws::String>
205 CreateNodegroupRequest& WithNodeRole(NodeRoleT&& value) { SetNodeRole(std::forward<NodeRoleT>(value)); return *this;}
207
209
213 inline const Aws::Map<Aws::String, Aws::String>& GetLabels() const { return m_labels; }
214 inline bool LabelsHasBeenSet() const { return m_labelsHasBeenSet; }
215 template<typename LabelsT = Aws::Map<Aws::String, Aws::String>>
216 void SetLabels(LabelsT&& value) { m_labelsHasBeenSet = true; m_labels = std::forward<LabelsT>(value); }
217 template<typename LabelsT = Aws::Map<Aws::String, Aws::String>>
218 CreateNodegroupRequest& WithLabels(LabelsT&& value) { SetLabels(std::forward<LabelsT>(value)); return *this;}
219 template<typename LabelsKeyT = Aws::String, typename LabelsValueT = Aws::String>
220 CreateNodegroupRequest& AddLabels(LabelsKeyT&& key, LabelsValueT&& value) {
221 m_labelsHasBeenSet = true; m_labels.emplace(std::forward<LabelsKeyT>(key), std::forward<LabelsValueT>(value)); return *this;
222 }
224
226
232 inline const Aws::Vector<Taint>& GetTaints() const { return m_taints; }
233 inline bool TaintsHasBeenSet() const { return m_taintsHasBeenSet; }
234 template<typename TaintsT = Aws::Vector<Taint>>
235 void SetTaints(TaintsT&& value) { m_taintsHasBeenSet = true; m_taints = std::forward<TaintsT>(value); }
236 template<typename TaintsT = Aws::Vector<Taint>>
237 CreateNodegroupRequest& WithTaints(TaintsT&& value) { SetTaints(std::forward<TaintsT>(value)); return *this;}
238 template<typename TaintsT = Taint>
239 CreateNodegroupRequest& AddTaints(TaintsT&& value) { m_taintsHasBeenSet = true; m_taints.emplace_back(std::forward<TaintsT>(value)); return *this; }
241
243
248 inline const Aws::Map<Aws::String, Aws::String>& GetTags() const { return m_tags; }
249 inline bool TagsHasBeenSet() const { return m_tagsHasBeenSet; }
250 template<typename TagsT = Aws::Map<Aws::String, Aws::String>>
251 void SetTags(TagsT&& value) { m_tagsHasBeenSet = true; m_tags = std::forward<TagsT>(value); }
252 template<typename TagsT = Aws::Map<Aws::String, Aws::String>>
253 CreateNodegroupRequest& WithTags(TagsT&& value) { SetTags(std::forward<TagsT>(value)); return *this;}
254 template<typename TagsKeyT = Aws::String, typename TagsValueT = Aws::String>
255 CreateNodegroupRequest& AddTags(TagsKeyT&& key, TagsValueT&& value) {
256 m_tagsHasBeenSet = true; m_tags.emplace(std::forward<TagsKeyT>(key), std::forward<TagsValueT>(value)); return *this;
257 }
259
261
265 inline const Aws::String& GetClientRequestToken() const { return m_clientRequestToken; }
266 inline bool ClientRequestTokenHasBeenSet() const { return m_clientRequestTokenHasBeenSet; }
267 template<typename ClientRequestTokenT = Aws::String>
268 void SetClientRequestToken(ClientRequestTokenT&& value) { m_clientRequestTokenHasBeenSet = true; m_clientRequestToken = std::forward<ClientRequestTokenT>(value); }
269 template<typename ClientRequestTokenT = Aws::String>
270 CreateNodegroupRequest& WithClientRequestToken(ClientRequestTokenT&& value) { SetClientRequestToken(std::forward<ClientRequestTokenT>(value)); return *this;}
272
274
284 inline const LaunchTemplateSpecification& GetLaunchTemplate() const { return m_launchTemplate; }
285 inline bool LaunchTemplateHasBeenSet() const { return m_launchTemplateHasBeenSet; }
286 template<typename LaunchTemplateT = LaunchTemplateSpecification>
287 void SetLaunchTemplate(LaunchTemplateT&& value) { m_launchTemplateHasBeenSet = true; m_launchTemplate = std::forward<LaunchTemplateT>(value); }
288 template<typename LaunchTemplateT = LaunchTemplateSpecification>
289 CreateNodegroupRequest& WithLaunchTemplate(LaunchTemplateT&& value) { SetLaunchTemplate(std::forward<LaunchTemplateT>(value)); return *this;}
291
293
296 inline const NodegroupUpdateConfig& GetUpdateConfig() const { return m_updateConfig; }
297 inline bool UpdateConfigHasBeenSet() const { return m_updateConfigHasBeenSet; }
298 template<typename UpdateConfigT = NodegroupUpdateConfig>
299 void SetUpdateConfig(UpdateConfigT&& value) { m_updateConfigHasBeenSet = true; m_updateConfig = std::forward<UpdateConfigT>(value); }
300 template<typename UpdateConfigT = NodegroupUpdateConfig>
301 CreateNodegroupRequest& WithUpdateConfig(UpdateConfigT&& value) { SetUpdateConfig(std::forward<UpdateConfigT>(value)); return *this;}
303
305
308 inline const NodeRepairConfig& GetNodeRepairConfig() const { return m_nodeRepairConfig; }
309 inline bool NodeRepairConfigHasBeenSet() const { return m_nodeRepairConfigHasBeenSet; }
310 template<typename NodeRepairConfigT = NodeRepairConfig>
311 void SetNodeRepairConfig(NodeRepairConfigT&& value) { m_nodeRepairConfigHasBeenSet = true; m_nodeRepairConfig = std::forward<NodeRepairConfigT>(value); }
312 template<typename NodeRepairConfigT = NodeRepairConfig>
313 CreateNodegroupRequest& WithNodeRepairConfig(NodeRepairConfigT&& value) { SetNodeRepairConfig(std::forward<NodeRepairConfigT>(value)); return *this;}
315
317
320 inline CapacityTypes GetCapacityType() const { return m_capacityType; }
321 inline bool CapacityTypeHasBeenSet() const { return m_capacityTypeHasBeenSet; }
322 inline void SetCapacityType(CapacityTypes value) { m_capacityTypeHasBeenSet = true; m_capacityType = value; }
325
327
337 inline const Aws::String& GetVersion() const { return m_version; }
338 inline bool VersionHasBeenSet() const { return m_versionHasBeenSet; }
339 template<typename VersionT = Aws::String>
340 void SetVersion(VersionT&& value) { m_versionHasBeenSet = true; m_version = std::forward<VersionT>(value); }
341 template<typename VersionT = Aws::String>
342 CreateNodegroupRequest& WithVersion(VersionT&& value) { SetVersion(std::forward<VersionT>(value)); return *this;}
344
346
363 inline const Aws::String& GetReleaseVersion() const { return m_releaseVersion; }
364 inline bool ReleaseVersionHasBeenSet() const { return m_releaseVersionHasBeenSet; }
365 template<typename ReleaseVersionT = Aws::String>
366 void SetReleaseVersion(ReleaseVersionT&& value) { m_releaseVersionHasBeenSet = true; m_releaseVersion = std::forward<ReleaseVersionT>(value); }
367 template<typename ReleaseVersionT = Aws::String>
368 CreateNodegroupRequest& WithReleaseVersion(ReleaseVersionT&& value) { SetReleaseVersion(std::forward<ReleaseVersionT>(value)); return *this;}
370 private:
371
372 Aws::String m_clusterName;
373 bool m_clusterNameHasBeenSet = false;
374
375 Aws::String m_nodegroupName;
376 bool m_nodegroupNameHasBeenSet = false;
377
378 NodegroupScalingConfig m_scalingConfig;
379 bool m_scalingConfigHasBeenSet = false;
380
381 int m_diskSize{0};
382 bool m_diskSizeHasBeenSet = false;
383
384 Aws::Vector<Aws::String> m_subnets;
385 bool m_subnetsHasBeenSet = false;
386
387 Aws::Vector<Aws::String> m_instanceTypes;
388 bool m_instanceTypesHasBeenSet = false;
389
390 AMITypes m_amiType{AMITypes::NOT_SET};
391 bool m_amiTypeHasBeenSet = false;
392
393 RemoteAccessConfig m_remoteAccess;
394 bool m_remoteAccessHasBeenSet = false;
395
396 Aws::String m_nodeRole;
397 bool m_nodeRoleHasBeenSet = false;
398
400 bool m_labelsHasBeenSet = false;
401
402 Aws::Vector<Taint> m_taints;
403 bool m_taintsHasBeenSet = false;
404
406 bool m_tagsHasBeenSet = false;
407
408 Aws::String m_clientRequestToken{Aws::Utils::UUID::PseudoRandomUUID()};
409 bool m_clientRequestTokenHasBeenSet = true;
410
411 LaunchTemplateSpecification m_launchTemplate;
412 bool m_launchTemplateHasBeenSet = false;
413
414 NodegroupUpdateConfig m_updateConfig;
415 bool m_updateConfigHasBeenSet = false;
416
417 NodeRepairConfig m_nodeRepairConfig;
418 bool m_nodeRepairConfigHasBeenSet = false;
419
421 bool m_capacityTypeHasBeenSet = false;
422
423 Aws::String m_version;
424 bool m_versionHasBeenSet = false;
425
426 Aws::String m_releaseVersion;
427 bool m_releaseVersionHasBeenSet = false;
428 };
429
430} // namespace Model
431} // namespace EKS
432} // namespace Aws
void SetNodegroupName(NodegroupNameT &&value)
AWS_EKS_API CreateNodegroupRequest()=default
CreateNodegroupRequest & WithRemoteAccess(RemoteAccessT &&value)
CreateNodegroupRequest & WithClusterName(ClusterNameT &&value)
CreateNodegroupRequest & WithReleaseVersion(ReleaseVersionT &&value)
CreateNodegroupRequest & WithAmiType(AMITypes value)
CreateNodegroupRequest & WithLaunchTemplate(LaunchTemplateT &&value)
CreateNodegroupRequest & AddTaints(TaintsT &&value)
const Aws::Vector< Aws::String > & GetSubnets() const
void SetReleaseVersion(ReleaseVersionT &&value)
CreateNodegroupRequest & WithLabels(LabelsT &&value)
void SetClientRequestToken(ClientRequestTokenT &&value)
void SetNodeRepairConfig(NodeRepairConfigT &&value)
CreateNodegroupRequest & WithTaints(TaintsT &&value)
const Aws::Map< Aws::String, Aws::String > & GetLabels() const
CreateNodegroupRequest & AddTags(TagsKeyT &&key, TagsValueT &&value)
const Aws::Vector< Taint > & GetTaints() const
CreateNodegroupRequest & WithNodeRepairConfig(NodeRepairConfigT &&value)
const Aws::Vector< Aws::String > & GetInstanceTypes() const
virtual const char * GetServiceRequestName() const override
CreateNodegroupRequest & WithUpdateConfig(UpdateConfigT &&value)
CreateNodegroupRequest & WithCapacityType(CapacityTypes value)
void SetScalingConfig(ScalingConfigT &&value)
const NodegroupUpdateConfig & GetUpdateConfig() const
CreateNodegroupRequest & WithScalingConfig(ScalingConfigT &&value)
const NodeRepairConfig & GetNodeRepairConfig() const
const LaunchTemplateSpecification & GetLaunchTemplate() const
const Aws::Map< Aws::String, Aws::String > & GetTags() const
AWS_EKS_API Aws::String SerializePayload() const override
CreateNodegroupRequest & WithTags(TagsT &&value)
CreateNodegroupRequest & WithNodegroupName(NodegroupNameT &&value)
CreateNodegroupRequest & WithInstanceTypes(InstanceTypesT &&value)
void SetLaunchTemplate(LaunchTemplateT &&value)
CreateNodegroupRequest & AddInstanceTypes(InstanceTypesT &&value)
CreateNodegroupRequest & WithSubnets(SubnetsT &&value)
const RemoteAccessConfig & GetRemoteAccess() const
const NodegroupScalingConfig & GetScalingConfig() const
const Aws::String & GetClientRequestToken() const
CreateNodegroupRequest & AddLabels(LabelsKeyT &&key, LabelsValueT &&value)
CreateNodegroupRequest & AddSubnets(SubnetsT &&value)
CreateNodegroupRequest & WithNodeRole(NodeRoleT &&value)
CreateNodegroupRequest & WithClientRequestToken(ClientRequestTokenT &&value)
CreateNodegroupRequest & WithVersion(VersionT &&value)
CreateNodegroupRequest & WithDiskSize(int value)
static Aws::Utils::UUID PseudoRandomUUID()
std::map< K, V, std::less< K >, Aws::Allocator< std::pair< const K, V > > > Map
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
std::vector< T, Aws::Allocator< T > > Vector