mirror of
https://github.com/Luzifer/mondash.git
synced 2024-11-14 02:12:42 +00:00
23 lines
360 B
Go
23 lines
360 B
Go
|
package kinesis
|
||
|
|
||
|
import (
|
||
|
"time"
|
||
|
|
||
|
"github.com/aws/aws-sdk-go/aws/request"
|
||
|
)
|
||
|
|
||
|
var readDuration = 5 * time.Second
|
||
|
|
||
|
func init() {
|
||
|
ops := []string{
|
||
|
opGetRecords,
|
||
|
}
|
||
|
initRequest = func(r *request.Request) {
|
||
|
for _, operation := range ops {
|
||
|
if r.Operation.Name == operation {
|
||
|
r.ApplyOptions(request.WithResponseReadTimeout(readDuration))
|
||
|
}
|
||
|
}
|
||
|
}
|
||
|
}
|