AWS SDK for C++

AWS SDK for C++ Version 1.11.780

Loading...
Searching...
No Matches
ClusterInstanceGroupSpecification.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/sagemaker/SageMaker_EXPORTS.h>
10#include <aws/sagemaker/model/ClusterCapacityRequirements.h>
11#include <aws/sagemaker/model/ClusterInstanceStorageConfig.h>
12#include <aws/sagemaker/model/ClusterInstanceType.h>
13#include <aws/sagemaker/model/ClusterKubernetesConfig.h>
14#include <aws/sagemaker/model/ClusterLifeCycleConfig.h>
15#include <aws/sagemaker/model/ClusterSlurmConfig.h>
16#include <aws/sagemaker/model/DeepHealthCheckType.h>
17#include <aws/sagemaker/model/ScheduledUpdateConfig.h>
18#include <aws/sagemaker/model/VpcConfig.h>
19
20#include <utility>
21
22namespace Aws {
23namespace Utils {
24namespace Json {
25class JsonValue;
26class JsonView;
27} // namespace Json
28} // namespace Utils
29namespace SageMaker {
30namespace Model {
31
39 public:
40 AWS_SAGEMAKER_API ClusterInstanceGroupSpecification() = default;
43 AWS_SAGEMAKER_API Aws::Utils::Json::JsonValue Jsonize() const;
44
46
50 inline int GetInstanceCount() const { return m_instanceCount; }
51 inline bool InstanceCountHasBeenSet() const { return m_instanceCountHasBeenSet; }
52 inline void SetInstanceCount(int value) {
53 m_instanceCountHasBeenSet = true;
54 m_instanceCount = value;
55 }
57 SetInstanceCount(value);
58 return *this;
59 }
61
63
72 inline int GetMinInstanceCount() const { return m_minInstanceCount; }
73 inline bool MinInstanceCountHasBeenSet() const { return m_minInstanceCountHasBeenSet; }
74 inline void SetMinInstanceCount(int value) {
75 m_minInstanceCountHasBeenSet = true;
76 m_minInstanceCount = value;
77 }
80 return *this;
81 }
83
85
88 inline const Aws::String& GetInstanceGroupName() const { return m_instanceGroupName; }
89 inline bool InstanceGroupNameHasBeenSet() const { return m_instanceGroupNameHasBeenSet; }
90 template <typename InstanceGroupNameT = Aws::String>
91 void SetInstanceGroupName(InstanceGroupNameT&& value) {
92 m_instanceGroupNameHasBeenSet = true;
93 m_instanceGroupName = std::forward<InstanceGroupNameT>(value);
94 }
95 template <typename InstanceGroupNameT = Aws::String>
97 SetInstanceGroupName(std::forward<InstanceGroupNameT>(value));
98 return *this;
99 }
101
103
106 inline ClusterInstanceType GetInstanceType() const { return m_instanceType; }
107 inline bool InstanceTypeHasBeenSet() const { return m_instanceTypeHasBeenSet; }
109 m_instanceTypeHasBeenSet = true;
110 m_instanceType = value;
111 }
113 SetInstanceType(value);
114 return *this;
115 }
117
119
122 inline const ClusterLifeCycleConfig& GetLifeCycleConfig() const { return m_lifeCycleConfig; }
123 inline bool LifeCycleConfigHasBeenSet() const { return m_lifeCycleConfigHasBeenSet; }
124 template <typename LifeCycleConfigT = ClusterLifeCycleConfig>
125 void SetLifeCycleConfig(LifeCycleConfigT&& value) {
126 m_lifeCycleConfigHasBeenSet = true;
127 m_lifeCycleConfig = std::forward<LifeCycleConfigT>(value);
128 }
129 template <typename LifeCycleConfigT = ClusterLifeCycleConfig>
131 SetLifeCycleConfig(std::forward<LifeCycleConfigT>(value));
132 return *this;
133 }
135
137
140 inline const Aws::String& GetExecutionRole() const { return m_executionRole; }
141 inline bool ExecutionRoleHasBeenSet() const { return m_executionRoleHasBeenSet; }
142 template <typename ExecutionRoleT = Aws::String>
143 void SetExecutionRole(ExecutionRoleT&& value) {
144 m_executionRoleHasBeenSet = true;
145 m_executionRole = std::forward<ExecutionRoleT>(value);
146 }
147 template <typename ExecutionRoleT = Aws::String>
149 SetExecutionRole(std::forward<ExecutionRoleT>(value));
150 return *this;
151 }
153
155
165 inline int GetThreadsPerCore() const { return m_threadsPerCore; }
166 inline bool ThreadsPerCoreHasBeenSet() const { return m_threadsPerCoreHasBeenSet; }
167 inline void SetThreadsPerCore(int value) {
168 m_threadsPerCoreHasBeenSet = true;
169 m_threadsPerCore = value;
170 }
172 SetThreadsPerCore(value);
173 return *this;
174 }
176
178
182 inline const Aws::Vector<ClusterInstanceStorageConfig>& GetInstanceStorageConfigs() const { return m_instanceStorageConfigs; }
183 inline bool InstanceStorageConfigsHasBeenSet() const { return m_instanceStorageConfigsHasBeenSet; }
184 template <typename InstanceStorageConfigsT = Aws::Vector<ClusterInstanceStorageConfig>>
185 void SetInstanceStorageConfigs(InstanceStorageConfigsT&& value) {
186 m_instanceStorageConfigsHasBeenSet = true;
187 m_instanceStorageConfigs = std::forward<InstanceStorageConfigsT>(value);
188 }
189 template <typename InstanceStorageConfigsT = Aws::Vector<ClusterInstanceStorageConfig>>
191 SetInstanceStorageConfigs(std::forward<InstanceStorageConfigsT>(value));
192 return *this;
193 }
194 template <typename InstanceStorageConfigsT = ClusterInstanceStorageConfig>
196 m_instanceStorageConfigsHasBeenSet = true;
197 m_instanceStorageConfigs.emplace_back(std::forward<InstanceStorageConfigsT>(value));
198 return *this;
199 }
201
203
207 inline const Aws::Vector<DeepHealthCheckType>& GetOnStartDeepHealthChecks() const { return m_onStartDeepHealthChecks; }
208 inline bool OnStartDeepHealthChecksHasBeenSet() const { return m_onStartDeepHealthChecksHasBeenSet; }
209 template <typename OnStartDeepHealthChecksT = Aws::Vector<DeepHealthCheckType>>
210 void SetOnStartDeepHealthChecks(OnStartDeepHealthChecksT&& value) {
211 m_onStartDeepHealthChecksHasBeenSet = true;
212 m_onStartDeepHealthChecks = std::forward<OnStartDeepHealthChecksT>(value);
213 }
214 template <typename OnStartDeepHealthChecksT = Aws::Vector<DeepHealthCheckType>>
216 SetOnStartDeepHealthChecks(std::forward<OnStartDeepHealthChecksT>(value));
217 return *this;
218 }
220 m_onStartDeepHealthChecksHasBeenSet = true;
221 m_onStartDeepHealthChecks.push_back(value);
222 return *this;
223 }
225
227
235 inline const Aws::String& GetTrainingPlanArn() const { return m_trainingPlanArn; }
236 inline bool TrainingPlanArnHasBeenSet() const { return m_trainingPlanArnHasBeenSet; }
237 template <typename TrainingPlanArnT = Aws::String>
238 void SetTrainingPlanArn(TrainingPlanArnT&& value) {
239 m_trainingPlanArnHasBeenSet = true;
240 m_trainingPlanArn = std::forward<TrainingPlanArnT>(value);
241 }
242 template <typename TrainingPlanArnT = Aws::String>
244 SetTrainingPlanArn(std::forward<TrainingPlanArnT>(value));
245 return *this;
246 }
248
250
278 inline const VpcConfig& GetOverrideVpcConfig() const { return m_overrideVpcConfig; }
279 inline bool OverrideVpcConfigHasBeenSet() const { return m_overrideVpcConfigHasBeenSet; }
280 template <typename OverrideVpcConfigT = VpcConfig>
281 void SetOverrideVpcConfig(OverrideVpcConfigT&& value) {
282 m_overrideVpcConfigHasBeenSet = true;
283 m_overrideVpcConfig = std::forward<OverrideVpcConfigT>(value);
284 }
285 template <typename OverrideVpcConfigT = VpcConfig>
287 SetOverrideVpcConfig(std::forward<OverrideVpcConfigT>(value));
288 return *this;
289 }
291
293
297 inline const ScheduledUpdateConfig& GetScheduledUpdateConfig() const { return m_scheduledUpdateConfig; }
298 inline bool ScheduledUpdateConfigHasBeenSet() const { return m_scheduledUpdateConfigHasBeenSet; }
299 template <typename ScheduledUpdateConfigT = ScheduledUpdateConfig>
300 void SetScheduledUpdateConfig(ScheduledUpdateConfigT&& value) {
301 m_scheduledUpdateConfigHasBeenSet = true;
302 m_scheduledUpdateConfig = std::forward<ScheduledUpdateConfigT>(value);
303 }
304 template <typename ScheduledUpdateConfigT = ScheduledUpdateConfig>
306 SetScheduledUpdateConfig(std::forward<ScheduledUpdateConfigT>(value));
307 return *this;
308 }
310
312
330 inline const Aws::String& GetImageId() const { return m_imageId; }
331 inline bool ImageIdHasBeenSet() const { return m_imageIdHasBeenSet; }
332 template <typename ImageIdT = Aws::String>
333 void SetImageId(ImageIdT&& value) {
334 m_imageIdHasBeenSet = true;
335 m_imageId = std::forward<ImageIdT>(value);
336 }
337 template <typename ImageIdT = Aws::String>
339 SetImageId(std::forward<ImageIdT>(value));
340 return *this;
341 }
343
345
351 inline const ClusterKubernetesConfig& GetKubernetesConfig() const { return m_kubernetesConfig; }
352 inline bool KubernetesConfigHasBeenSet() const { return m_kubernetesConfigHasBeenSet; }
353 template <typename KubernetesConfigT = ClusterKubernetesConfig>
354 void SetKubernetesConfig(KubernetesConfigT&& value) {
355 m_kubernetesConfigHasBeenSet = true;
356 m_kubernetesConfig = std::forward<KubernetesConfigT>(value);
357 }
358 template <typename KubernetesConfigT = ClusterKubernetesConfig>
360 SetKubernetesConfig(std::forward<KubernetesConfigT>(value));
361 return *this;
362 }
364
366
369 inline const ClusterSlurmConfig& GetSlurmConfig() const { return m_slurmConfig; }
370 inline bool SlurmConfigHasBeenSet() const { return m_slurmConfigHasBeenSet; }
371 template <typename SlurmConfigT = ClusterSlurmConfig>
372 void SetSlurmConfig(SlurmConfigT&& value) {
373 m_slurmConfigHasBeenSet = true;
374 m_slurmConfig = std::forward<SlurmConfigT>(value);
375 }
376 template <typename SlurmConfigT = ClusterSlurmConfig>
378 SetSlurmConfig(std::forward<SlurmConfigT>(value));
379 return *this;
380 }
382
384
387 inline const ClusterCapacityRequirements& GetCapacityRequirements() const { return m_capacityRequirements; }
388 inline bool CapacityRequirementsHasBeenSet() const { return m_capacityRequirementsHasBeenSet; }
389 template <typename CapacityRequirementsT = ClusterCapacityRequirements>
390 void SetCapacityRequirements(CapacityRequirementsT&& value) {
391 m_capacityRequirementsHasBeenSet = true;
392 m_capacityRequirements = std::forward<CapacityRequirementsT>(value);
393 }
394 template <typename CapacityRequirementsT = ClusterCapacityRequirements>
396 SetCapacityRequirements(std::forward<CapacityRequirementsT>(value));
397 return *this;
398 }
400 private:
401 int m_instanceCount{0};
402
403 int m_minInstanceCount{0};
404
405 Aws::String m_instanceGroupName;
406
408
409 ClusterLifeCycleConfig m_lifeCycleConfig;
410
411 Aws::String m_executionRole;
412
413 int m_threadsPerCore{0};
414
415 Aws::Vector<ClusterInstanceStorageConfig> m_instanceStorageConfigs;
416
417 Aws::Vector<DeepHealthCheckType> m_onStartDeepHealthChecks;
418
419 Aws::String m_trainingPlanArn;
420
421 VpcConfig m_overrideVpcConfig;
422
423 ScheduledUpdateConfig m_scheduledUpdateConfig;
424
425 Aws::String m_imageId;
426
427 ClusterKubernetesConfig m_kubernetesConfig;
428
429 ClusterSlurmConfig m_slurmConfig;
430
431 ClusterCapacityRequirements m_capacityRequirements;
432 bool m_instanceCountHasBeenSet = false;
433 bool m_minInstanceCountHasBeenSet = false;
434 bool m_instanceGroupNameHasBeenSet = false;
435 bool m_instanceTypeHasBeenSet = false;
436 bool m_lifeCycleConfigHasBeenSet = false;
437 bool m_executionRoleHasBeenSet = false;
438 bool m_threadsPerCoreHasBeenSet = false;
439 bool m_instanceStorageConfigsHasBeenSet = false;
440 bool m_onStartDeepHealthChecksHasBeenSet = false;
441 bool m_trainingPlanArnHasBeenSet = false;
442 bool m_overrideVpcConfigHasBeenSet = false;
443 bool m_scheduledUpdateConfigHasBeenSet = false;
444 bool m_imageIdHasBeenSet = false;
445 bool m_kubernetesConfigHasBeenSet = false;
446 bool m_slurmConfigHasBeenSet = false;
447 bool m_capacityRequirementsHasBeenSet = false;
448};
449
450} // namespace Model
451} // namespace SageMaker
452} // namespace Aws
ClusterInstanceGroupSpecification & WithImageId(ImageIdT &&value)
ClusterInstanceGroupSpecification & WithExecutionRole(ExecutionRoleT &&value)
ClusterInstanceGroupSpecification & WithOnStartDeepHealthChecks(OnStartDeepHealthChecksT &&value)
ClusterInstanceGroupSpecification & WithTrainingPlanArn(TrainingPlanArnT &&value)
ClusterInstanceGroupSpecification & AddInstanceStorageConfigs(InstanceStorageConfigsT &&value)
ClusterInstanceGroupSpecification & WithOverrideVpcConfig(OverrideVpcConfigT &&value)
AWS_SAGEMAKER_API ClusterInstanceGroupSpecification(Aws::Utils::Json::JsonView jsonValue)
const Aws::Vector< ClusterInstanceStorageConfig > & GetInstanceStorageConfigs() const
ClusterInstanceGroupSpecification & WithScheduledUpdateConfig(ScheduledUpdateConfigT &&value)
ClusterInstanceGroupSpecification & WithInstanceGroupName(InstanceGroupNameT &&value)
ClusterInstanceGroupSpecification & WithCapacityRequirements(CapacityRequirementsT &&value)
AWS_SAGEMAKER_API ClusterInstanceGroupSpecification & operator=(Aws::Utils::Json::JsonView jsonValue)
ClusterInstanceGroupSpecification & WithMinInstanceCount(int value)
AWS_SAGEMAKER_API Aws::Utils::Json::JsonValue Jsonize() const
ClusterInstanceGroupSpecification & WithInstanceType(ClusterInstanceType value)
const Aws::Vector< DeepHealthCheckType > & GetOnStartDeepHealthChecks() const
ClusterInstanceGroupSpecification & WithLifeCycleConfig(LifeCycleConfigT &&value)
ClusterInstanceGroupSpecification & WithKubernetesConfig(KubernetesConfigT &&value)
ClusterInstanceGroupSpecification & WithSlurmConfig(SlurmConfigT &&value)
ClusterInstanceGroupSpecification & AddOnStartDeepHealthChecks(DeepHealthCheckType value)
ClusterInstanceGroupSpecification & WithInstanceStorageConfigs(InstanceStorageConfigsT &&value)
AWS_SAGEMAKER_API ClusterInstanceGroupSpecification()=default
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
std::vector< T, Aws::Allocator< T > > Vector
Aws::Utils::Json::JsonValue JsonValue