Skip to content
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

finishing Syslog formatter #1689

Merged
merged 5 commits into from
Jul 22, 2022
Merged

finishing Syslog formatter #1689

merged 5 commits into from
Jul 22, 2022

Conversation

picass0
Copy link
Contributor

@picass0 picass0 commented Jun 13, 2022

This PR finishes work started by @dkarlovi here #1599

In theory metadata(context and extra) can be stored in native syslog structured data format https://datatracker.ietf.org/doc/html/rfc5424#section-6.3 (as suggested by @dkarlovi) but storing arbitrary structred data requires registering "private enterprise number" with IANA(it says so in here https://datatracker.ietf.org/doc/html/rfc5424#section-6.3.2) which looks like too much work, so i just added metadata as part of a message. Hope this is ok

@dkarlovi
Copy link
Contributor

@picass0 thanks so much for working on this! \o/

I'm not picky about structured data being in the message TBH. My only worry is if lnav will be able to use it to filter the messages? Being able to have it running in development with my Symfony apps is basically the only reason why I'd want this formatter. Could you test your implementation with it to confirm it will work? If so, I'm all 👍 here.

@picass0
Copy link
Contributor Author

picass0 commented Jun 16, 2022

Thanks for response @dkarlovi )
i recorded video of dev.log with this formatter, looks really nice imho :)
as you can see in video searching and filtering works fine

simplescreenrecorder-2022-06-17_01.05.44.mp4

@dkarlovi dkarlovi mentioned this pull request Jun 17, 2022
@Seldaek Seldaek added this to the 3.x milestone Jul 22, 2022
@Seldaek Seldaek merged commit a7e5bed into Seldaek:main Jul 22, 2022
@Seldaek
Copy link
Owner

Seldaek commented Jul 22, 2022

Thank you both!

@Seldaek
Copy link
Owner

Seldaek commented Jul 22, 2022

Just FYI f7dfa00 reverts some changes done here to keep BC and make use of the new Level::toRFC5424Level method - hope that makes sense to you too.

@picass0
Copy link
Contributor Author

picass0 commented Jul 22, 2022

Just FYI f7dfa00 reverts some changes done here to keep BC and make use of the new Level::toRFC5424Level method - hope that makes sense to you too.

Sorry for breaking BC. I think u missed one use statement here \Monolog\Formatter\SyslogFormatter:14
2022-07-22_19-33

Seldaek added a commit that referenced this pull request Jul 22, 2022
@Seldaek
Copy link
Owner

Seldaek commented Jul 22, 2022

Right, cleaned those up :) And no worries about the BC break, it was very minor so I thought I'd let it slide but then I realized I could as well just fix it easily.

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

Successfully merging this pull request may close these issues.

None yet

3 participants