꧁岡
Size: a a a
꧁岡
АК
I
DR
꧁岡
I
PS
AV
for await (const section of sections) {
await myArticle.related('section').create({ sectionId: section });
}
PS
for await (const section of sections) {
await myArticle.related('section').create({ sectionId: section });
}
AV
ЕГ
this.amqp.connect('amqp://localhost', (error0, connection) => {Мне эти throw error в try/catch ловить и просто их логировать, чтобы он в очередь продолжал задачи ставить или что сделать?
if (error0) { throw error0; }
connection.createChannel((error1, channel) => {
if (error1) { throw error1; }
channel.assertQueue(name, {
durable: true,
});
channel.sendToQueue(name, Buffer.from(JSON.stringify({name: task.name, context: task.context})), {
persistent: true,
});
console.log(' [x] Sent \'%s\'', task.name);
});
setTimeout(() => {
connection.close();
}, 1500);
})
КС
КС
КС
КС
L