Extract NUM_MESSAGES_PER_BATCH
This commit is contained in:
parent
85788d3c4a
commit
3c57dbfb56
1 changed files with 2 additions and 1 deletions
|
@ -15,6 +15,7 @@ const DATABASE_NAME = 'signal';
|
|||
const EXPECTED_DATABASE_VERSION = 17;
|
||||
const MESSAGES_STORE_NAME = 'messages';
|
||||
const ITEMS_STORE_NAME = 'items';
|
||||
const NUM_MESSAGES_PER_BATCH = 50;
|
||||
|
||||
exports.processNext = async ({
|
||||
BackboneMessage,
|
||||
|
@ -104,7 +105,7 @@ exports.processAll = async ({
|
|||
// eslint-disable-next-line no-await-in-loop
|
||||
await _dangerouslyFetchMessagesRequiringSchemaUpgradeWithoutIndex({
|
||||
connection,
|
||||
count: 10,
|
||||
count: NUM_MESSAGES_PER_BATCH,
|
||||
lastIndex: lastProcessedIndex,
|
||||
});
|
||||
const fetchDuration = Date.now() - fetchUnprocessedMessagesStartTime;
|
||||
|
|
Loading…
Reference in a new issue