Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Logging Utility Class #6

Closed
zsteinkamp opened this issue Jun 30, 2023 · 1 comment · Fixed by #9
Closed

Logging Utility Class #6

zsteinkamp opened this issue Jun 30, 2023 · 1 comment · Fixed by #9

Comments

@zsteinkamp
Copy link
Contributor

Problem

Log entries generated by this code are not easily discernible from other log entries. Using a log prefix requires the developer to include the prefix in each log event entry.

Proposed Solution

A utility method/class that wraps logging and adds a consistent log entry prefix.

From @ryepup:

nit/future: might be worth a tiny leveled logging wrapper to ensure we always have the acme-njs: [$MODULE] prefix and control verbosity.

import {Logger} from './logger'
const log = new Logger("utils")
...
log.info(`Generated a new account key and saved it to ${path}`)
@ryepup
Copy link
Collaborator

ryepup commented Jun 30, 2023

You can assign this to me, I sketched it up this morning so will put in a PR after #5

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants