Skip to content

Commit 65d900e

Browse files
committed
feat: 🎸 README
1 parent d0626ce commit 65d900e

File tree

2 files changed

+18
-9
lines changed

2 files changed

+18
-9
lines changed

README.md

+16-8
Original file line numberDiff line numberDiff line change
@@ -22,9 +22,9 @@ Lumberjack Applicationinsights Driver is a custom log driver for [ngworker/lumbe
2222

2323
TODO: Update the features of this driver
2424

25-
- ✅ Logs to custom log store
25+
- ✅ Logs to Azure Application Insights log store
2626
- ✅ Unit test coverage
27-
-Custom Logger
27+
-Prints your DEBUG, WARNING and CRITICAL logs to console
2828
- ✅ Follows Lumberjack Best Practices guide
2929

3030
## Table of Contents
@@ -49,11 +49,10 @@ LumberjackApplicationinsightsDriver is published as the `@ngworker/lumberjack-ap
4949

5050
`LumberjackApplicationinsightsDriver` has verified compatibility with the following packages versions.
5151

52-
| LumberjackApplicationinsightsDriver | Lumberjack | Another Package |
53-
| ----------------------------------- | -------------- | --------------- |
54-
| 2.0.x | ^2.0.0 | ^8.0.0 |
55-
| 1.2.x | >=2.0.0-rc.0 | ^7.4.1 |
56-
| 1.1.x | >=2.0.0-beta.3 | ^7.0.0 |
52+
| LumberjackApplicationinsightsDriver | Lumberjack | @microsoft/applicationinsights-web |
53+
| ----------------------------------- | -------------- | ---------------------------------- |
54+
| 1.0.x | ^2.0.0 | ^2.5.11 |
55+
5756

5857
If the version you are using is not listed, please [raise an issue in our GitHub repository](https://github.com/ngworker/lumberjack-applicationinsights-driver/issues/new).
5958

@@ -75,7 +74,8 @@ import { LumberjackApplicationinsightsDriver } from '@ngworker/lumberjack-applic
7574
}),
7675
LumberjackApplicationinsightsDriver.forRoot({
7776
levels: [LumberjackLevel.Critical, LumberjackLevel.Error],
78-
// Options
77+
instrumentationKey: environment.appInsights.instrumentationKey,
78+
loggingLevelConsole: 3,
7979
}),
8080
// (...)
8181
],
@@ -89,6 +89,14 @@ Now you can start using the `LumberjackService` or extend `LumberjackLogger` and
8989
## Configuration
9090

9191
TODO: Here it is explained how this custom driver can be configured.
92+
To use the Application Insights you must provide or `instrumentationKey`, or `connectionString` in the configuration object provided in `forRoot`. Additionally you can specify `loggingLevelConsole`.
93+
94+
| Setting | Description
95+
|----------------------|----------------
96+
| `instrumentationKey` | Instrumentation key of resource. Either this or connectionString must be specified.
97+
| `connectionString` | Connection string of resource. Either this or instrumentationKey must be specified.
98+
| `loggingLevelConsole` | Console logging level. All logs with a severity level higher than the configured level will be printed to console. Otherwise they are suppressed. Level 3 will print DEBUG, WARNING and CRITICAL logs to console, level 2 will print both CRITICAL and WARNING logs to console, level 1 prints only CRITICAL.
99+
92100

93101
## Wallaby.js
94102

libs/ngworker/lumberjack-applicationinsights-driver/src/lib/configuration/lumberjack-applicationinsights-driver-internal.config.ts

+2-1
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,8 @@ export interface LumberjackApplicationinsightsDriverInternalConfig extends Lumbe
1414
/**
1515
* Console logging level. All logs with a severity level higher
1616
* than the configured level will be printed to console. Otherwise
17-
* they are suppressed. ie Level 2 will print both CRITICAL and
17+
* they are suppressed. Level 3 will print DEBUG, WARNING and CRITICAL logs
18+
* to console, level 2 will print both CRITICAL and
1819
* WARNING logs to console, level 1 prints only CRITICAL.
1920
*
2021
* Note: Logs sent as telemetry to instrumentation key will also

0 commit comments

Comments
 (0)