[Python] Mettere in pausa gli altri threads

Giampaolo Rodola' g.rodola a gmail.com
Gio 3 Ott 2013 22:14:37 CEST


On Thu, Oct 3, 2013 at 7:03 PM, enrico franchi <enrico.franchi a gmail.com>wrote:

>
>
>
> 2013/10/3 Luca <luca800 a gmail.com>
>
>> 2013/10/3 Gollum1 <gollum1.smeagol1 a gmail.com>
>>
>>
>>> i semafori...
>>>
>>>
>>> http://www.laurentluce.com/posts/python-threads-synchronization-locks-rlocks-semaphores-conditions-events-and-queues/
>>>
>>> L'avevo trovato proprio questa mattina ma non ho ancora avuto il tempo.
>> Ma visto che è consigliato darà la precedenza.
>>
>
>
> If you've spent years learning tricks to make your multithreaded code work
> at all, let alone rapidly, with locks and semaphores and critical sections,
> you will be disgusted when you realize it was all for nothing. If there's
> one lesson we've learned from 30+ years of concurrent programming, it is:
> *just don't share state*. It's like two drunkards trying to share a beer.
> It doesn't matter if they're good buddies. Sooner or later, they're going
> to get into a fight. And the more drunkards you add to the table, the more
> they fight each other over the beer. The tragic majority of MT applications
> look like drunken bar fights.
>
> http://zguide.zeromq.org/page:all#Multithreading-with-MQ
>

Bellissima!


--- Giampaolo
https://code.google.com/p/pyftpdlib/
https://code.google.com/p/psutil/
https://code.google.com/p/pysendfile/
-------------- parte successiva --------------
Un allegato HTML è stato rimosso...
URL: <http://lists.python.it/pipermail/python/attachments/20131003/51841033/attachment.html>


Maggiori informazioni sulla lista Python