Hi,
I have an app with a few background threads doing housekeeping tasks,
periodically updating stats etc. The way I have it setup is in Globals, I create
instances of my thread-classes, start them and save a handle. This makes it
possible for me to have controller methods which can query the threads, and
start/stop them.
I'm in the process of comparing options to better utilize multi-core machines.
The problem with the housekeeping threads is that there can only be one instance
of each because they would stomp over each other when updating the database. One
option is to move housekeeping activity into a separate app and then run
multiple instances of my app to use all the available cores. I'm not too excited
about this because it splits things up, requires duplication of config and adds
complexity to communicate between the housekeeper and the other apps.
The other possibility is to run my app in jython and get java threading which
would utilize the machine better. This also has a nice side-effect of making
other java utilities available. I'm wondering if others have experience running
pylons under jython and what problems there might be in terms of libraries or
subtle gotchas.
I'm also curious how others in the pylons world manage background tasks running
within your application. Are independent daemons the norm?
Thanks,
- Shailesh
--
You received this message because you are subscribed to the Google Groups
"pylons-discuss" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/pylons-discuss?hl=en.