You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
// HandleDeserialize gets the clock skew context from the context, and if set, sets it on the pointer
215
-
// held by AddTimeOffsetDeserializeMiddleware
216
-
func (m*AddTimeOffsetDeserializeMiddleware) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) (
217
-
out middleware.DeserializeOutput, metadata middleware.Metadata, errerror,
// Middleware to set a `Date` object that includes sdk time and offset
232
-
typeMockAddDateHeaderstruct {
233
-
}
234
-
235
-
func (l*MockAddDateHeader) ID() string {
236
-
return"MockAddDateHeader"
237
-
}
238
-
239
-
func (l*MockAddDateHeader) HandleFinalize(
240
-
ctx context.Context, in smithymiddleware.FinalizeInput, next smithymiddleware.FinalizeHandler,
241
-
) (
242
-
out smithymiddleware.FinalizeOutput, metadata smithymiddleware.Metadata, attemptErrorerror,
243
-
) {
244
-
req:=in.Request.(*smithyhttp.Request)
245
-
date:=sdk.NowTime()
246
-
skew:=middleware.GetAttemptSkewContext(ctx)
247
-
date=date.Add(skew)
248
-
req.Header.Set("Date", date.Format(time.RFC850))
249
-
returnnext.HandleFinalize(ctx, in)
250
-
}
251
-
252
-
// Middleware to deserialize the response which just says "OK" if the response is 200
253
-
typeDeserializeFailIfNotHTTP200struct {
254
-
}
255
-
256
-
func (*DeserializeFailIfNotHTTP200) ID() string {
257
-
return"DeserializeFailIfNotHTTP200"
258
-
}
259
-
260
-
func (m*DeserializeFailIfNotHTTP200) HandleDeserialize(ctx context.Context, in smithymiddleware.DeserializeInput, next smithymiddleware.DeserializeHandler) (
261
-
out smithymiddleware.DeserializeOutput, metadata smithymiddleware.Metadata, errerror,
0 commit comments