1.0.16 • Published 5 years ago

otoz-logger v1.0.16

Weekly downloads
35
License
UNLICENSED
Repository
-
Last release
5 years ago

Introduction

A wrapper module around winston specifically written for OTOZ.

Getting Started

  • first install the package npm i otoz-logger
  • Import it in your application import { Logger } from 'otoz-logger'
  • Create logger instance const myLogger = new Logger();
  • Set the following environment variables

LOGGER_STRATEGY=winston
LOGGER_TRANSPORT=appInsights
APPINSIGHTS_INSTRUMENTATIONKEY=your-application-insights-key

Usage

myLogger.logInfo({
    name: 'serverStarted',
    message: 'Express server listening on port ' + PORT,
    meta: {
		corelationId: 'abc-corelationId',
        sessionId: 'abc-sessionId',
        requestId: 'abc-requestId',
    }
});
1.0.16

5 years ago

1.0.15

5 years ago

1.0.14

5 years ago

1.0.13

5 years ago

1.0.12

5 years ago

1.0.11

5 years ago

1.0.10

5 years ago

1.0.9

5 years ago

1.0.8

5 years ago

1.0.7

5 years ago

1.0.6

5 years ago

1.0.5

5 years ago

1.0.4

5 years ago

1.0.3

5 years ago

1.0.2

5 years ago

1.0.1

5 years ago

1.0.0

5 years ago