Aidas Kasparas <[email protected]> writes: > And, I'm not against fair order for message sending. I just want to > be fair per user, not per message.
Right, something would have to track how much each user has submitted to the queue in the last [some amount of time], in number of bytes multipled by number of recipients. I think to determine priority I'd take the square root of that figure (multiplied by a configurable scaling factor, which could probably just default to 1) and subtract it from the number of milliseconds the thing's been in the queue. The queued message with the greatest difference goes next. Thus, if you've sent a megabyte's worth of data your priority starts around -1024, gets up to zero after 10.24 seconds and climbs linearly from there (until it gets sent), but if you've sent a gigabyte's worth it takes your priority almost five and a half hours to get up to zero, and meanwhile all the short messages would be going ahead of you unless there's spare bandwidth (which, in practice, there frequently would be, but each time a new message came in it would beat you to the next sending slot, if you've got multiple big messages going out, or need to have your big message sent out multiple times to different domains). Just to be clear, messages with a negative priority *would* be sent, but only *after* any messages with higher priority. But yeah, that sounds like fair amount of work to implement. And it would be controversial (although, if the scaling factor defaults to zero all messages would be sent in the order they are received by default, unless they need to be requeued). -- Nathan Eady Galion Public Library ------------------------------------------------------------------------------ Beautiful is writing same markup. Internet Explorer 9 supports standards for HTML5, CSS3, SVG 1.1, ECMAScript5, and DOM L2 & L3. Spend less time writing and rewriting code and more time creating great experiences on the web. Be a part of the beta today http://p.sf.net/sfu/msIE9-sfdev2dev _______________________________________________ courier-users mailing list [email protected] Unsubscribe: https://lists.sourceforge.net/lists/listinfo/courier-users
