Parallelize SQL queries
This commit is contained in:
parent
86b4da1ec2
commit
c64762858e
178 changed files with 3377 additions and 3618 deletions
|
@ -3,6 +3,7 @@
|
|||
|
||||
import type { AciString } from '../types/ServiceId';
|
||||
import type { MessageModel } from '../models/messages';
|
||||
import { DataReader } from '../sql/Client';
|
||||
import * as Errors from '../types/errors';
|
||||
import * as log from '../logging/log';
|
||||
import { getMessageIdForLogging } from '../util/idForLogging';
|
||||
|
@ -66,9 +67,7 @@ export async function onSync(
|
|||
const logId = `ViewOnceOpenSyncs.onSync(timestamp=${sync.timestamp})`;
|
||||
|
||||
try {
|
||||
const messages = await window.Signal.Data.getMessagesBySentAt(
|
||||
sync.timestamp
|
||||
);
|
||||
const messages = await DataReader.getMessagesBySentAt(sync.timestamp);
|
||||
|
||||
const found = messages.find(item => {
|
||||
const itemSourceAci = item.sourceServiceId;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue