aws_sdk_sagemaker/operation/create_endpoint_config/builders.rs
1// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
2pub use crate::operation::create_endpoint_config::_create_endpoint_config_output::CreateEndpointConfigOutputBuilder;
3
4pub use crate::operation::create_endpoint_config::_create_endpoint_config_input::CreateEndpointConfigInputBuilder;
5
6impl crate::operation::create_endpoint_config::builders::CreateEndpointConfigInputBuilder {
7 /// Sends a request with this input using the given client.
8 pub async fn send_with(
9 self,
10 client: &crate::Client,
11 ) -> ::std::result::Result<
12 crate::operation::create_endpoint_config::CreateEndpointConfigOutput,
13 ::aws_smithy_runtime_api::client::result::SdkError<
14 crate::operation::create_endpoint_config::CreateEndpointConfigError,
15 ::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
16 >,
17 > {
18 let mut fluent_builder = client.create_endpoint_config();
19 fluent_builder.inner = self;
20 fluent_builder.send().await
21 }
22}
23/// Fluent builder constructing a request to `CreateEndpointConfig`.
24///
25/// <p>Creates an endpoint configuration that SageMaker hosting services uses to deploy models. In the configuration, you identify one or more models, created using the <code>CreateModel</code> API, to deploy and the resources that you want SageMaker to provision. Then you call the <a href="https://docs.aws.amazon.com/sagemaker/latest/APIReference/API_CreateEndpoint.html">CreateEndpoint</a> API.</p><note>
26/// <p>Use this API if you want to use SageMaker hosting services to deploy models into production.</p>
27/// </note>
28/// <p>In the request, you define a <code>ProductionVariant</code>, for each model that you want to deploy. Each <code>ProductionVariant</code> parameter also describes the resources that you want SageMaker to provision. This includes the number and type of ML compute instances to deploy.</p>
29/// <p>If you are hosting multiple models, you also assign a <code>VariantWeight</code> to specify how much traffic you want to allocate to each model. For example, suppose that you want to host two models, A and B, and you assign traffic weight 2 for model A and 1 for model B. SageMaker distributes two-thirds of the traffic to Model A, and one-third to model B.</p><note>
30/// <p>When you call <a href="https://docs.aws.amazon.com/sagemaker/latest/APIReference/API_CreateEndpoint.html">CreateEndpoint</a>, a load call is made to DynamoDB to verify that your endpoint configuration exists. When you read data from a DynamoDB table supporting <a href="https://docs.aws.amazon.com/amazondynamodb/latest/developerguide/HowItWorks.ReadConsistency.html"> <code>Eventually Consistent Reads</code> </a>, the response might not reflect the results of a recently completed write operation. The response might include some stale data. If the dependent entities are not yet in DynamoDB, this causes a validation error. If you repeat your read request after a short time, the response should return the latest data. So retry logic is recommended to handle these possible issues. We also recommend that customers call <a href="https://docs.aws.amazon.com/sagemaker/latest/APIReference/API_DescribeEndpointConfig.html">DescribeEndpointConfig</a> before calling <a href="https://docs.aws.amazon.com/sagemaker/latest/APIReference/API_CreateEndpoint.html">CreateEndpoint</a> to minimize the potential impact of a DynamoDB eventually consistent read.</p>
31/// </note>
32#[derive(::std::clone::Clone, ::std::fmt::Debug)]
33pub struct CreateEndpointConfigFluentBuilder {
34 handle: ::std::sync::Arc<crate::client::Handle>,
35 inner: crate::operation::create_endpoint_config::builders::CreateEndpointConfigInputBuilder,
36 config_override: ::std::option::Option<crate::config::Builder>,
37}
38impl
39 crate::client::customize::internal::CustomizableSend<
40 crate::operation::create_endpoint_config::CreateEndpointConfigOutput,
41 crate::operation::create_endpoint_config::CreateEndpointConfigError,
42 > for CreateEndpointConfigFluentBuilder
43{
44 fn send(
45 self,
46 config_override: crate::config::Builder,
47 ) -> crate::client::customize::internal::BoxFuture<
48 crate::client::customize::internal::SendResult<
49 crate::operation::create_endpoint_config::CreateEndpointConfigOutput,
50 crate::operation::create_endpoint_config::CreateEndpointConfigError,
51 >,
52 > {
53 ::std::boxed::Box::pin(async move { self.config_override(config_override).send().await })
54 }
55}
56impl CreateEndpointConfigFluentBuilder {
57 /// Creates a new `CreateEndpointConfigFluentBuilder`.
58 pub(crate) fn new(handle: ::std::sync::Arc<crate::client::Handle>) -> Self {
59 Self {
60 handle,
61 inner: ::std::default::Default::default(),
62 config_override: ::std::option::Option::None,
63 }
64 }
65 /// Access the CreateEndpointConfig as a reference.
66 pub fn as_input(&self) -> &crate::operation::create_endpoint_config::builders::CreateEndpointConfigInputBuilder {
67 &self.inner
68 }
69 /// Sends the request and returns the response.
70 ///
71 /// If an error occurs, an `SdkError` will be returned with additional details that
72 /// can be matched against.
73 ///
74 /// By default, any retryable failures will be retried twice. Retry behavior
75 /// is configurable with the [RetryConfig](aws_smithy_types::retry::RetryConfig), which can be
76 /// set when configuring the client.
77 pub async fn send(
78 self,
79 ) -> ::std::result::Result<
80 crate::operation::create_endpoint_config::CreateEndpointConfigOutput,
81 ::aws_smithy_runtime_api::client::result::SdkError<
82 crate::operation::create_endpoint_config::CreateEndpointConfigError,
83 ::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
84 >,
85 > {
86 let input = self
87 .inner
88 .build()
89 .map_err(::aws_smithy_runtime_api::client::result::SdkError::construction_failure)?;
90 let runtime_plugins = crate::operation::create_endpoint_config::CreateEndpointConfig::operation_runtime_plugins(
91 self.handle.runtime_plugins.clone(),
92 &self.handle.conf,
93 self.config_override,
94 );
95 crate::operation::create_endpoint_config::CreateEndpointConfig::orchestrate(&runtime_plugins, input).await
96 }
97
98 /// Consumes this builder, creating a customizable operation that can be modified before being sent.
99 pub fn customize(
100 self,
101 ) -> crate::client::customize::CustomizableOperation<
102 crate::operation::create_endpoint_config::CreateEndpointConfigOutput,
103 crate::operation::create_endpoint_config::CreateEndpointConfigError,
104 Self,
105 > {
106 crate::client::customize::CustomizableOperation::new(self)
107 }
108 pub(crate) fn config_override(mut self, config_override: impl ::std::convert::Into<crate::config::Builder>) -> Self {
109 self.set_config_override(::std::option::Option::Some(config_override.into()));
110 self
111 }
112
113 pub(crate) fn set_config_override(&mut self, config_override: ::std::option::Option<crate::config::Builder>) -> &mut Self {
114 self.config_override = config_override;
115 self
116 }
117 /// <p>The name of the endpoint configuration. You specify this name in a <a href="https://docs.aws.amazon.com/sagemaker/latest/APIReference/API_CreateEndpoint.html">CreateEndpoint</a> request.</p>
118 pub fn endpoint_config_name(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
119 self.inner = self.inner.endpoint_config_name(input.into());
120 self
121 }
122 /// <p>The name of the endpoint configuration. You specify this name in a <a href="https://docs.aws.amazon.com/sagemaker/latest/APIReference/API_CreateEndpoint.html">CreateEndpoint</a> request.</p>
123 pub fn set_endpoint_config_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
124 self.inner = self.inner.set_endpoint_config_name(input);
125 self
126 }
127 /// <p>The name of the endpoint configuration. You specify this name in a <a href="https://docs.aws.amazon.com/sagemaker/latest/APIReference/API_CreateEndpoint.html">CreateEndpoint</a> request.</p>
128 pub fn get_endpoint_config_name(&self) -> &::std::option::Option<::std::string::String> {
129 self.inner.get_endpoint_config_name()
130 }
131 ///
132 /// Appends an item to `ProductionVariants`.
133 ///
134 /// To override the contents of this collection use [`set_production_variants`](Self::set_production_variants).
135 ///
136 /// <p>An array of <code>ProductionVariant</code> objects, one for each model that you want to host at this endpoint.</p>
137 pub fn production_variants(mut self, input: crate::types::ProductionVariant) -> Self {
138 self.inner = self.inner.production_variants(input);
139 self
140 }
141 /// <p>An array of <code>ProductionVariant</code> objects, one for each model that you want to host at this endpoint.</p>
142 pub fn set_production_variants(mut self, input: ::std::option::Option<::std::vec::Vec<crate::types::ProductionVariant>>) -> Self {
143 self.inner = self.inner.set_production_variants(input);
144 self
145 }
146 /// <p>An array of <code>ProductionVariant</code> objects, one for each model that you want to host at this endpoint.</p>
147 pub fn get_production_variants(&self) -> &::std::option::Option<::std::vec::Vec<crate::types::ProductionVariant>> {
148 self.inner.get_production_variants()
149 }
150 /// <p>Configuration to control how SageMaker AI captures inference data.</p>
151 pub fn data_capture_config(mut self, input: crate::types::DataCaptureConfig) -> Self {
152 self.inner = self.inner.data_capture_config(input);
153 self
154 }
155 /// <p>Configuration to control how SageMaker AI captures inference data.</p>
156 pub fn set_data_capture_config(mut self, input: ::std::option::Option<crate::types::DataCaptureConfig>) -> Self {
157 self.inner = self.inner.set_data_capture_config(input);
158 self
159 }
160 /// <p>Configuration to control how SageMaker AI captures inference data.</p>
161 pub fn get_data_capture_config(&self) -> &::std::option::Option<crate::types::DataCaptureConfig> {
162 self.inner.get_data_capture_config()
163 }
164 ///
165 /// Appends an item to `Tags`.
166 ///
167 /// To override the contents of this collection use [`set_tags`](Self::set_tags).
168 ///
169 /// <p>An array of key-value pairs. You can use tags to categorize your Amazon Web Services resources in different ways, for example, by purpose, owner, or environment. For more information, see <a href="https://docs.aws.amazon.com/general/latest/gr/aws_tagging.html">Tagging Amazon Web Services Resources</a>.</p>
170 pub fn tags(mut self, input: crate::types::Tag) -> Self {
171 self.inner = self.inner.tags(input);
172 self
173 }
174 /// <p>An array of key-value pairs. You can use tags to categorize your Amazon Web Services resources in different ways, for example, by purpose, owner, or environment. For more information, see <a href="https://docs.aws.amazon.com/general/latest/gr/aws_tagging.html">Tagging Amazon Web Services Resources</a>.</p>
175 pub fn set_tags(mut self, input: ::std::option::Option<::std::vec::Vec<crate::types::Tag>>) -> Self {
176 self.inner = self.inner.set_tags(input);
177 self
178 }
179 /// <p>An array of key-value pairs. You can use tags to categorize your Amazon Web Services resources in different ways, for example, by purpose, owner, or environment. For more information, see <a href="https://docs.aws.amazon.com/general/latest/gr/aws_tagging.html">Tagging Amazon Web Services Resources</a>.</p>
180 pub fn get_tags(&self) -> &::std::option::Option<::std::vec::Vec<crate::types::Tag>> {
181 self.inner.get_tags()
182 }
183 /// <p>The Amazon Resource Name (ARN) of a Amazon Web Services Key Management Service key that SageMaker uses to encrypt data on the storage volume attached to the ML compute instance that hosts the endpoint.</p>
184 /// <p>The KmsKeyId can be any of the following formats:</p>
185 /// <ul>
186 /// <li>
187 /// <p>Key ID: <code>1234abcd-12ab-34cd-56ef-1234567890ab</code></p></li>
188 /// <li>
189 /// <p>Key ARN: <code>arn:aws:kms:us-west-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab</code></p></li>
190 /// <li>
191 /// <p>Alias name: <code>alias/ExampleAlias</code></p></li>
192 /// <li>
193 /// <p>Alias name ARN: <code>arn:aws:kms:us-west-2:111122223333:alias/ExampleAlias</code></p></li>
194 /// </ul>
195 /// <p>The KMS key policy must grant permission to the IAM role that you specify in your <code>CreateEndpoint</code>, <code>UpdateEndpoint</code> requests. For more information, refer to the Amazon Web Services Key Management Service section<a href="https://docs.aws.amazon.com/kms/latest/developerguide/key-policies.html"> Using Key Policies in Amazon Web Services KMS </a></p><note>
196 /// <p>Certain Nitro-based instances include local storage, dependent on the instance type. Local storage volumes are encrypted using a hardware module on the instance. You can't request a <code>KmsKeyId</code> when using an instance type with local storage. If any of the models that you specify in the <code>ProductionVariants</code> parameter use nitro-based instances with local storage, do not specify a value for the <code>KmsKeyId</code> parameter. If you specify a value for <code>KmsKeyId</code> when using any nitro-based instances with local storage, the call to <code>CreateEndpointConfig</code> fails.</p>
197 /// <p>For a list of instance types that support local instance storage, see <a href="https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/InstanceStorage.html#instance-store-volumes">Instance Store Volumes</a>.</p>
198 /// <p>For more information about local instance storage encryption, see <a href="https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ssd-instance-store.html">SSD Instance Store Volumes</a>.</p>
199 /// </note>
200 pub fn kms_key_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
201 self.inner = self.inner.kms_key_id(input.into());
202 self
203 }
204 /// <p>The Amazon Resource Name (ARN) of a Amazon Web Services Key Management Service key that SageMaker uses to encrypt data on the storage volume attached to the ML compute instance that hosts the endpoint.</p>
205 /// <p>The KmsKeyId can be any of the following formats:</p>
206 /// <ul>
207 /// <li>
208 /// <p>Key ID: <code>1234abcd-12ab-34cd-56ef-1234567890ab</code></p></li>
209 /// <li>
210 /// <p>Key ARN: <code>arn:aws:kms:us-west-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab</code></p></li>
211 /// <li>
212 /// <p>Alias name: <code>alias/ExampleAlias</code></p></li>
213 /// <li>
214 /// <p>Alias name ARN: <code>arn:aws:kms:us-west-2:111122223333:alias/ExampleAlias</code></p></li>
215 /// </ul>
216 /// <p>The KMS key policy must grant permission to the IAM role that you specify in your <code>CreateEndpoint</code>, <code>UpdateEndpoint</code> requests. For more information, refer to the Amazon Web Services Key Management Service section<a href="https://docs.aws.amazon.com/kms/latest/developerguide/key-policies.html"> Using Key Policies in Amazon Web Services KMS </a></p><note>
217 /// <p>Certain Nitro-based instances include local storage, dependent on the instance type. Local storage volumes are encrypted using a hardware module on the instance. You can't request a <code>KmsKeyId</code> when using an instance type with local storage. If any of the models that you specify in the <code>ProductionVariants</code> parameter use nitro-based instances with local storage, do not specify a value for the <code>KmsKeyId</code> parameter. If you specify a value for <code>KmsKeyId</code> when using any nitro-based instances with local storage, the call to <code>CreateEndpointConfig</code> fails.</p>
218 /// <p>For a list of instance types that support local instance storage, see <a href="https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/InstanceStorage.html#instance-store-volumes">Instance Store Volumes</a>.</p>
219 /// <p>For more information about local instance storage encryption, see <a href="https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ssd-instance-store.html">SSD Instance Store Volumes</a>.</p>
220 /// </note>
221 pub fn set_kms_key_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
222 self.inner = self.inner.set_kms_key_id(input);
223 self
224 }
225 /// <p>The Amazon Resource Name (ARN) of a Amazon Web Services Key Management Service key that SageMaker uses to encrypt data on the storage volume attached to the ML compute instance that hosts the endpoint.</p>
226 /// <p>The KmsKeyId can be any of the following formats:</p>
227 /// <ul>
228 /// <li>
229 /// <p>Key ID: <code>1234abcd-12ab-34cd-56ef-1234567890ab</code></p></li>
230 /// <li>
231 /// <p>Key ARN: <code>arn:aws:kms:us-west-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab</code></p></li>
232 /// <li>
233 /// <p>Alias name: <code>alias/ExampleAlias</code></p></li>
234 /// <li>
235 /// <p>Alias name ARN: <code>arn:aws:kms:us-west-2:111122223333:alias/ExampleAlias</code></p></li>
236 /// </ul>
237 /// <p>The KMS key policy must grant permission to the IAM role that you specify in your <code>CreateEndpoint</code>, <code>UpdateEndpoint</code> requests. For more information, refer to the Amazon Web Services Key Management Service section<a href="https://docs.aws.amazon.com/kms/latest/developerguide/key-policies.html"> Using Key Policies in Amazon Web Services KMS </a></p><note>
238 /// <p>Certain Nitro-based instances include local storage, dependent on the instance type. Local storage volumes are encrypted using a hardware module on the instance. You can't request a <code>KmsKeyId</code> when using an instance type with local storage. If any of the models that you specify in the <code>ProductionVariants</code> parameter use nitro-based instances with local storage, do not specify a value for the <code>KmsKeyId</code> parameter. If you specify a value for <code>KmsKeyId</code> when using any nitro-based instances with local storage, the call to <code>CreateEndpointConfig</code> fails.</p>
239 /// <p>For a list of instance types that support local instance storage, see <a href="https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/InstanceStorage.html#instance-store-volumes">Instance Store Volumes</a>.</p>
240 /// <p>For more information about local instance storage encryption, see <a href="https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ssd-instance-store.html">SSD Instance Store Volumes</a>.</p>
241 /// </note>
242 pub fn get_kms_key_id(&self) -> &::std::option::Option<::std::string::String> {
243 self.inner.get_kms_key_id()
244 }
245 /// <p>Specifies configuration for how an endpoint performs asynchronous inference. This is a required field in order for your Endpoint to be invoked using <a href="https://docs.aws.amazon.com/sagemaker/latest/APIReference/API_runtime_InvokeEndpointAsync.html">InvokeEndpointAsync</a>.</p>
246 pub fn async_inference_config(mut self, input: crate::types::AsyncInferenceConfig) -> Self {
247 self.inner = self.inner.async_inference_config(input);
248 self
249 }
250 /// <p>Specifies configuration for how an endpoint performs asynchronous inference. This is a required field in order for your Endpoint to be invoked using <a href="https://docs.aws.amazon.com/sagemaker/latest/APIReference/API_runtime_InvokeEndpointAsync.html">InvokeEndpointAsync</a>.</p>
251 pub fn set_async_inference_config(mut self, input: ::std::option::Option<crate::types::AsyncInferenceConfig>) -> Self {
252 self.inner = self.inner.set_async_inference_config(input);
253 self
254 }
255 /// <p>Specifies configuration for how an endpoint performs asynchronous inference. This is a required field in order for your Endpoint to be invoked using <a href="https://docs.aws.amazon.com/sagemaker/latest/APIReference/API_runtime_InvokeEndpointAsync.html">InvokeEndpointAsync</a>.</p>
256 pub fn get_async_inference_config(&self) -> &::std::option::Option<crate::types::AsyncInferenceConfig> {
257 self.inner.get_async_inference_config()
258 }
259 /// <p>A member of <code>CreateEndpointConfig</code> that enables explainers.</p>
260 pub fn explainer_config(mut self, input: crate::types::ExplainerConfig) -> Self {
261 self.inner = self.inner.explainer_config(input);
262 self
263 }
264 /// <p>A member of <code>CreateEndpointConfig</code> that enables explainers.</p>
265 pub fn set_explainer_config(mut self, input: ::std::option::Option<crate::types::ExplainerConfig>) -> Self {
266 self.inner = self.inner.set_explainer_config(input);
267 self
268 }
269 /// <p>A member of <code>CreateEndpointConfig</code> that enables explainers.</p>
270 pub fn get_explainer_config(&self) -> &::std::option::Option<crate::types::ExplainerConfig> {
271 self.inner.get_explainer_config()
272 }
273 ///
274 /// Appends an item to `ShadowProductionVariants`.
275 ///
276 /// To override the contents of this collection use [`set_shadow_production_variants`](Self::set_shadow_production_variants).
277 ///
278 /// <p>An array of <code>ProductionVariant</code> objects, one for each model that you want to host at this endpoint in shadow mode with production traffic replicated from the model specified on <code>ProductionVariants</code>. If you use this field, you can only specify one variant for <code>ProductionVariants</code> and one variant for <code>ShadowProductionVariants</code>.</p>
279 pub fn shadow_production_variants(mut self, input: crate::types::ProductionVariant) -> Self {
280 self.inner = self.inner.shadow_production_variants(input);
281 self
282 }
283 /// <p>An array of <code>ProductionVariant</code> objects, one for each model that you want to host at this endpoint in shadow mode with production traffic replicated from the model specified on <code>ProductionVariants</code>. If you use this field, you can only specify one variant for <code>ProductionVariants</code> and one variant for <code>ShadowProductionVariants</code>.</p>
284 pub fn set_shadow_production_variants(mut self, input: ::std::option::Option<::std::vec::Vec<crate::types::ProductionVariant>>) -> Self {
285 self.inner = self.inner.set_shadow_production_variants(input);
286 self
287 }
288 /// <p>An array of <code>ProductionVariant</code> objects, one for each model that you want to host at this endpoint in shadow mode with production traffic replicated from the model specified on <code>ProductionVariants</code>. If you use this field, you can only specify one variant for <code>ProductionVariants</code> and one variant for <code>ShadowProductionVariants</code>.</p>
289 pub fn get_shadow_production_variants(&self) -> &::std::option::Option<::std::vec::Vec<crate::types::ProductionVariant>> {
290 self.inner.get_shadow_production_variants()
291 }
292 /// <p>The Amazon Resource Name (ARN) of an IAM role that Amazon SageMaker AI can assume to perform actions on your behalf. For more information, see <a href="https://docs.aws.amazon.com/sagemaker/latest/dg/sagemaker-roles.html">SageMaker AI Roles</a>.</p><note>
293 /// <p>To be able to pass this role to Amazon SageMaker AI, the caller of this action must have the <code>iam:PassRole</code> permission.</p>
294 /// </note>
295 pub fn execution_role_arn(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
296 self.inner = self.inner.execution_role_arn(input.into());
297 self
298 }
299 /// <p>The Amazon Resource Name (ARN) of an IAM role that Amazon SageMaker AI can assume to perform actions on your behalf. For more information, see <a href="https://docs.aws.amazon.com/sagemaker/latest/dg/sagemaker-roles.html">SageMaker AI Roles</a>.</p><note>
300 /// <p>To be able to pass this role to Amazon SageMaker AI, the caller of this action must have the <code>iam:PassRole</code> permission.</p>
301 /// </note>
302 pub fn set_execution_role_arn(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
303 self.inner = self.inner.set_execution_role_arn(input);
304 self
305 }
306 /// <p>The Amazon Resource Name (ARN) of an IAM role that Amazon SageMaker AI can assume to perform actions on your behalf. For more information, see <a href="https://docs.aws.amazon.com/sagemaker/latest/dg/sagemaker-roles.html">SageMaker AI Roles</a>.</p><note>
307 /// <p>To be able to pass this role to Amazon SageMaker AI, the caller of this action must have the <code>iam:PassRole</code> permission.</p>
308 /// </note>
309 pub fn get_execution_role_arn(&self) -> &::std::option::Option<::std::string::String> {
310 self.inner.get_execution_role_arn()
311 }
312 /// <p>Specifies an Amazon Virtual Private Cloud (VPC) that your SageMaker jobs, hosted models, and compute resources have access to. You can control access to and from your resources by configuring a VPC. For more information, see <a href="https://docs.aws.amazon.com/sagemaker/latest/dg/infrastructure-give-access.html">Give SageMaker Access to Resources in your Amazon VPC</a>.</p>
313 pub fn vpc_config(mut self, input: crate::types::VpcConfig) -> Self {
314 self.inner = self.inner.vpc_config(input);
315 self
316 }
317 /// <p>Specifies an Amazon Virtual Private Cloud (VPC) that your SageMaker jobs, hosted models, and compute resources have access to. You can control access to and from your resources by configuring a VPC. For more information, see <a href="https://docs.aws.amazon.com/sagemaker/latest/dg/infrastructure-give-access.html">Give SageMaker Access to Resources in your Amazon VPC</a>.</p>
318 pub fn set_vpc_config(mut self, input: ::std::option::Option<crate::types::VpcConfig>) -> Self {
319 self.inner = self.inner.set_vpc_config(input);
320 self
321 }
322 /// <p>Specifies an Amazon Virtual Private Cloud (VPC) that your SageMaker jobs, hosted models, and compute resources have access to. You can control access to and from your resources by configuring a VPC. For more information, see <a href="https://docs.aws.amazon.com/sagemaker/latest/dg/infrastructure-give-access.html">Give SageMaker Access to Resources in your Amazon VPC</a>.</p>
323 pub fn get_vpc_config(&self) -> &::std::option::Option<crate::types::VpcConfig> {
324 self.inner.get_vpc_config()
325 }
326 /// <p>Sets whether all model containers deployed to the endpoint are isolated. If they are, no inbound or outbound network calls can be made to or from the model containers.</p>
327 pub fn enable_network_isolation(mut self, input: bool) -> Self {
328 self.inner = self.inner.enable_network_isolation(input);
329 self
330 }
331 /// <p>Sets whether all model containers deployed to the endpoint are isolated. If they are, no inbound or outbound network calls can be made to or from the model containers.</p>
332 pub fn set_enable_network_isolation(mut self, input: ::std::option::Option<bool>) -> Self {
333 self.inner = self.inner.set_enable_network_isolation(input);
334 self
335 }
336 /// <p>Sets whether all model containers deployed to the endpoint are isolated. If they are, no inbound or outbound network calls can be made to or from the model containers.</p>
337 pub fn get_enable_network_isolation(&self) -> &::std::option::Option<bool> {
338 self.inner.get_enable_network_isolation()
339 }
340}