Comments (3)
Fixed in #82 :)
from winston-loki.
We ran into an issue too on one application which was using v6.0.2; basically, the issue ran as follows:
- The batcher.js, if you log the response from its post request (and NOT the error) in winston-loki/src/batcher.js line 195, you will actually get back an error from the Go Parser used by Loki, in that there is a malformed body.
- We found that we kept getting error 400 responses in the access logs for our nginx setup in front of Loki (but no error logs), so basically - the errors weren't being returned as errors from Loki, so the winston-loki package thought it was okay. Hence why it never showed up in the Node application logs.
The specific error it got back from the Loki parser is "Value looks like object, but can't find closing '}' symbol", source code here: https://github.com/buger/jsonparser/blob/master/parser.go
It seemed to always point at byte #10 at the end of the log message, which was in the context/metadata object. Fiddling with the Winston formatter settings didn't seem to have an impact.
Reverting to winston-loki v6.0.1 fixed the problem. Hope this helps!
from winston-loki.
Same here...long time user/fan. 6.0.1 works fine. 6.0.2 means no logs.
from winston-loki.
Related Issues (20)
- use Symbol.for('level') when extracting label HOT 1
- useCustomFormat is broken
- Race condition in batching leading to lost logs HOT 1
- QUESTION: How many log levels are supported? HOT 2
- Feature Request: awaitable finishRequests method
- TypeError: winston_loki_1.default is not a constructor HOT 2
- Remote Loki HOT 1
- Possible to quit the batcher loop ASAP when closing? HOT 1
- [patch] A method to wait until all the logs are physically sent to winston HOT 3
- Docs: Add a section to explain how to make it work with nextjs and/or webpack HOT 5
- Snappy optionalDependency upgrade breaks build HOT 2
- CVE-2023-36665 protobufjs Dependency HOT 3
- Childlogger with additional labels
- NodeJS crash when batching is enabled
- Segmentation fault with swc & vitest in github action ubuntu-latest when using version 6.0.7
- Documentation improvement ideas
- logfmt syntax error with Grafana cloud
- push log to grafana cloud having logs lost
- Module parse failed error on Next.js 14 HOT 2
- Add support for structured metadata HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from winston-loki.