Skip to content
This repository has been archived by the owner on Jan 15, 2025. It is now read-only.

Add syslog to runtimes with Ruby >= 3.4 #915

Closed
mhashizume opened this issue Sep 16, 2024 · 3 comments
Closed

Add syslog to runtimes with Ruby >= 3.4 #915

mhashizume opened this issue Sep 16, 2024 · 3 comments
Labels
triaged Jira issue has been created for this

Comments

@mhashizume
Copy link
Contributor

Ruby 3.4 will move the syslog gem from a default gem to bundled gem. Ruby 3.3 is already warning about this:

warning: syslog was loaded from the standard library, but will no longer be part of the default gems since Ruby 3.4.0. Add syslog to your Gemfile or gemspec.

Since syslog requires native extensions, we should include it in any runtimes that use Ruby >= 3.4, once that's been released.

@mhashizume mhashizume added the triaged Jira issue has been created for this label Sep 16, 2024
Copy link

Migrated issue to PA-6971

@joshcooper
Copy link
Contributor

Thanks for filing @mhashizume! I would expect the ruby 3.4 build and install all of the "bundled" gems, so I'm hoping we don't actually need to do anything? For example, our agent-runtime-main tarball contains the rss gem which isn't a runtime component, but is present in the tarball:

$ tar tf agent-runtime-main-202409090.ubuntu-20.04-amd64.tar.gz | grep 'rss-.*.gem'
opt/puppetlabs/puppet/lib/ruby/gems/3.2.0/cache/rss-0.2.9.gem
opt/puppetlabs/puppet/lib/ruby/gems/3.2.0/specifications/rss-0.2.9.gemspec

However, since the syslog gem contains native extensions, it may not be that simple, so thanks again for filing.

@joshcooper
Copy link
Contributor

joshcooper commented Sep 24, 2024

Based on https://github.com/ruby/ruby/blob/9d69619623ec6b86c464b7cac911b7201f74dab7/gems/bundled_gems#L35C1-L36C1 I think we safely assume syslog will be a bundled gem and will be present in the ruby that we build (if/when we move to Ruby 3.4.x).

Also racc was changed from default to bundled gem in 3.3.x, https://github.com/ruby/ruby/blob/ef084cc8f4958c1b6e4ead99136631bef6d8ddba/gems/bundled_gems#L23, so we can assume that is present as well.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
triaged Jira issue has been created for this
Projects
None yet
Development

No branches or pull requests

2 participants