mirror of
https://github.com/coredns/coredns.git
synced 2025-10-27 16:24:19 -04:00
[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>
This commit is contained in:
@@ -248,6 +248,7 @@ func (h *Route53) updateZones(ctx context.Context) error {
|
|||||||
newZ.Upstream = h.upstream
|
newZ.Upstream = h.upstream
|
||||||
in := &route53.ListResourceRecordSetsInput{
|
in := &route53.ListResourceRecordSetsInput{
|
||||||
HostedZoneId: aws.String(hostedZone.id),
|
HostedZoneId: aws.String(hostedZone.id),
|
||||||
|
MaxItems: aws.String("1000"),
|
||||||
}
|
}
|
||||||
err = h.client.ListResourceRecordSetsPagesWithContext(ctx, in,
|
err = h.client.ListResourceRecordSetsPagesWithContext(ctx, in,
|
||||||
func(out *route53.ListResourceRecordSetsOutput, last bool) bool {
|
func(out *route53.ListResourceRecordSetsOutput, last bool) bool {
|
||||||
|
|||||||
Reference in New Issue
Block a user