/* * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * * Licensed under the Apache License, Version 2.0 (the "License"). * You may not use this file except in compliance with the License. * A copy of the License is located at * * http://aws.amazon.com/apache2.0 * * or in the "license" file accompanying this file. This file is distributed * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either * express or implied. See the License for the specific language governing * permissions and limitations under the License. */ /* * Do not modify this file. This file is generated from the codecatalyst-2022-09-28.normal.json service model. */ using System; using System.Collections.Generic; using System.Collections.ObjectModel; using Amazon.Runtime; namespace Amazon.CodeCatalyst { /// /// Configuration for accessing Amazon CodeCatalyst service /// public static class AmazonCodeCatalystDefaultConfiguration { /// /// Collection of all s supported by /// CodeCatalyst /// public static ReadOnlyCollection GetAllConfigurations() { return new ReadOnlyCollection(new List { Standard, InRegion, CrossRegion, Mobile, Auto, Legacy }); } /// ///

The STANDARD mode provides the latest recommended default values that should be safe to run in most scenarios

Note that the default values vended from this mode might change as best practices may evolve. As a result, it is encouraged to perform tests when upgrading the SDK

///
public static IDefaultConfiguration Standard {get;} = new DefaultConfiguration { Name = DefaultConfigurationMode.Standard, RetryMode = RequestRetryMode.Standard, StsRegionalEndpoints = StsRegionalEndpointsValue.Regional, S3UsEast1RegionalEndpoint = S3UsEast1RegionalEndpointValue.Regional, // 0:00:03.1 ConnectTimeout = TimeSpan.FromMilliseconds(3100L), // 0:00:03.1 TlsNegotiationTimeout = TimeSpan.FromMilliseconds(3100L), TimeToFirstByteTimeout = null, HttpRequestTimeout = null }; /// ///

The IN_REGION mode builds on the standard mode and includes optimization tailored for applications which call AWS services from within the same AWS region

Note that the default values vended from this mode might change as best practices may evolve. As a result, it is encouraged to perform tests when upgrading the SDK

///
public static IDefaultConfiguration InRegion {get;} = new DefaultConfiguration { Name = DefaultConfigurationMode.InRegion, RetryMode = RequestRetryMode.Standard, StsRegionalEndpoints = StsRegionalEndpointsValue.Regional, S3UsEast1RegionalEndpoint = S3UsEast1RegionalEndpointValue.Regional, // 0:00:01.1 ConnectTimeout = TimeSpan.FromMilliseconds(1100L), // 0:00:01.1 TlsNegotiationTimeout = TimeSpan.FromMilliseconds(1100L), TimeToFirstByteTimeout = null, HttpRequestTimeout = null }; /// ///

The CROSS_REGION mode builds on the standard mode and includes optimization tailored for applications which call AWS services in a different region

Note that the default values vended from this mode might change as best practices may evolve. As a result, it is encouraged to perform tests when upgrading the SDK

///
public static IDefaultConfiguration CrossRegion {get;} = new DefaultConfiguration { Name = DefaultConfigurationMode.CrossRegion, RetryMode = RequestRetryMode.Standard, StsRegionalEndpoints = StsRegionalEndpointsValue.Regional, S3UsEast1RegionalEndpoint = S3UsEast1RegionalEndpointValue.Regional, // 0:00:03.1 ConnectTimeout = TimeSpan.FromMilliseconds(3100L), // 0:00:03.1 TlsNegotiationTimeout = TimeSpan.FromMilliseconds(3100L), TimeToFirstByteTimeout = null, HttpRequestTimeout = null }; /// ///

The MOBILE mode builds on the standard mode and includes optimization tailored for mobile applications

Note that the default values vended from this mode might change as best practices may evolve. As a result, it is encouraged to perform tests when upgrading the SDK

///
public static IDefaultConfiguration Mobile {get;} = new DefaultConfiguration { Name = DefaultConfigurationMode.Mobile, RetryMode = RequestRetryMode.Standard, StsRegionalEndpoints = StsRegionalEndpointsValue.Regional, S3UsEast1RegionalEndpoint = S3UsEast1RegionalEndpointValue.Regional, // 0:00:30 ConnectTimeout = TimeSpan.FromMilliseconds(30000L), // 0:00:30 TlsNegotiationTimeout = TimeSpan.FromMilliseconds(30000L), TimeToFirstByteTimeout = null, HttpRequestTimeout = null }; /// ///

The AUTO mode is an experimental mode that builds on the standard mode. The SDK will attempt to discover the execution environment to determine the appropriate settings automatically.

Note that the auto detection is heuristics-based and does not guarantee 100% accuracy. STANDARD mode will be used if the execution environment cannot be determined. The auto detection might query EC2 Instance Metadata service, which might introduce latency. Therefore we recommend choosing an explicit defaults_mode instead if startup latency is critical to your application

///
public static IDefaultConfiguration Auto {get;} = new DefaultConfiguration { Name = DefaultConfigurationMode.Auto, RetryMode = RequestRetryMode.Standard, StsRegionalEndpoints = StsRegionalEndpointsValue.Regional, S3UsEast1RegionalEndpoint = S3UsEast1RegionalEndpointValue.Regional, // 0:00:01.1 ConnectTimeout = TimeSpan.FromMilliseconds(1100L), // 0:00:01.1 TlsNegotiationTimeout = TimeSpan.FromMilliseconds(1100L), TimeToFirstByteTimeout = null, HttpRequestTimeout = null }; /// ///

The LEGACY mode provides default settings that vary per SDK and were used prior to establishment of defaults_mode

///
public static IDefaultConfiguration Legacy {get;} = new DefaultConfiguration { Name = DefaultConfigurationMode.Legacy, RetryMode = RequestRetryMode.Legacy, StsRegionalEndpoints = StsRegionalEndpointsValue.Legacy, S3UsEast1RegionalEndpoint = S3UsEast1RegionalEndpointValue.Legacy, ConnectTimeout = null, TlsNegotiationTimeout = null, TimeToFirstByteTimeout = null, HttpRequestTimeout = null }; } }