judge: update logging

This commit is contained in:
undefined committed 2024-01-28 08:45:10 +08:00
1 parent 314bba6a0e
commit 3a87afbe6f
1 file changed
+2 -1
+2 -1
View File
@@ -263,7 +263,7 @@ export class JudgeConnectionHandler extends ConnectionHandler {
}
async message(msg) {
if (!['ping', 'prio', 'config'].includes(msg.key)) {
if (!['ping', 'prio', 'config', 'start'].includes(msg.key)) {
const method = ['status', 'next'].includes(msg.key) ? 'debug' : 'info';
const keys = method === 'debug' ? ['key'] : ['key', 'subtasks', 'cases'];
logger[method]('%o', omit(msg, keys));
@@ -299,6 +299,7 @@ export class JudgeConnectionHandler extends ConnectionHandler {
} else if (msg.key === 'start') {
clearTimeout(this.startTimeout);
this.consumer ||= task.consume(this.query, this.newTask.bind(this), true, this.concurrency);
logger.info('Judge daemon started');
}
}