def iterExport( module, target, importKey, cursor=None ):
"""
Processes 100 Entries and calls the next batch
"""
urlfetch.set_default_fetch_deadline(20)
Skel = skeletonByKind( module )
if not Skel:
logging.error("TaskExportKind: Invalid module")
return
query = Skel().all().cursor( cursor )
startCursor = cursor
query.run(100, keysOnly=True)
endCursor = query.getCursor().urlsafe()
exportItems(module, target, importKey, startCursor, endCursor)
if startCursor is None or startCursor != endCursor:
iterExport(module, target, importKey, endCursor)
评论列表
文章目录