Skip to content

Commit a49c874

Browse files
committed
docs: add comment about page-limit backoff logic
1 parent 217529b commit a49c874

File tree

1 file changed

+2
-0
lines changed
  • packages/gatsby-source-contentful/src

1 file changed

+2
-0
lines changed

packages/gatsby-source-contentful/src/fetch.js

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -226,6 +226,8 @@ ${formatPluginOptionsForCLI(pluginConfig.getOriginalPluginOptions(), errors)}`,
226226
currentPageLimit > 1
227227
) {
228228
lastCurrentPageLimit = currentPageLimit
229+
// Reduce page limit by a arbitrary 1/3 of the current limit to ensure
230+
// the new and bigger entries are synced without exceeding the reponse size limit
229231
currentPageLimit = Math.floor((currentPageLimit / 3) * 2) || 1
230232
reporter.warn(
231233
[

0 commit comments

Comments
 (0)