mirror of
https://github.com/signalapp/Signal-Desktop.git
synced 2025-12-24 12:19:41 +00:00
Extract NUM_MESSAGES_PER_BATCH
This commit is contained in:
@@ -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;
|
||||
|
||||
Reference in New Issue
Block a user