224 224 | }
|
225 225 | #[derive(Debug)]
|
226 226 | struct InvokeEndpointParamsInterceptor;
|
227 227 |
|
228 228 | impl ::aws_smithy_runtime_api::client::interceptors::Intercept for InvokeEndpointParamsInterceptor {
|
229 229 | fn name(&self) -> &'static str {
|
230 230 | "InvokeEndpointParamsInterceptor"
|
231 231 | }
|
232 232 |
|
233 233 | fn read_before_execution(
|
234 234 | &self,
|
235 235 | context: &::aws_smithy_runtime_api::client::interceptors::context::BeforeSerializationInterceptorContextRef<
|
236 236 | '_,
|
237 237 | ::aws_smithy_runtime_api::client::interceptors::context::Input,
|
238 238 | ::aws_smithy_runtime_api::client::interceptors::context::Output,
|
239 239 | ::aws_smithy_runtime_api::client::interceptors::context::Error,
|
240 240 | >,
|
241 241 | cfg: &mut ::aws_smithy_types::config_bag::ConfigBag,
|
242 242 | ) -> ::std::result::Result<(), ::aws_smithy_runtime_api::box_error::BoxError> {
|
243 243 | let _input = context.input().downcast_ref::<InvokeInput>().ok_or("failed to downcast to InvokeInput")?;
|
244 244 |
|
245 245 | let params = crate::config::endpoint::Params::builder()
|
246 246 | .set_region(cfg.load::<::aws_types::region::Region>().map(|r| r.as_ref().to_owned()))
|
247 247 | .set_use_dual_stack(cfg.load::<::aws_types::endpoint_config::UseDualStack>().map(|ty| ty.0))
|
248 248 | .set_use_fips(cfg.load::<::aws_types::endpoint_config::UseFips>().map(|ty| ty.0))
|
249 249 | .set_endpoint(cfg.load::<::aws_types::endpoint_config::EndpointUrl>().map(|ty| ty.0.clone()))
|
250 250 | .build()
|
251 251 | .map_err(|err| {
|
252 252 | ::aws_smithy_runtime_api::client::interceptors::error::ContextAttachedError::new("endpoint params could not be built", err)
|
253 253 | })?;
|
254 + |
|
254 255 | cfg.interceptor_state()
|
255 256 | .store_put(::aws_smithy_runtime_api::client::endpoint::EndpointResolverParams::new(params));
|
257 + |
|
256 258 | ::std::result::Result::Ok(())
|
257 259 | }
|
258 260 | }
|
259 261 |
|
260 262 | // The get_* functions below are generated from JMESPath expressions in the
|
261 263 | // operationContextParams trait. They target the operation's input shape.
|
262 264 |
|
263 265 | /// Error type for the `InvokeError` operation.
|
264 266 | #[non_exhaustive]
|
265 267 | #[derive(::std::fmt::Debug)]
|
266 268 | pub enum InvokeError {
|
267 269 | /// <p>Need additional permissions to configure VPC settings.</p>
|
268 270 | Ec2AccessDeniedException(crate::types::error::Ec2AccessDeniedException),
|
269 271 | /// <p>Amazon EC2 throttled Lambda during Lambda function initialization using the execution role provided for the function.</p>
|
270 272 | Ec2ThrottledException(crate::types::error::Ec2ThrottledException),
|
271 273 | /// <p>Lambda received an unexpected Amazon EC2 client exception while setting up for the Lambda function.</p>
|
272 274 | Ec2UnexpectedException(crate::types::error::Ec2UnexpectedException),
|
273 275 | /// <p>An error occurred when reading from or writing to a connected file system.</p>
|
274 276 | EfsioException(crate::types::error::EfsioException),
|
275 277 | /// <p>The Lambda function couldn't make a network connection to the configured file system.</p>
|
276 278 | EfsMountConnectivityException(crate::types::error::EfsMountConnectivityException),
|
277 279 | /// <p>The Lambda function couldn't mount the configured file system due to a permission or configuration issue.</p>
|
278 280 | EfsMountFailureException(crate::types::error::EfsMountFailureException),
|
279 281 | /// <p>The Lambda function made a network connection to the configured file system, but the mount operation timed out.</p>
|
280 282 | EfsMountTimeoutException(crate::types::error::EfsMountTimeoutException),
|
281 283 | /// <p>Lambda couldn't create an elastic network interface in the VPC, specified as part of Lambda function configuration, because the limit for network interfaces has been reached. For more information, see <a href="https://docs.aws.amazon.com/lambda/latest/dg/gettingstarted-limits.html">Lambda quotas</a>.</p>
|
282 284 | EniLimitReachedException(crate::types::error::EniLimitReachedException),
|
283 285 | /// <p>One of the parameters in the request is not valid.</p>
|
284 286 | InvalidParameterValueException(crate::types::error::InvalidParameterValueException),
|
285 287 | /// <p>The request body could not be parsed as JSON.</p>
|