Skip to content
This repository was archived by the owner on Mar 13, 2025. It is now read-only.

[$75] Fix receiver logging #203

Closed
jmgasper opened this issue Oct 12, 2019 · 6 comments
Closed

[$75] Fix receiver logging #203

jmgasper opened this issue Oct 12, 2019 · 6 comments

Comments

@jmgasper
Copy link
Collaborator

Noticed by Topcoder when moving to AWS:

The logger setup is either very messy, or just plain wrong. In app.js, it’s importing morgan as logger but then calling logger.logFullError, which is a function on utils/logger.js. This should be refactored into one unified and clean logger

Fix:

The Topcoder-X processor has good logging, so let's:

  1. Remove morgan as a dependency in the receiver
  2. Copy in the logging implementation from the processor
  3. Update the receiver code to use the new logging implementation from the processor.
@jmgasper jmgasper changed the title [$60] Fix receiver logging [$75] Fix receiver logging Oct 12, 2019
@afrisalyp
Copy link
Collaborator

@jmgasper,
The processor logger also uses morgan as a dependency.
Here is the code.
https://github.com/topcoder-platform/topcoder-x-processor/blob/c792201129a91d56a97e6bc7ddadd00f80911e62/utils/logger.js#L15

Remove morgan as a dependency in the receiver

Can you please tell me what do we really want for removing the morgan module in the receiver?

@jmgasper
Copy link
Collaborator Author

@afrisalyp - Let's remove morgan from the package.json and replace it with the winston dependency that the processor uses: "winston": "^2.4.3". That way they're consistent.

@afrisalyp
Copy link
Collaborator

@jmgasper oh i'm sorry. I misunderstood.
Thanks for the clarification.

@afrisalyp
Copy link
Collaborator

@jmgasper it's ready for review. thanks.

@jmgasper
Copy link
Collaborator Author

Contest https://www.topcoder.com/challenges/30104204 has been updated - it has been assigned to afrisalyp.

This is an automated message for ghostar via Topcoder X

@jmgasper
Copy link
Collaborator Author

Payment task has been updated: https://software.topcoder.com/review/actions/ViewProjectDetails?pid=30104204

This is an automated message for ghostar via Topcoder X

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

No branches or pull requests

2 participants