You are here: Re: [PHP] Shared variable / exclusive locking? « PHP « IT news, forums, messages
Re: [PHP] Shared variable / exclusive locking?

Posted by The_roibm on 10/04/63 11:10

ok, so the solution is shm or shmop, but there is something I'm not
sure about it...
the way I wanna go is shm and sem and the things that are clear are:
- use sem to block multiple processes(or threads) writing to the same shm block
- there is no need to use sem for reading since multiple
processes(threads) can read safely from the same shm block

what is not that clear is... what happens when a process reads and
another writes exactly at the same time? do the read operations behave
like some sort of transactions that ensure you get the content
available in the shm block at the beginning of the read even when it
is changed during the read? I guess this is not the case, so how would
you handle this properly?

regards

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация