Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #81399

Re: Recurring Task

References <4a496b58-867f-43ae-b6f9-48f4d885b170@googlegroups.com>
Date 2014-11-23 11:48 -0800
Subject Re: Recurring Task
From Dan Stromberg <drsalists@gmail.com>
Newsgroups comp.lang.python
Message-ID <mailman.16205.1416772126.18130.python-list@python.org> (permalink)

Show all headers | View raw


On Sun, Nov 23, 2014 at 7:23 AM,  <tim@timothyarnold.co.uk> wrote:
> Hi All
> Looking for some advice. I'm creating a small netwok poller and wondered what people recommend to use? Will be polling up to 100 hosts every ten reconds or so
>
> Options I can see
>
> Home grown using worker threads with Queue and dispatcher based on timestamp

This might be good, as might the multiprocessing module.

> Twisted timer service

I wouldn't wish a large Twisted project on my worst enemy.  If you
need async, you might consider gevent.

> Python Scheduler

Perhaps - I have no experience with this.

I'd probably go the multiprocessing route.  multithreading is fine
with CPython if you're 100% I/O bound, but as soon as you add one
CPU-bound thread, the multitasking gets all messed up - unless you
move to jython.

Back to comp.lang.python | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread


Thread

Recurring Task tim@timothyarnold.co.uk - 2014-11-23 07:23 -0800
  Re: Recurring Task Dennis Lee Bieber <wlfraed@ix.netcom.com> - 2014-11-23 13:35 -0500
  Re: Recurring Task Dan Stromberg <drsalists@gmail.com> - 2014-11-23 11:48 -0800
  Re: Recurring Task Dan Stromberg <drsalists@gmail.com> - 2014-11-23 11:56 -0800

csiph-web