You are here: Re: Locking threads « PHP Programming Language « IT news, forums, messages
Re: Locking threads

Posted by Jerry Stuckle on 07/16/07 00:28

Jim wrote:
> Hi,
>
> I'm developing a CMS and I'd like to be able cache the site "tree" in
> a multi-dimensional array in shared memory (far too many sql calls
> otherwise). When someone adds an item in the tree I need to be able to
> read in the array from shared memory, add the new item, then write it
> back to shared memory.....all in one atomic action.
>
> I've done plenty of research and short of using something like
> eaccelerator or mmcache I'm stuck with PHP semaphores which even then
> don't appear to be thread safe, only process safe (correct me if I'm
> wrong) - and then I'm restricted to *nix systems.
>
> Is there any way to create a method of doing the above which will work
> on *nix and Windows, whether it's multi-threaded or single-threaded?
>
> Thanks,
>
> Jim.
>

Jim,

Use a database. There are dozens around which use databases; if
implemented properly they can be quite efficient.

--
==================
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
jstucklex@attglobal.net
==================

 

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

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