Skip to content

Commit

Permalink
Merge pull request #39 from osher-sade/master
Browse files Browse the repository at this point in the history
fix: removed the moment-timezone dependency
  • Loading branch information
osher-sade authored Apr 16, 2019
2 parents 9b57a1e + ee6551b commit f539334
Show file tree
Hide file tree
Showing 11 changed files with 93 additions and 119 deletions.
Empty file removed .nojekyll
Empty file.
12 changes: 6 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -32,9 +32,9 @@ days.
This interface represent the application configurable log properties.

Those properties are:
+ systemId
+ systemName
+ repositoryVersion
+ id
+ name
+ version
+ environment
+ component

Expand All @@ -53,7 +53,7 @@ import { ApplicationLogProperties, LoggerConfiguration, PolarisLogger } from '@e
const appProps: ApplicationLogProperties = {
id: 'p0laris-l0gs',
name: 'polaris-logs',
repositoryVersion: 'v1',
version: 'v1',
environment: 'environment',
component: 'component',
};
Expand Down Expand Up @@ -82,8 +82,8 @@ const logConf: LoggerConfiguration = {

const logger = new PolarisLogger(appProps, logConf);

logger.fatal('fatal message');
logger.error('error message');
logger.fatal('fatal message', { elapsedTime: 500, eventKind: 'foo' });
logger.error('error message', { elapsedTime: 15000, throwable: new Error('oops') });
logger.warn('warn message');
logger.info('info message');
logger.debug('debug message');
Expand Down
85 changes: 44 additions & 41 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 1 addition & 4 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@
"clean": "shx rm -rf node_modules/ dist/ docs/",
"typedoc": "typedoc --out ./docs --mode modules --tsconfig ./tsconfig.json ./src/",
"posttypedoc": "shx cp .nojekyll docs/.nojekyll",
"buildDependents": "npm i && tsc && npm link",
"prepare": "npm run lint:fix && npm run build",
"lint": "npm run tslint-check && tslint -p .",
"lint:fix": "npm run tslint-check && tslint -p . --fix",
Expand Down Expand Up @@ -68,8 +67,6 @@
"@types/serialize-error": "^2.1.0",
"@types/winston": "^2.4.4",
"clean-deep": "^3.0.2",
"moment-timezone": "^0.5.23",
"@types/moment-timezone": "^0.5.12",
"serialize-error": "^3.0.0",
"winston": "^3.2.1",
"winston-daily-rotate-file": "^3.8.0",
Expand All @@ -88,7 +85,7 @@
"pre-commit": "^1.2.2",
"prettier": "^1.16.4",
"rimraf": "^2.6.3",
"semantic-release": "^15.13.3",
"semantic-release": "^15.13.9",
"shx": "^0.3.2",
"travis-deploy-once": "^5.0.11",
"ts-jest": "^23.10.5",
Expand Down
1 change: 0 additions & 1 deletion src/configurations/logger-configuration.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,5 @@ export interface LoggerConfiguration {
writeFullMessageToConsole?: boolean;
logFilePath?: string;
dailyRotateFileConfiguration?: DailyRotateFileConfiguration;
timezone?: string;
customTransports?: Transport[];
}
2 changes: 1 addition & 1 deletion src/entities/application-log-properties.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
export interface ApplicationLogProperties {
id: string;
name: string;
repositoryVersion: string;
version: string;
environment: string;
component: string;
}
2 changes: 1 addition & 1 deletion src/polaris-logger.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ export class PolarisLogger {
eventKindDescription: {
systemId: applicationProperties.id,
},
repositoryVersion: applicationProperties.repositoryVersion,
version: applicationProperties.version,
environment: applicationProperties.environment,
component: applicationProperties.component,
};
Expand Down
11 changes: 0 additions & 11 deletions src/timezone-formatter.ts

This file was deleted.

Loading

0 comments on commit f539334

Please sign in to comment.