How to use the winston.verbose function in winston

To help you get started, weā€™ve selected a few winston examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github soomtong / blititor / core / index.js View on Github external
winston.info('Server listening on port ' + app.get('port') + ' in ' + BLITITOR.env + ' mode')
    console.info("=== Server listening on port " + clc.yellow(app.get('port')) + " in " + clc.red(BLITITOR.env) + " mode");
    // display default route table
    // misc.showRouteTable();
});

if (!process.send) {
    // If run using `node app`, log copyright info along with server info
    const config = require('../package.json');
    winston.info('----------------------------------------------------------------');
    winston.info('BLITITOR v' + config.version + ' Copyright (C) 2016 @' + config.author + '.');
    winston.info('This program comes with ABSOLUTELY NO WARRANTY.');
    winston.info('This is free software, under ' + config.license + ' license');
    winston.info('and you are welcome to redistribute it under certain conditions.');
    winston.info('----------------------------------------------------------------');
    winston.verbose('module data file loaded. ' + BLITITOR.moduleList.length + ' modules located');
}

if (BLITITOR.env === 'development') { // Only in dev environment
    process.nextTick(function () {
        winston.info('update route data to log folder');
        misc.showGlobalVar(BLITITOR);
        misc.showRoutes(app);
    });
}
github a632079 / teng-koa / core.js View on Github external
async function registerRoutes (routes) {
  try {
    await routes.then(router => {
      app
        .use(router.routes())
        .use(router.allowedMethods())
    })
      .catch(err => {
        winston.error(err)
        // mail.error(err)
        process.exit(1)
      })
    winston.verbose('All Routes Load done.')
  } catch (e) {
    winston.error(e)
    // mail.error(e)
    process.exit(1)
  }
}
github soomtong / blititor / module / administrator / lib / administrator.js View on Github external
bcrypt.compare(params.password, auth.user_password, function (err, result) {
            if (err) {
                winston.error("bcrypt system error", err);

                return res.redirect('back');
            }
            if (!result) {
                winston.verbose('user given password not exactly same with authorized hash', result);

                req.flash('error', {msg: 'ė”œź·øģø ź³¼ģ •ģ— ė¬øģ œź°€ ė°œģƒķ–ˆģŠµė‹ˆė‹¤.'});

                return res.redirect('back');
            } else {
                // retrieve with auth
                account.findUserByAuthID(auth.id, function (error, userData) {
                    if (error || !userData) {
                        req.flash('error', {msg: 'ė”œź·øģø ė°ģ“ķ„°ė² ģ“ģŠ¤ģ— ė¬øģ œź°€ ģžˆģŠµė‹ˆė‹¤.'});

                        winston.error(err);

                        return res.redirect('back');
                    }

                    const user = {
github lbryio / spee.ch / server / speechPassport / utils / local-signup.js View on Github external
.then(tx => {
        // create user record
        const userData = {
          userName: username,
          password: password,
        };
        logger.verbose('userData >', userData);
        // create user record
        const channelData = {
          channelName   : `@${username}`,
          channelClaimId: tx.claim_id,
        };
        logger.verbose('channelData >', channelData);
        // create certificate record
        const certificateData = {
          claimId: tx.claim_id,
          name   : `@${username}`,
          // address,
        };
        logger.verbose('certificateData >', certificateData);
        // save user and certificate to db
        return Promise.all([db.User.create(userData), db.Channel.create(channelData), db.Certificate.create(certificateData)]);
      })
github fjn2 / one4all / server / classes / SongPlayer.js View on Github external
constructor() {
    Winston.verbose('SongPlayer -> constructor');
    this.volume = 100;
    this.cronometer = new Cronometer();
    this.playing = false;
  }
  init() {
github NodeBB / NodeBB / src / meta / minifier.js View on Github external
set: function (val) {
		maxThreads = val;
		if (!process.env.minifier_child) {
			winston.verbose('[minifier] utilizing a maximum of ' + maxThreads + ' additional threads');
		}
	},
	configurable: true,
github NodeBB / NodeBB / src / upgrades / 1.1.0 / separate_upvote_downvote.js View on Github external
batch.processSortedSet('posts:pid', function (pids, next) {
			winston.verbose('upgraded ' + count + ' posts');
			count += pids.length;
			async.each(pids, function (pid, next) {
				async.parallel({
					upvotes: function (next) {
						db.setCount('pid:' + pid + ':upvote', next);
					},
					downvotes: function (next) {
						db.setCount('pid:' + pid + ':downvote', next);
					},
				}, function (err, results) {
					if (err) {
						return next(err);
					}
					var data = {};

					if (parseInt(results.upvotes, 10) > 0) {
github yodle / new-relic-synthetics-manager / bin / cmds / config.js View on Github external
exports.handler = function (argv) {
    require('../../lib/config/LoggingConfig')(argv);

    validate(argv);

    const config = require('../../lib/config/SyntheticsConfig').getConfig(argv);

    logger.verbose('Config: ' + argv.name + ':' + argv.id);
    logger.verbose(argv);

    const changeConfigOrchestrator = dependencies(config).changeConfigOrchestrator;

    if (!_.isNil(argv.id)) {
        changeConfigOrchestrator.changeConfigurationById(
            argv.id,
            argv.frequency,
            argv.locations,
            argv.uri,
            argv.status,
            argv.rename,
            argv.addemail,
            argv.rmemail
        );
    } else if (!_.isNil(argv.name)) {
        changeConfigOrchestrator.changeConfigurationByName(
github dogbin / dogbin / lib / url_handler.js View on Github external
_this.store.set(key, buffer, function (res) {
        if (res) {
          winston.verbose('added url', { key: key });
          response.writeHead(200, { 'content-type': 'application/json' });
          response.end(JSON.stringify({ key: key }));
        }
        else {
          winston.verbose('error adding url');
          response.writeHead(500, { 'content-type': 'application/json' });
          response.end(JSON.stringify({ message: 'Error adding document.' }));
        }
      }, true);
    });
github fjn2 / one4all / server / classes / PlayList.js View on Github external
nextSong() {
    Winston.info('Playlist -> nextSong');
    this.currentSong += 1;

    if (this.currentSong > this.songs.length - 1) {
      this.currentSong = 0;
    }

    this.songPlayer.reset();
    this.clientsControl.sendPlaylist({
      songs: this.songs,
      currentSong: this.getCurrentSong(),
    });
    this.songPlayer.play();
    Winston.verbose('Playlist -> nextSong -> now playing #', this.currentSong);
  }
}