Skip to content

Commit 872f01f

Browse files
committed
performance
1 parent 794d412 commit 872f01f

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

backend/onyx/connectors/confluence/connector.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -454,9 +454,12 @@ def _fetch_document_batches(
454454
page_query = self._construct_page_query(checkpoint.last_updated or start, end)
455455
logger.debug(f"page_query: {page_query}")
456456

457+
# most requests will include a few pages to skip, so we limit each page to
458+
# 2 * batch_size to only need a single request for most checkpoint runs
457459
for page in self.confluence_client.paginated_cql_retrieval(
458460
cql=page_query,
459461
expand=",".join(_PAGE_EXPANSION_FIELDS),
462+
limit=2 * self.batch_size,
460463
):
461464
if page["id"] in prev_doc_ids:
462465
# There are a few seconds of fuzziness in the request,

0 commit comments

Comments
 (0)