what about add property for event.categoryName ?

Open
#1 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

  • #30 by @dhruval-dream — closed without merging

Assessment

Difficulty
2/5
Estimated time
1-3 hours
Newbie friendliness
35/100
Issue type
Feature
Clarity
Mostly clear
Activity status
Stale
Tech stack
javascript

Research direction

Locate the returned function in logstashHTTPAppender(config) and inspect how its output object is assembled. Check the linked pull request and existing output coverage first; done means the emitted data includes the event category name without breaking the other fields.

Written by the indexing model from the issue text.

Description

Hi.

In the current version, although event has property 'categoryName', which is defined the parameter of getLogger(), there's no property in output data that is defined by the categoryName. What about to add the following line in the returned function of function logstashHTTPAppender(config) ?

{
  message: format(event.data),
  context: event.context,
  level: event.level.level / 100,
  level_name: event.level.levelStr,
  category_name: event.categoryName, // +
  channel: config.logChannel,
  datetime: (new Date(event.startTime)).toISOString(),
  extra: {},
},
Dominant language
JavaScript
Stars
14
Forks
8
PR merge metrics
No merged PRs in 30d

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Similar issues

More JavaScript issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.