Better handle large numbers of messages in cache on startup
This commit is contained in:
parent
102c2717cb
commit
2cfbfe477a
5 changed files with 56 additions and 21 deletions
|
@ -72,6 +72,7 @@ module.exports = {
|
|||
getNextExpiringMessage,
|
||||
getMessagesByConversation,
|
||||
|
||||
getUnprocessedCount,
|
||||
getAllUnprocessed,
|
||||
getUnprocessedById,
|
||||
saveUnprocessed,
|
||||
|
@ -458,6 +459,10 @@ async function getNextExpiringMessage({ MessageCollection }) {
|
|||
return new MessageCollection(messages);
|
||||
}
|
||||
|
||||
async function getUnprocessedCount() {
|
||||
return channels.getUnprocessedCount();
|
||||
}
|
||||
|
||||
async function getAllUnprocessed() {
|
||||
return channels.getAllUnprocessed();
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue