227 227 |
|
228 228 | impl ::aws_smithy_runtime_api::client::interceptors::Intercept for UpdateFunctionCodeEndpointParamsInterceptor {
|
229 229 | fn name(&self) -> &'static str {
|
230 230 | "UpdateFunctionCodeEndpointParamsInterceptor"
|
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
|
244 244 | .input()
|
245 245 | .downcast_ref::<UpdateFunctionCodeInput>()
|
246 246 | .ok_or("failed to downcast to UpdateFunctionCodeInput")?;
|
247 247 |
|
248 248 | let params = crate::config::endpoint::Params::builder()
|
249 249 | .set_region(cfg.load::<::aws_types::region::Region>().map(|r| r.as_ref().to_owned()))
|
250 250 | .set_use_dual_stack(cfg.load::<::aws_types::endpoint_config::UseDualStack>().map(|ty| ty.0))
|
251 251 | .set_use_fips(cfg.load::<::aws_types::endpoint_config::UseFips>().map(|ty| ty.0))
|
252 252 | .set_endpoint(cfg.load::<::aws_types::endpoint_config::EndpointUrl>().map(|ty| ty.0.clone()))
|
253 253 | .build()
|
254 254 | .map_err(|err| {
|
255 255 | ::aws_smithy_runtime_api::client::interceptors::error::ContextAttachedError::new("endpoint params could not be built", err)
|
256 256 | })?;
|
257 + |
|
257 258 | cfg.interceptor_state()
|
258 259 | .store_put(::aws_smithy_runtime_api::client::endpoint::EndpointResolverParams::new(params));
|
260 + |
|
259 261 | ::std::result::Result::Ok(())
|
260 262 | }
|
261 263 | }
|
262 264 |
|
263 265 | // The get_* functions below are generated from JMESPath expressions in the
|
264 266 | // operationContextParams trait. They target the operation's input shape.
|
265 267 |
|
266 268 | /// Error type for the `UpdateFunctionCodeError` operation.
|
267 269 | #[non_exhaustive]
|
268 270 | #[derive(::std::fmt::Debug)]
|
269 271 | pub enum UpdateFunctionCodeError {
|
270 272 | /// <p>The specified code signing configuration does not exist.</p>
|
271 273 | CodeSigningConfigNotFoundException(crate::types::error::CodeSigningConfigNotFoundException),
|
272 274 | /// <p>Your Amazon Web Services account has exceeded its maximum total code size. For more information, see <a href="https://docs.aws.amazon.com/lambda/latest/dg/gettingstarted-limits.html">Lambda quotas</a>.</p>
|
273 275 | CodeStorageExceededException(crate::types::error::CodeStorageExceededException),
|
274 276 | /// <p>The code signature failed one or more of the validation checks for signature mismatch or expiry, and the code signing policy is set to ENFORCE. Lambda blocks the deployment.</p>
|
275 277 | CodeVerificationFailedException(crate::types::error::CodeVerificationFailedException),
|
276 278 | /// <p>The code signature failed the integrity check. If the integrity check fails, then Lambda blocks deployment, even if the code signing policy is set to WARN.</p>
|
277 279 | InvalidCodeSignatureException(crate::types::error::InvalidCodeSignatureException),
|
278 280 | /// <p>One of the parameters in the request is not valid.</p>
|
279 281 | InvalidParameterValueException(crate::types::error::InvalidParameterValueException),
|
280 282 | /// <p>The RevisionId provided does not match the latest RevisionId for the Lambda function or alias. Call the <code>GetFunction</code> or the <code>GetAlias</code> API operation to retrieve the latest RevisionId for your resource.</p>
|
281 283 | PreconditionFailedException(crate::types::error::PreconditionFailedException),
|
282 284 | /// <p>The resource already exists, or another operation is in progress.</p>
|
283 285 | ResourceConflictException(crate::types::error::ResourceConflictException),
|
284 286 | /// <p>The resource specified in the request does not exist.</p>
|
285 287 | ResourceNotFoundException(crate::types::error::ResourceNotFoundException),
|
286 288 | /// <p>The Lambda service encountered an internal error.</p>
|
287 289 | ServiceException(crate::types::error::ServiceException),
|
288 290 | /// <p>The request throughput limit was exceeded. For more information, see <a href="https://docs.aws.amazon.com/lambda/latest/dg/gettingstarted-limits.html#api-requests">Lambda quotas</a>.</p>
|