全部搜索项
buster  ] [  bullseye  ] [  bookworm  ] [  trixie  ] [  sid  ]
[ 源代码: libschedule-ratelimiter-perl  ]

软件包:libschedule-ratelimiter-perl(0.01-2)

libschedule-ratelimiter-perl 的相关链接

Screenshot

Debian 的资源:

下载源码包 libschedule-ratelimiter-perl

维护小组:

外部的资源:

相似软件包:

Perl library to prevent events from happening too quickly

Schedule::RateLimiter provides a way to voluntarily restrict how many times a given action may take place within a specified time frame. Such a tool may be useful if you have written something which periodically polls some public resource and want to ensure that you do not overburden that resource with too many requests.

Initially, one might think that solving this problem would be as simple as sleeping for the number of seconds divided by the number of iterations in between each event. However, that would only be correct if the event took no time at all.

If you know exactly how much time each event is going to take then you could build an even more complicated one-liner such as this:

sleep( (seconds / iterations) - single_event_time )

标签: 软件开发: Perl 开发, 函数库, 实做语言: Perl, 角色: 共用函数库

其他与 libschedule-ratelimiter-perl 有关的软件包

  • 依赖
  • 推荐
  • 建议
  • 增强

下载 libschedule-ratelimiter-perl

下载可用于所有硬件架构的
硬件架构 软件包大小 安装后大小 文件
all 9.4 kB27.0 kB [文件列表]