单台机器最快的 Perl IPC/消息队列是多少?

发布于 2024-08-10 02:43:27 字数 322 浏览 2 评论 0原文

我正在开发一个(主要)Perl 项目,并希望使用消息队列来相互隔离进程。我有这样的工作流程:

输入 ->接收器->处理器 ->输出

我需要每秒处理数百笔交易,所以速度是我最大的动力。对于这种类型的设置来说,最快的消息队列系统是什么?

我的所有进程都在同一台计算机上运行,​​因此我可以使用 UNIX 套接字或临时文件(如果这意味着更好的性能)。

到目前为止,我最喜欢的两个是 IPC::DirQueue 和 beanstalkd。任何人都有这两种方法的经验并且可以得出哪个更快的结论吗?

还有什么可以在单台机器上实现超快的工作队列?

I'm working on a (primarily) Perl project and want to use a message queue to isolate processes from each other. I have a work flow like this:

Input -> Receiver -> Processor(s) -> Output(s)

I need to handle several hundred transactions/second, so speed my biggest motivator. What is the fastest message queue system for this type of setup?

All of my processes run on the same machine, so I can use UNIX sockets or temp-files if it means better performance.

So far my two favorites are IPC::DirQueue and beanstalkd. Anyone have experience with both and can make conclusions about which is faster?

What else is available that would make a super-fast work queue on a single machine?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

不回头走下去 2024-08-17 02:43:27

我不知道 IPC::Dirqueue 或 beanstalkd,但我在 spread 方面取得了很好的成功(使用传播Spread::Message 模块)。可以很容易地进行多进程(运行另一个守护进程)和多机。好处是,由于它是基于组的,如果您想要执行日志记录、统计或调试等操作,而无需更改(或减慢)处理器,您可以轻松附加另一个侦听器。

I don't know about IPC::Dirqueue or beanstalkd, but I've had good success with spread (with either the Spread or Spread::Message modules). It's easy to do multi-process (with another daemon running) and also multi-machine. The nice thing is that since it's group based you can easily attach another listener if you want to do things like logging, statistics or debugging without having to alter (or slow down) your processors.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文