Parallelize SQL queries

This commit is contained in:
Fedor Indutny 2024-07-22 11:16:33 -07:00 committed by GitHub
parent 86b4da1ec2
commit c64762858e
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
178 changed files with 3377 additions and 3618 deletions

View file

@ -4,7 +4,7 @@
import { assert } from 'chai';
import { v4 as generateUuid } from 'uuid';
import dataInterface from '../../sql/Client';
import { DataReader, DataWriter } from '../../sql/Client';
import { generateAci } from '../../types/ServiceId';
import { constantTimeEqual, getRandomBytes } from '../../Crypto';
import { singleProtoJobQueue } from '../../jobs/singleProtoJobQueue';
@ -12,17 +12,19 @@ import { singleProtoJobQueue } from '../../jobs/singleProtoJobQueue';
const {
_getAllSentProtoMessageIds,
_getAllSentProtoRecipients,
getAllSentProtos,
} = DataReader;
const {
deleteSentProtoByMessageId,
deleteSentProtoRecipient,
deleteSentProtosOlderThan,
getAllSentProtos,
getSentProtoByRecipient,
insertProtoRecipients,
insertSentProto,
removeAllSentProtos,
removeMessage,
saveMessage,
} = dataInterface;
} = DataWriter;
describe('sql/sendLog', () => {
beforeEach(async () => {