Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(clients): allow client creation without configuration #5060

Merged
merged 2 commits into from
Aug 8, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
5 changes: 3 additions & 2 deletions clients/client-accessanalyzer/src/AccessAnalyzerClient.ts
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ import {
} from "@smithy/smithy-client";
import {
BodyLengthCalculator as __BodyLengthCalculator,
CheckOptionalClientConfig as __CheckOptionalClientConfig,
Checksum as __Checksum,
ChecksumConstructor as __ChecksumConstructor,
Decoder as __Decoder,
Expand Down Expand Up @@ -362,8 +363,8 @@ export class AccessAnalyzerClient extends __Client<
*/
readonly config: AccessAnalyzerClientResolvedConfig;

constructor(configuration: AccessAnalyzerClientConfig) {
const _config_0 = __getRuntimeConfig(configuration);
constructor(...[configuration]: __CheckOptionalClientConfig<AccessAnalyzerClientConfig>) {
const _config_0 = __getRuntimeConfig(configuration || {});
const _config_1 = resolveClientEndpointParameters(_config_0);
const _config_2 = resolveRegionConfig(_config_1);
const _config_3 = resolveEndpointConfig(_config_2);
Expand Down
5 changes: 3 additions & 2 deletions clients/client-account/src/AccountClient.ts
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ import {
} from "@smithy/smithy-client";
import {
BodyLengthCalculator as __BodyLengthCalculator,
CheckOptionalClientConfig as __CheckOptionalClientConfig,
Checksum as __Checksum,
ChecksumConstructor as __ChecksumConstructor,
Decoder as __Decoder,
Expand Down Expand Up @@ -288,8 +289,8 @@ export class AccountClient extends __Client<
*/
readonly config: AccountClientResolvedConfig;

constructor(configuration: AccountClientConfig) {
const _config_0 = __getRuntimeConfig(configuration);
constructor(...[configuration]: __CheckOptionalClientConfig<AccountClientConfig>) {
const _config_0 = __getRuntimeConfig(configuration || {});
const _config_1 = resolveClientEndpointParameters(_config_0);
const _config_2 = resolveRegionConfig(_config_1);
const _config_3 = resolveEndpointConfig(_config_2);
Expand Down
5 changes: 3 additions & 2 deletions clients/client-acm-pca/src/ACMPCAClient.ts
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ import {
} from "@smithy/smithy-client";
import {
BodyLengthCalculator as __BodyLengthCalculator,
CheckOptionalClientConfig as __CheckOptionalClientConfig,
Checksum as __Checksum,
ChecksumConstructor as __ChecksumConstructor,
Decoder as __Decoder,
Expand Down Expand Up @@ -369,8 +370,8 @@ export class ACMPCAClient extends __Client<
*/
readonly config: ACMPCAClientResolvedConfig;

constructor(configuration: ACMPCAClientConfig) {
const _config_0 = __getRuntimeConfig(configuration);
constructor(...[configuration]: __CheckOptionalClientConfig<ACMPCAClientConfig>) {
const _config_0 = __getRuntimeConfig(configuration || {});
const _config_1 = resolveClientEndpointParameters(_config_0);
const _config_2 = resolveRegionConfig(_config_1);
const _config_3 = resolveEndpointConfig(_config_2);
Expand Down
5 changes: 3 additions & 2 deletions clients/client-acm/src/ACMClient.ts
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ import {
} from "@smithy/smithy-client";
import {
BodyLengthCalculator as __BodyLengthCalculator,
CheckOptionalClientConfig as __CheckOptionalClientConfig,
Checksum as __Checksum,
ChecksumConstructor as __ChecksumConstructor,
Decoder as __Decoder,
Expand Down Expand Up @@ -317,8 +318,8 @@ export class ACMClient extends __Client<
*/
readonly config: ACMClientResolvedConfig;

constructor(configuration: ACMClientConfig) {
const _config_0 = __getRuntimeConfig(configuration);
constructor(...[configuration]: __CheckOptionalClientConfig<ACMClientConfig>) {
const _config_0 = __getRuntimeConfig(configuration || {});
const _config_1 = resolveClientEndpointParameters(_config_0);
const _config_2 = resolveRegionConfig(_config_1);
const _config_3 = resolveEndpointConfig(_config_2);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ import {
} from "@smithy/smithy-client";
import {
BodyLengthCalculator as __BodyLengthCalculator,
CheckOptionalClientConfig as __CheckOptionalClientConfig,
Checksum as __Checksum,
ChecksumConstructor as __ChecksumConstructor,
Decoder as __Decoder,
Expand Down Expand Up @@ -644,8 +645,8 @@ export class AlexaForBusinessClient extends __Client<
*/
readonly config: AlexaForBusinessClientResolvedConfig;

constructor(configuration: AlexaForBusinessClientConfig) {
const _config_0 = __getRuntimeConfig(configuration);
constructor(...[configuration]: __CheckOptionalClientConfig<AlexaForBusinessClientConfig>) {
const _config_0 = __getRuntimeConfig(configuration || {});
const _config_1 = resolveClientEndpointParameters(_config_0);
const _config_2 = resolveRegionConfig(_config_1);
const _config_3 = resolveEndpointConfig(_config_2);
Expand Down
5 changes: 3 additions & 2 deletions clients/client-amp/src/AmpClient.ts
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ import {
} from "@smithy/smithy-client";
import {
BodyLengthCalculator as __BodyLengthCalculator,
CheckOptionalClientConfig as __CheckOptionalClientConfig,
Checksum as __Checksum,
ChecksumConstructor as __ChecksumConstructor,
Decoder as __Decoder,
Expand Down Expand Up @@ -354,8 +355,8 @@ export class AmpClient extends __Client<
*/
readonly config: AmpClientResolvedConfig;

constructor(configuration: AmpClientConfig) {
const _config_0 = __getRuntimeConfig(configuration);
constructor(...[configuration]: __CheckOptionalClientConfig<AmpClientConfig>) {
const _config_0 = __getRuntimeConfig(configuration || {});
const _config_1 = resolveClientEndpointParameters(_config_0);
const _config_2 = resolveRegionConfig(_config_1);
const _config_3 = resolveEndpointConfig(_config_2);
Expand Down
5 changes: 3 additions & 2 deletions clients/client-amplify/src/AmplifyClient.ts
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ import {
} from "@smithy/smithy-client";
import {
BodyLengthCalculator as __BodyLengthCalculator,
CheckOptionalClientConfig as __CheckOptionalClientConfig,
Checksum as __Checksum,
ChecksumConstructor as __ChecksumConstructor,
Decoder as __Decoder,
Expand Down Expand Up @@ -392,8 +393,8 @@ export class AmplifyClient extends __Client<
*/
readonly config: AmplifyClientResolvedConfig;

constructor(configuration: AmplifyClientConfig) {
const _config_0 = __getRuntimeConfig(configuration);
constructor(...[configuration]: __CheckOptionalClientConfig<AmplifyClientConfig>) {
const _config_0 = __getRuntimeConfig(configuration || {});
const _config_1 = resolveClientEndpointParameters(_config_0);
const _config_2 = resolveRegionConfig(_config_1);
const _config_3 = resolveEndpointConfig(_config_2);
Expand Down
5 changes: 3 additions & 2 deletions clients/client-amplifybackend/src/AmplifyBackendClient.ts
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ import {
} from "@smithy/smithy-client";
import {
BodyLengthCalculator as __BodyLengthCalculator,
CheckOptionalClientConfig as __CheckOptionalClientConfig,
Checksum as __Checksum,
ChecksumConstructor as __ChecksumConstructor,
Decoder as __Decoder,
Expand Down Expand Up @@ -366,8 +367,8 @@ export class AmplifyBackendClient extends __Client<
*/
readonly config: AmplifyBackendClientResolvedConfig;

constructor(configuration: AmplifyBackendClientConfig) {
const _config_0 = __getRuntimeConfig(configuration);
constructor(...[configuration]: __CheckOptionalClientConfig<AmplifyBackendClientConfig>) {
const _config_0 = __getRuntimeConfig(configuration || {});
const _config_1 = resolveClientEndpointParameters(_config_0);
const _config_2 = resolveRegionConfig(_config_1);
const _config_3 = resolveEndpointConfig(_config_2);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ import {
} from "@smithy/smithy-client";
import {
BodyLengthCalculator as __BodyLengthCalculator,
CheckOptionalClientConfig as __CheckOptionalClientConfig,
Checksum as __Checksum,
ChecksumConstructor as __ChecksumConstructor,
Decoder as __Decoder,
Expand Down Expand Up @@ -332,8 +333,8 @@ export class AmplifyUIBuilderClient extends __Client<
*/
readonly config: AmplifyUIBuilderClientResolvedConfig;

constructor(configuration: AmplifyUIBuilderClientConfig) {
const _config_0 = __getRuntimeConfig(configuration);
constructor(...[configuration]: __CheckOptionalClientConfig<AmplifyUIBuilderClientConfig>) {
const _config_0 = __getRuntimeConfig(configuration || {});
const _config_1 = resolveClientEndpointParameters(_config_0);
const _config_2 = resolveRegionConfig(_config_1);
const _config_3 = resolveEndpointConfig(_config_2);
Expand Down
5 changes: 3 additions & 2 deletions clients/client-api-gateway/src/APIGatewayClient.ts
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@ import {
} from "@smithy/smithy-client";
import {
BodyLengthCalculator as __BodyLengthCalculator,
CheckOptionalClientConfig as __CheckOptionalClientConfig,
Checksum as __Checksum,
ChecksumConstructor as __ChecksumConstructor,
Decoder as __Decoder,
Expand Down Expand Up @@ -716,8 +717,8 @@ export class APIGatewayClient extends __Client<
*/
readonly config: APIGatewayClientResolvedConfig;

constructor(configuration: APIGatewayClientConfig) {
const _config_0 = __getRuntimeConfig(configuration);
constructor(...[configuration]: __CheckOptionalClientConfig<APIGatewayClientConfig>) {
const _config_0 = __getRuntimeConfig(configuration || {});
const _config_1 = resolveClientEndpointParameters(_config_0);
const _config_2 = resolveRegionConfig(_config_1);
const _config_3 = resolveEndpointConfig(_config_2);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ import {
} from "@smithy/smithy-client";
import {
BodyLengthCalculator as __BodyLengthCalculator,
CheckOptionalClientConfig as __CheckOptionalClientConfig,
Checksum as __Checksum,
ChecksumConstructor as __ChecksumConstructor,
Decoder as __Decoder,
Expand Down Expand Up @@ -252,8 +253,8 @@ export class ApiGatewayManagementApiClient extends __Client<
*/
readonly config: ApiGatewayManagementApiClientResolvedConfig;

constructor(configuration: ApiGatewayManagementApiClientConfig) {
const _config_0 = __getRuntimeConfig(configuration);
constructor(...[configuration]: __CheckOptionalClientConfig<ApiGatewayManagementApiClientConfig>) {
const _config_0 = __getRuntimeConfig(configuration || {});
const _config_1 = resolveClientEndpointParameters(_config_0);
const _config_2 = resolveRegionConfig(_config_1);
const _config_3 = resolveEndpointConfig(_config_2);
Expand Down
5 changes: 3 additions & 2 deletions clients/client-apigatewayv2/src/ApiGatewayV2Client.ts
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ import {
} from "@smithy/smithy-client";
import {
BodyLengthCalculator as __BodyLengthCalculator,
CheckOptionalClientConfig as __CheckOptionalClientConfig,
Checksum as __Checksum,
ChecksumConstructor as __ChecksumConstructor,
Decoder as __Decoder,
Expand Down Expand Up @@ -501,8 +502,8 @@ export class ApiGatewayV2Client extends __Client<
*/
readonly config: ApiGatewayV2ClientResolvedConfig;

constructor(configuration: ApiGatewayV2ClientConfig) {
const _config_0 = __getRuntimeConfig(configuration);
constructor(...[configuration]: __CheckOptionalClientConfig<ApiGatewayV2ClientConfig>) {
const _config_0 = __getRuntimeConfig(configuration || {});
const _config_1 = resolveClientEndpointParameters(_config_0);
const _config_2 = resolveRegionConfig(_config_1);
const _config_3 = resolveEndpointConfig(_config_2);
Expand Down
5 changes: 3 additions & 2 deletions clients/client-app-mesh/src/AppMeshClient.ts
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ import {
} from "@smithy/smithy-client";
import {
BodyLengthCalculator as __BodyLengthCalculator,
CheckOptionalClientConfig as __CheckOptionalClientConfig,
Checksum as __Checksum,
ChecksumConstructor as __ChecksumConstructor,
Decoder as __Decoder,
Expand Down Expand Up @@ -425,8 +426,8 @@ export class AppMeshClient extends __Client<
*/
readonly config: AppMeshClientResolvedConfig;

constructor(configuration: AppMeshClientConfig) {
const _config_0 = __getRuntimeConfig(configuration);
constructor(...[configuration]: __CheckOptionalClientConfig<AppMeshClientConfig>) {
const _config_0 = __getRuntimeConfig(configuration || {});
const _config_1 = resolveClientEndpointParameters(_config_0);
const _config_2 = resolveRegionConfig(_config_1);
const _config_3 = resolveEndpointConfig(_config_2);
Expand Down
5 changes: 3 additions & 2 deletions clients/client-appconfig/src/AppConfigClient.ts
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ import {
} from "@smithy/smithy-client";
import {
BodyLengthCalculator as __BodyLengthCalculator,
CheckOptionalClientConfig as __CheckOptionalClientConfig,
Checksum as __Checksum,
ChecksumConstructor as __ChecksumConstructor,
Decoder as __Decoder,
Expand Down Expand Up @@ -483,8 +484,8 @@ export class AppConfigClient extends __Client<
*/
readonly config: AppConfigClientResolvedConfig;

constructor(configuration: AppConfigClientConfig) {
const _config_0 = __getRuntimeConfig(configuration);
constructor(...[configuration]: __CheckOptionalClientConfig<AppConfigClientConfig>) {
const _config_0 = __getRuntimeConfig(configuration || {});
const _config_1 = resolveClientEndpointParameters(_config_0);
const _config_2 = resolveRegionConfig(_config_1);
const _config_3 = resolveEndpointConfig(_config_2);
Expand Down
5 changes: 3 additions & 2 deletions clients/client-appconfigdata/src/AppConfigDataClient.ts
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ import {
} from "@smithy/smithy-client";
import {
BodyLengthCalculator as __BodyLengthCalculator,
CheckOptionalClientConfig as __CheckOptionalClientConfig,
Checksum as __Checksum,
ChecksumConstructor as __ChecksumConstructor,
Decoder as __Decoder,
Expand Down Expand Up @@ -312,8 +313,8 @@ export class AppConfigDataClient extends __Client<
*/
readonly config: AppConfigDataClientResolvedConfig;

constructor(configuration: AppConfigDataClientConfig) {
const _config_0 = __getRuntimeConfig(configuration);
constructor(...[configuration]: __CheckOptionalClientConfig<AppConfigDataClientConfig>) {
const _config_0 = __getRuntimeConfig(configuration || {});
const _config_1 = resolveClientEndpointParameters(_config_0);
const _config_2 = resolveRegionConfig(_config_1);
const _config_3 = resolveEndpointConfig(_config_2);
Expand Down
5 changes: 3 additions & 2 deletions clients/client-appfabric/src/AppFabricClient.ts
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ import {
} from "@smithy/smithy-client";
import {
BodyLengthCalculator as __BodyLengthCalculator,
CheckOptionalClientConfig as __CheckOptionalClientConfig,
Checksum as __Checksum,
ChecksumConstructor as __ChecksumConstructor,
Decoder as __Decoder,
Expand Down Expand Up @@ -374,8 +375,8 @@ export class AppFabricClient extends __Client<
*/
readonly config: AppFabricClientResolvedConfig;

constructor(configuration: AppFabricClientConfig) {
const _config_0 = __getRuntimeConfig(configuration);
constructor(...[configuration]: __CheckOptionalClientConfig<AppFabricClientConfig>) {
const _config_0 = __getRuntimeConfig(configuration || {});
const _config_1 = resolveClientEndpointParameters(_config_0);
const _config_2 = resolveRegionConfig(_config_1);
const _config_3 = resolveEndpointConfig(_config_2);
Expand Down
5 changes: 3 additions & 2 deletions clients/client-appflow/src/AppflowClient.ts
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ import {
} from "@smithy/smithy-client";
import {
BodyLengthCalculator as __BodyLengthCalculator,
CheckOptionalClientConfig as __CheckOptionalClientConfig,
Checksum as __Checksum,
ChecksumConstructor as __ChecksumConstructor,
Decoder as __Decoder,
Expand Down Expand Up @@ -391,8 +392,8 @@ export class AppflowClient extends __Client<
*/
readonly config: AppflowClientResolvedConfig;

constructor(configuration: AppflowClientConfig) {
const _config_0 = __getRuntimeConfig(configuration);
constructor(...[configuration]: __CheckOptionalClientConfig<AppflowClientConfig>) {
const _config_0 = __getRuntimeConfig(configuration || {});
const _config_1 = resolveClientEndpointParameters(_config_0);
const _config_2 = resolveRegionConfig(_config_1);
const _config_3 = resolveEndpointConfig(_config_2);
Expand Down
5 changes: 3 additions & 2 deletions clients/client-appintegrations/src/AppIntegrationsClient.ts
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ import {
} from "@smithy/smithy-client";
import {
BodyLengthCalculator as __BodyLengthCalculator,
CheckOptionalClientConfig as __CheckOptionalClientConfig,
Checksum as __Checksum,
ChecksumConstructor as __ChecksumConstructor,
Decoder as __Decoder,
Expand Down Expand Up @@ -333,8 +334,8 @@ export class AppIntegrationsClient extends __Client<
*/
readonly config: AppIntegrationsClientResolvedConfig;

constructor(configuration: AppIntegrationsClientConfig) {
const _config_0 = __getRuntimeConfig(configuration);
constructor(...[configuration]: __CheckOptionalClientConfig<AppIntegrationsClientConfig>) {
const _config_0 = __getRuntimeConfig(configuration || {});
const _config_1 = resolveClientEndpointParameters(_config_0);
const _config_2 = resolveRegionConfig(_config_1);
const _config_3 = resolveEndpointConfig(_config_2);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ import {
} from "@smithy/smithy-client";
import {
BodyLengthCalculator as __BodyLengthCalculator,
CheckOptionalClientConfig as __CheckOptionalClientConfig,
Checksum as __Checksum,
ChecksumConstructor as __ChecksumConstructor,
Decoder as __Decoder,
Expand Down Expand Up @@ -385,8 +386,8 @@ export class ApplicationAutoScalingClient extends __Client<
*/
readonly config: ApplicationAutoScalingClientResolvedConfig;

constructor(configuration: ApplicationAutoScalingClientConfig) {
const _config_0 = __getRuntimeConfig(configuration);
constructor(...[configuration]: __CheckOptionalClientConfig<ApplicationAutoScalingClientConfig>) {
const _config_0 = __getRuntimeConfig(configuration || {});
const _config_1 = resolveClientEndpointParameters(_config_0);
const _config_2 = resolveRegionConfig(_config_1);
const _config_3 = resolveEndpointConfig(_config_2);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ import {
} from "@smithy/smithy-client";
import {
BodyLengthCalculator as __BodyLengthCalculator,
CheckOptionalClientConfig as __CheckOptionalClientConfig,
Checksum as __Checksum,
ChecksumConstructor as __ChecksumConstructor,
Decoder as __Decoder,
Expand Down Expand Up @@ -472,8 +473,8 @@ export class ApplicationDiscoveryServiceClient extends __Client<
*/
readonly config: ApplicationDiscoveryServiceClientResolvedConfig;

constructor(configuration: ApplicationDiscoveryServiceClientConfig) {
const _config_0 = __getRuntimeConfig(configuration);
constructor(...[configuration]: __CheckOptionalClientConfig<ApplicationDiscoveryServiceClientConfig>) {
const _config_0 = __getRuntimeConfig(configuration || {});
const _config_1 = resolveClientEndpointParameters(_config_0);
const _config_2 = resolveRegionConfig(_config_1);
const _config_3 = resolveEndpointConfig(_config_2);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ import {
} from "@smithy/smithy-client";
import {
BodyLengthCalculator as __BodyLengthCalculator,
CheckOptionalClientConfig as __CheckOptionalClientConfig,
Checksum as __Checksum,
ChecksumConstructor as __ChecksumConstructor,
Decoder as __Decoder,
Expand Down Expand Up @@ -380,8 +381,8 @@ export class ApplicationInsightsClient extends __Client<
*/
readonly config: ApplicationInsightsClientResolvedConfig;

constructor(configuration: ApplicationInsightsClientConfig) {
const _config_0 = __getRuntimeConfig(configuration);
constructor(...[configuration]: __CheckOptionalClientConfig<ApplicationInsightsClientConfig>) {
const _config_0 = __getRuntimeConfig(configuration || {});
const _config_1 = resolveClientEndpointParameters(_config_0);
const _config_2 = resolveRegionConfig(_config_1);
const _config_3 = resolveEndpointConfig(_config_2);
Expand Down
Loading