221 221 |
|
222 222 | impl ::aws_smithy_runtime_api::client::interceptors::Intercept for UpdateServicePrimaryTaskSetEndpointParamsInterceptor {
|
223 223 | fn name(&self) -> &'static str {
|
224 224 | "UpdateServicePrimaryTaskSetEndpointParamsInterceptor"
|
225 225 | }
|
226 226 |
|
227 227 | fn read_before_execution(
|
228 228 | &self,
|
229 229 | context: &::aws_smithy_runtime_api::client::interceptors::context::BeforeSerializationInterceptorContextRef<
|
230 230 | '_,
|
231 231 | ::aws_smithy_runtime_api::client::interceptors::context::Input,
|
232 232 | ::aws_smithy_runtime_api::client::interceptors::context::Output,
|
233 233 | ::aws_smithy_runtime_api::client::interceptors::context::Error,
|
234 234 | >,
|
235 235 | cfg: &mut ::aws_smithy_types::config_bag::ConfigBag,
|
236 236 | ) -> ::std::result::Result<(), ::aws_smithy_runtime_api::box_error::BoxError> {
|
237 237 | let _input = context
|
238 238 | .input()
|
239 239 | .downcast_ref::<UpdateServicePrimaryTaskSetInput>()
|
240 240 | .ok_or("failed to downcast to UpdateServicePrimaryTaskSetInput")?;
|
241 241 |
|
242 242 | let params = crate::config::endpoint::Params::builder()
|
243 243 | .set_region(cfg.load::<::aws_types::region::Region>().map(|r| r.as_ref().to_owned()))
|
244 244 | .set_use_dual_stack(cfg.load::<::aws_types::endpoint_config::UseDualStack>().map(|ty| ty.0))
|
245 245 | .set_use_fips(cfg.load::<::aws_types::endpoint_config::UseFips>().map(|ty| ty.0))
|
246 246 | .set_endpoint(cfg.load::<::aws_types::endpoint_config::EndpointUrl>().map(|ty| ty.0.clone()))
|
247 247 | .build()
|
248 248 | .map_err(|err| {
|
249 249 | ::aws_smithy_runtime_api::client::interceptors::error::ContextAttachedError::new("endpoint params could not be built", err)
|
250 250 | })?;
|
251 + |
|
251 252 | cfg.interceptor_state()
|
252 253 | .store_put(::aws_smithy_runtime_api::client::endpoint::EndpointResolverParams::new(params));
|
254 + |
|
253 255 | ::std::result::Result::Ok(())
|
254 256 | }
|
255 257 | }
|
256 258 |
|
257 259 | // The get_* functions below are generated from JMESPath expressions in the
|
258 260 | // operationContextParams trait. They target the operation's input shape.
|
259 261 |
|
260 262 | /// Error type for the `UpdateServicePrimaryTaskSetError` operation.
|
261 263 | #[non_exhaustive]
|
262 264 | #[derive(::std::fmt::Debug)]
|
263 265 | pub enum UpdateServicePrimaryTaskSetError {
|
264 266 | /// <p>You don't have authorization to perform the requested action.</p>
|
265 267 | AccessDeniedException(crate::types::error::AccessDeniedException),
|
266 268 | /// <p>These errors are usually caused by a client action. This client action might be using an action or resource on behalf of a user that doesn't have permissions to use the action or resource. Or, it might be specifying an identifier that isn't valid.</p>
|
267 269 | ClientException(crate::types::error::ClientException),
|
268 270 | /// <p>The specified cluster wasn't found. You can view your available clusters with <code>ListClusters</code>. Amazon ECS clusters are Region specific.</p>
|
269 271 | ClusterNotFoundException(crate::types::error::ClusterNotFoundException),
|
270 272 | /// <p>The specified parameter isn't valid. Review the available parameters for the API request.</p>
|
271 273 | InvalidParameterException(crate::types::error::InvalidParameterException),
|
272 274 | /// <p>These errors are usually caused by a server issue.</p>
|
273 275 | ServerException(crate::types::error::ServerException),
|
274 276 | /// <p>The specified service isn't active. You can't update a service that's inactive. If you have previously deleted a service, you can re-create it with <code>CreateService</code>.</p>
|
275 277 | ServiceNotActiveException(crate::types::error::ServiceNotActiveException),
|
276 278 | /// <p>The specified service wasn't found. You can view your available services with <code>ListServices</code>. Amazon ECS services are cluster specific and Region specific.</p>
|
277 279 | ServiceNotFoundException(crate::types::error::ServiceNotFoundException),
|
278 280 | /// <p>The specified task set wasn't found. You can view your available task sets with <code>DescribeTaskSets</code>. Task sets are specific to each cluster, service and Region.</p>
|
279 281 | TaskSetNotFoundException(crate::types::error::TaskSetNotFoundException),
|
280 282 | /// <p>The specified task isn't supported in this Region.</p>
|
281 283 | UnsupportedFeatureException(crate::types::error::UnsupportedFeatureException),
|
282 284 | /// An unexpected error occurred (e.g., invalid JSON returned by the service or an unknown error code).
|