migrate-mongo icon indicating copy to clipboard operation
migrate-mongo copied to clipboard

forward console.log in console

Open blackholegalaxy opened this issue 4 years ago • 1 comments

Sometime it can be useful to get some intermediate result when writing migration script. For log purpose in our migration runner, to be able to be parsed by elasticsearch for example. Or catch some errors.

Any option to get the console.log and thrown errors forwared back?

blackholegalaxy avatar Oct 07 '19 15:10 blackholegalaxy

Did you try to setup your own package.json in your migrate-mongo project directory, and add a logging library (eg. winston) as a dependency? If so, you could configure your own logger and use it in your migration files. It should be possible.

seppevs avatar Jul 21 '20 06:07 seppevs