aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGravatar Matt Kulka <mattlqx@users.noreply.github.com> 2019-07-31 12:09:10 -0700
committerGravatar dilyevsky <ilyevsky@gmail.com> 2019-07-31 12:09:10 -0700
commit45e17c325c16760374455157795d375709ee72ab (patch)
tree2f48feb1429e74af884d71e8d57bf1f5dc298f6a
parentcd5dcebe9352b6a08687cfdf3ac8115bd7c8dfcc (diff)
downloadcoredns-45e17c325c16760374455157795d375709ee72ab.tar.gz
coredns-45e17c325c16760374455157795d375709ee72ab.tar.zst
coredns-45e17c325c16760374455157795d375709ee72ab.zip
[plugin/route53]: Increase ListResourceRecordSets paging size. (#3073)
without the paging parameter set, it will default to 100 records per request. with large enough zones and potentially multiple coredns daemons configured to pull from route 53, this can quickly add up and reach aws global api rate limits (5/sec per root account). increasing paging to max can help reduce the number of requests needed to pull records for a zone without no down side that i am aware of. this helps issue #2353, but probably is not a complete fix. Signed-off-by: Matt Kulka <mkulka@parchment.com>
-rw-r--r--plugin/route53/route53.go1
1 files changed, 1 insertions, 0 deletions
diff --git a/plugin/route53/route53.go b/plugin/route53/route53.go
index 02d0b8230..0f7c2b1d2 100644
--- a/plugin/route53/route53.go
+++ b/plugin/route53/route53.go
@@ -248,6 +248,7 @@ func (h *Route53) updateZones(ctx context.Context) error {
newZ.Upstream = h.upstream
in := &route53.ListResourceRecordSetsInput{
HostedZoneId: aws.String(hostedZone.id),
+ MaxItems: aws.String("1000"),
}
err = h.client.ListResourceRecordSetsPagesWithContext(ctx, in,
func(out *route53.ListResourceRecordSetsOutput, last bool) bool {