-
Notifications
You must be signed in to change notification settings - Fork 42
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
LegacyTransportStream passes info as meta #27
Comments
@markdascher, if you strip level, message and [LEVEL] from info, you’re left with the equivalent of meta. |
Would a PR that makes LegacyTransportStream do that be welcome? |
@markdascher I've submitted a PR adding Winston 3.0 support to the Google Stackdriver transport, which is stuck on 2.4.4. Your suggestion would help... |
@kazazes Your comment from long ago, "if you strip level, message and [LEVEL] from info" - does that need to be done in the transport itself? Or can it be done outside the transport in a custom |
In a v2 transport, my understanding was that meta was something different from the message. (i.e.
logger.info('hello world', { happy: true });
) As an example, winston-papertrail sends extra JSON-formatted messages if there's a meta object. LegacyTransportStream just passes info here, which isn't really the same thing. The end result is that winston 3 ends up sending two messages for each log, one of them in JSON.Should LegacyTransportStream be doing some interpretation of info, similar to the simple logform? Then it would only pass an object if there's more than just a level and message, which might make more sense to v2 transports.
Honestly it's tough to figure out exactly what the v3 equivalent of meta is (staring at winstonjs/winston#1235 hasn't helped), so this all could be a misunderstanding on my part too.
The text was updated successfully, but these errors were encountered: