log4js-node / log4js-node/log4js-node
numBackups failed when using dot into pattern
Nobody has claimed this yet.
- Dominant language
- JavaScript
- Stars
- 5.8k
- Forks
- 752
- PR merge metrics
- No merged PRs in 30d
Description
Hi,
i using this configuration
{
appenders: {
console: { type: "stdout" },
file: {
type: "dateFile",
filename: conf.directory + '/' +conf.filePattern,
pattern:'yyyy.MM.dd.hh.mm',
numBackups : 1,
},
},
categories: {
default: { appenders: ["file"], level: conf.logLevel },
}
}
And the rolling is ok but the numBackups doesn't work.
If i replace '.' by '-' into filename, it works fine.
pattern:'yyyy-MM-dd-hh-mm',
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reproducing the issue's dateFile configuration, comparing numBackups behavior with dots and hyphens in the pattern. Trace the dateFile and numBackups handling, then verify that the dot-separated pattern retains the configured backup count without breaking the rolling behavior.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript, node.js
- Domain
- observability-sre
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 42/100