You are here: Re: Free internet components for developers « PHP Programming Language « IT news, forums, messages
Re: Free internet components for developers

Posted by Jerry Stuckle on 07/25/07 15:13

Webrickco wrote:
> On Jul 25, 3:46 pm, Rik <luiheidsgoe...@hotmail.com> wrote:
>> On Wed, 25 Jul 2007 16:25:13 +0200, Webrickco <webric...@gmail.com> wrote:
>>> A race condition?
>> You write in a file that may be opened by another instance of the same
>> counter[*]. At least implement something like flock() so you make sure
>> your own scipt doesn't bug.
>>
>> [*]
>> Chronological:
>> 1. First request
>> 2. Second request
>> 3. 1.Opening for writing.
>> 4. 2.Opening for writing.
>> 5. 1.Writing to file.
>> 6. 2.Writing to file.
>>
>> What do you think will happen? It all depends on being written to & closed
>> before opening it again in another instance.
>>
>> --
>> Rik Wasmus
>
> This is a simple technical solution, that certainly would work for
> most of the sites. What are the odds 2 different users open the page
> at the exact same time? and if so, what would be the result? Miss one
> count! In professional IT, you have to measure the odds against the
> cost. Not everything is implementable regarding the costs. Consider
> this a will-serve-in-most-case solution.
>
> But the solution is always discutable. I thank you for your
> contribution!
>

With any reasonably active website, eventually it's almost 100%.

--
==================
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

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