Skip to content

Commit 9a5c627

Browse files
committed
HCK-11091: Move the log of the start to the studio
1 parent a3228a8 commit 9a5c627

File tree

3 files changed

+0
-45
lines changed

3 files changed

+0
-45
lines changed

forward_engineering/api.js

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,9 +11,6 @@ module.exports = {
1111
isDropInStatements,
1212

1313
applyToInstance(connectionInfo, logger, callback, app) {
14-
logger.clear();
15-
logger.log('info', connectionInfo, 'connectionInfo', connectionInfo.hiddenKeys);
16-
1714
applyToInstance(connectionInfo, logger, app)
1815
.then(result => {
1916
callback(null, result);

reverse_engineering/api.js

Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -69,8 +69,6 @@ module.exports = {
6969
},
7070

7171
testConnection: function (connectionInfo, logger, cb, app) {
72-
logInfo('Test connection', connectionInfo, logger);
73-
7472
this.connect(
7573
connectionInfo,
7674
logger,
@@ -92,7 +90,6 @@ module.exports = {
9290
getDbCollectionsNames: function (connectionInfo, logger, cb, app) {
9391
initPluginConfiguration(connectionInfo.pluginConfiguration, logger);
9492

95-
logInfo('Retrieving keyspaces and tables information', connectionInfo, logger);
9693
const { includeSystemCollection } = connectionInfo;
9794
const cassandra = cassandraHelper();
9895

@@ -145,8 +142,6 @@ module.exports = {
145142
initPluginConfiguration(data.pluginConfiguration, logger);
146143

147144
const cassandra = cassandraHelper();
148-
logger.log('info', data, 'Retrieving schema', data.hiddenKeys);
149-
150145
const tables = data.collectionData.collections;
151146
const keyspacesNames = data.collectionData.dataBaseNames;
152147
const includeEmptyCollection = data.includeEmptyCollection;
@@ -283,12 +278,6 @@ module.exports = {
283278
},
284279
};
285280

286-
const logInfo = (step, connectionInfo, logger) => {
287-
logger.clear();
288-
logger.log('info', logHelper.getSystemInfo(connectionInfo.appVersion), step);
289-
logger.log('info', connectionInfo, 'connectionInfo', connectionInfo.hiddenKeys);
290-
};
291-
292281
const progress = (logger, keyspace, table, message) => {
293282
logger.progress({
294283
containerName: keyspace,

reverse_engineering/logHelper.js

Lines changed: 0 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -22,36 +22,6 @@ const checkConnection = (host, port, timeout = 5000) =>
2222

2323
const getPluginVersion = () => packageFile.version;
2424

25-
const getSystemInfo = appVersion => {
26-
return (
27-
'' +
28-
`Date: ${new Date()}` +
29-
'\n' +
30-
`Application version: ${appVersion}` +
31-
'\n' +
32-
`Plugin version: ${getPluginVersion()}` +
33-
'\n\n' +
34-
`System information:` +
35-
'\n' +
36-
` Hostname: ${os.hostname()}` +
37-
'\n' +
38-
` Platform: ${os.platform()} ${os.arch()}` +
39-
'\n' +
40-
` Release: ${os.release()}` +
41-
'\n' +
42-
` Uptime: ${toTime(os.uptime())}` +
43-
'\n' +
44-
` Total RAM: ${(os.totalmem() / 1073741824).toFixed(2)} GB` +
45-
'\n' +
46-
` CPU Model: ${os.cpus()[0].model}` +
47-
'\n' +
48-
` CPU Clock: ${maxClock(os.cpus())} MHZ` +
49-
'\n' +
50-
` CPU Cores: ${os.cpus().length} cores` +
51-
'\n\n'
52-
);
53-
};
54-
5525
const maxClock = cpus => {
5626
return cpus.reduce((highestClock, cpu) => Math.max(highestClock, cpu.speed), 0);
5727
};
@@ -63,7 +33,6 @@ const toTime = number => {
6333
};
6434

6535
const logHelper = {
66-
getSystemInfo,
6736
checkConnection,
6837
};
6938

0 commit comments

Comments
 (0)