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

Mojo::IOLoop::ForkCall deprecated, use Mojo::IOLoop::Subprocess instead #494

Closed
ahesford opened this issue Jul 20, 2020 · 9 comments
Closed

Comments

@ahesford
Copy link

I'm looking to package znapzend for Void Linux, but found that Mojo::IOLoop::ForkCall is marked deprecated by the maintainer. The preferred replacement is Mojo::IOLoop::Subprocess, built right into Mojolicious.

A quick review of znapzend and the Mojo::IOLoop::Subprocess documentation leads me to believe that moving to the preferred replacment is as simple as s/ForkCall/Subprocess/ in lib/ZnapZend.pm and lib/ZnapZend/ZFS.pm, but I am neither a very sophisticated Perl hacker nor terribly familiar with znapzend.

@jberger
Copy link

jberger commented Jul 20, 2020

I'm the maintainer of the module in question: (a) yes usually changing the module name is that easy, there are some slight differences especially if you are using the events it emits, but for simple usage it is an easy port and (b) I'm not going to delete it from CPAN any time in the near future. Worst case is it gets less maintenance than I'd normally do. Certainly you should port it so that you get better support from Mojo core but don't fear that I'm going to intentionally cause outages.

@oetiker
Copy link
Owner

oetiker commented Jul 21, 2020

@ahesford will certainly be updating to the new subprocess approach ... but for now, you can just continue using it as is.

@ahesford
Copy link
Author

Thank you both for your responses. I am not currently using znapsend but thought I might explore while creating a Void package. Void is also missing a couple of dependencies, including Mojo::IOLoop::ForkCall. Adding a new package for a Perl module labeled deprecated, even knowing that it will persist indefinitely, may raise some eyebrows with the rest of the Void team. This is a back-burner issue for me, so I might let things sit for awhile and reevaluate when interest or necessity demands.

@jimklimov
Copy link
Contributor

Just in case, is this new method introduced recently? A bit back I did have to amend the configure script (and requirements file) to require an older Mojolicious version if running with perl-5.10 for example.

Being quite cross-platform, including Solaris 10 systems still running, znapzend has to support quite a wide range of perl versions and dependencies, at least if that is not prohibitively hard to maintain. Probably this does not mean that an obsolete implementation must remain the only one used - especially if like in this case it is a simple replacement, than some variable for function name, or a wrapper function making the choice, can suffice. And of course an optional include of new dependency, with fallback to old one.

@oetiker
Copy link
Owner

oetiker commented Jul 29, 2020

subprocess has been around for quite some time ...

@cgaspar
Copy link

cgaspar commented Jan 7, 2021

FYI, this has broken the spike repo znapzend RPM on Fedora 33, as there is no longer a perl-Mojo-IOLoop-ForkCall RPM available :-(

@jberger
Copy link

jberger commented Jan 7, 2021

Unfortunately system packagers rarely if ever communicate with upstream library authors. I was neither aware that there had been an rpm for it nor that it no longer had one. Personally I always recommend getting your CPAN dependencies from CPAN. Distro packagers do a service, but not one that we CPAN authors can control or even see.

@spike77453
Copy link
Contributor

FYI, this has broken the spike repo znapzend RPM on Fedora 33, as there is no longer a perl-Mojo-IOLoop-ForkCall RPM available :-(

Sorry about that, it should be fixed now.

@ahesford
Copy link
Author

ahesford commented Jun 2, 2021

Closing because I'm not really thinking about this anymore.

@ahesford ahesford closed this as completed Jun 2, 2021
fdd-rev added a commit to fdd-rev/znapzend that referenced this issue May 13, 2022
oetiker added a commit that referenced this issue May 25, 2022
Replace ForkCall with Subprocess, fix #494
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

No branches or pull requests

6 participants