Skip to content
Snippets Groups Projects
Commit c62a16ae authored by syuilo's avatar syuilo
Browse files

Add some log for debugging

parent 350310c4
No related branches found
No related tags found
No related merge requests found
......@@ -291,12 +291,15 @@ export default abstract class Chart<T extends Record<string, any>> {
date: Chart.dateToTimestamp(current),
...Chart.convertObjectToFlattenColumns(data)
});
logger.info(`${this.name}: New commit created`);
} catch (e) {
// duplicate key error
// 並列動作している他のチャートエンジンプロセスと処理が重なる場合がある
// その場合は再度最も新しいログを持ってくる
if (isDuplicateKeyValueError(e)) {
log = await this.getLatestLog(span, group) as Log;
logger.info(`${this.name}: Commit duplicated`);
} else {
logger.error(e);
throw e;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment