Skip to content

Commit ff1d3f5

Browse files
authored
HCK-8774: interrupt table processing on absence of db table information (#94)
* HCK-8774: interrupt table processing on absence of db table information * HCK-8774: add logging for case of not found table
1 parent cf871c2 commit ff1d3f5

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

reverse_engineering/reverseEngineeringService/reverseEngineeringService.js

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -433,6 +433,13 @@ const reverseCollectionsToJSON = logger => async (dbConnectionClient, tablesInfo
433433
const tableInfo = await getTableInfo(dbConnectionClient, dbName, tableName, schemaName).catch(
434434
logError(logger, 'Getting table info'),
435435
);
436+
if (!tableInfo) {
437+
logger.log('error', {
438+
type: 'warning',
439+
message: `Can't find the information about ${tableName} table`,
440+
});
441+
return;
442+
}
436443

437444
const [tableRows, fieldsKeyConstraints, distributionData] = await Promise.all([
438445
containsJson(tableInfo)

0 commit comments

Comments
 (0)