Threading, Queue for a function so it only runs once at a time.
mailinglists at riddergarn.dk
Fri Mar 12 16:56:12 CET 2010
Sorry but its not really an option for me with PostgreSQL. Thanks anyway.
I wonder if there is a simple way of just queueing the run of a function
make it only run once at a time but by multiply threads? :)
On Fri, 12 Mar 2010 00:54:57 -0800, Jonathan Gardner
<jgardner at jonathangardner.net> wrote:
> For lots of transactions running at once, MySQL is a terrible choice.
> Give PostgreSQL a try. It does a much better job with that kind of
> On Thu, Mar 11, 2010 at 11:11 PM, John P. <mailinglists at riddergarn.dk>
>> Im programming a simple webcrawler with threading for the fun of it,
>> is inserting the data fetch into a mysql database, but after
>> cause my mysql server to produce error during database queries (i
>> its cause because of the many execution at the same time.) the scipt
>> produces errors.
>> I figured out i need some kind of queue for the function i use to
>> into the database, to make sure its only called once at a time.
>> I have looked at the Queue module but its for more complicated than my
>> current python skills can cope with. :)
>> Would somebody please help me out here?
More information about the Python-list