Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions Doc/spelling_wordlist.txt
Original file line number Diff line number Diff line change
Expand Up @@ -116,6 +116,7 @@ refmodule
refreshAndPersist
refreshDeletes
refreshOnly
reloadHint
requestName
requestValue
resiter
Expand Down
8 changes: 6 additions & 2 deletions Lib/ldap/syncrepl.py
Original file line number Diff line number Diff line change
Expand Up @@ -352,7 +352,7 @@ class SyncreplConsumer:
SyncreplConsumer - LDAP syncrepl consumer object.
"""

def syncrepl_search(self, base, scope, mode='refreshOnly', cookie=None, **search_args):
def syncrepl_search(self, base, scope, mode='refreshOnly', cookie=None, reloadHint=False, **search_args):
"""
Starts syncrepl search operation.

Expand All @@ -371,6 +371,10 @@ def syncrepl_search(self, base, scope, mode='refreshOnly', cookie=None, **search
methods to store the cookie appropriately, rather than
passing it.

reloadHint: if True, ask the server to send the full
content when it cannot resume synchronization from the given
cookie, rather than returning an error.

Only a single syncrepl search may be active on a SyncreplConsumer
object. Multiple concurrent syncrepl searches require multiple
separate SyncreplConsumer objects and thus multiple connections
Expand All @@ -379,7 +383,7 @@ def syncrepl_search(self, base, scope, mode='refreshOnly', cookie=None, **search
if cookie is None:
cookie = self.syncrepl_get_cookie()

syncreq = SyncRequestControl(cookie=cookie, mode=mode)
syncreq = SyncRequestControl(cookie=cookie, mode=mode, reloadHint=reloadHint)

if 'serverctrls' in search_args:
search_args['serverctrls'] += [syncreq]
Expand Down