From 04c0ad32298dbc4916fb92b6c6ffe1c90b56c981 Mon Sep 17 00:00:00 2001 From: Ezerous Date: Mon, 14 Mar 2022 10:53:42 +0200 Subject: [PATCH] fix: remove constant polling logging in pinner --- packages/concordia-pinner/src/app.js | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/packages/concordia-pinner/src/app.js b/packages/concordia-pinner/src/app.js index 2e3eee9..9f32d22 100644 --- a/packages/concordia-pinner/src/app.js +++ b/packages/concordia-pinner/src/app.js @@ -8,7 +8,7 @@ import { getResolvedRendezvousMultiaddress } from './utils/ipfsUtils'; import { logger } from './utils/logger'; const POLLING_INTERVAL = 1000; -logger.info('Initializing API service.'); +logger.info(`Initializing API service (polling interval is ${POLLING_INTERVAL / 1000}s).`); const responseBody = { ipfs: { @@ -23,13 +23,11 @@ const responseBody = { getResolvedRendezvousMultiaddress().then((multiaddress) => { const { address, port } = multiaddress.nodeAddress(); const rendezvousUrl = `http://${address}:${port}`; - logger.info(`Resolved rendezvous URL to: ${rendezvousUrl}`); + logger.info(`Resolved rendezvous URL to ${rendezvousUrl}`); responseBody.rendezvous.url = rendezvousUrl; }); const getStats = async (orbit) => { - logger.info('Gathering stats.'); - try { const ipfs = orbit._ipfs; const { id } = await ipfs.id(); @@ -70,7 +68,7 @@ const startAPI = (orbit) => { }); app.listen(pinnerApiPort, () => { - logger.info(`Pinner API at http://localhost:${pinnerApiPort}!`); + logger.info(`Pinner API at http://localhost:${pinnerApiPort}`); }); setInterval(getStats, POLLING_INTERVAL, orbit);