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

Build journald subscriber only on Linux #2232

Closed
wants to merge 1 commit into from
Closed

Build journald subscriber only on Linux #2232

wants to merge 1 commit into from

Conversation

swsnr
Copy link
Contributor

@swsnr swsnr commented Jul 20, 2022

Only build tracing-journald subscriber on Linux.

Follow up from #1744 (comment)

Motivation

journald only exists on Linux, and it's client API requires Linux-only features (memfd) for large payloads, so it makes no sense to build the subscriber on other OS.

This also prevents anyone from accidentally creating a tracing-journald subscriber on other operating systems and have their traces send into nirvana by mistake.

@swsnr
Copy link
Contributor Author

swsnr commented Jul 20, 2022

I have no Windows system to test the build on, so I've already opened this to see what Github actions has to say about the change.

@swsnr
Copy link
Contributor Author

swsnr commented Jul 20, 2022

@hawkw Feel free to close this if you'd like to keep journald available on other systems as well.

@hawkw
Copy link
Member

hawkw commented Jul 20, 2022

@hawkw Feel free to close this if you'd like to keep journald available on other systems as well.

I'm not opposed to making this change in a semver-incompatible release; I just want to ensure that the MSRV issue is resolved in a semver-compatible release before we make breaking changes. :)

@swsnr swsnr marked this pull request as ready for review July 20, 2022 18:35
@Ralith
Copy link
Collaborator

Ralith commented Jul 20, 2022

We should not make this change, because it breaks perfectly reasonable code that tries to use journald and dynamically falls back to more general solutions in its absence.

@Ralith
Copy link
Collaborator

Ralith commented Jul 20, 2022

This also prevents anyone from accidentally creating a tracing-journald subscriber on other operating systems and have their traces send into nirvana by mistake.

This is already impossible, as creating a journald subscriber when journald is not present will fail with an error.

@swsnr
Copy link
Contributor Author

swsnr commented Jul 20, 2022

I guess that's a point. It didn't occur to me that anyone would want to do this, but for some kind of cross-platform service that's perhaps actually a use case.

I'll close this MR, since the original issue is fixed.

@swsnr swsnr closed this Jul 20, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants