@@ -281,6 +281,8 @@ import {
281
281
expectNumber as __expectNumber,
282
282
expectString as __expectString,
283
283
extendedEncodeURIComponent as __extendedEncodeURIComponent,
284
+ handleFloat as __handleFloat,
285
+ serializeFloat as __serializeFloat,
284
286
} from "@aws-sdk/smithy-client";
285
287
import {
286
288
Endpoint as __Endpoint,
@@ -16786,7 +16788,7 @@ const serializeAws_restJson1CanarySettings = (input: CanarySettings, context: __
16786
16788
return {
16787
16789
...(input.deploymentId !== undefined && input.deploymentId !== null && { deploymentId: input.deploymentId }),
16788
16790
...(input.percentTraffic !== undefined &&
16789
- input.percentTraffic !== null && { percentTraffic: input.percentTraffic }),
16791
+ input.percentTraffic !== null && { percentTraffic: __serializeFloat( input.percentTraffic) }),
16790
16792
...(input.stageVariableOverrides !== undefined &&
16791
16793
input.stageVariableOverrides !== null && {
16792
16794
stageVariableOverrides: serializeAws_restJson1MapOfStringToString(input.stageVariableOverrides, context),
@@ -16801,7 +16803,7 @@ const serializeAws_restJson1DeploymentCanarySettings = (
16801
16803
): any => {
16802
16804
return {
16803
16805
...(input.percentTraffic !== undefined &&
16804
- input.percentTraffic !== null && { percentTraffic: input.percentTraffic }),
16806
+ input.percentTraffic !== null && { percentTraffic: __serializeFloat( input.percentTraffic) }),
16805
16807
...(input.stageVariableOverrides !== undefined &&
16806
16808
input.stageVariableOverrides !== null && {
16807
16809
stageVariableOverrides: serializeAws_restJson1MapOfStringToString(input.stageVariableOverrides, context),
@@ -16904,7 +16906,7 @@ const serializeAws_restJson1MapOfApiStageThrottleSettings = (
16904
16906
input: { [key: string]: ThrottleSettings },
16905
16907
context: __SerdeContext
16906
16908
): any => {
16907
- return Object.entries(input).reduce((acc: { [key: string]: ThrottleSettings }, [key, value]: [string, any]) => {
16909
+ return Object.entries(input).reduce((acc: { [key: string]: any }, [key, value]: [string, any]) => {
16908
16910
if (value === null) {
16909
16911
return acc;
16910
16912
}
@@ -16919,7 +16921,7 @@ const serializeAws_restJson1MapOfStringToBoolean = (
16919
16921
input: { [key: string]: boolean },
16920
16922
context: __SerdeContext
16921
16923
): any => {
16922
- return Object.entries(input).reduce((acc: { [key: string]: boolean }, [key, value]: [string, any]) => {
16924
+ return Object.entries(input).reduce((acc: { [key: string]: any }, [key, value]: [string, any]) => {
16923
16925
if (value === null) {
16924
16926
return acc;
16925
16927
}
@@ -16931,7 +16933,7 @@ const serializeAws_restJson1MapOfStringToBoolean = (
16931
16933
};
16932
16934
16933
16935
const serializeAws_restJson1MapOfStringToList = (input: { [key: string]: string[] }, context: __SerdeContext): any => {
16934
- return Object.entries(input).reduce((acc: { [key: string]: string[] }, [key, value]: [string, any]) => {
16936
+ return Object.entries(input).reduce((acc: { [key: string]: any }, [key, value]: [string, any]) => {
16935
16937
if (value === null) {
16936
16938
return acc;
16937
16939
}
@@ -16943,7 +16945,7 @@ const serializeAws_restJson1MapOfStringToList = (input: { [key: string]: string[
16943
16945
};
16944
16946
16945
16947
const serializeAws_restJson1MapOfStringToString = (input: { [key: string]: string }, context: __SerdeContext): any => {
16946
- return Object.entries(input).reduce((acc: { [key: string]: string }, [key, value]: [string, any]) => {
16948
+ return Object.entries(input).reduce((acc: { [key: string]: any }, [key, value]: [string, any]) => {
16947
16949
if (value === null) {
16948
16950
return acc;
16949
16951
}
@@ -16992,7 +16994,7 @@ const serializeAws_restJson1StageKey = (input: StageKey, context: __SerdeContext
16992
16994
const serializeAws_restJson1ThrottleSettings = (input: ThrottleSettings, context: __SerdeContext): any => {
16993
16995
return {
16994
16996
...(input.burstLimit !== undefined && input.burstLimit !== null && { burstLimit: input.burstLimit }),
16995
- ...(input.rateLimit !== undefined && input.rateLimit !== null && { rateLimit: input.rateLimit }),
16997
+ ...(input.rateLimit !== undefined && input.rateLimit !== null && { rateLimit: __serializeFloat( input.rateLimit) }),
16996
16998
};
16997
16999
};
16998
17000
@@ -17077,7 +17079,7 @@ const deserializeAws_restJson1BasePathMapping = (output: any, context: __SerdeCo
17077
17079
const deserializeAws_restJson1CanarySettings = (output: any, context: __SerdeContext): CanarySettings => {
17078
17080
return {
17079
17081
deploymentId: __expectString(output.deploymentId),
17080
- percentTraffic: __expectNumber (output.percentTraffic),
17082
+ percentTraffic: __handleFloat (output.percentTraffic),
17081
17083
stageVariableOverrides:
17082
17084
output.stageVariableOverrides !== undefined && output.stageVariableOverrides !== null
17083
17085
? deserializeAws_restJson1MapOfStringToString(output.stageVariableOverrides, context)
@@ -17755,7 +17757,7 @@ const deserializeAws_restJson1MethodSetting = (output: any, context: __SerdeCont
17755
17757
metricsEnabled: __expectBoolean(output.metricsEnabled),
17756
17758
requireAuthorizationForCacheControl: __expectBoolean(output.requireAuthorizationForCacheControl),
17757
17759
throttlingBurstLimit: __expectNumber(output.throttlingBurstLimit),
17758
- throttlingRateLimit: __expectNumber (output.throttlingRateLimit),
17760
+ throttlingRateLimit: __handleFloat (output.throttlingRateLimit),
17759
17761
unauthorizedCacheControlHeaderStrategy: __expectString(output.unauthorizedCacheControlHeaderStrategy),
17760
17762
} as any;
17761
17763
};
@@ -17943,7 +17945,7 @@ const deserializeAws_restJson1Stage = (output: any, context: __SerdeContext): St
17943
17945
const deserializeAws_restJson1ThrottleSettings = (output: any, context: __SerdeContext): ThrottleSettings => {
17944
17946
return {
17945
17947
burstLimit: __expectNumber(output.burstLimit),
17946
- rateLimit: __expectNumber (output.rateLimit),
17948
+ rateLimit: __handleFloat (output.rateLimit),
17947
17949
} as any;
17948
17950
};
17949
17951
0 commit comments