Will PHP ever "grow up" and have threading?
Will PHP ever "grow up" and have threading?
am 23.03.2010 01:02:30 von Daevid Vincent
I've been using PHP for a decade or so (since PHP/FI) and love it. The one
problem that seems to always keep coming back on enterprise level projects
is the lack of threading. This always means we have to write some back-end
code in Ruby or Java or C/C++ and some hacky database layer or DBUS or
something to communicate with PHP.
Will PHP ever have proper threading? It would sure let the language take
the next logical leap to writing applications and daemons. I love the idea
that Rails/Ruby have where you can just load objects in memory once and
keep using them from page to page (this is NOT the same as a $_SESSION,
it's way more flexible and powerful).
But more importantly, in one application I'm working on, we need to connect
to an Asterisk system for the IVR abilities. This means we have Ruby doing
all that fun stuff and PHP doing the web stuff, but we're also duplicating
a LOT of work. Both Ruby AND PHP now have to have ORMs for the user who's
calling in, advertisements served, products shown, etc. We could have used
Rails for the web portion, but I want to stay with PHP and I'm sure I don't
have to explain to you PHPers why that is. Without threads, PHP just isn't
even an option or only one user would be able to call in at a time.
The pcntl stuff is not feasible. It's a hack at best. Spawning multiple
scripts is also a recipie for disaster.
When will the PHP core-devs (Zend?) realize that PHP is much more than a
hook to a database. It's much more than web pages.
Is this a case of "it's too hard"? Or is it a case of PHP core developers
just being douche-bags like they are about the whole
"foo($set_this_parameter=$bar);" bull$hit??! (there is NO reason NOT to let
the developer choose WHICH of the list of parameters they want to set in a
function/method call aside from being stubborn! Especially when there are
many parameters and you can't overload functions like you can in Java or
other typed languages)
As usual, I created a poll here too:
http://www.rapidpoll.net/awp1ocy
Past polls are below:
http://www.rapidpoll.net/8opnt1e
http://www.rapidpoll.net/arc1opy (although someone hacked this poll and
loaded up the 76 votes like a little cheater)
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 23.03.2010 01:38:59 von Larry Garfield
Perhaps if you asked a question you'd get an answer rather than coming off as
an angry immature crybaby in your last paragraph... No, I'm not going to
dignify your post with a real answer. Come back when you can ask a real
question and maybe you'll get a real answer.
--Larry Garfield
On Monday 22 March 2010 07:02:30 pm Daevid Vincent wrote:
> I've been using PHP for a decade or so (since PHP/FI) and love it. The one
> problem that seems to always keep coming back on enterprise level projects
> is the lack of threading. This always means we have to write some back-end
> code in Ruby or Java or C/C++ and some hacky database layer or DBUS or
> something to communicate with PHP.
>
> Will PHP ever have proper threading? It would sure let the language take
> the next logical leap to writing applications and daemons. I love the idea
> that Rails/Ruby have where you can just load objects in memory once and
> keep using them from page to page (this is NOT the same as a $_SESSION,
> it's way more flexible and powerful).
>
> But more importantly, in one application I'm working on, we need to connect
> to an Asterisk system for the IVR abilities. This means we have Ruby doing
> all that fun stuff and PHP doing the web stuff, but we're also duplicating
> a LOT of work. Both Ruby AND PHP now have to have ORMs for the user who's
> calling in, advertisements served, products shown, etc. We could have used
> Rails for the web portion, but I want to stay with PHP and I'm sure I don't
> have to explain to you PHPers why that is. Without threads, PHP just isn't
> even an option or only one user would be able to call in at a time.
>
> The pcntl stuff is not feasible. It's a hack at best. Spawning multiple
> scripts is also a recipie for disaster.
>
> When will the PHP core-devs (Zend?) realize that PHP is much more than a
> hook to a database. It's much more than web pages.
>
> Is this a case of "it's too hard"? Or is it a case of PHP core developers
> just being douche-bags like they are about the whole
> "foo($set_this_parameter=$bar);" bull$hit??! (there is NO reason NOT to let
> the developer choose WHICH of the list of parameters they want to set in a
> function/method call aside from being stubborn! Especially when there are
> many parameters and you can't overload functions like you can in Java or
> other typed languages)
>
> As usual, I created a poll here too:
> http://www.rapidpoll.net/awp1ocy
>
> Past polls are below:
> http://www.rapidpoll.net/8opnt1e
> http://www.rapidpoll.net/arc1opy (although someone hacked this poll and
> loaded up the 76 votes like a little cheater)
>
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
RE: Will PHP ever "grow up" and have threading?
am 23.03.2010 01:59:21 von Daevid Vincent
That's okay Larry, YOU don't have to answer.
Sorry my post offended you Larry (and anyone else equally offended).
....and yes. I AM angry that they refuse to add functionality to the PHP
language that MANY people have been requesting, just because they are
stubborn. I'll spare you the links to the threads (no pun intended) as you
can easily find them.
Have a lovely day!
Your best friend always,
Daevid.
> -----Original Message-----
> From: Larry Garfield [mailto:larry@garfieldtech.com]
> Sent: Monday, March 22, 2010 5:39 PM
> To: php-general@lists.php.net
> Subject: Re: [PHP] Will PHP ever "grow up" and have threading?
>
> Perhaps if you asked a question you'd get an answer rather
> than coming off as
> an angry immature crybaby in your last paragraph... No, I'm
> not going to
> dignify your post with a real answer. Come back when you can
> ask a real
> question and maybe you'll get a real answer.
>
> --Larry Garfield
>
> > Is this a case of "it's too hard"? Or is it a case of PHP
> core developers
> > just being douche-bags like they are about the whole
> > "foo($set_this_parameter=$bar);" bull$hit??! (there is NO
> reason NOT to let
> > the developer choose WHICH of the list of parameters they
> want to set in a
> > function/method call aside from being stubborn! Especially
> when there are
> > many parameters and you can't overload functions like you
> can in Java or
> > other typed languages)
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 23.03.2010 02:10:33 von David McGlone
On Monday 22 March 2010 20:59:21 Daevid Vincent wrote:
> That's okay Larry, YOU don't have to answer.
>
> Sorry my post offended you Larry (and anyone else equally offended).
>
> ...and yes. I AM angry that they refuse to add functionality to the PHP
> language that MANY people have been requesting, just because they are
> stubborn. I'll spare you the links to the threads (no pun intended) as you
> can easily find them.
>
> Have a lovely day!
>
> Your best friend always,
>
> Daevid.
>
> > -----Original Message-----
> > From: Larry Garfield [mailto:larry@garfieldtech.com]
> > Sent: Monday, March 22, 2010 5:39 PM
> > To: php-general@lists.php.net
> > Subject: Re: [PHP] Will PHP ever "grow up" and have threading?
> >
> > Perhaps if you asked a question you'd get an answer rather
> > than coming off as
> > an angry immature crybaby in your last paragraph... No, I'm
> > not going to
> > dignify your post with a real answer. Come back when you can
> > ask a real
> > question and maybe you'll get a real answer.
> >
> > --Larry Garfield
> >
> > > Is this a case of "it's too hard"? Or is it a case of PHP
> >
> > core developers
> >
> > > just being douche-bags like they are about the whole
> > > "foo($set_this_parameter=$bar);" bull$hit??! (there is NO
> >
> > reason NOT to let
> >
> > > the developer choose WHICH of the list of parameters they
> >
> > want to set in a
> >
> > > function/method call aside from being stubborn! Especially
> >
> > when there are
> >
> > > many parameters and you can't overload functions like you
> >
> > can in Java or
> >
> > > other typed languages)
>
You could implement the features yourself.
--
Blessings
David M.
I have been driven to my knees many times by the overwhelming conviction that
I had nowhere else to go.
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 23.03.2010 02:36:11 von Robert Cummings
David McGlone wrote:
> On Monday 22 March 2010 20:59:21 Daevid Vincent wrote:
>> That's okay Larry, YOU don't have to answer.
>>
>> Sorry my post offended you Larry (and anyone else equally offended).
>>
>> ...and yes. I AM angry that they refuse to add functionality to the PHP
>> language that MANY people have been requesting, just because they are
>> stubborn. I'll spare you the links to the threads (no pun intended) as you
>> can easily find them.
>>
>> Have a lovely day!
>>
>> Your best friend always,
>>
>> Daevid.
>>
>>> -----Original Message-----
>>> From: Larry Garfield [mailto:larry@garfieldtech.com]
>>> Sent: Monday, March 22, 2010 5:39 PM
>>> To: php-general@lists.php.net
>>> Subject: Re: [PHP] Will PHP ever "grow up" and have threading?
>>>
>>> Perhaps if you asked a question you'd get an answer rather
>>> than coming off as
>>> an angry immature crybaby in your last paragraph... No, I'm
>>> not going to
>>> dignify your post with a real answer. Come back when you can
>>> ask a real
>>> question and maybe you'll get a real answer.
>>>
>>> --Larry Garfield
>>>
>>>> Is this a case of "it's too hard"? Or is it a case of PHP
>>> core developers
Subscribe to internals. Read the archives. The truth is out there.
>>>> just being douche-bags like they are about the whole
That's just rude.
>>>> "foo($set_this_parameter=$bar);" bull$hit??! (there is NO
>>> reason NOT to let
>>>
>>>> the developer choose WHICH of the list of parameters they
>>> want to set in a
There are reasons. You would know this if you had done the legwork
before opening your mouth and letting crap fall out.
>>>> function/method call aside from being stubborn! Especially
>>> when there are
>>>
>>>> many parameters and you can't overload functions like you
>>> can in Java or
PHP is NOT Java.
>>>> other typed languages)
Nor is it OTHER types languages.
> You could implement the features yourself.
Damn, Mr McGlone beat me to it :)
When you set the subject line of your rant to something like "Will PHP
ever 'grow up'", I expect your argument to at least be rationale,
logical, and quite possibly contain a patch. It's called "open source"
because you too can make changes.
Cheers,
Rob.
--
http://www.interjinn.com
Application and Templating Framework for PHP
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 23.03.2010 03:22:07 von ahlin.hans
It's code design problem you face, there is loots of solutions to "use
treading" in php. (analyse the way ms C# and VB creates and handles
threads, and when you have done that you can create a couple of php
scripts to acquire the same result).
Read GOF (gang of fore) Design Patterns: Elements of Reusable
Object-Oriented Software (ISBN 0-201-63361-2) and PHP 5 Power
Programming (ISBN 0-131-47149-X)
Start reading and stop being an AHole.
2010/3/23 Daevid Vincent :
> I've been using PHP for a decade or so (since PHP/FI) and love it. The on=
e
> problem that seems to always keep coming back on enterprise level project=
s
> is the lack of threading. This always means we have to write some back-en=
d
> code in Ruby or Java or C/C++ and some hacky database layer or DBUS or
> something to communicate with PHP.
>
> Will PHP ever have proper threading? It would sure let the language take
> the next logical leap to writing applications and daemons. I love the ide=
a
> that Rails/Ruby have where you can just load objects in memory once and
> keep using them from page to page (this is NOT the same as a $_SESSION,
> it's way more flexible and powerful).
>
> But more importantly, in one application I'm working on, we need to conne=
ct
> to an Asterisk system for the IVR abilities. This means we have Ruby doin=
g
> all that fun stuff and PHP doing the web stuff, but we're also duplicatin=
g
> a LOT of work. Both Ruby AND PHP now have to have ORMs for the user who's
> calling in, advertisements served, products shown, etc. We could have use=
d
> Rails for the web portion, but I want to stay with PHP and I'm sure I don=
't
> have to explain to you PHPers why that is. Without threads, PHP just isn'=
t
> even an option or only one user would be able to call in at a time.
>
> The pcntl stuff is not feasible. It's a hack at best. Spawning multiple
> scripts is also a recipie for disaster.
>
> When will the PHP core-devs (Zend?) realize that PHP is much more than a
> hook to a database. It's much more than web pages.
>
> Is this a case of "it's too hard"? Or is it a case of PHP core developers
> just being douche-bags like they are about the whole
> "foo($set_this_parameter=3D$bar);" bull$hit??! (there is NO reason NOT to=
let
> the developer choose WHICH of the list of parameters they want to set in =
a
> function/method call aside from being stubborn! Especially when there are
> many parameters and you can't overload functions like you can in Java or
> other typed languages)
>
> As usual, I created a poll here too:
> http://www.rapidpoll.net/awp1ocy
>
> Past polls are below:
> http://www.rapidpoll.net/8opnt1e
> http://www.rapidpoll.net/arc1opy (although someone hacked this poll and
> loaded up the 76 votes like a little cheater)
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>
--=20
MvH / Hans Ã
hlin
Tel: +46761488019
http//www.kronan-net.com/
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
RE: Will PHP ever "grow up" and have threading?
am 23.03.2010 03:23:59 von Daevid Vincent
> >>>> Is this a case of "it's too hard"?
>
> Subscribe to internals. Read the archives. The truth is out there.
I have Googled a while on this and don't see much of anything about "PHP
threading" of use. Just a bunch of people desperately wishing for this
feature and trying to hack some way of doing it. Hence my asking here.
>>>> "foo($set_this_parameter=$bar);" bull$hit??! (there is NO
>>> reason NOT to let
>>>
>>>> the developer choose WHICH of the list of parameters they
>>> want to set in a
> There are reasons. You would know this if you had done the legwork
> before opening your mouth and letting crap fall out.
I have researched this. (http://bugs.php.net/bug.php?id=47331) The only
reason I see given for this lack of feature is "it was decided that you can
pass an array parameter instead". This isn't a solution, it's a hack. AND
it only works if you are creating a new function or adding to a function.
It does nothing for existing functions that have many parameters. Why
wouldn't you want to make an already amazing language better and more
flexible. I honestly see zero downside or complication to this. In fact I
am working on a site coded in PHP by Python people, and often find exactly
what I suggest in the code because Python can do this. Ironically it works
by dumb luck b/c PHP ignores the assignment or something and so the
parameters just happened to line up. Even C# can do this.
> >>>> many parameters and you can't overload functions like you
> >>> can in Java or
>
> PHP is NOT Java.
>
> >>>> other typed languages)
>
> Nor is it OTHER types languages.
Uh. Pretty much EVERY other major language has threading. C++, C#, Java,
Ruby, Python and even the archaic Perl.
I KNOW PHP is not Java. That's why I use it. That doesn't take away from
the fact it still needs to have threading to compete as a serious language
if you ever want to do anything more than web pages.
> > You could implement the features yourself.
>
> Damn, Mr McGlone beat me to it :)
That's such a STUPID retort I'm so sick of hearing from the FOSS community.
"build it yourself uh huhh uhhh huhhh". Obviously I'm not a low-level C/C++
coder -- that's WHY I use PHP. :-\ So, you just stay content with the
status quo. I will continue to ask for features to enhance the language.
They may fall on deaf ears, but sometimes... just sometimes... The squeaky
wheel get's the grease.
> When you set the subject line of your rant to something like
> "Will PHP
> ever 'grow up'", I expect your argument to at least be rationale,
> logical, and quite possibly contain a patch. It's called
> "open source"
> because you too can make changes.
It was logical and rational. I gave examples of why threads are needed in
PHP and why it's STILL considered a sub-language by many enterprise level
people, and also why it will NEVER be used for anything more than web pages
until threading is implemented.
By "grow up", I mean exactly that. PHP needs to be considered a contender
and an equal to other enterprise level languages, not this little amateur
language that script kiddies use. While we here may know the power and
virtues of the language, I assure you that most of the world still views it
as a toy language. And spare me your examples of Google or Twitter or some
other large site that uses it. I'm saying, as a whole, it is still viewed
that way by most enterprises. But more importantly, it is IMPOSSIBLE for
PHP to be used in writing daemons or anything of any complexity save web
pages. This is one reason why Python is used for most of your Linux
scripts. Or why Java/C# are used for applications. And honestly, I'd say a
big reason that Rails has taken off even.
You're all getting hung up on my little paragraph rant about the parameter
feature that is desperately missing from PHP too. I'm sorry I threw that
into the mix, I didn't realize it would confuse you all so much from the
main topic.
Clearly you had nothing of value to add to the question(s) and only wished
to chastise me for using harsh words which offended your delicate ears. I'm
sorry, but when a project like PHP is made for the masses to use, and when
many people are asking for useful, sane and reasonable features, and the
internal devs simply dismiss them because they don't feel like implementing
something (or maybe they don't have the skills to), I call bullshit. And
then to hide under the safety net of "well then submit a patch" is just
cowardice. I suspect that even *if* I submitted the perfect patch, that the
internal devs would not put it in the main tree because THEY are
fundamentally against the idea, so it's a Catch22. You need their blessing
either way. As John Acton said, "Power corrupts; absolute power corrupts
absolutely".
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 23.03.2010 03:40:46 von Adam Richardson
--00c09f7f9efba3711704826ebde3
Content-Type: text/plain; charset=ISO-8859-1
On Mon, Mar 22, 2010 at 10:23 PM, Daevid Vincent wrote:
> > >>>> Is this a case of "it's too hard"?
> >
> > Subscribe to internals. Read the archives. The truth is out there.
>
> I have Googled a while on this and don't see much of anything about "PHP
> threading" of use. Just a bunch of people desperately wishing for this
> feature and trying to hack some way of doing it. Hence my asking here.
>
> >>>> "foo($set_this_parameter=$bar);" bull$hit??! (there is NO
> >>> reason NOT to let
> >>>
> >>>> the developer choose WHICH of the list of parameters they
> >>> want to set in a
>
> > There are reasons. You would know this if you had done the legwork
> > before opening your mouth and letting crap fall out.
>
> I have researched this. (http://bugs.php.net/bug.php?id=47331) The only
> reason I see given for this lack of feature is "it was decided that you can
> pass an array parameter instead". This isn't a solution, it's a hack. AND
> it only works if you are creating a new function or adding to a function.
> It does nothing for existing functions that have many parameters. Why
> wouldn't you want to make an already amazing language better and more
> flexible. I honestly see zero downside or complication to this. In fact I
> am working on a site coded in PHP by Python people, and often find exactly
> what I suggest in the code because Python can do this. Ironically it works
> by dumb luck b/c PHP ignores the assignment or something and so the
> parameters just happened to line up. Even C# can do this.
>
> > >>>> many parameters and you can't overload functions like you
> > >>> can in Java or
> >
> > PHP is NOT Java.
> >
> > >>>> other typed languages)
> >
> > Nor is it OTHER types languages.
>
> Uh. Pretty much EVERY other major language has threading. C++, C#, Java,
> Ruby, Python and even the archaic Perl.
>
> I KNOW PHP is not Java. That's why I use it. That doesn't take away from
> the fact it still needs to have threading to compete as a serious language
> if you ever want to do anything more than web pages.
>
> > > You could implement the features yourself.
> >
> > Damn, Mr McGlone beat me to it :)
>
> That's such a STUPID retort I'm so sick of hearing from the FOSS community.
> "build it yourself uh huhh uhhh huhhh". Obviously I'm not a low-level C/C++
> coder -- that's WHY I use PHP. :-\ So, you just stay content with the
> status quo. I will continue to ask for features to enhance the language.
> They may fall on deaf ears, but sometimes... just sometimes... The squeaky
> wheel get's the grease.
>
> > When you set the subject line of your rant to something like
> > "Will PHP
> > ever 'grow up'", I expect your argument to at least be rationale,
> > logical, and quite possibly contain a patch. It's called
> > "open source"
> > because you too can make changes.
>
> It was logical and rational. I gave examples of why threads are needed in
> PHP and why it's STILL considered a sub-language by many enterprise level
> people, and also why it will NEVER be used for anything more than web pages
> until threading is implemented.
>
> By "grow up", I mean exactly that. PHP needs to be considered a contender
> and an equal to other enterprise level languages, not this little amateur
> language that script kiddies use. While we here may know the power and
> virtues of the language, I assure you that most of the world still views it
> as a toy language. And spare me your examples of Google or Twitter or some
> other large site that uses it. I'm saying, as a whole, it is still viewed
> that way by most enterprises. But more importantly, it is IMPOSSIBLE for
> PHP to be used in writing daemons or anything of any complexity save web
> pages. This is one reason why Python is used for most of your Linux
> scripts. Or why Java/C# are used for applications. And honestly, I'd say a
> big reason that Rails has taken off even.
>
> You're all getting hung up on my little paragraph rant about the parameter
> feature that is desperately missing from PHP too. I'm sorry I threw that
> into the mix, I didn't realize it would confuse you all so much from the
> main topic.
>
> Clearly you had nothing of value to add to the question(s) and only wished
> to chastise me for using harsh words which offended your delicate ears. I'm
> sorry, but when a project like PHP is made for the masses to use, and when
> many people are asking for useful, sane and reasonable features, and the
> internal devs simply dismiss them because they don't feel like implementing
> something (or maybe they don't have the skills to), I call bullshit. And
> then to hide under the safety net of "well then submit a patch" is just
> cowardice. I suspect that even *if* I submitted the perfect patch, that the
> internal devs would not put it in the main tree because THEY are
> fundamentally against the idea, so it's a Catch22. You need their blessing
> either way. As John Acton said, "Power corrupts; absolute power corrupts
> absolutely".
>
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>
Hi Deavid,
At this point, I find that when I need threading capabilities, I switch over
to developing with C# or Java most of the time, but it would be nice to stay
in PHP for these tasks (I, too, looked into the pcntl technique and that
just didn't seem like the right way to handle them.)
Yes, your last paragraph was a doozy, and few will accuse you of long-term
political aspirations in any arena ;) However, I will go on record saying
that having threading would be a feature I'd very much appreciate, and I
believe it would strengthen the value proposition of PHP in the
ever-changing world of development.
Adam
--
Nephtali: PHP web framework that functions beautifully
http://nephtaliproject.com
--00c09f7f9efba3711704826ebde3--
Re: Will PHP ever "grow up" and have threading?
am 23.03.2010 04:51:14 von Tommy Pham
On Mon, Mar 22, 2010 at 7:40 PM, Adam Richardson wro=
te:
> On Mon, Mar 22, 2010 at 10:23 PM, Daevid Vincent wrot=
e:
>
>> > >>>> Is this a case of "it's too hard"?
>> >
>> > Subscribe to internals. Read the archives. The truth is out there.
>>
>> I have Googled a while on this and don't see much of anything about "PHP
>> threading" of use. Just a bunch of people desperately wishing for this
>> feature and trying to hack some way of doing it. Hence my asking here.
>>
>> >>>> "foo($set_this_parameter=3D$bar);" bull$hit??! (there is NO
>> >>> reason NOT to let
>> >>>
>> >>>> the developer choose WHICH of the list of parameters they
>> >>> want to set in a
>>
>> > There are reasons. You would know this if you had done the legwork
>> > before opening your mouth and letting crap fall out.
>>
>> I have researched this. (http://bugs.php.net/bug.php?id=3D47331) The onl=
y
>> reason I see given for this lack of feature is "it was decided that you =
can
>> pass an array parameter instead". This isn't a solution, it's a hack. AN=
D
>> it only works if you are creating a new function or adding to a function=
..
>> It does nothing for existing functions that have many parameters. Why
>> wouldn't you want to make an already amazing language better and more
>> flexible. I honestly see zero downside or complication to this. In fact =
I
>> am working on a site coded in PHP by Python people, and often find exact=
ly
>> what I suggest in the code because Python can do this. Ironically it wor=
ks
>> by dumb luck b/c PHP ignores the assignment or something and so the
>> parameters just happened to line up. Even C# can do this.
>>
>> > >>>> many parameters and you can't overload functions like you
>> > >>> can in Java or
>> >
>> > PHP is NOT Java.
>> >
>> > >>>> other typed languages)
>> >
>> > Nor is it OTHER types languages.
>>
>> Uh. Pretty much EVERY other major language has threading. C++, C#, Java,
>> Ruby, Python and even the archaic Perl.
>>
>> I KNOW PHP is not Java. That's why I use it. That doesn't take away from
>> the fact it still needs to have threading to compete as a serious langua=
ge
>> if you ever want to do anything more than web pages.
>>
>> > > You could implement the features yourself.
>> >
>> > Damn, Mr McGlone beat me to it :)
>>
>> That's such a STUPID retort I'm so sick of hearing from the FOSS communi=
ty.
>> "build it yourself uh huhh uhhh huhhh". Obviously I'm not a low-level C/=
C++
>> coder -- that's WHY I use PHP. :-\ So, you just stay content with the
>> status quo. I will continue to ask for features to enhance the language.
>> They may fall on deaf ears, but sometimes... just sometimes... The squea=
ky
>> wheel get's the grease.
>>
>> > When you set the subject line of your rant to something like
>> > "Will PHP
>> > ever 'grow up'", I expect your argument to at least be rationale,
>> > logical, and quite possibly contain a patch. It's called
>> > "open source"
>> > because you too can make changes.
>>
>> It was logical and rational. I gave examples of why threads are needed i=
n
>> PHP and why it's STILL considered a sub-language by many enterprise leve=
l
>> people, and also why it will NEVER be used for anything more than web pa=
ges
>> until threading is implemented.
>>
>> By "grow up", I mean exactly that. PHP needs to be considered a contende=
r
>> and an equal to other enterprise level languages, not this little amateu=
r
>> language that script kiddies use. While we here may know the power and
>> virtues of the language, I assure you that most of the world still views=
it
>> as a toy language. And spare me your examples of Google or Twitter or so=
me
>> other large site that uses it. I'm saying, as a whole, it is still viewe=
d
>> that way by most enterprises. But more importantly, it is IMPOSSIBLE for
>> PHP to be used in writing daemons or anything of any complexity save web
>> pages. This is one reason why Python is used for most of your Linux
>> scripts. Or why Java/C# are used for applications. And honestly, I'd say=
a
>> big reason that Rails has taken off even.
>>
>> You're all getting hung up on my little paragraph rant about the paramet=
er
>> feature that is desperately missing from PHP too. I'm sorry I threw that
>> into the mix, I didn't realize it would confuse you all so much from the
>> main topic.
>>
>> Clearly you had nothing of value to add to the question(s) and only wish=
ed
>> to chastise me for using harsh words which offended your delicate ears. =
I'm
>> sorry, but when a project like PHP is made for the masses to use, and wh=
en
>> many people are asking for useful, sane and reasonable features, and the
>> internal devs simply dismiss them because they don't feel like implement=
ing
>> something (or maybe they don't have the skills to), I call bullshit. And
>> then to hide under the safety net of "well then submit a patch" is just
>> cowardice. I suspect that even *if* I submitted the perfect patch, that =
the
>> internal devs would not put it in the main tree because THEY are
>> fundamentally against the idea, so it's a Catch22. You need their blessi=
ng
>> either way. As John Acton said, "Power corrupts; absolute power corrupts
>> absolutely".
>>
>>
>>
>> --
>> PHP General Mailing List (http://www.php.net/)
>> To unsubscribe, visit: http://www.php.net/unsub.php
>>
>>
> Hi Deavid,
>
> At this point, I find that when I need threading capabilities, I switch o=
ver
> to developing with C# or Java most of the time, but it would be nice to s=
tay
> in PHP for these tasks (I, too, looked into the pcntl technique and that
> just didn't seem like the right way to handle them.)
>
> Yes, your last paragraph was a doozy, and few will accuse you of long-ter=
m
> political aspirations in any arena ;) Â However, I will go on record =
saying
> that having threading would be a feature I'd very much appreciate, and I
> believe it would strengthen the value proposition of PHP in the
> ever-changing world of development.
>
> Adam
>
> --
> Nephtali: Â PHP web framework that functions beautifully
> http://nephtaliproject.com
>
Threading is one of the 2 two main reasons why I moved to Java &
asp.net (C#). I've built a PHP based web crawler about 10 years ago.
I ran into some problems: cookies, form handling and submission,
threading, and application variables. I later found some solutions
for cookies, form handling & submission. But no solution for
threading and application variables. Thus the move. Here's a simple
example of one of the many uses for threading. For an e-commerce
site, when the shopper requests for a category (ID), you can have a
thread to get all subcategories for that category, another thread to
get any assigned products, another thread to fetch all manufacturers
listed under that category, another thread to fetch any filters (price
ranges, features, specs, etc) set by the store owner that would fall
under that category, etc... versus what PHP currently doing now:
fetch subcategories, then fetch assigned products, then fetch
manufacturers, etc.... Performance would increase ten fold because of
parallel (threading) operations versus serial operations. Add that to
application variable (less memory usage and CPU cycles due to
creating/GC of variables that could be used for an entire application
regardless of requests & sessions), you have an excellent tool.
Regards,
Tommy
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 23.03.2010 05:23:52 von Teus Benschop
There can be, and there are, differences between the languages. There
are so many languages out there, and it works like a market place. If
you like the language, use it. It it fails to do what you want, you
switch to another one. There is no need to beg the php developers to
implement anything, as long as you can switch to another language. Teus.
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 23.03.2010 06:01:57 von Larry Garfield
On Monday 22 March 2010 10:51:14 pm Tommy Pham wrote:
> Threading is one of the 2 two main reasons why I moved to Java &
> asp.net (C#). I've built a PHP based web crawler about 10 years ago.
> I ran into some problems: cookies, form handling and submission,
> threading, and application variables. I later found some solutions
> for cookies, form handling & submission. But no solution for
> threading and application variables. Thus the move. Here's a simple
> example of one of the many uses for threading. For an e-commerce
> site, when the shopper requests for a category (ID), you can have a
> thread to get all subcategories for that category, another thread to
> get any assigned products, another thread to fetch all manufacturers
> listed under that category, another thread to fetch any filters (price
> ranges, features, specs, etc) set by the store owner that would fall
> under that category, etc... versus what PHP currently doing now:
> fetch subcategories, then fetch assigned products, then fetch
> manufacturers, etc.... Performance would increase ten fold because of
> parallel (threading) operations versus serial operations. Add that to
> application variable (less memory usage and CPU cycles due to
> creating/GC of variables that could be used for an entire application
> regardless of requests & sessions), you have an excellent tool.
>
> Regards,
> Tommy
Threading is also much more difficult to program for safely, because thread
order is non-deterministic. Do you really want to unleash hoards of
marginally competent programmers on a threaded enviornment? :-)
Also, the architecture you describe above is fine if you're scaling a single
server really big. PHP is designed to scale the other direction: Just add
more servers. There's no data shared from one request to another, so there's
no need to share data between web heads. Throw a load balancer in front of it
and spin up as many web servers as you need.
The "shared nothing" design is very deliberate. It has design trade-offs like
anything else.
PHP is a web-centric language. It's not really intended for building tier-1
daemon processes, just like you'd be an idiot to try and code your entire web
app in C from the start.
--Larry Garfield
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 23.03.2010 06:39:59 von Jochem Maas
Op 3/23/10 12:02 AM, Daevid Vincent schreef:
> I've been using PHP for a decade or so (since PHP/FI) and love it. The one
well they certainly ripped you a new one didn't they :)
why no threads? shared-nothing architecture, that's very deliberate, it has draw
backs as well as advantages, either way you have to understand the reasoning and
how to leverage it. shared-nothing obviously doesn't lend itself to writing fast
daemonized code, then again it wasn't meant to.
I'd say that named function/method parameters would be a nice addition though -
although having said that a decent IDE with code completion (DocBlocks) and well commented,
well structured code mitigate the issue, for me anyway.
>
>
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 23.03.2010 07:26:46 von Rene Veerman
ExecSum:
* +1 for better threading features in PHP.
* overloading = inheritance?
* listreaders plz allow ppl to vent some frustration without
starting a flamewar.
Threading can be implemented in PHP with an
fopen('http://yourserver.com/url')->fread()_all_threads+usle ep(50ms)->fclose()+process
loop.
My own newsscraper threads well like this.
The central script figures out what sites to scrape, and the treaded
subsystem makes sure 1 page per site per N seconds is retrieved.
But i've yet to find a way to keep global objects in memory between
http requests, outside $_SESSION, which i believe is just stored to-
and loaded from disk between http requests.
However, now that i think of it, you could have large pieces of
software stay in memory in a single php script that runs forever and
reads commands (as arrays) out of files (on memory disk?) (put there
by "thread-scripts") and [the "forever running script"] outputs to
stdout, which is caught by the thread-scripts, then passed back to the
thread-caller via fread().
I usually use json for such constructs.
But it's a total hack of course, and i have no idea about performance
issues or even timing bugs. it's "theoretically possible"..
>there is NO reason NOT to let
> the developer choose WHICH of the list of parameters they want to set in a
> function/method call aside from being stubborn! Especially when there are
> many parameters and you can't overload functions like you can in Java
well you could shove all the params in an array, then shove that to
the function called, _or_ a preparatory function that calls the old
function.
as for overloading functions, i think with a bit of cleverness you can
come up with a class / set of functions that simulate overloading of
functions and even inheritance. i for a fact simulate polymorphism
with $functionName_fromPluginX ($params).
i smell all the ingredients that would allow you to overload functions
in php aswell. you'd just have to call things a bit differently,
perhaps like
$var = $overloadingManager->call ('functionName',
'context(object-instance-id)', $param1, $param2).
Better yet; aren't OOP's (and php5's) inheritance features (for
classes) similar to functions overloading? k, it forces you to group
such functions into an object, and derivations into subobjects, but
that's not a show-stopper at all.. You can always ignore the object
boundary and have 1 object-tree for all functions that require
overloading.
& lastly, about the politics of this mail-thread;
imo, it's the ones who "open the counterattack" who start the
flamewar, out of something that is clearly in this case just venting
some frustration with at least partially valid reasons..
imo, it would be wiser to have offered the guy some actual tips and/or
a casual "hey, you could've phrased it friendlier, given the fact that
php costs nothing and all, dude", rather than grabbing the
flamethrower and setting it to vaporize.
On Tue, Mar 23, 2010 at 1:02 AM, Daevid Vincent wrote:
> I've been using PHP for a decade or so (since PHP/FI) and love it. The one
> problem that seems to always keep coming back on enterprise level projects
> is the lack of threading. This always means we have to write some back-end
> code in Ruby or Java or C/C++ and some hacky database layer or DBUS or
> something to communicate with PHP.
>
> Will PHP ever have proper threading? It would sure let the language take
> the next logical leap to writing applications and daemons. I love the idea
> that Rails/Ruby have where you can just load objects in memory once and
> keep using them from page to page (this is NOT the same as a $_SESSION,
> it's way more flexible and powerful).
>
> But more importantly, in one application I'm working on, we need to connect
> to an Asterisk system for the IVR abilities. This means we have Ruby doing
> all that fun stuff and PHP doing the web stuff, but we're also duplicating
> a LOT of work. Both Ruby AND PHP now have to have ORMs for the user who's
> calling in, advertisements served, products shown, etc. We could have used
> Rails for the web portion, but I want to stay with PHP and I'm sure I don't
> have to explain to you PHPers why that is. Without threads, PHP just isn't
> even an option or only one user would be able to call in at a time.
>
> The pcntl stuff is not feasible. It's a hack at best. Spawning multiple
> scripts is also a recipie for disaster.
>
> When will the PHP core-devs (Zend?) realize that PHP is much more than a
> hook to a database. It's much more than web pages.
>
> Is this a case of "it's too hard"? Or is it a case of PHP core developers
> just being douche-bags like they are about the whole
> "foo($set_this_parameter=$bar);" bull$hit??! (there is NO reason NOT to let
> the developer choose WHICH of the list of parameters they want to set in a
> function/method call aside from being stubborn! Especially when there are
> many parameters and you can't overload functions like you can in Java or
> other typed languages)
>
> As usual, I created a poll here too:
> http://www.rapidpoll.net/awp1ocy
>
> Past polls are below:
> http://www.rapidpoll.net/8opnt1e
> http://www.rapidpoll.net/arc1opy (although someone hacked this poll and
> loaded up the 76 votes like a little cheater)
>
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 23.03.2010 08:35:41 von Tommy Pham
On Mon, Mar 22, 2010 at 10:01 PM, Larry Garfield w=
rote:
> On Monday 22 March 2010 10:51:14 pm Tommy Pham wrote:
>> Threading is one of the 2 two main reasons why I moved to Java &
>> asp.net (C#). Â I've built a PHP based web crawler about 10 years ag=
o.
>> I ran into some problems: cookies, form handling and submission,
>> threading, and application variables. Â I later found some solutions
>> for cookies, form handling & submission. Â But no solution for
>> threading and application variables. Â Thus the move. Â Here's a=
simple
>> example of one of the many uses for threading. Â For an e-commerce
>> site, Â when the shopper requests for a category (ID), you can have =
a
>> thread to get all subcategories for that category, another thread to
>> get any assigned products, Â another thread to fetch all manufacture=
rs
>> listed under that category, another thread to fetch any filters (price
>> ranges, features, specs, etc) set by the store owner that would fall
>> under that category, etc... Â versus what PHP currently doing now:
>> fetch subcategories, then fetch assigned products, then fetch
>> manufacturers, etc.... Â Performance would increase ten fold because=
of
>> parallel (threading) operations versus serial operations. Â Add that=
to
>> application variable (less memory usage and CPU cycles due to
>> creating/GC of variables that could be used for an entire application
>> regardless of requests & sessions), you have an excellent tool.
>>
>> Regards,
>> Tommy
>
> Threading is also much more difficult to program for safely, because thre=
ad
> order is non-deterministic. Â Do you really want to unleash hoards of
> marginally competent programmers on a threaded enviornment? :-)
Marginally competent? I think some, if not many, on this list will
disagree with that ;)
>
> Also, the architecture you describe above is fine if you're scaling a sin=
gle
> server really big. Â PHP is designed to scale the other direction: Ju=
st add
> more servers. Â There's no data shared from one request to another, s=
o there's
> no need to share data between web heads. Â Throw a load balancer in f=
ront of it
> and spin up as many web servers as you need.
Load balancer is used when the server is overloaded with requests and
upgrade has reached it's limit. That's not the same thing as a simple
request where multiple answers are needed as in my example. If you're
thinking of implementing something like my example across multiple
servers (where each server will fetch an answer for a simple request)
via another method, then you're going to face similar issues as
threading ie session/request sync which is equivalent to thread
safety/sync/deadlock but now it's worse because it's spread across
network where performance issues comes in because internal system IO >
(network IO + internal system IO).
>
> The "shared nothing" design is very deliberate. Â It has design trade=
-offs like
> anything else.
>
> PHP is a web-centric language. Â It's not really intended for buildin=
g tier-1
> daemon processes, just like you'd be an idiot to try and code your entire=
web
> app in C from the start.
Of course since C was engineered to create OSes and (text based) apps
when SMP/MC is unheard of. But we're now in the digital era where
SMP/MC is very common place. In fact, trying to buy a new
desktop/laptop now without a multicore becomes very difficult and
undesired. Why not make use of the SMP/MC? :) PHP seems strive and
somewhat 'imitate' languages like java & asp.net. Not trying to go
off topice but for example: namespace (namespace in asp.net and
packages in java). For many of us that don't use namespace now or
even when it's not yet implemented, we (PHP web app dev) already
implement our own version of it - subfolders. So why not copy or
imitate the features that would be more beneficial if not more
usability ie threading? PHP is already ahead of java & asp.net in
terms of generics, not strong typed.
Regards,
Tommy
>
> --Larry Garfield
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 23.03.2010 09:31:31 von Tommy Pham
Here's another analogy. For those of us in the field long enough, we
see the power of AJAX and we use it in one form or another. For the
newbies, they have yet to see it's power nor the requirements to
implement it. Threading is similar to that. It's not for everybody.
But for those of us that are ready and have need for it, we can
implement it IF IT'S THERE, which is the point of OP, although the way
he put it isn't exactly welcoming... perhaps he had a very long week
and it's just starting too.
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 23.03.2010 10:04:02 von Per Jessen
Daevid Vincent wrote:
> I've been using PHP for a decade or so (since PHP/FI) and love it. Th=
e
> one problem that seems to always keep coming back on enterprise level=
> projects is the lack of threading. This always means we have to write=
> some back-end code in Ruby or Java or C/C++ and some hacky database
> layer or DBUS or something to communicate with PHP.
Use the right tool for the right job - PHP is a scripting/interpreted
language, it does not need threading (IMO of course).
--=20
Per Jessen, Zürich (9.4°C)
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 23.03.2010 10:42:36 von jose javier parra sanchez
Maybe that's what you are looking for : http://nanoserv.si.kz/
Not done with threads, but who cares ?
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 23.03.2010 11:56:48 von Rene Veerman
hmm i use scripted languages because i prefer and they allow/force
simple-to-read-code.
but that does not mean a scripted language can't evolve to expose
"complicated" code constructs like multi-threading and daemon-building
in a simple manner too.
i'd prefer it if a language like PHP can be used for other things
besides webserving too.
i also think at least some web-apps could benefit from multi-threading
and daemon-building.. particularly web-apps that deal with real-time
dataflows.
and btw, the distinction between compiled and scripted is not a hard
one anymore eh.. not with zend and that facebook php-compiler out
there.
On Tue, Mar 23, 2010 at 10:04 AM, Per Jessen wrote:
> Daevid Vincent wrote:
>
>> I've been using PHP for a decade or so (since PHP/FI) and love it. The
>> one problem that seems to always keep coming back on enterprise level
>> projects is the lack of threading. This always means we have to write
>> some back-end code in Ruby or Java or C/C++ and some hacky database
>> layer or DBUS or something to communicate with PHP.
>
> Use the right tool for the right job - PHP is a scripting/interpreted
> language, it does not need threading (IMO of course).
>
>
> --
> Per Jessen, Zürich (9.4°C)
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 23.03.2010 12:36:09 von David McGlone
> > > You could implement the features yourself.
> >
> > Damn, Mr McGlone beat me to it :)
>
> That's such a STUPID retort I'm so sick of hearing from the FOSS community.
> "build it yourself uh huhh uhhh huhhh". Obviously I'm not a low-level C/C++
> coder -- that's WHY I use PHP. :-\ So, you just stay content with the
> status quo. I will continue to ask for features to enhance the language.
> They may fall on deaf ears, but sometimes... just sometimes... The squeaky
> wheel get's the grease.
I didn't intend for my reply to sound nasty. After reading your OP, I see that
you are a very experienced programmer and I meant for it as a suggestion.
--
Blessings
David M.
I have been driven to my knees many times by the overwhelming conviction that
I had nowhere else to go.
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 23.03.2010 12:53:25 von Richard Quadling
On 23 March 2010 00:02, Daevid Vincent wrote:
> douche-bags
I think this is about the best way to get the wrong attention.
Not everyone has a sense of humour like yours.
Maybe no one has a sense of humour like yours.
Good luck.
Richard.
--
-----
Richard Quadling
"Standing on the shoulders of some very clever giants!"
EE : http://www.experts-exchange.com/M_248814.html
EE4Free : http://www.experts-exchange.com/becomeAnExpert.jsp
Zend Certified Engineer : http://zend.com/zce.php?c=ZEND002498&r=213474731
ZOPA : http://uk.zopa.com/member/RQuadling
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 23.03.2010 14:39:55 von Michael Peters
Rene Veerman wrote:
>
> But i've yet to find a way to keep global objects in memory between
> http requests, outside $_SESSION, which i believe is just stored to-
> and loaded from disk between http requests.
You can store sessions in a cache and avoid the disk IO.
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 23.03.2010 23:15:56 von Tommy Pham
On Tue, Mar 23, 2010 at 2:04 AM, Per Jessen wrote:
>
> Use the right tool for the right job - PHP is a scripting/interpreted
> language, it does not need threading (IMO of course).
>
>
> --
> Per Jessen, Zürich (9.4°C)
>
>
I couldn't agree more. But here's a real life example. Your client
has a forum and is using phpbb for their in house use. They also have
an in house custom PHP app, integrated with phpbb, built to suit their
needs. Now they want to implement some kind of CMS. You come in and
implemented a PHP based CMS to integrate into their existing
applications. Then you realize something troublesome, you have a
performance issue where it could be resolved by implementing thread.
What are you going to do? Are you going to say to the client "We seem
to have a problem. I suggest we migrate to Java or ASP.Net because
threading will resolve the performance issue." Or are you going to
spend who knows how long to try find a hack to resolve the issue?
What do you think the client's response is when their need for the
solution requires a short time frame of, if not immediate,
implementation?
Regards,
Tommy
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 23.03.2010 23:33:39 von Per Jessen
Tommy Pham wrote:
> On Tue, Mar 23, 2010 at 2:04 AM, Per Jessen wrote:=
>>
>> Use the right tool for the right job - PHP is a scripting/interprete=
d
>> language, it does not need threading (IMO of course).
>>
>>
>> --
>> Per Jessen, Zürich (9.4°C)
>>
>>
>=20
> I couldn't agree more. But here's a real life example. Your client
> has a forum and is using phpbb for their in house use. They also hav=
e
> an in house custom PHP app, integrated with phpbb, built to suit thei=
r
> needs. Now they want to implement some kind of CMS. You come in and=
> implemented a PHP based CMS to integrate into their existing
> applications. Then you realize something troublesome, you have a
> performance issue where it could be resolved by implementing thread.
> What are you going to do?=20
The standard, mature, experienced answer is - buy a bigger box.=20
[snip]
> What do you think the client's response is when their need for the
> solution requires a short time frame of, if not immediate,
> implementation?
There are no immediate solutions to immediate performance problems. If=
you have a poor design that restricts your throughput, you can 1) throw=
hardware at it or 2) change the design. At some point you'll hit yet
another limit with 1), and you are forced back to 2). Somewhere along
the line the original designer has presumably left or been made to.=20
/Per
--=20
Per Jessen, Zürich (7.5°C)
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 00:04:42 von Tommy Pham
On Tue, Mar 23, 2010 at 3:33 PM, Per Jessen wrote:
> Tommy Pham wrote:
>
>> On Tue, Mar 23, 2010 at 2:04 AM, Per Jessen wrote:
>>>
>>> Use the right tool for the right job - PHP is a scripting/interpreted
>>> language, it does not need threading (IMO of course).
>>>
>>>
>>> --
>>> Per Jessen, Zürich (9.4°C)
>>>
>>>
>>
>> I couldn't agree more. Â But here's a real life example. Â Your =
client
>> has a forum and is using phpbb for their in house use. Â They also h=
ave
>> an in house custom PHP app, integrated with phpbb, built to suit their
>> needs. Â Now they want to implement some kind of CMS. Â You come=
in and
>> implemented a PHP based CMS to integrate into their existing
>> applications. Â Then you realize something troublesome, you have a
>> performance issue where it could be resolved by implementing thread.
>> What are you going to do?
>
> The standard, mature, experienced answer is - buy a bigger box.
>
The company started small. As their business grows because they have
products & services that do not exist in the marketplace, their
hardware are already growing along side with it, (load balancers,
clusters). So then your solution is buy bigger/more boxes? What if
the their server room is filled and already using recent hardware.
Their current business needs doesn't need to move to a bigger
building. What then? Hire data center's services? What if they want
to protect their proprietary break through products and services?
What about unnecessary additional total cost of ownership (licenses,
power consumption, etc...) for more/bigger boxes, even if they have
available space, that could be avoided by just implementing threads?
> [snip]
>> What do you think the client's response is when their need for the
>> solution requires a short time frame of, if not immediate,
>> implementation?
>
> There are no immediate solutions to immediate performance problems. =C2=
=A0If
> you have a poor design that restricts your throughput, you can 1) throw
> hardware at it or 2) change the design. Â At some point you'll hit ye=
t
> another limit with 1), and you are forced back to 2). Â Somewhere alo=
ng
> the line the original designer has presumably left or been made to.
>
>
> /Per
>
> --
> Per Jessen, Zürich (7.5°C)
>
If throwing hardware at it won't work because of the above mentioned,
then you would change the design right? How long would that take?
What if PHP has threads, how long would it take you implement threads
with minor changes versus and overhaul of application design, coding,
QA, etc... In summary, you're saying that PHP can not grow/evolve with
business right? If the company started small and want to use
available open source solutions, then grow quickly because of their
unique and quality products and services, and become enterprise level
with-in a few years, what then? Slow down business growth just so
that IT can migrate everything to another language? Of all the
enterprise applications I've seen, they used threads.
Regards,
Tommy
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 00:25:46 von Larry Garfield
On 3/23/10 6:04 PM, Tommy Pham wrote:
> If throwing hardware at it won't work because of the above mentioned,
> then you would change the design right? How long would that take?
> What if PHP has threads, how long would it take you implement threads
> with minor changes versus and overhaul of application design, coding,
> QA, etc... In summary, you're saying that PHP can not grow/evolve with
> business right? If the company started small and want to use
> available open source solutions, then grow quickly because of their
> unique and quality products and services, and become enterprise level
> with-in a few years, what then? Slow down business growth just so
> that IT can migrate everything to another language? Of all the
> enterprise applications I've seen, they used threads.
>
> Regards,
> Tommy
The word "enterprise" is meaningless in this context because it provides
no context for the distinction. What does "enterprise" mean? Gets
Captain Kirk to his next date? Is OpenOffice.org's plugin download site
enterprise? Is Sony BMG enterprise? The sites for the cities of London
and Athens? Whitehouse.gov?
That's just a couple of sites now running on Drupal, a particular
single-threaded PHP application. That's not counting the thousands of
similar organizations running PHP (not even PHP-wrapping-custom-C like
Yahoo) applications of various and sundry kinds. (Wikipedia anyone?)
PHP *is* in the enterprise and quite happy there.
"Not ready for the enterprise" is a totally meaningless statement.
Similarly, if you cannot think of any way to scale an application that
doesn't involve threads then I question your competence as a programmer.
Sure, threads can be one way to speed things up. There are lots and
lots of others that may be more or less appropriate depending on the
circumstances. Threads have their own scaling issues, namely they have
to live within the same process on the same box. That means when you
hit the maximum size of your server, you're done. That doesn't mean
threads are bad, but they have their trade-offs just like everything
else does.
But let's consider what adding threads to PHP would take. That would
mean making PHP a shared-memory architecture, so that different requests
now operated in the same memory space. That means RAM-based
persistence. That means needing to write thread-safe PHP libraries.
(Not the ones in C; I mean the millions of lines of code of PHP already
out there.)
In short, adding threading support to PHP means PHP is no longer PHP.
It's Java with dollarsigns. It's a complete and total rewrite of the
entire language runtime and environment, and all of the code build atop it.
The idea that you could "just add threads" to PHP and make it
"enterprise-ready" is so naive it's mind boggling.
--Larry Garfield
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 00:30:16 von ahlin.hans
2010/3/24 Tommy Pham :
> On Tue, Mar 23, 2010 at 3:33 PM, Per Jessen wrote:
>> Tommy Pham wrote:
>>
>>> On Tue, Mar 23, 2010 at 2:04 AM, Per Jessen wrote:
>>>>
>>>> Use the right tool for the right job - PHP is a scripting/interpreted
>>>> language, it does not need threading (IMO of course).
>>>>
>>>>
>>>> --
>>>> Per Jessen, Zürich (9.4°C)
>>>>
>>>>
>>>
>>> I couldn't agree more. Â But here's a real life example. Â Your=
client
>>> has a forum and is using phpbb for their in house use. Â They also =
have
>>> an in house custom PHP app, integrated with phpbb, built to suit their
>>> needs. Â Now they want to implement some kind of CMS. Â You com=
e in and
>>> implemented a PHP based CMS to integrate into their existing
>>> applications. Â Then you realize something troublesome, you have a
>>> performance issue where it could be resolved by implementing thread.
>>> What are you going to do?
>>
>> The standard, mature, experienced answer is - buy a bigger box.
>>
>
> The company started small. Â As their business grows because they hav=
e
> products & services that do not exist in the marketplace, their
> hardware are already growing along side with it, (load balancers,
> clusters). Â So then your solution is buy bigger/more boxes? Â Wh=
at if
> the their server room is filled and already using recent hardware.
> Their current business needs doesn't need to move to a bigger
> building. Â What then? Hire data center's services? Â What if the=
y want
> to protect their proprietary break through products and services?
> What about unnecessary additional total cost of ownership (licenses,
> power consumption, etc...) for more/bigger boxes, even if they have
> available space, that could be avoided by just implementing threads?
>
That screams poor code design. Then to solve the problem might not be
threading or change of language but a reanalyze of the code and the
design, probably a re-write.
>> [snip]
>>> What do you think the client's response is when their need for the
>>> solution requires a short time frame of, if not immediate,
>>> implementation?
>>
>> There are no immediate solutions to immediate performance problems. =C2=
=A0If
>> you have a poor design that restricts your throughput, you can 1) throw
>> hardware at it or 2) change the design. Â At some point you'll hit y=
et
>> another limit with 1), and you are forced back to 2). Â Somewhere al=
ong
>> the line the original designer has presumably left or been made to.
>>
>>
>> /Per
>>
>> --
>> Per Jessen, Zürich (7.5°C)
>>
>
> If throwing hardware at it won't work because of the above mentioned,
> then you would change the design right? Â How long would that take?
> What if PHP has threads, how long would it take you implement threads
> with minor changes versus and overhaul of application design, coding,
> QA, etc... In summary, you're saying that PHP can not grow/evolve with
> business right? Â If the company started small and want to use
> available open source solutions, then grow quickly because of their
> unique and quality products and services, and become enterprise level
> with-in a few years, what then? Â Slow down business growth just so
> that IT can migrate everything to another language? Of all the
> enterprise applications I've seen, they used threads.
>
Same answer as above.
> Regards,
> Tommy
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>
--=20
MvH / Hans Ã
hlin
Tel: +46761488019
http//www.kronan-net.com/
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 01:31:03 von Michael Peters
Tommy Pham wrote:
> On Tue, Mar 23, 2010 at 3:33 PM, Per Jessen wrote:
>> Tommy Pham wrote:
>>
>>> On Tue, Mar 23, 2010 at 2:04 AM, Per Jessen wrote:
>>>> Use the right tool for the right job - PHP is a scripting/interpreted
>>>> language, it does not need threading (IMO of course).
>>>>
>>>>
>>>> --
>>>> Per Jessen, Zürich (9.4°C)
>>>>
>>>>
>>> I couldn't agree more. But here's a real life example. Your client
>>> has a forum and is using phpbb for their in house use. They also have
>>> an in house custom PHP app, integrated with phpbb, built to suit their
>>> needs. Now they want to implement some kind of CMS. You come in and
>>> implemented a PHP based CMS to integrate into their existing
>>> applications. Then you realize something troublesome, you have a
>>> performance issue where it could be resolved by implementing thread.
>>> What are you going to do?
>> The standard, mature, experienced answer is - buy a bigger box.
>>
>
> The company started small. As their business grows because they have
> products & services that do not exist in the marketplace, their
> hardware are already growing along side with it, (load balancers,
> clusters). So then your solution is buy bigger/more boxes? What if
> the their server room is filled and already using recent hardware.
> Their current business needs doesn't need to move to a bigger
> building. What then? Hire data center's services?
Very few companies have a legitimate reason to run their own server room
at this point in time and should be using a data center if they are not
already.
Data centers have excellent bandwidth, diesel generators to keep things
live during sustained power outages, temperature control to keep things
cool, and often have technicians on hand with spare parts that can take
care of many hardware issues 24/7.
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 02:17:56 von Tommy Pham
Let's go back to my 1st e-commerce example. The manufacturers list is
about 3,700. The categories is about about 2,400. The products list
is right now at 500,000 and expected to be around 750,000. The site
is only in English. The store owner wants to expand and be I18n:
Chinese, French, German, Korean, Spanish. You see how big and complex
that database gets? The store owners want to have this happens when a
customer clicks on a category:
* show all subcategories for that category, if any
* show all products for that category, if any,
* show all manufacturers, used as filtering, for that category and subcategories
* show price range filter for that category
* show features & specifications filter for that category
* show 10 top sellers for that category and related subcategories
* the shopper can then select/deselect any of those filters and
ability to sort by manufacturers, prices, user rating, popularity
(purchased quantity)
* have the ability to switch to another language translation on the fly
* from the moment the shopper click on a link, the response time (when
web browser saids "Done" in the status bar) is 5 seconds or less.
Preferably 2-3 seconds. Will be using stopwatch for the timer.
Now show me a website that meets those requirements and uses PHP, I'll
be glad to support your argument about PHP w/o threads :) BTW, this
is not even enterprise requirement. I may have another possible
project where # products is over 10 million easily. With similar
requirements when the user click on category. Do you think this site,
which currently isn't, can run on PHP?
Regards,
Tommy
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 02:44:56 von Tommy Pham
On Tue, Mar 23, 2010 at 6:17 PM, Tommy Pham wrote:
> Let's go back to my 1st e-commerce example. Â The manufacturers list =
is
> about 3,700. Â The categories is about about 2,400. Â The product=
s list
> is right now at 500,000 and expected to be around 750,000. Â The site
> is only in English. Â The store owner wants to expand and be I18n:
> Chinese, French, German, Korean, Spanish. Â You see how big and compl=
ex
> that database gets? Â The store owners want to have this happens when=
a
> customer clicks on a category:
>
> * show all subcategories for that category, if any
> * show all products for that category, if any,
> * show all manufacturers, used as filtering, for that category and subcat=
egories
> * show price range filter for that category
> * show features & specifications filter for that category
> * show 10 top sellers for that category and related subcategories
forgot to mention:
* show 10 random sale specials for that category and subcategories
> * the shopper can then select/deselect any of those filters and
> ability to sort by manufacturers, prices, user rating, popularity
> (purchased quantity)
> * have the ability to switch to another language translation on the fly
> * from the moment the shopper click on a link, the response time (when
> web browser saids "Done" in the status bar) is 5 seconds or less.
> Preferably 2-3 seconds. Will be using stopwatch for the timer.
>
> Now show me a website that meets those requirements and uses PHP, I'll
> be glad to support your argument about PHP w/o threads :) Â BTW, this
> is not even enterprise requirement. Â I may have another possible
> project where # products is over 10 million easily. Â With similar
> requirements when the user click on category. Â Do you think this sit=
e,
> which currently isn't, can run on PHP?
>
> Regards,
> Tommy
>
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 02:47:06 von Robert Cummings
Tommy Pham wrote:
> Let's go back to my 1st e-commerce example. The manufacturers list is
> about 3,700. The categories is about about 2,400. The products list
> is right now at 500,000 and expected to be around 750,000. The site
> is only in English. The store owner wants to expand and be I18n:
> Chinese, French, German, Korean, Spanish. You see how big and complex
> that database gets? The store owners want to have this happens when a
> customer clicks on a category:
>
> * show all subcategories for that category, if any
> * show all products for that category, if any,
> * show all manufacturers, used as filtering, for that category and subcategories
> * show price range filter for that category
> * show features & specifications filter for that category
> * show 10 top sellers for that category and related subcategories
> * the shopper can then select/deselect any of those filters and
> ability to sort by manufacturers, prices, user rating, popularity
> (purchased quantity)
> * have the ability to switch to another language translation on the fly
> * from the moment the shopper click on a link, the response time (when
> web browser saids "Done" in the status bar) is 5 seconds or less.
> Preferably 2-3 seconds. Will be using stopwatch for the timer.
>
> Now show me a website that meets those requirements and uses PHP, I'll
> be glad to support your argument about PHP w/o threads :) BTW, this
I don't currently know a site, sounds like a fun job though.
> is not even enterprise requirement. I may have another possible
> project where # products is over 10 million easily. With similar
> requirements when the user click on category. Do you think this site,
> which currently isn't, can run on PHP?
Yes, I do. There's nothing in your requirements above that sound
particularly difficult for PHP to handle with a good design and lots of
caching... and of course the right hardware. I think you're hung up on
the numbers a bit... those aren't very big numbers for a database.
Cheers,
Rob.
--
http://www.interjinn.com
Application and Templating Framework for PHP
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 02:57:18 von Paul M Foster
On Tue, Mar 23, 2010 at 06:17:56PM -0700, Tommy Pham wrote:
> Let's go back to my 1st e-commerce example. The manufacturers list is
> about 3,700. The categories is about about 2,400. The products list
> is right now at 500,000 and expected to be around 750,000. The site
> is only in English. The store owner wants to expand and be I18n:
> Chinese, French, German, Korean, Spanish. You see how big and complex
> that database gets? The store owners want to have this happens when a
> customer clicks on a category:
>
> * show all subcategories for that category, if any
> * show all products for that category, if any,
> * show all manufacturers, used as filtering, for that category and
> subcategories
> * show price range filter for that category
> * show features & specifications filter for that category
> * show 10 top sellers for that category and related subcategories
> * the shopper can then select/deselect any of those filters and
> ability to sort by manufacturers, prices, user rating, popularity
> (purchased quantity)
> * have the ability to switch to another language translation on the fly
> * from the moment the shopper click on a link, the response time (when
> web browser saids "Done" in the status bar) is 5 seconds or less.
> Preferably 2-3 seconds. Will be using stopwatch for the timer.
>
> Now show me a website that meets those requirements and uses PHP, I'll
> be glad to support your argument about PHP w/o threads :) BTW, this
> is not even enterprise requirement. I may have another possible
> project where # products is over 10 million easily. With similar
> requirements when the user click on category. Do you think this site,
> which currently isn't, can run on PHP?
That strikes me as a pretty stiff target, no matter how you look at it.
You effectively want 6 major queries at once, plus response in under 3
seconds on a 750000 row product table. I'm not sure I could produce that
kind of performance in C at the command line. (I'm sure some smart guy
on the list will say he can do it in 2 seconds flat over a 10 Base 2
network with teletypes and acoustic modems.)
Which brings me to my question. Why do people expect console-level
performance from a web browser? It's kind of rhetorical, since people
want everything they can get and more all the time. But if performance
came up as a customer question for me, I'd make it clear that they're
not going to get console-level performance from a web browser, unless
they want to spend a whole lot more money. Neither the world wide web
nor browser software were ever designed primarily with speed in mind.
The internet is not your local 64-bit 10 gigabyte memory loaded machine.
Paul
--
Paul M. Foster
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 03:08:36 von Tommy Pham
On Tue, Mar 23, 2010 at 6:57 PM, Paul M Foster wr=
ote:
> On Tue, Mar 23, 2010 at 06:17:56PM -0700, Tommy Pham wrote:
>
>> Let's go back to my 1st e-commerce example. Â The manufacturers list=
is
>> about 3,700. Â The categories is about about 2,400. Â The produc=
ts list
>> is right now at 500,000 and expected to be around 750,000. Â The sit=
e
>> is only in English. Â The store owner wants to expand and be I18n:
>> Chinese, French, German, Korean, Spanish. Â You see how big and comp=
lex
>> that database gets? Â The store owners want to have this happens whe=
n a
>> customer clicks on a category:
>>
>> * show all subcategories for that category, if any
>> * show all products for that category, if any,
>> * show all manufacturers, used as filtering, for that category and
>> subcategories
>> * show price range filter for that category
>> * show features & specifications filter for that category
>> * show 10 top sellers for that category and related subcategories
>> * the shopper can then select/deselect any of those filters and
>> ability to sort by manufacturers, prices, user rating, popularity
>> (purchased quantity)
>> * have the ability to switch to another language translation on the fly
>> * from the moment the shopper click on a link, the response time (when
>> web browser saids "Done" in the status bar) is 5 seconds or less.
>> Preferably 2-3 seconds. Will be using stopwatch for the timer.
>>
>> Now show me a website that meets those requirements and uses PHP, I'll
>> be glad to support your argument about PHP w/o threads :) Â BTW, thi=
s
>> is not even enterprise requirement. Â I may have another possible
>> project where # products is over 10 million easily. Â With similar
>> requirements when the user click on category. Â Do you think this si=
te,
>> which currently isn't, can run on PHP?
>
> That strikes me as a pretty stiff target, no matter how you look at it.
> You effectively want 6 major queries at once, plus response in under 3
> seconds on a 750000 row product table. I'm not sure I could produce that
> kind of performance in C at the command line. (I'm sure some smart guy
> on the list will say he can do it in 2 seconds flat over a 10 Base 2
> network with teletypes and acoustic modems.)
>
> Which brings me to my question. Why do people expect console-level
> performance from a web browser? It's kind of rhetorical, since people
> want everything they can get and more all the time. But if performance
> came up as a customer question for me, I'd make it clear that they're
> not going to get console-level performance from a web browser, unless
> they want to spend a whole lot more money. Neither the world wide web
> nor browser software were ever designed primarily with speed in mind.
> The internet is not your local 64-bit 10 gigabyte memory loaded machine.
>
> Paul
>
> --
> Paul M. Foster
>
The response time, max 5 seconds, will be tested on local gigabit LAN
to ensure the adequate response (optimized DB & code & proper
hardware) without worrying about users' connection limit and site's
upload bandwidth limit (which can easily rectify). Then thereafter
will be doing stress test of about 10 concurrent users. As for the
major queries, that's where threads come in, IMO, because those
queries depend on 1 primary parameter (category ID) and 1 secondary
parameter (language ID). This particular site starts with 500
products about 15 categories, without many of those mentioned filters,
later grew to its current state.
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 03:27:41 von Robert Cummings
Paul M Foster wrote:
> On Tue, Mar 23, 2010 at 06:17:56PM -0700, Tommy Pham wrote:
>
>> Let's go back to my 1st e-commerce example. The manufacturers list is
>> about 3,700. The categories is about about 2,400. The products list
>> is right now at 500,000 and expected to be around 750,000. The site
>> is only in English. The store owner wants to expand and be I18n:
>> Chinese, French, German, Korean, Spanish. You see how big and complex
>> that database gets? The store owners want to have this happens when a
>> customer clicks on a category:
>>
>> * show all subcategories for that category, if any
>> * show all products for that category, if any,
>> * show all manufacturers, used as filtering, for that category and
>> subcategories
>> * show price range filter for that category
>> * show features & specifications filter for that category
>> * show 10 top sellers for that category and related subcategories
>> * the shopper can then select/deselect any of those filters and
>> ability to sort by manufacturers, prices, user rating, popularity
>> (purchased quantity)
>> * have the ability to switch to another language translation on the fly
>> * from the moment the shopper click on a link, the response time (when
>> web browser saids "Done" in the status bar) is 5 seconds or less.
>> Preferably 2-3 seconds. Will be using stopwatch for the timer.
>>
>> Now show me a website that meets those requirements and uses PHP, I'll
>> be glad to support your argument about PHP w/o threads :) BTW, this
>> is not even enterprise requirement. I may have another possible
>> project where # products is over 10 million easily. With similar
>> requirements when the user click on category. Do you think this site,
>> which currently isn't, can run on PHP?
>
> That strikes me as a pretty stiff target, no matter how you look at it.
> You effectively want 6 major queries at once, plus response in under 3
> seconds on a 750000 row product table. I'm not sure I could produce that
> kind of performance in C at the command line. (I'm sure some smart guy
> on the list will say he can do it in 2 seconds flat over a 10 Base 2
> network with teletypes and acoustic modems.)
I'm not sure why you consider this 6 major queries. To show all
sub-categories for a category is a major query only if you need to
recursively gather sub-categories. Admittedly that would be a slow hit
to the database server on first request, but afterwards one would expect
the tree to be cached so the next request would be very fast due to
priming of the cache.
Show all products for a category should be quite fast, the category
would be associated with an integer ID upon which I would presume
indexing has occured. Presumably "show all" means show all products in a
paged manner. The same principles should show true for manufacturer.
Price range also plays nicely with indexes. Features and specifications
may be a biut of a hump, but it depends. It's hard to say exactly what
is meant by this filter.
The top 10 sellers might be an issue, but I don't see why a cron job
can't handle updating top sellers information so that this is an
indexable field.
I'm not sure why language translation would be an issue. Presumably if
you have support for one, switching to another requires the same legwork
with different pants.
Also, it's notable that all of the search data is based on need to read
only. This screams replication to me if the server is very busy.
The big thing about indexes is that the more rows you add, the time to
retrieve a particular indexed row only grows logarithmically.
Cheers,
Rob.
--
http://www.interjinn.com
Application and Templating Framework for PHP
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 04:53:06 von daniel.brown
--00163646bd9a2aefb3048283de7b
Content-Type: text/plain; charset=ISO-8859-1
First of all, I'll apologize for the top-post. My DROID doesn't give me the
option of top or bottom. So not ready for enterprise.
Secondly, I'll append to the statements made by Larry that, unless it's
non-web based, there are far more layers involved before, during, and after
PHP's execution. Threading is fantastic.... if you're not relying on several
other components (which are likely non-threaded themselves).
On Mar 23, 2010 7:27 PM, "larry@garfieldtech.com"
wrote:
On 3/23/10 6:04 PM, Tommy Pham wrote:
> If throwing hardware at it won't work because of the above ...
The word "enterprise" is meaningless in this context because it provides no
context for the distinction. What does "enterprise" mean? Gets Captain
Kirk to his next date? Is OpenOffice.org's plugin download site enterprise?
Is Sony BMG enterprise? The sites for the cities of London and Athens?
Whitehouse.gov?
That's just a couple of sites now running on Drupal, a particular
single-threaded PHP application. That's not counting the thousands of
similar organizations running PHP (not even PHP-wrapping-custom-C like
Yahoo) applications of various and sundry kinds. (Wikipedia anyone?) PHP
*is* in the enterprise and quite happy there.
"Not ready for the enterprise" is a totally meaningless statement.
Similarly, if you cannot think of any way to scale an application that
doesn't involve threads then I question your competence as a programmer.
Sure, threads can be one way to speed things up. There are lots and lots
of others that may be more or less appropriate depending on the
circumstances. Threads have their own scaling issues, namely they have to
live within the same process on the same box. That means when you hit the
maximum size of your server, you're done. That doesn't mean threads are
bad, but they have their trade-offs just like everything else does.
But let's consider what adding threads to PHP would take. That would mean
making PHP a shared-memory architecture, so that different requests now
operated in the same memory space. That means RAM-based persistence. That
means needing to write thread-safe PHP libraries. (Not the ones in C; I mean
the millions of lines of code of PHP already out there.)
In short, adding threading support to PHP means PHP is no longer PHP. It's
Java with dollarsigns. It's a complete and total rewrite of the entire
language runtime and environment, and all of the code build atop it.
The idea that you could "just add threads" to PHP and make it
"enterprise-ready" is so naive it's mind boggling.
--Larry Garfield
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub...
--00163646bd9a2aefb3048283de7b--
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 05:06:18 von Teus Benschop
When looking at PHP as used in enterprise class applications, we can see
the following happening. Let imagine that we have a site that gets a
1000 requests per second. That seems to be a good candidate for
threading so as to be able to handle the 1000 requests per second. The
site runs PHP and Apache. Well, what happens? Each request coming in is
handed of to a separate instance of Apache. Thus the site would be able
to process many requests simultaneously. It looks as if parallel
computing is taking place here, which looks much like threading. Even
though PHP itself does not know about threads, and does not need to, I
think, the whole process of handling the 1000 requests per second uses
parallel computing. There are no performance bottle-necks here. Teus.
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 05:11:32 von Teus Benschop
On Tue, 2010-03-23 at 19:08 -0700, Tommy Pham wrote:
> The response time, max 5 seconds, will be tested on local gigabit LAN
> to ensure the adequate response (optimized DB & code & proper
> hardware) without worrying about users' connection limit and site's
> upload bandwidth limit (which can easily rectify). Then thereafter
> will be doing stress test of about 10 concurrent users. As for the
> major queries, that's where threads come in, IMO, because those
> queries depend on 1 primary parameter (category ID) and 1 secondary
> parameter (language ID). This particular site starts with 500
> products about 15 categories, without many of those mentioned filters,
> later grew to its current state.
>=20
The bottle neck looking at speed in this example seems to be the
database backend, not PHP. What would be needed is a fast database, and
SQL queries optimized for speed. Teus.
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 05:13:53 von Phpster
Most if that stuff should only be in the db as a reference and when
editing te lists. The actual user acessed data should sit in simple
XML files that can be passed to the client, broken out by category or
prod line. The reasons are simple, database access time is going to
suck, no matter what you are running. And why would you ever need to
run translation real time. I can tell you from persoanl experience
that such solution totally blows. I lost that battle at work and the
current solution build every field on the fly each time with
translation ( supporting 12 languages) and it's damn slow. Cache out
whatever you can, to an in memory cache or to the file system. Let the
web server do it's job of serving files, not processing upteen little
bits of data from a db.
It's about design, from all I've seen, threading introduces about as
many challenges as problems it solves.
Bastien
Sent from my iPod
On Mar 23, 2010, at 9:17 PM, Tommy Pham wrote:
> Let's go back to my 1st e-commerce example. The manufacturers list is
> about 3,700. The categories is about about 2,400. The products list
> is right now at 500,000 and expected to be around 750,000. The site
> is only in English. The store owner wants to expand and be I18n:
> Chinese, French, German, Korean, Spanish. You see how big and complex
> that database gets? The store owners want to have this happens when a
> customer clicks on a category:
>
> * show all subcategories for that category, if any
> * show all products for that category, if any,
> * show all manufacturers, used as filtering, for that category and
> subcategories
> * show price range filter for that category
> * show features & specifications filter for that category
> * show 10 top sellers for that category and related subcategories
> * the shopper can then select/deselect any of those filters and
> ability to sort by manufacturers, prices, user rating, popularity
> (purchased quantity)
> * have the ability to switch to another language translation on the
> fly
> * from the moment the shopper click on a link, the response time (when
> web browser saids "Done" in the status bar) is 5 seconds or less.
> Preferably 2-3 seconds. Will be using stopwatch for the timer.
>
> Now show me a website that meets those requirements and uses PHP, I'll
> be glad to support your argument about PHP w/o threads :) BTW, this
> is not even enterprise requirement. I may have another possible
> project where # products is over 10 million easily. With similar
> requirements when the user click on category. Do you think this site,
> which currently isn't, can run on PHP?
>
> Regards,
> Tommy
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 05:32:10 von Tommy Pham
On Tue, Mar 23, 2010 at 9:06 PM, Teus Benschop wrote:
> When looking at PHP as used in enterprise class applications, we can see
> the following happening. Let imagine that we have a site that gets a
> 1000 requests per second. That seems to be a good candidate for
> threading so as to be able to handle the 1000 requests per second. The
> site runs PHP and Apache. Well, what happens? Each request coming in is
> handed of to a separate instance of Apache. Thus the site would be able
> to process many requests simultaneously. It looks as if parallel
> computing is taking place here, which looks much like threading. Even
> though PHP itself does not know about threads, and does not need to, I
> think, the whole process of handling the 1000 requests per second uses
> parallel computing. There are no performance bottle-necks here. Teus.
>
# of requests / second can be solved by load balancers/clusters. What
about the multiple answers for a simple request per user as in my
example? How you would solve that if not by threading? Amazon has
about 30 million products and they have filters similar to what I
mentioned. But when clicking on one of the I18n site at the bottom,
you're taken to another server, which looks like it uses a different
DB back end (I could be wrong) and you don't get instant translation
of the category you're looking at. Their response time is about 3
seconds on my 10mbs (not cable) download. As for what programming
language they use...
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 05:49:08 von Larry Garfield
On Tuesday 23 March 2010 11:32:10 pm Tommy Pham wrote:
> On Tue, Mar 23, 2010 at 9:06 PM, Teus Benschop
wrote:
> > When looking at PHP as used in enterprise class applications, we can see
> > the following happening. Let imagine that we have a site that gets a
> > 1000 requests per second. That seems to be a good candidate for
> > threading so as to be able to handle the 1000 requests per second. The
> > site runs PHP and Apache. Well, what happens? Each request coming in is
> > handed of to a separate instance of Apache. Thus the site would be able
> > to process many requests simultaneously. It looks as if parallel
> > computing is taking place here, which looks much like threading. Even
> > though PHP itself does not know about threads, and does not need to, I
> > think, the whole process of handling the 1000 requests per second uses
> > parallel computing. There are no performance bottle-necks here. Teus.
>
> # of requests / second can be solved by load balancers/clusters. What
> about the multiple answers for a simple request per user as in my
> example? How you would solve that if not by threading? Amazon has
> about 30 million products and they have filters similar to what I
> mentioned. But when clicking on one of the I18n site at the bottom,
> you're taken to another server, which looks like it uses a different
> DB back end (I could be wrong) and you don't get instant translation
> of the category you're looking at. Their response time is about 3
> seconds on my 10mbs (not cable) download. As for what programming
> language they use...
Honestly, how WOULD you solve that with threading? You describe a page that
needs to be generated that has a half-dozen queries against the database
ranging from simple to moderately complex, some of which are site-generic and
some are user-specific.
How does one solve that with threading?
1) Run the site-generic queries once and cache them in memory and let other
threads just use that query result. You can do that without threads. Just
render that part of the page and cache that string to disk, to the database,
or to memcache. If the memecache server is on the same box then it should be
identical to the threading version, performance-wise. (Give or take VM
considerations.)
2) Push the user-specific DB queries to separate threads so they can run in
parallel. All that does is push the hard work off onto the DB server, which is
still running the same number of queries. And PHP can't respond until all of
the queries finish anyway, and the DB server will respond no faster, so you're
really gaining nothing.
You keep saying "how would you solve this without threads?" as if they're some
magical speed fairy dust. Given the scenario you describe, I don't even see
how threads would buy you anything at all.
Where threads would be useful is for lots of very small writes on rapidly
changing data. I would never want to write, say, the World of Warcraft
servers without threading and a persistent runtime, but then I wouldn't want
to write them in PHP to begin with.
Insert that old saying about hammers and nails here.
--Larry Garfield
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 05:49:52 von Tommy Pham
On Tue, Mar 23, 2010 at 9:13 PM, Phpster wrote:
> Most if that stuff should only be in the db as a reference and when editi=
ng
> te lists. The actual user acessed data should sit in simple XML files tha=
t
> can be passed to the client, broken out by category or prod line. The
> reasons are simple, database access time is going to suck, no matter what
> you are running. And why would you ever need to run translation real time=
.. I
> can tell you from persoanl experience that such solution totally blows. I
> lost that battle at work and the current solution build every field on th=
e
> fly each time with translation ( supporting 12 languages) and it's damn
> slow. Cache out whatever you can, to an in memory cache or to the file
> system. Let the web server do it's job of serving files, not processing
> upteen little bits of data from a db.
>
> It's about design, from all I've seen, threading introduces about as many
> challenges as problems it solves.
>
> Bastien
If having the products info in categorized XML files as you mention,
why the need for DB then? What about some product name changes to
correctly describe the product without the informed shopper having to
read the description/specifications? The translation is fetched from
the DB and not using any 3rd party software translation on the fly.
>
> Sent from my iPod
>
> On Mar 23, 2010, at 9:17 PM, Tommy Pham wrote:
>
>> Let's go back to my 1st e-commerce example. Â The manufacturers list=
is
>> about 3,700. Â The categories is about about 2,400. Â The produc=
ts list
>> is right now at 500,000 and expected to be around 750,000. Â The sit=
e
>> is only in English. Â The store owner wants to expand and be I18n:
>> Chinese, French, German, Korean, Spanish. Â You see how big and comp=
lex
>> that database gets? Â The store owners want to have this happens whe=
n a
>> customer clicks on a category:
>>
>> * show all subcategories for that category, if any
>> * show all products for that category, if any,
>> * show all manufacturers, used as filtering, for that category and
>> subcategories
>> * show price range filter for that category
>> * show features & specifications filter for that category
>> * show 10 top sellers for that category and related subcategories
>> * the shopper can then select/deselect any of those filters and
>> ability to sort by manufacturers, prices, user rating, popularity
>> (purchased quantity)
>> * have the ability to switch to another language translation on the fly
>> * from the moment the shopper click on a link, the response time (when
>> web browser saids "Done" in the status bar) is 5 seconds or less.
>> Preferably 2-3 seconds. Will be using stopwatch for the timer.
>>
>> Now show me a website that meets those requirements and uses PHP, I'll
>> be glad to support your argument about PHP w/o threads :) Â BTW, thi=
s
>> is not even enterprise requirement. Â I may have another possible
>> project where # products is over 10 million easily. Â With similar
>> requirements when the user click on category. Â Do you think this si=
te,
>> which currently isn't, can run on PHP?
>>
>> Regards,
>> Tommy
>>
>> --
>> PHP General Mailing List (http://www.php.net/)
>> To unsubscribe, visit: http://www.php.net/unsub.php
>>
>
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 05:55:56 von Teus Benschop
On Tue, 2010-03-23 at 21:32 -0700, Tommy Pham wrote:
> # of requests / second can be solved by load balancers/clusters. What
> about the multiple answers for a simple request per user as in my
> example? How you would solve that if not by threading? Amazon has
> about 30 million products and they have filters similar to what I
> mentioned. But when clicking on one of the I18n site at the bottom,
> you're taken to another server, which looks like it uses a different
> DB back end (I could be wrong) and you don't get instant translation
> of the category you're looking at. Their response time is about 3
> seconds on my 10mbs (not cable) download. As for what programming
> language they use...
>=20
Well, the multiple answers for a simple request per user as in your
example, seem to be a lot of information to display all on one page, and
present all that information to the user in one request. I would
probably resolve it, IMHO, by using pagers. That is, only part of the
information is shown to the user at one time, and the user can page
through that information so as to get to other bits of information. If
only part is shown, then the database query becomes so much faster
(hopefully), and PHP still can do all of it in one thread.
A PHP application, by the nature of PHP, consists of small page requests
to be done at one time, rather than move a lot of information around per
request. Thinking the PHP-way requires some study because, as said, the
information is presented or moved about in small chunks. Desktop
applications, and probably Java web applications (I have no experience
with Java but have read up on it a little) work differently. A
successful PHP application is redesigned from the ground up, rather than
remorphing a Java or other desktop application in PHP without changing
the design principles.
The key to makign your eCommerce application snappy, is, I think, not
threading, but optimization of database queries. And another key is that
less information presented to the user is usually clearer to the user,
and thus they feel better at the site, and would return sooner to buy
something. The real head-ache here and the difficult part is: How to
design a clear and clean interface for the user. It's not threading.
Teus.
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 08:04:38 von Tommy Pham
On Tue, Mar 23, 2010 at 9:49 PM, Larry Garfield wr=
ote:
> On Tuesday 23 March 2010 11:32:10 pm Tommy Pham wrote:
>> On Tue, Mar 23, 2010 at 9:06 PM, Teus Benschop
> wrote:
>> > When looking at PHP as used in enterprise class applications, we can s=
ee
>> > the following happening. Let imagine that we have a site that gets a
>> > 1000 requests per second. That seems to be a good candidate for
>> > threading so as to be able to handle the 1000 requests per second. The
>> > site runs PHP and Apache. Well, what happens? Each request coming in i=
s
>> > handed of to a separate instance of Apache. Thus the site would be abl=
e
>> > to process many requests simultaneously. It looks as if parallel
>> > computing is taking place here, which looks much like threading. Even
>> > though PHP itself does not know about threads, and does not need to, I
>> > think, the whole process of handling the 1000 requests per second uses
>> > parallel computing. There are no performance bottle-necks here. Teus.
>>
>> # of requests / second can be solved by load balancers/clusters. Â W=
hat
>> about the multiple answers for a simple request per user as in my
>> example? Â How you would solve that if not by threading? Â Amazo=
n has
>> about 30 million products and they have filters similar to what I
>> mentioned. Â But when clicking on one of the I18n site at the bottom=
,
>> you're taken to another server, which looks like it uses a different
>> DB back end (I could be wrong) and you don't get instant translation
>> of the category you're looking at. Â Their response time is about 3
>> seconds on my 10mbs (not cable) download. Â As for what programming
>> language they use...
>
> Honestly, how WOULD you solve that with threading? Â You describe a p=
age that
> needs to be generated that has a half-dozen queries against the database
> ranging from simple to moderately complex, some of which are site-generic=
and
> some are user-specific.
>
> How does one solve that with threading?
>
> 1) Run the site-generic queries once and cache them in memory and let oth=
er
> threads just use that query result. Â You can do that without threads=
.. Â Just
> render that part of the page and cache that string to disk, to the databa=
se,
> or to memcache. Â If the memecache server is on the same box then it =
should be
> identical to the threading version, performance-wise. Â (Give or take=
VM
> considerations.)
>
> 2) Push the user-specific DB queries to separate threads so they can run =
in
> parallel. Â All that does is push the hard work off onto the DB serve=
r, which is
> still running the same number of queries. Â And PHP can't respond unt=
il all of
> the queries finish anyway, and the DB server will respond no faster, so y=
ou're
> really gaining nothing.
>
> You keep saying "how would you solve this without threads?" as if they're=
some
> magical speed fairy dust. Â Given the scenario you describe, I don't =
even see
> how threads would buy you anything at all.
>
> Where threads would be useful is for lots of very small writes on rapidly
> changing data. Â I would never want to write, say, the World of Warcr=
aft
> servers without threading and a persistent runtime, but then I wouldn't w=
ant
> to write them in PHP to begin with.
>
> Insert that old saying about hammers and nails here.
>
> --Larry Garfield
>
The difference is doing all those queries in serial operations (one
after another) versus parallel operations (threads). Instead of
waiting, for example, about .05 to .25 sec for each of those queries,
the total wait time would be diminishes since each thread would
execute a query. Either way, the DB is still doing the required total
work. Difference is serial & parallel operations as I iterated
several times. Being running in parallel, the web browser will be
getting the required info faster since PHP is able to get all the info
faster.
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 08:11:48 von Tommy Pham
On Tue, Mar 23, 2010 at 9:55 PM, Teus Benschop wro=
te:
> On Tue, 2010-03-23 at 21:32 -0700, Tommy Pham wrote:
>> # of requests / second can be solved by load balancers/clusters. Â W=
hat
>> about the multiple answers for a simple request per user as in my
>> example? Â How you would solve that if not by threading? Â Amazo=
n has
>> about 30 million products and they have filters similar to what I
>> mentioned. Â But when clicking on one of the I18n site at the bottom=
,
>> you're taken to another server, which looks like it uses a different
>> DB back end (I could be wrong) and you don't get instant translation
>> of the category you're looking at. Â Their response time is about 3
>> seconds on my 10mbs (not cable) download. Â As for what programming
>> language they use...
>>
>
> Well, the multiple answers for a simple request per user as in your
> example, seem to be a lot of information to display all on one page, and
> present all that information to the user in one request. I would
> probably resolve it, IMHO, by using pagers. That is, only part of the
Pagers are needed when there's a lot of products to display. But
using the filters and show them is different. Look at Amazon (not
endorsing it). Click any category. You'll see what I mean by the
filters (manufacturers, price range, subcategories, etc) and the
display requirements (specials, bestsellers) as I mentioned. They
also have other things, like shoppers' discussions, on that page too.
Think about how many queries they have to run for all that info to
show based on a simple request of a 'category'. Then time the
response time.
> information is shown to the user at one time, and the user can page
> through that information so as to get to other bits of information. If
> only part is shown, then the database query becomes so much faster
> (hopefully), and PHP still can do all of it in one thread.
>
> A PHP application, by the nature of PHP, consists of small page requests
> to be done at one time, rather than move a lot of information around per
> request. Thinking the PHP-way requires some study because, as said, the
> information is presented or moved about in small chunks. Desktop
> applications, and probably Java web applications (I have no experience
> with Java but have read up on it a little) work differently. A
> successful PHP application is redesigned from the ground up, rather than
> remorphing a Java or other desktop application in PHP without changing
> the design principles.
>
> The key to makign your eCommerce application snappy, is, I think, not
> threading, but optimization of database queries. And another key is that
> less information presented to the user is usually clearer to the user,
> and thus they feel better at the site, and would return sooner to buy
> something. The real head-ache here and the difficult part is: How to
> design a clear and clean interface for the user. It's not threading.
>
> Teus.
>
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 08:31:24 von Per Jessen
Tommy Pham wrote:
> The company started small. As their business grows because they have=
> products & services that do not exist in the marketplace, their
> hardware are already growing along side with it, (load balancers,
> clusters). So then your solution is buy bigger/more boxes? What if
> the their server room is filled and already using recent hardware.
Same answer - buy a bigger box (i.e. serverroom). I would certainly
also start a redesign from the ground up, but to solve the immediate
problem, get more hardware.=20
> Their current business needs doesn't need to move to a bigger
> building. What then? Hire data center's services? What if they want=
> to protect their proprietary break through products and services?
Rent space and maybe hardware. That's what most businesses do.=20
> What about unnecessary additional total cost of ownership (licenses,
> power consumption, etc...) for more/bigger boxes, even if they have
> available space, that could be avoided by just implementing threads?
If you believe threading is such a silver bullet, I really think you
need to reconsider. This business has already invested in more
hardware to satisfy demand, so the application has some scalability -
presumably achieved by running multiple processes. Threads have some
advantages over processes, but when your design doesn't take that into
account anyway, why do you need threads?
[snip]
> In summary, you're saying that PHP can not grow/evolve with=20
> business right?=20
Certainly not. PHP is just a language, like most other programming
languages, it doesn't grow nor does it evolve a lot. (the OOP paradigm=
is an example of where PHP evolved).=20
I'm saying that a back-of-a-fag-packet design won't grow nor evolve ver=
y
well, and its inevitable shortcomings will not be solved by bolting
on "threading".
> If the company started small and want to use available open source
> solutions, then grow quickly because of their unique and quality
> products and services, and become enterprise level with-in a few
> years, what then? Slow down business growth just so that IT can
> migrate everything to another language? Of all the enterprise
> applications I've seen, they used threads.=20
Tommy, that's not about the language, that's a design issue. Run PHP i=
n
multiple processes, and you've got the parallelism you seem to seek.=20=
/Per
--=20
Per Jessen, Zürich (6.8°C)
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 08:33:09 von Rene Veerman
stop bashing the people who DO have a use for threading and other
advanced concepts eh.
just because you don't have a use for it, it shouldn't be included?!
kinda arrogant.
also kinda arrogant: how do you know the guy needing threading is not
working on projects many times as complex as your own projects??
On Wed, Mar 24, 2010 at 12:33 AM, Per Jessen wrote:
> Tommy Pham wrote:
>
>> On Tue, Mar 23, 2010 at 2:04 AM, Per Jessen wrote:
>>>
>>> Use the right tool for the right job - PHP is a scripting/interpreted
>>> language, it does not need threading (IMO of course).
>>>
>>>
>>> --
>>> Per Jessen, Zürich (9.4°C)
>>>
>>>
>>
>> I couldn't agree more. =A0But here's a real life example. =A0Your client
>> has a forum and is using phpbb for their in house use. =A0They also have
>> an in house custom PHP app, integrated with phpbb, built to suit their
>> needs. =A0Now they want to implement some kind of CMS. =A0You come in an=
d
>> implemented a PHP based CMS to integrate into their existing
>> applications. =A0Then you realize something troublesome, you have a
>> performance issue where it could be resolved by implementing thread.
>> What are you going to do?
>
> The standard, mature, experienced answer is - buy a bigger box.
>
> [snip]
>> What do you think the client's response is when their need for the
>> solution requires a short time frame of, if not immediate,
>> implementation?
>
> There are no immediate solutions to immediate performance problems. =A0If
> you have a poor design that restricts your throughput, you can 1) throw
> hardware at it or 2) change the design. =A0At some point you'll hit yet
> another limit with 1), and you are forced back to 2). =A0Somewhere along
> the line the original designer has presumably left or been made to.
>
>
> /Per
>
> --
> Per Jessen, Zürich (7.5°C)
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 08:36:05 von Rene Veerman
throw more hardware at it?
how about you not butt into my business and how i save costs eh..
On Wed, Mar 24, 2010 at 9:31 AM, Per Jessen wrote:
> Tommy Pham wrote:
>
>> The company started small. =A0As their business grows because they have
>> products & services that do not exist in the marketplace, their
>> hardware are already growing along side with it, (load balancers,
>> clusters). =A0So then your solution is buy bigger/more boxes? =A0What if
>> the their server room is filled and already using recent hardware.
>
> Same answer - buy a bigger box (i.e. serverroom). =A0I would certainly
> also start a redesign from the ground up, but to solve the immediate
> problem, get more hardware.
>
>> Their current business needs doesn't need to move to a bigger
>> building. =A0What then? Hire data center's services? =A0What if they wan=
t
>> to protect their proprietary break through products and services?
>
> Rent space and maybe hardware. That's what most businesses do.
>
>> What about unnecessary additional total cost of ownership (licenses,
>> power consumption, etc...) for more/bigger boxes, even if they have
>> available space, that could be avoided by just implementing threads?
>
> If you believe threading is such a silver bullet, I really think you
> need to reconsider. =A0This business has already invested in more
> hardware to satisfy demand, so the application has some scalability -
> presumably achieved by running multiple processes. =A0Threads have some
> advantages over processes, but when your design doesn't take that into
> account anyway, why do you need threads?
>
> [snip]
>> In summary, you're saying that PHP can not grow/evolve with
>> business right?
>
> Certainly not. =A0PHP is just a language, like most other programming
> languages, it doesn't grow nor does it evolve a lot. =A0(the OOP paradigm
> is an example of where PHP evolved).
> I'm saying that a back-of-a-fag-packet design won't grow nor evolve very
> well, and its inevitable shortcomings will not be solved by bolting
> on "threading".
>
>> If the company started small and want to use available open source
>> solutions, then grow quickly because of their unique and quality
>> products and services, and become enterprise level with-in a few
>> years, what then? =A0Slow down business growth just so that IT can
>> migrate everything to another language? Of all the enterprise
>> applications I've seen, they used threads.
>
> Tommy, that's not about the language, that's a design issue. =A0Run PHP i=
n
> multiple processes, and you've got the parallelism you seem to seek.
>
> /Per
>
> --
> Per Jessen, Zürich (6.8°C)
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 08:39:21 von Rene Veerman
and btw, complexity of design can go up considerably when you have to
deal with more than 1 php and 1 mysql server, because the language
forces inefficient constructs _and_ is "stuck on 1 server"....
On Wed, Mar 24, 2010 at 9:36 AM, Rene Veerman wrote:
> throw more hardware at it?
>
> how about you not butt into my business and how i save costs eh..
>
> On Wed, Mar 24, 2010 at 9:31 AM, Per Jessen wrote:
>> Tommy Pham wrote:
>>
>>> The company started small. =A0As their business grows because they have
>>> products & services that do not exist in the marketplace, their
>>> hardware are already growing along side with it, (load balancers,
>>> clusters). =A0So then your solution is buy bigger/more boxes? =A0What i=
f
>>> the their server room is filled and already using recent hardware.
>>
>> Same answer - buy a bigger box (i.e. serverroom). =A0I would certainly
>> also start a redesign from the ground up, but to solve the immediate
>> problem, get more hardware.
>>
>>> Their current business needs doesn't need to move to a bigger
>>> building. =A0What then? Hire data center's services? =A0What if they wa=
nt
>>> to protect their proprietary break through products and services?
>>
>> Rent space and maybe hardware. That's what most businesses do.
>>
>>> What about unnecessary additional total cost of ownership (licenses,
>>> power consumption, etc...) for more/bigger boxes, even if they have
>>> available space, that could be avoided by just implementing threads?
>>
>> If you believe threading is such a silver bullet, I really think you
>> need to reconsider. =A0This business has already invested in more
>> hardware to satisfy demand, so the application has some scalability -
>> presumably achieved by running multiple processes. =A0Threads have some
>> advantages over processes, but when your design doesn't take that into
>> account anyway, why do you need threads?
>>
>> [snip]
>>> In summary, you're saying that PHP can not grow/evolve with
>>> business right?
>>
>> Certainly not. =A0PHP is just a language, like most other programming
>> languages, it doesn't grow nor does it evolve a lot. =A0(the OOP paradig=
m
>> is an example of where PHP evolved).
>> I'm saying that a back-of-a-fag-packet design won't grow nor evolve very
>> well, and its inevitable shortcomings will not be solved by bolting
>> on "threading".
>>
>>> If the company started small and want to use available open source
>>> solutions, then grow quickly because of their unique and quality
>>> products and services, and become enterprise level with-in a few
>>> years, what then? =A0Slow down business growth just so that IT can
>>> migrate everything to another language? Of all the enterprise
>>> applications I've seen, they used threads.
>>
>> Tommy, that's not about the language, that's a design issue. =A0Run PHP =
in
>> multiple processes, and you've got the parallelism you seem to seek.
>>
>> /Per
>>
>> --
>> Per Jessen, Zürich (6.8°C)
>>
>>
>> --
>> PHP General Mailing List (http://www.php.net/)
>> To unsubscribe, visit: http://www.php.net/unsub.php
>>
>>
>
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 08:43:15 von Per Jessen
Tommy Pham wrote:
> Let's go back to my 1st e-commerce example. The manufacturers list i=
s
> about 3,700. The categories is about about 2,400. The products list=
> is right now at 500,000 and expected to be around 750,000. The site
> is only in English. The store owner wants to expand and be I18n:
> Chinese, French, German, Korean, Spanish. You see how big and comple=
x
> that database gets?=20
No, not really. So you want to add five languages - if your applicatio=
n
is just half-way prepared for multiple languages, that's no big deal
(apart from pure translation effort), and a database with only 5
million rows is also no big deal. If that is causing you a performance=
problem, it is definitely solveable by 1) hardware and 2) database
optimization.=20
> * from the moment the shopper click on a link, the response time
> (when web browser saids "Done" in the status bar) is 5 seconds or
> less. Preferably 2-3 seconds. Will be using stopwatch for the timer.
Yes, 3 seconds used to be the maximum response time for an inter-active=
application. The web might have moved the goal posts a bit :-)
> Now show me a website that meets those requirements and uses PHP, I'l=
l
> be glad to support your argument about PHP w/o threads :)=20
Tommy, you neglected to say anything about the number of concurrent
users, but if you have e.g. 10.000, you will need enough hardware to
run the webserver and the database. A webserver for serving 10.000
concurrent clients I would run on multiple boxes with an LVS load
distribution mechanism in front. The 5 million row database is
storage-wise not a lot, but running 10.000 concurrent queries will be a=
significant challenge. MySql cluster comes to mind. Apart from that,
apache and mysql will do all the threading you need.=20
/Per
--=20
Per Jessen, Zürich (7.8°C)
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 08:44:57 von Per Jessen
Teus Benschop wrote:
> On Tue, 2010-03-23 at 19:08 -0700, Tommy Pham wrote:
>> The response time, max 5 seconds, will be tested on local gigabit LA=
N
>> to ensure the adequate response (optimized DB & code & proper
>> hardware) without worrying about users' connection limit and site's
>> upload bandwidth limit (which can easily rectify). Then thereafter
>> will be doing stress test of about 10 concurrent users. As for the
>> major queries, that's where threads come in, IMO, because those
>> queries depend on 1 primary parameter (category ID) and 1 secondary
>> parameter (language ID). This particular site starts with 500
>> products about 15 categories, without many of those mentioned
>> filters, later grew to its current state.
>>=20
> The bottle neck looking at speed in this example seems to be the
> database backend, not PHP. What would be needed is a fast database,
> and SQL queries optimized for speed. Teus.
>=20
+1.
--=20
Per Jessen, Zürich (7.8°C)
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 08:46:27 von Per Jessen
Robert Cummings wrote:
> Yes, I do. There's nothing in your requirements above that sound
> particularly difficult for PHP to handle with a good design and lots
> of caching... and of course the right hardware. I think you're hung u=
p
> on the numbers a bit... those aren't very big numbers for a database.=
Yeah. Given a decent database machine, those 5 millions rows can be
kept in-core all the time.=20
--=20
Per Jessen, Zürich (7.8°C)
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 08:51:33 von Rene Veerman
look per, i for one build systems designed to scale to popular levels.
that means that whatever i can squeeze out of a single machine will
save me money. quite a lot, coz as you know dedicated hosting gets
very expensive when you have to buy fast machines.
threading features and persistent shared memory _would_ decrease cost,
a lot, for any php app that wants to scale to popular levels.
i'd like to keep coding in php, and not have to switch languages
because my app got popular.
On Wed, Mar 24, 2010 at 9:46 AM, Per Jessen wrote:
> Robert Cummings wrote:
>
>> Yes, I do. There's nothing in your requirements above that sound
>> particularly difficult for PHP to handle with a good design and lots
>> of caching... and of course the right hardware. I think you're hung up
>> on the numbers a bit... those aren't very big numbers for a database.
>
> Yeah. =A0Given a decent database machine, those 5 millions rows can be
> kept in-core all the time.
>
>
>
> --
> Per Jessen, Zürich (7.8°C)
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 08:52:22 von Per Jessen
Tommy Pham wrote:
> # of requests / second can be solved by load balancers/clusters. Wha=
t
> about the multiple answers for a simple request per user as in my
> example? How you would solve that if not by threading?=20
Ah, you're worried that running multiple sql queries sequentially will
cause the response time to be too long? Now we're getting to the crux
of the matter. My immediate thought is - if you can't optimize the
database any further, run multiple http requests, there are ways of
doing that. at.
--=20
Per Jessen, Zürich (7.9°C)
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 08:53:40 von Lester Caine
Per Jessen wrote:
> Teus Benschop wrote:
>
>> On Tue, 2010-03-23 at 19:08 -0700, Tommy Pham wrote:
>>> The response time, max 5 seconds, will be tested on local gigabit LAN
>>> to ensure the adequate response (optimized DB& code& proper
>>> hardware) without worrying about users' connection limit and site's
>>> upload bandwidth limit (which can easily rectify). Then thereafter
>>> will be doing stress test of about 10 concurrent users. As for the
>>> major queries, that's where threads come in, IMO, because those
>>> queries depend on 1 primary parameter (category ID) and 1 secondary
>>> parameter (language ID). This particular site starts with 500
>>> products about 15 categories, without many of those mentioned
>>> filters, later grew to its current state.
>>>
>> The bottle neck looking at speed in this example seems to be the
>> database backend, not PHP. What would be needed is a fast database,
>> and SQL queries optimized for speed. Teus.
>
> +1.
Seconded ...
My own servers spend 75% of the time in firebird and 25% in apache/php, and when
I need some extra performance I just add a second machine for firebird with a
lot more memory. PHP is not the bottleneck and while the computer is 99.5% idle
anyway I don't see any need for threading any time soon.
--
Lester Caine - G8HFL
-----------------------------
Contact - http://lsces.co.uk/wiki/?page=contact
L.S.Caine Electronic Services - http://lsces.co.uk
EnquirySolve - http://enquirysolve.com/
Model Engineers Digital Workshop - http://medw.co.uk//
Firebird - http://www.firebirdsql.org/index.php
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 08:55:46 von Lester Caine
Rene Veerman wrote:
> and btw, complexity of design can go up considerably when you have to
> deal with more than 1 php and 1 mysql server, because the language
> forces inefficient constructs _and_ is "stuck on 1 server"....
Switch to a real database?
MySQL still needs to grow up as well :)
--
Lester Caine - G8HFL
-----------------------------
Contact - http://lsces.co.uk/wiki/?page=contact
L.S.Caine Electronic Services - http://lsces.co.uk
EnquirySolve - http://enquirysolve.com/
Model Engineers Digital Workshop - http://medw.co.uk//
Firebird - http://www.firebirdsql.org/index.php
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 09:00:23 von Rene Veerman
jeez dude, you're assuming that all software problems are best solved
by a sql solution.
imo, they're NOT. example? any realtime system with real work to do.
please stop pretending you know the proper design of all software that
is made or yet has to be made.
both a ya.
On Wed, Mar 24, 2010 at 9:55 AM, Lester Caine wrote:
> Rene Veerman wrote:
>>
>> and btw, complexity of design can go up considerably when you have to
>> deal with more than 1 php and 1 mysql server, because the language
>> forces inefficient constructs _and_ is "stuck on 1 server"....
>
> Switch to a real database?
> MySQL still needs to grow up as well :)
>
> --
> Lester Caine - G8HFL
> -----------------------------
> Contact - http://lsces.co.uk/wiki/?page=contact
> L.S.Caine Electronic Services - http://lsces.co.uk
> EnquirySolve - http://enquirysolve.com/
> Model Engineers Digital Workshop - http://medw.co.uk//
> Firebird - http://www.firebirdsql.org/index.php
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 09:02:51 von Per Jessen
Rene Veerman wrote:
> stop bashing the people who DO have a use for threading and other
> advanced concepts eh.
I'm not bashing anyone.=20
> just because you don't have a use for it, it shouldn't be included?!
> kinda arrogant.
Feel free to think so - I never said I don't have a use for it
(threading), I just said thread-support doesn't belong in PHP.=20
> also kinda arrogant: how do you know the guy needing threading is not=
> working on projects many times as complex as your own projects??
I don't care what he is working on. It has absolutely no bearing on the=
conversation. =20
Please stop top-posting, it's not good netiquette.=20
--=20
Per Jessen, Zürich (8.4°C)
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 09:07:24 von Rene Veerman
yes you are bashing them (me included) imo
you say threading support doesnt belong in php; with that you're
determining what i may and may not do, even if i have given you good
reasons for it, that you chose to ignore.
i hope the php developers have more sense than you. i'm done
discussing this with you.
and i like top-posting. a lot.
you may wanna stop trying to change the ways of others, especially if
they don't interfere with what YOU may and may not do.
On Wed, Mar 24, 2010 at 10:02 AM, Per Jessen wrote:
> Rene Veerman wrote:
>
>> stop bashing the people who DO have a use for threading and other
>> advanced concepts eh.
>
> I'm not bashing anyone.
>
>> just because you don't have a use for it, it shouldn't be included?!
>> kinda arrogant.
>
> Feel free to think so - I never said I don't have a use for it
> (threading), I just said thread-support doesn't belong in PHP.
>
>> also kinda arrogant: how do you know the guy needing threading is not
>> working on projects many times as complex as your own projects??
>
> I don't care what he is working on. It has absolutely no bearing on the
> conversation.
>
> Please stop top-posting, it's not good netiquette.
>
>
> --
> Per Jessen, Zürich (8.4°C)
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 09:09:07 von Ashley Sheridan
--=-pSy4Avg7z50Pr5kaZdJn
Content-Type: text/plain
Content-Transfer-Encoding: 7bit
On Wed, 2010-03-24 at 10:00 +0200, Rene Veerman wrote:
> jeez dude, you're assuming that all software problems are best solved
> by a sql solution.
> imo, they're NOT. example? any realtime system with real work to do.
>
> please stop pretending you know the proper design of all software that
> is made or yet has to be made.
> both a ya.
>
> On Wed, Mar 24, 2010 at 9:55 AM, Lester Caine wrote:
> > Rene Veerman wrote:
> >>
> >> and btw, complexity of design can go up considerably when you have to
> >> deal with more than 1 php and 1 mysql server, because the language
> >> forces inefficient constructs _and_ is "stuck on 1 server"....
> >
> > Switch to a real database?
> > MySQL still needs to grow up as well :)
> >
> > --
> > Lester Caine - G8HFL
> > -----------------------------
> > Contact - http://lsces.co.uk/wiki/?page=contact
> > L.S.Caine Electronic Services - http://lsces.co.uk
> > EnquirySolve - http://enquirysolve.com/
> > Model Engineers Digital Workshop - http://medw.co.uk//
> > Firebird - http://www.firebirdsql.org/index.php
> >
> > --
> > PHP General Mailing List (http://www.php.net/)
> > To unsubscribe, visit: http://www.php.net/unsub.php
> >
> >
>
But aren't you doing exactly that by saying that PHP needs threading and
that threading is the only way to achieve certain goals. I've watched
this thread go on quite a bit, and haven't seen a really good argument
that proves PHP needs threading when it can't be solved without it. PHP
is PHP. If it behaved exactly the same as all the other languages, what
would make it distinct against those others. One of it's main strenghts
is its simplicity I feel. If you added threading to the bag of tricks it
already has, you're getting into areas that make it more difficult to
pick up for beginners (and that's not to mention the technical elements
involved in actually adding threading to PHP) Currently the only other
'easy' language I know for beginners is ColdFusion, and that's just
horrible. You wouldn't want to be responsible for sending the newbies
down that path would you?! :p
Thanks,
Ash
http://www.ashleysheridan.co.uk
--=-pSy4Avg7z50Pr5kaZdJn--
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 09:11:42 von Ashley Sheridan
--=-JKui+qooeeIRdzVhL/2C
Content-Type: text/plain
Content-Transfer-Encoding: 7bit
On Wed, 2010-03-24 at 10:07 +0200, Rene Veerman wrote:
>
> and i like top-posting. a lot.
Rene, please do stop posting. It is in the mailing list rules that you
should bottom post.
There is a reason for it. It helps with readability if everyone conforms
to the same practice, and the mailing archives online are easier to
digest also.
Thanks,
Ash
http://www.ashleysheridan.co.uk
--=-JKui+qooeeIRdzVhL/2C--
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 09:15:28 von Lester Caine
Rene Veerman wrote:
> jeez dude, you're assuming that all software problems are best solved
> by a sql solution.
> imo, they're NOT. example? any realtime system with real work to do.
>
> please stop pretending you know the proper design of all software that
> is made or yet has to be made.
> both a ya.
I run real time systems for offices that count serving time in seconds. I know
currently where the bottlenecks are, and adding 'threading' to PHP is not a
solution. I fact adding much of the dross that has been added to PHP5 is
ACTUALLY slowing down performance. I have PHP5.3 and PHP5.2 running on similarly
loaded sites, and PHP5.2 is faster! I am just pointing out that on *MY* REAL
applications, the SQL element is a major part of the processing time, and yes
moving some of the table lookups to be hard coded arrays in PHP would make a
difference, but then complicates configurability, so keeping them in the
database makes life easier.
The proper design is the one that meets the customers requirements and gets the
bills paid. Processing the raw statistics required for my own sites is best done
away from PHP, so using the right tools for the job is the important thing?
--
Lester Caine - G8HFL
-----------------------------
Contact - http://lsces.co.uk/wiki/?page=contact
L.S.Caine Electronic Services - http://lsces.co.uk
EnquirySolve - http://enquirysolve.com/
Model Engineers Digital Workshop - http://medw.co.uk//
Firebird - http://www.firebirdsql.org/index.php
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 09:19:27 von Per Jessen
Rene Veerman wrote:
> look per, i for one build systems designed to scale to popular levels=
..
>=20
> that means that whatever i can squeeze out of a single machine will
> save me money. quite a lot, coz as you know dedicated hosting gets
> very expensive when you have to buy fast machines.
Well, at Hetzner in Nuernberg you can rent an EQ8 for EUR89/month. It
comes with bandwidth, 1.5Tb software RAID, 24Gb RAM and a EUR149 setup
cost. That's an Intel Core i7, so 2.6GHz quad core plus
hyper-threading, meaning 4 to 8 concurrent processes.=20
I've got four of the slightly smaller EQ4 running as backend mailserver=
s
handling up to about 3000 concurrent SMTP connections per box. Is that
what you call a popular level?=20
--=20
Per Jessen, Zürich (8.9°C)
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 09:28:05 von Rene Veerman
--0015174768a2c0dc4c048287b6fa
Content-Type: text/plain; charset=ISO-8859-1
funny how i've been topposting for over a year here and the complaints start
when i tell some people not to butt into my business and choice of tools.
On Wed, Mar 24, 2010 at 10:11 AM, Ashley Sheridan
wrote:
> On Wed, 2010-03-24 at 10:07 +0200, Rene Veerman wrote:
>
> and i like top-posting. a lot.
>
>
>
> Rene, please do stop posting. It is in the mailing list rules that you
> should bottom post.
>
> There is a reason for it. It helps with readability if everyone conforms to
> the same practice, and the mailing archives online are easier to digest
> also.
>
i find 'm easier to digest with topposting.
>
>
> Thanks,
> Ash
> http://www.ashleysheridan.co.uk
>
>
>
--0015174768a2c0dc4c048287b6fa--
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 09:30:32 von Ashley Sheridan
--=-3elW3s5vU13XquX+FSFO
Content-Type: text/plain
Content-Transfer-Encoding: 7bit
On Wed, 2010-03-24 at 10:28 +0200, Rene Veerman wrote:
> funny how i've been topposting for over a year here and the complaints
> start when i tell some people not to butt into my business and choice
> of tools.
>
>
>
> On Wed, Mar 24, 2010 at 10:11 AM, Ashley Sheridan
> wrote:
>
> On Wed, 2010-03-24 at 10:07 +0200, Rene Veerman wrote:
>
>
> > and i like top-posting. a lot.
>
>
>
>
>
> Rene, please do stop posting. It is in the mailing list rules
> that you should bottom post.
>
> There is a reason for it. It helps with readability if
> everyone conforms to the same practice, and the mailing
> archives online are easier to digest also.
>
> i find 'm easier to digest with topposting.
>
>
> Thanks,
> Ash
> http://www.ashleysheridan.co.uk
>
>
>
>
>
What you're actually saying is you find them easier to digest with both
top AND bottom posting, because the majority of the list bottom posts as
according to the rules, and you flaunt it deliberately for some reason.
You're asking people on the list to not make assumptions about your
applications and your 'need' for threading, and then blatantly ignore
the rules on posting assuming that because you find a mix of top and
bottom posting 'easier' to read, then so too will others.
I'm not suddenly bringing this into focus now because you've asked
people not to 'butt in' but because of the rude way you responded to Per
Jessen about top-posting. I'm just asking that please, for the sake of
clarity and readability, you bottom post to the list. If everyone does
the same thing, it makes it a lot easier.
Thanks,
Ash
http://www.ashleysheridan.co.uk
--=-3elW3s5vU13XquX+FSFO--
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 09:30:44 von Rene Veerman
popular : facebook youtube etc
and you're still trying to impose a toolset on me. i think it's not
strange to ask a programming language support basic hardware
architecture features as they evolve into mainstream.
On Wed, Mar 24, 2010 at 10:19 AM, Per Jessen wrote:
> Rene Veerman wrote:
>
>> look per, i for one build systems designed to scale to popular levels.
>>
>> that means that whatever i can squeeze out of a single machine will
>> save me money. quite a lot, coz as you know dedicated hosting gets
>> very expensive when you have to buy fast machines.
>
> Well, at Hetzner in Nuernberg you can rent an EQ8 for EUR89/month. It
> comes with bandwidth, 1.5Tb software RAID, 24Gb RAM and a EUR149 setup
> cost. =A0That's an Intel Core i7, so 2.6GHz quad core plus
> hyper-threading, meaning 4 to 8 concurrent processes.
>
> I've got four of the slightly smaller EQ4 running as backend mailservers
> handling up to about 3000 concurrent SMTP connections per box. Is that
> what you call a popular level?
>
>
>
> --
> Per Jessen, Zürich (8.9°C)
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 09:31:48 von Rene Veerman
so your systems represent all the software problems out there in the world?
or your experience does?
hard to believe.
On Wed, Mar 24, 2010 at 10:15 AM, Lester Caine wrote:
> Rene Veerman wrote:
>>
>> jeez dude, you're assuming that all software problems are best solved
>> by a sql solution.
>> imo, they're NOT. example? any realtime system with real work to do.
>>
>> please stop pretending you know the proper design of all software that
>> is made or yet has to be made.
>> both a ya.
>
> I run real time systems for offices that count serving time in seconds. I
> know currently where the bottlenecks are, and adding 'threading' to PHP is
> not a solution. I fact adding much of the dross that has been added to PHP5
> is ACTUALLY slowing down performance. I have PHP5.3 and PHP5.2 running on
> similarly loaded sites, and PHP5.2 is faster! I am just pointing out that on
> *MY* REAL applications, the SQL element is a major part of the processing
> time, and yes moving some of the table lookups to be hard coded arrays in
> PHP would make a difference, but then complicates configurability, so
> keeping them in the database makes life easier.
>
> The proper design is the one that meets the customers requirements and gets
> the bills paid. Processing the raw statistics required for my own sites is
> best done away from PHP, so using the right tools for the job is the
> important thing?
>
> --
> Lester Caine - G8HFL
> -----------------------------
> Contact - http://lsces.co.uk/wiki/?page=contact
> L.S.Caine Electronic Services - http://lsces.co.uk
> EnquirySolve - http://enquirysolve.com/
> Model Engineers Digital Workshop - http://medw.co.uk//
> Firebird - http://www.firebirdsql.org/index.php
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 09:36:04 von Per Jessen
Rene Veerman wrote:
> yes you are bashing them (me included) imo
>=20
> you say threading support doesnt belong in php; with that you're
> determining what i may and may not do, even if i have given you good
> reasons for it, that you chose to ignore.
Well, call it what you like, I think I'm being perfectly civil.=20
By advocating that thread support does not belong in PHP, I am in no wa=
y
determining what you (or anyone else) may or may not do. You are a
free individual and free to choose the programming language and
paradigm that is best suited to your purposes.=20
Using your argument, one could also say that Kernighan and Ritchie
determined that "C should have no threading", just as the US DoD was
incredibly foresighted and decided we all should go multi-threaded when=
they gave Ada its tasks and rendezvous.=20
--=20
Per Jessen, Zürich (9.0°C)
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 09:41:56 von Rene Veerman
--00151747af9e48a831048287e810
Content-Type: text/plain; charset=ISO-8859-1
talk to me about this some other time.
atm i'm having an argument with per and his kind about their very very
annoying behaviour of determining my toolset for me.
keeping a thread on topic is also ettiquette from the mailinglist rules eh?
you might wanna consider just how much it pisses me off to have strangers
determining my toolset and/or lifestyle for me.
that's why i got rude. no other reason.
On Wed, Mar 24, 2010 at 10:30 AM, Ashley Sheridan
wrote:
> On Wed, 2010-03-24 at 10:28 +0200, Rene Veerman wrote:
>
> funny how i've been topposting for over a year here and the complaints
> start when i tell some people not to butt into my business and choice of
> tools.
>
>
>
>
> On Wed, Mar 24, 2010 at 10:11 AM, Ashley Sheridan <
> ash@ashleysheridan.co.uk> wrote:
>
> On Wed, 2010-03-24 at 10:07 +0200, Rene Veerman wrote:
>
> and i like top-posting. a lot.
>
>
>
>
> Rene, please do stop posting. It is in the mailing list rules that you
> should bottom post.
>
> There is a reason for it. It helps with readability if everyone conforms to
> the same practice, and the mailing archives online are easier to digest
> also.
>
>
>
> i find 'm easier to digest with topposting.
>
>
>
> Thanks,
> Ash
> http://www.ashleysheridan.co.uk
>
>
>
>
>
> What you're actually saying is you find them easier to digest with both top
> AND bottom posting, because the majority of the list bottom posts as
> according to the rules, and you flaunt it deliberately for some reason.
> You're asking people on the list to not make assumptions about your
> applications and your 'need' for threading, and then blatantly ignore the
> rules on posting assuming that because you find a mix of top and bottom
> posting 'easier' to read, then so too will others.
>
> I'm not suddenly bringing this into focus now because you've asked people
> not to 'butt in' but because of the rude way you responded to Per Jessen
> about top-posting. I'm just asking that please, for the sake of clarity and
> readability, you bottom post to the list. If everyone does the same thing,
> it makes it a lot easier.
>
>
> Thanks,
> Ash
> http://www.ashleysheridan.co.uk
>
>
>
--00151747af9e48a831048287e810--
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 09:42:20 von Tommy Pham
On Wed, Mar 24, 2010 at 1:09 AM, Ashley Sheridan
wrote:
> On Wed, 2010-03-24 at 10:00 +0200, Rene Veerman wrote:
>
>> jeez dude, you're assuming that all software problems are best solved
>> by a sql solution.
>> imo, they're NOT. example? any realtime system with real work to do.
>>
>> please stop pretending you know the proper design of all software that
>> is made or yet has to be made.
>> both a ya.
>>
>> On Wed, Mar 24, 2010 at 9:55 AM, Lester Caine wrote:
>> > Rene Veerman wrote:
>> >>
>> >> and btw, complexity of design can go up considerably when you have to
>> >> deal with more than 1 php and 1 mysql server, because the language
>> >> forces inefficient constructs _and_ is "stuck on 1 server"....
>> >
>> > Switch to a real database?
>> > MySQL still needs to grow up as well :)
>> >
>> > --
>> > Lester Caine - G8HFL
>> > -----------------------------
>> > Contact - http://lsces.co.uk/wiki/?page=contact
>> > L.S.Caine Electronic Services - http://lsces.co.uk
>> > EnquirySolve - http://enquirysolve.com/
>> > Model Engineers Digital Workshop - http://medw.co.uk//
>> > Firebird - http://www.firebirdsql.org/index.php
>> >
>> > --
>> > PHP General Mailing List (http://www.php.net/)
>> > To unsubscribe, visit: http://www.php.net/unsub.php
>> >
>> >
>>
>
>
> But aren't you doing exactly that by saying that PHP needs threading and
> that threading is the only way to achieve certain goals. I've watched
> this thread go on quite a bit, and haven't seen a really good argument
> that proves PHP needs threading when it can't be solved without it. PHP
> is PHP. If it behaved exactly the same as all the other languages, what
> would make it distinct against those others. One of it's main strenghts
> is its simplicity I feel. If you added threading to the bag of tricks it
> already has, you're getting into areas that make it more difficult to
> pick up for beginners (and that's not to mention the technical elements
> involved in actually adding threading to PHP) Currently the only other
> 'easy' language I know for beginners is ColdFusion, and that's just
> horrible. You wouldn't want to be responsible for sending the newbies
> down that path would you?! :p
>
> Thanks,
> Ash
> http://www.ashleysheridan.co.uk
>
That's why I gave an analogy of AJAX earlier. You use AJAX yourself.
Do you use it for every project? Would you recommend AJAX to newbies?
When you do use AJAX, there is a slight difference in your app design
then when you don't use AJAX. That's the way I see threads. It's not
for every body nor for every project. But it would be great if it's
there when the need/requirement arises. And yes, coldfusion should be
phased out long ago...
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 09:44:04 von Rene Veerman
On Wed, Mar 24, 2010 at 10:36 AM, Per Jessen wrote:
> By advocating that thread support does not belong in PHP, I am in no way
> determining what you (or anyone else) may or may not do. =A0You are a
> free individual and free to choose the programming language and
> paradigm that is best suited to your purposes.
right! that's saying "you're free to leave behind the tool you've
chosen for another one, because really, that tool should not start to
support things that i dont happen to have a use for."
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 09:47:29 von Per Jessen
Rene Veerman wrote:
> popular : facebook youtube etc
>=20
Rene, I must be missing something here. That sort of size implies
millions in advertising revenue, so why are we discussing how much
performance we can squeeze out of a single box? I mean, I'm all for
efficient use of system resources, but if I have a semi-scalable
application, it's a lot easier just getting another box than trying to
change the implementation language. OTOH, if my design is not
scalable, it's probably also easier to redo it than trying to change
the implementation language.
> and you're still trying to impose a toolset on me.=20
I didn't think I was - you're the one who seem to be fixed on PHP as th=
e
only solution, and advocating that it be enhanced to suit your
purposes.=20
--=20
Per Jessen, Zürich (9.2°C)
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 09:58:42 von Rene Veerman
On Wed, Mar 24, 2010 at 10:47 AM, Per Jessen wrote:
> Rene Veerman wrote:
>
>> popular : facebook youtube etc
>>
>
> Rene, I must be missing something here. =A0That sort of size implies
> millions in advertising revenue, so why are we discussing how much
> performance we can squeeze out of a single box? =A0I mean, I'm all for
> efficient use of system resources, but if I have a semi-scalable
> application, it's a lot easier just getting another box than trying to
> change the implementation language. =A0OTOH, if my design is not
> scalable, it's probably also easier to redo it than trying to change
> the implementation language.
again:
a) you're determining the contents of my toolset, without it affecting
you at all. the way you want it php will degrade into a toy language.
b) i will aim for all possible decreases in development time and
operating costs during, not only in the grow phase but also in hard
economic times. any business person knows why.
>
>> and you're still trying to impose a toolset on me.
>
> I didn't think I was - you're the one who seem to be fixed on PHP as the
> only solution, and advocating that it be enhanced to suit your
> purposes.
no, php is just my toolset of choice, and i think it should grow with
the times and support threading and shared memory.
maybe even a few cool features to enable use-as-a-cloud.
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 09:59:14 von Per Jessen
Tommy Pham wrote:
> When you do use AJAX, there is a slight difference in your app design=
> then when you don't use AJAX. That's the way I see threads.=20
A threaded design makes for a lot more than a slight difference IMHO.=20=
Once you've said "threading", the next words in rapid succession are:
mutexes, semaphores, locking, spin-locks, signals, race conditions,
atomic updates, cache coherency, asynchronous IO etcetera. They are
all perfectly well-known but complex concepts, and I would always
choose C and/or assembler to work with those.=20
--=20
Per Jessen, Zürich (9.5°C)
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 10:04:00 von Per Jessen
Rene Veerman wrote:
> funny how i've been topposting for over a year here and the complaint=
s
> start when i tell some people not to butt into my business and choice=
> of tools.
Rene, the only reason I mentioned it was because your language was
becoming abusive and annoying. If it hadn't, I wouldn't have mentioned=
your equally annoying top-posting. I've been around for long enough to=
know that most top-posters will eventually see the light.=20
--=20
Per Jessen, Zürich (9.8°C)
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 10:08:48 von Rene Veerman
exactly. the knock-on problems you mentioned are well solved and well
documented.
realtime programmers using threads have to get their heads around it
on their first realtime project.
i don't like doing my code in c(++), or worse; having to interface
between c(++) and php.
i chose php because my code can stay close to simple english that way.
what you're suggesting is highly intrusive in my work-style, one that
you're not affected by at all.
in fact if you make things more difficult for me, i have less time to
release opensource code of my own.
On Wed, Mar 24, 2010 at 10:59 AM, Per Jessen wrote:
> Tommy Pham wrote:
>
>> When you do use AJAX, there is a slight difference in your app design
>> then when you don't use AJAX. =A0That's the way I see threads.
>
> A threaded design makes for a lot more than a slight difference IMHO.
> Once you've said "threading", the next words in rapid succession are:
> mutexes, semaphores, locking, spin-locks, signals, race conditions,
> atomic updates, cache coherency, asynchronous IO etcetera. =A0They are
> all perfectly well-known but complex concepts, and I would always
> choose C and/or assembler to work with those.
>
>
>
> --
> Per Jessen, Zürich (9.5°C)
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 10:13:35 von Per Jessen
Rene Veerman wrote:
> again:
> a) you're determining the contents of my toolset, without it affectin=
g
> you at all. the way you want it php will degrade into a toy language.=
Rene, it seems to me that you and I are advocating two opposite
positions on the topic of threading in PHP, so aren't we both trying to=
determine the contents of each others toolset?=20
> b) i will aim for all possible decreases in development time and
> operating costs during, not only in the grow phase but also in hard
> economic times. any business person knows why.
Given that the lifetime effort (=3Dcost) of any software project is
divided into 25% development and 75% maintenance, you really ought to
focus on the latter. If you want more performance at a minimal cost,
surely you should opt to write in a compiled language where you'll get
far more bang for the buck. =20
--=20
Per Jessen, Zürich (9.8°C)
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 10:17:04 von Rene Veerman
On Wed, Mar 24, 2010 at 11:13 AM, Per Jessen wrote:
> Rene Veerman wrote:
>
>> again:
>> a) you're determining the contents of my toolset, without it affecting
>> you at all. the way you want it php will degrade into a toy language.
>
> Rene, it seems to me that you and I are advocating two opposite
> positions on the topic of threading in PHP, so aren't we both trying to
> determine the contents of each others toolset?
>
Per: that's EXACTLY the point.
You are determining it for me, i'm not for you.
Simply because you dont have to use the language features you atm
think you don't need in php.
>> b) i will aim for all possible decreases in development time and
>> operating costs during, not only in the grow phase but also in hard
>> economic times. any business person knows why.
>
> Given that the lifetime effort (=3Dcost) of any software project is
> divided into 25% development and 75% maintenance, you really ought to
> focus on the latter. =A0If you want more performance at a minimal cost,
> surely you should opt to write in a compiled language where you'll get
> far more bang for the buck.
>
zend? facebook compiler?
i'm staying with php coz the trend is towards jit compiling bro.
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 10:22:03 von Stut
Heh, you guys are funny!
On 24 Mar 2010, at 08:58, Rene Veerman wrote:
> On Wed, Mar 24, 2010 at 10:47 AM, Per Jessen wrote:
>> Rene Veerman wrote:
>>=20
>>> popular : facebook youtube etc
>>>=20
>>=20
>> Rene, I must be missing something here. That sort of size implies
>> millions in advertising revenue, so why are we discussing how much
>> performance we can squeeze out of a single box? I mean, I'm all for
>> efficient use of system resources, but if I have a semi-scalable
>> application, it's a lot easier just getting another box than trying =
to
>> change the implementation language. OTOH, if my design is not
>> scalable, it's probably also easier to redo it than trying to change
>> the implementation language.
>=20
> again:
> a) you're determining the contents of my toolset, without it affecting
> you at all. the way you want it php will degrade into a toy language.
And how exactly are you defining a toy language? If you want features =
like threading, why not switch to a language that already supports it?
> b) i will aim for all possible decreases in development time and
> operating costs during, not only in the grow phase but also in hard
> economic times. any business person knows why.
Yup, this is very good practice, but deciding that one particular tool =
is the only option is a fatal business decision. Use the right tool for =
the job!
What you're trying to do here is akin to taking a hammer and whittling a =
screwdriver in to the handle. It's ridiculously inefficient, and imo, =
pretty stupid.
>>> and you're still trying to impose a toolset on me.
>>=20
>> I didn't think I was - you're the one who seem to be fixed on PHP as =
the
>> only solution, and advocating that it be enhanced to suit your
>> purposes.
>=20
> no, php is just my toolset of choice, and i think it should grow with
> the times and support threading and shared memory.
> maybe even a few cool features to enable use-as-a-cloud.
PHP is a hammer, and a bloody good one at that, but you seem to want it =
to be a tool shed. Accept that it's a hammer, go visit a DIY store, find =
the right tool for the job and get on with your life!
The fact is that even if we all agree that PHP needs threading, and one =
or more people start working on putting it into the core, it will likely =
be many months before you see any sight of a working version, and even =
longer before you see a stable release.
-Stuart
--=20
http://stut.net/=
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 10:23:54 von Per Jessen
Rene Veerman wrote:
> what you're suggesting is highly intrusive in my work-style, one that=
> you're not affected by at all.
Hmm, you're the one suggesting a change, I'm suggesting no change. How=
can "no change" be intrusive?=20
> in fact if you make things more difficult for me, i have less time to=
> release opensource code of my own.
Well, we can't have that, so how about we stick to "no change", thereby=
not making anything more difficult for you. It will remain exactly as
difficult as it is today.
--=20
Per Jessen, Zürich (10.4°C)
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
RE: Will PHP ever "grow up" and have threading?
am 24.03.2010 10:24:01 von Arno Kuhl
If you added threading to the bag of tricks it already has, you're getting
into areas that make it more difficult to pick up for beginners (and that's
not to mention the technical elements involved in actually adding threading
to PHP) Currently the only other 'easy' language I know for beginners is
ColdFusion, and that's just horrible. You wouldn't want to be responsible
for sending the newbies down that path would you?! :p
Thanks,
Ash
http://www.ashleysheridan.co.uk
======================================
That's not a good argument against implementing threading, regardless of the
technical issues involved in making it work. There are plenty of more
advanced areas of php that beginners stay clear of. Just because threading
is available doesn't mean it will automatically be used or even considered
in most projects. I wrote C code for years in a large fairly complex banking
front-office system and only found a very few occasions where threading was
required to get the job done. In the majority of C and C++ code you find
very few examples of threading, either because it's not required (99.9% of
the time) or the coder didn't feel comfortable using it and found another
way to achieve the result. In the few occasions where I did use threading I
would say that most the time there was no other way of achieving the
required result. But the issues you need to solve with C are very different
to the issues you need to solve with php. I've spent more than 8 years
coding php and I haven't ever hit a brick wall because of the lack of
threading, but of course every project is different and I'm sure there are
situations out there where trying to work around the lack of threading can
cause major hassles. But as others have pointed out you use the right tools
for the job, and if php doesn't have what is required then use something
else.
Cheers
Arno
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 10:30:32 von Per Jessen
Rene Veerman wrote:
>>> b) i will aim for all possible decreases in development time and
>>> operating costs during, not only in the grow phase but also in hard=
>>> economic times. any business person knows why.
>>
>> Given that the lifetime effort (=3Dcost) of any software project is
>> divided into 25% development and 75% maintenance, you really ought t=
o
>> focus on the latter. Â If you want more performance at a minimal=
cost,
>> surely you should opt to write in a compiled language where you'll
>> get far more bang for the buck.
>>
> zend? facebook compiler?
C, then assembler. C for productivity, assembler for raw speed. PHP
for prototyping and web frontends (to which it is very well suited
IMHO). (assembler is usually bad for both productivity and
maintenance, but if speed is paramount, well).
--=20
Per Jessen, Zürich (10.4°C)
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 10:31:20 von Rene Veerman
php is not a hammer, its a programming language.
one that i feel needs to stay ahead of the computing trend if it is to
be considered a language for large scale applications.
but you nay-sayers here have convinced me; i'll be shopping for
another language with which to serve my applications and the weboutput
they produce..
thanks for opening my eyes and telling to abandon ship in time.
On Wed, Mar 24, 2010 at 11:22 AM, Stuart Dallas wrote:
> Heh, you guys are funny!
>
> On 24 Mar 2010, at 08:58, Rene Veerman wrote:
>
>> On Wed, Mar 24, 2010 at 10:47 AM, Per Jessen wrote:
>>> Rene Veerman wrote:
>>>
>>>> popular : facebook youtube etc
>>>>
>>>
>>> Rene, I must be missing something here. =A0That sort of size implies
>>> millions in advertising revenue, so why are we discussing how much
>>> performance we can squeeze out of a single box? =A0I mean, I'm all for
>>> efficient use of system resources, but if I have a semi-scalable
>>> application, it's a lot easier just getting another box than trying to
>>> change the implementation language. =A0OTOH, if my design is not
>>> scalable, it's probably also easier to redo it than trying to change
>>> the implementation language.
>>
>> again:
>> a) you're determining the contents of my toolset, without it affecting
>> you at all. the way you want it php will degrade into a toy language.
>
> And how exactly are you defining a toy language? If you want features lik=
e threading, why not switch to a language that already supports it?
>
>> b) i will aim for all possible decreases in development time and
>> operating costs during, not only in the grow phase but also in hard
>> economic times. any business person knows why.
>
> Yup, this is very good practice, but deciding that one particular tool is=
the only option is a fatal business decision. Use the right tool for the j=
ob!
>
> What you're trying to do here is akin to taking a hammer and whittling a =
screwdriver in to the handle. It's ridiculously inefficient, and imo, prett=
y stupid.
>
>>>> and you're still trying to impose a toolset on me.
>>>
>>> I didn't think I was - you're the one who seem to be fixed on PHP as th=
e
>>> only solution, and advocating that it be enhanced to suit your
>>> purposes.
>>
>> no, php is just my toolset of choice, and i think it should grow with
>> the times and support threading and shared memory.
>> maybe even a few cool features to enable use-as-a-cloud.
>
> PHP is a hammer, and a bloody good one at that, but you seem to want it t=
o be a tool shed. Accept that it's a hammer, go visit a DIY store, find the=
right tool for the job and get on with your life!
>
> The fact is that even if we all agree that PHP needs threading, and one o=
r more people start working on putting it into the core, it will likely be =
many months before you see any sight of a working version, and even longer =
before you see a stable release.
>
> -Stuart
>
> --
> http://stut.net/
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 10:36:07 von Rene Veerman
unless the actual php development team would like to weigh in on this
matter of course.
yes, i do consider it that important.
these nay-sayers usually also lobby the dev-team to such extent that
these features would actually not make it into php.
On Wed, Mar 24, 2010 at 11:31 AM, Rene Veerman wrote:
> php is not a hammer, its a programming language.
>
> one that i feel needs to stay ahead of the computing trend if it is to
> be considered a language for large scale applications.
>
> but you nay-sayers here have convinced me; i'll be shopping for
> another language with which to serve my applications and the weboutput
> they produce..
>
> thanks for opening my eyes and telling to abandon ship in time.
>
>
> On Wed, Mar 24, 2010 at 11:22 AM, Stuart Dallas wrote=
:
>> Heh, you guys are funny!
>>
>> On 24 Mar 2010, at 08:58, Rene Veerman wrote:
>>
>>> On Wed, Mar 24, 2010 at 10:47 AM, Per Jessen wrote:
>>>> Rene Veerman wrote:
>>>>
>>>>> popular : facebook youtube etc
>>>>>
>>>>
>>>> Rene, I must be missing something here. =A0That sort of size implies
>>>> millions in advertising revenue, so why are we discussing how much
>>>> performance we can squeeze out of a single box? =A0I mean, I'm all for
>>>> efficient use of system resources, but if I have a semi-scalable
>>>> application, it's a lot easier just getting another box than trying to
>>>> change the implementation language. =A0OTOH, if my design is not
>>>> scalable, it's probably also easier to redo it than trying to change
>>>> the implementation language.
>>>
>>> again:
>>> a) you're determining the contents of my toolset, without it affecting
>>> you at all. the way you want it php will degrade into a toy language.
>>
>> And how exactly are you defining a toy language? If you want features li=
ke threading, why not switch to a language that already supports it?
>>
>>> b) i will aim for all possible decreases in development time and
>>> operating costs during, not only in the grow phase but also in hard
>>> economic times. any business person knows why.
>>
>> Yup, this is very good practice, but deciding that one particular tool i=
s the only option is a fatal business decision. Use the right tool for the =
job!
>>
>> What you're trying to do here is akin to taking a hammer and whittling a=
screwdriver in to the handle. It's ridiculously inefficient, and imo, pret=
ty stupid.
>>
>>>>> and you're still trying to impose a toolset on me.
>>>>
>>>> I didn't think I was - you're the one who seem to be fixed on PHP as t=
he
>>>> only solution, and advocating that it be enhanced to suit your
>>>> purposes.
>>>
>>> no, php is just my toolset of choice, and i think it should grow with
>>> the times and support threading and shared memory.
>>> maybe even a few cool features to enable use-as-a-cloud.
>>
>> PHP is a hammer, and a bloody good one at that, but you seem to want it =
to be a tool shed. Accept that it's a hammer, go visit a DIY store, find th=
e right tool for the job and get on with your life!
>>
>> The fact is that even if we all agree that PHP needs threading, and one =
or more people start working on putting it into the core, it will likely be=
many months before you see any sight of a working version, and even longer=
before you see a stable release.
>>
>> -Stuart
>>
>> --
>> http://stut.net/
>
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 10:38:49 von Rene Veerman
and if threading and shared memory aren't implemented, then hey, the
php dev team can build something else in that these naysayers DO need
eh...
lol...
On Wed, Mar 24, 2010 at 11:36 AM, Rene Veerman wrote:
> unless the actual php development team would like to weigh in on this
> matter of course.
>
> yes, i do consider it that important.
>
> these nay-sayers usually also lobby the dev-team to such extent that
> these features would actually not make it into php.
>
> On Wed, Mar 24, 2010 at 11:31 AM, Rene Veerman wrote=
:
>> php is not a hammer, its a programming language.
>>
>> one that i feel needs to stay ahead of the computing trend if it is to
>> be considered a language for large scale applications.
>>
>> but you nay-sayers here have convinced me; i'll be shopping for
>> another language with which to serve my applications and the weboutput
>> they produce..
>>
>> thanks for opening my eyes and telling to abandon ship in time.
>>
>>
>> On Wed, Mar 24, 2010 at 11:22 AM, Stuart Dallas wrot=
e:
>>> Heh, you guys are funny!
>>>
>>> On 24 Mar 2010, at 08:58, Rene Veerman wrote:
>>>
>>>> On Wed, Mar 24, 2010 at 10:47 AM, Per Jessen wrote:
>>>>> Rene Veerman wrote:
>>>>>
>>>>>> popular : facebook youtube etc
>>>>>>
>>>>>
>>>>> Rene, I must be missing something here. =A0That sort of size implies
>>>>> millions in advertising revenue, so why are we discussing how much
>>>>> performance we can squeeze out of a single box? =A0I mean, I'm all fo=
r
>>>>> efficient use of system resources, but if I have a semi-scalable
>>>>> application, it's a lot easier just getting another box than trying t=
o
>>>>> change the implementation language. =A0OTOH, if my design is not
>>>>> scalable, it's probably also easier to redo it than trying to change
>>>>> the implementation language.
>>>>
>>>> again:
>>>> a) you're determining the contents of my toolset, without it affecting
>>>> you at all. the way you want it php will degrade into a toy language.
>>>
>>> And how exactly are you defining a toy language? If you want features l=
ike threading, why not switch to a language that already supports it?
>>>
>>>> b) i will aim for all possible decreases in development time and
>>>> operating costs during, not only in the grow phase but also in hard
>>>> economic times. any business person knows why.
>>>
>>> Yup, this is very good practice, but deciding that one particular tool =
is the only option is a fatal business decision. Use the right tool for the=
job!
>>>
>>> What you're trying to do here is akin to taking a hammer and whittling =
a screwdriver in to the handle. It's ridiculously inefficient, and imo, pre=
tty stupid.
>>>
>>>>>> and you're still trying to impose a toolset on me.
>>>>>
>>>>> I didn't think I was - you're the one who seem to be fixed on PHP as =
the
>>>>> only solution, and advocating that it be enhanced to suit your
>>>>> purposes.
>>>>
>>>> no, php is just my toolset of choice, and i think it should grow with
>>>> the times and support threading and shared memory.
>>>> maybe even a few cool features to enable use-as-a-cloud.
>>>
>>> PHP is a hammer, and a bloody good one at that, but you seem to want it=
to be a tool shed. Accept that it's a hammer, go visit a DIY store, find t=
he right tool for the job and get on with your life!
>>>
>>> The fact is that even if we all agree that PHP needs threading, and one=
or more people start working on putting it into the core, it will likely b=
e many months before you see any sight of a working version, and even longe=
r before you see a stable release.
>>>
>>> -Stuart
>>>
>>> --
>>> http://stut.net/
>>
>
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 10:40:41 von Ashley Sheridan
--=-LYJx9s8Ke4qMDNr8HT2f
Content-Type: text/plain
Content-Transfer-Encoding: 7bit
On Wed, 2010-03-24 at 11:36 +0200, Rene Veerman wrote:
> these nay-sayers usually also lobby the dev-team to such extent that
> these features would actually not make it into php
I assume you have some proof for that accusation?
This thread has almost now turned into a platform for insulting each
other. Why do those few feel it necessary to do this on what could
otherwise be an intelligent discussion?
There are clearly two sides for this, although it does seem that the
majority of this list (or at least those that have participated in the
thread) are in favour of not including threading support in PHP.
Rene, clearly you feel strongly about this. Why don't you ask on the
internals list, as that is where you'll get the best response about
whether or not it is something that is feasible (although feasibility is
no indicator of whether it will be included or not)
Thanks,
Ash
http://www.ashleysheridan.co.uk
--=-LYJx9s8Ke4qMDNr8HT2f--
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 10:43:27 von Peter Lind
On 24 March 2010 10:38, Rene Veerman wrote:
> and if threading and shared memory aren't implemented, then hey, the
> php dev team can build something else in that these naysayers DO need
> eh...
>
> lol...
Do you have any idea how sad and pathetic you come across? I'm very
sorry to say this, but really, now's the time to stop posting and step
back, take a deep breath, then focus on something else.
> On Wed, Mar 24, 2010 at 11:36 AM, Rene Veerman wrote=
:
>> unless the actual php development team would like to weigh in on this
>> matter of course.
>>
>> yes, i do consider it that important.
>>
>> these nay-sayers usually also lobby the dev-team to such extent that
>> these features would actually not make it into php.
>>
>> On Wed, Mar 24, 2010 at 11:31 AM, Rene Veerman wrot=
e:
>>> php is not a hammer, its a programming language.
>>>
>>> one that i feel needs to stay ahead of the computing trend if it is to
>>> be considered a language for large scale applications.
>>>
>>> but you nay-sayers here have convinced me; i'll be shopping for
>>> another language with which to serve my applications and the weboutput
>>> they produce..
>>>
>>> thanks for opening my eyes and telling to abandon ship in time.
>>>
>>>
>>> On Wed, Mar 24, 2010 at 11:22 AM, Stuart Dallas wro=
te:
>>>> Heh, you guys are funny!
>>>>
>>>> On 24 Mar 2010, at 08:58, Rene Veerman wrote:
>>>>
>>>>> On Wed, Mar 24, 2010 at 10:47 AM, Per Jessen wrote=
:
>>>>>> Rene Veerman wrote:
>>>>>>
>>>>>>> popular : facebook youtube etc
>>>>>>>
>>>>>>
>>>>>> Rene, I must be missing something here. Â That sort of size impl=
ies
>>>>>> millions in advertising revenue, so why are we discussing how much
>>>>>> performance we can squeeze out of a single box? Â I mean, I'm al=
l for
>>>>>> efficient use of system resources, but if I have a semi-scalable
>>>>>> application, it's a lot easier just getting another box than trying =
to
>>>>>> change the implementation language. Â OTOH, if my design is not
>>>>>> scalable, it's probably also easier to redo it than trying to change
>>>>>> the implementation language.
>>>>>
>>>>> again:
>>>>> a) you're determining the contents of my toolset, without it affectin=
g
>>>>> you at all. the way you want it php will degrade into a toy language.
>>>>
>>>> And how exactly are you defining a toy language? If you want features =
like threading, why not switch to a language that already supports it?
>>>>
>>>>> b) i will aim for all possible decreases in development time and
>>>>> operating costs during, not only in the grow phase but also in hard
>>>>> economic times. any business person knows why.
>>>>
>>>> Yup, this is very good practice, but deciding that one particular tool=
is the only option is a fatal business decision. Use the right tool for th=
e job!
>>>>
>>>> What you're trying to do here is akin to taking a hammer and whittling=
a screwdriver in to the handle. It's ridiculously inefficient, and imo, pr=
etty stupid.
>>>>
>>>>>>> and you're still trying to impose a toolset on me.
>>>>>>
>>>>>> I didn't think I was - you're the one who seem to be fixed on PHP as=
the
>>>>>> only solution, and advocating that it be enhanced to suit your
>>>>>> purposes.
>>>>>
>>>>> no, php is just my toolset of choice, and i think it should grow with
>>>>> the times and support threading and shared memory.
>>>>> maybe even a few cool features to enable use-as-a-cloud.
>>>>
>>>> PHP is a hammer, and a bloody good one at that, but you seem to want i=
t to be a tool shed. Accept that it's a hammer, go visit a DIY store, find =
the right tool for the job and get on with your life!
>>>>
>>>> The fact is that even if we all agree that PHP needs threading, and on=
e or more people start working on putting it into the core, it will likely =
be many months before you see any sight of a working version, and even long=
er before you see a stable release.
>>>>
>>>> -Stuart
>>>>
>>>> --
>>>> http://stut.net/
>>>
>>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>
--=20
WWW: http://plphp.dk / http://plind.dk
LinkedIn: http://www.linkedin.com/in/plind
Flickr: http://www.flickr.com/photos/fake51
BeWelcome: Fake51
Couchsurfing: Fake51
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 10:46:33 von jose javier parra sanchez
On 24 March 2010 10:38, Rene Veerman wrote:
> and if threading and shared memory aren't implemented, then hey, the
> php dev team can build something else in that these naysayers DO need
> eh...
>
> lol...
>
take a look at this -> http://nanoserv.si.kz/
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
RE: Will PHP ever "grow up" and have threading?
am 24.03.2010 10:54:46 von Arno Kuhl
-----Original Message-----
From: Rene Veerman [mailto:rene7705@gmail.com]
Sent: 24 March 2010 11:31 AM
Subject: Re: [PHP] Will PHP ever "grow up" and have threading?
thanks for opening my eyes and telling to abandon ship in time.
===============================
Bye, enjoy the swim...
Maybe by the time you get back to shore you'll realise how dumb it would be
if a sailor complained that his yatch didn't behave like a hovercraft, or
his passenger ship couldn't carry a million barrels of oil, or his tug boat
was useless at pulling a skier... Just how much (or little) development
experience do you have?
Cheers
Arno
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 10:55:33 von Ashley Sheridan
--=-8HyG6DJB9j5Jb4FlsqHo
Content-Type: text/plain
Content-Transfer-Encoding: 7bit
On Wed, 2010-03-24 at 11:56 +0200, Rene Veerman wrote:
> sad and pathetic? how about "revealing".
>
> i can call your sad and pathetic for:
> - insisting on how others should do their work.
> - group-attacking your opposition, hoping to intimidate by outnumbering.
> - ignoring all valid explanations on why someone would like their fav
> tool to evolve with the market.
> - degrading into petty insults as a way to indicate i'm probably right
> about the claim that led you to petty insults.
>
> i can go on, but i just dont want another political battle on my hands.
>
> i'll find out what the php dev team thinks about this issue, and base
> my descision on whether or not to leave php behind, on that.
>
> but you people truly are worthy of some serious IRL larting for being
> such assholes who think they can determine the habits of others that
> don't affect them.
> i dont usually do this, have never done it to programmers; but you're
> lucky we're not in the same buiding.
> i'd get you to try and punch me, followed by a relatively nonviolent
> yet very public humiliation.
> THATS how strongly i feel about those who determine the lifestyle of
> others when it doesn't even affect them.
>
> Seriously, wars have erupted over this behaviour. The kind where axes
> and such are used to settle the issue.
Sorry Rene, but this has just made me lose all respect for you. I shan't
be too sad if you do jump ship.
Thanks,
Ash
http://www.ashleysheridan.co.uk
--=-8HyG6DJB9j5Jb4FlsqHo--
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 10:56:41 von Rene Veerman
sad and pathetic? how about "revealing".
i can call your sad and pathetic for:
- insisting on how others should do their work.
- group-attacking your opposition, hoping to intimidate by outnumbering.
- ignoring all valid explanations on why someone would like their fav
tool to evolve with the market.
- degrading into petty insults as a way to indicate i'm probably right
about the claim that led you to petty insults.
i can go on, but i just dont want another political battle on my hands.
i'll find out what the php dev team thinks about this issue, and base
my descision on whether or not to leave php behind, on that.
but you people truly are worthy of some serious IRL larting for being
such assholes who think they can determine the habits of others that
don't affect them.
i dont usually do this, have never done it to programmers; but you're
lucky we're not in the same buiding.
i'd get you to try and punch me, followed by a relatively nonviolent
yet very public humiliation.
THATS how strongly i feel about those who determine the lifestyle of
others when it doesn't even affect them.
Seriously, wars have erupted over this behaviour. The kind where axes
and such are used to settle the issue.
On Wed, Mar 24, 2010 at 11:43 AM, Peter Lind wrote=
:
> On 24 March 2010 10:38, Rene Veerman wrote:
>> and if threading and shared memory aren't implemented, then hey, the
>> php dev team can build something else in that these naysayers DO need
>> eh...
>>
>> lol...
>
> Do you have any idea how sad and pathetic you come across? I'm very
> sorry to say this, but really, now's the time to stop posting and step
> back, take a deep breath, then focus on something else.
>
>> On Wed, Mar 24, 2010 at 11:36 AM, Rene Veerman wrot=
e:
>>> unless the actual php development team would like to weigh in on this
>>> matter of course.
>>>
>>> yes, i do consider it that important.
>>>
>>> these nay-sayers usually also lobby the dev-team to such extent that
>>> these features would actually not make it into php.
>>>
>>> On Wed, Mar 24, 2010 at 11:31 AM, Rene Veerman wro=
te:
>>>> php is not a hammer, its a programming language.
>>>>
>>>> one that i feel needs to stay ahead of the computing trend if it is to
>>>> be considered a language for large scale applications.
>>>>
>>>> but you nay-sayers here have convinced me; i'll be shopping for
>>>> another language with which to serve my applications and the weboutput
>>>> they produce..
>>>>
>>>> thanks for opening my eyes and telling to abandon ship in time.
>>>>
>>>>
>>>> On Wed, Mar 24, 2010 at 11:22 AM, Stuart Dallas wr=
ote:
>>>>> Heh, you guys are funny!
>>>>>
>>>>> On 24 Mar 2010, at 08:58, Rene Veerman wrote:
>>>>>
>>>>>> On Wed, Mar 24, 2010 at 10:47 AM, Per Jessen wrot=
e:
>>>>>>> Rene Veerman wrote:
>>>>>>>
>>>>>>>> popular : facebook youtube etc
>>>>>>>>
>>>>>>>
>>>>>>> Rene, I must be missing something here. =A0That sort of size implie=
s
>>>>>>> millions in advertising revenue, so why are we discussing how much
>>>>>>> performance we can squeeze out of a single box? =A0I mean, I'm all =
for
>>>>>>> efficient use of system resources, but if I have a semi-scalable
>>>>>>> application, it's a lot easier just getting another box than trying=
to
>>>>>>> change the implementation language. =A0OTOH, if my design is not
>>>>>>> scalable, it's probably also easier to redo it than trying to chang=
e
>>>>>>> the implementation language.
>>>>>>
>>>>>> again:
>>>>>> a) you're determining the contents of my toolset, without it affecti=
ng
>>>>>> you at all. the way you want it php will degrade into a toy language=
..
>>>>>
>>>>> And how exactly are you defining a toy language? If you want features=
like threading, why not switch to a language that already supports it?
>>>>>
>>>>>> b) i will aim for all possible decreases in development time and
>>>>>> operating costs during, not only in the grow phase but also in hard
>>>>>> economic times. any business person knows why.
>>>>>
>>>>> Yup, this is very good practice, but deciding that one particular too=
l is the only option is a fatal business decision. Use the right tool for t=
he job!
>>>>>
>>>>> What you're trying to do here is akin to taking a hammer and whittlin=
g a screwdriver in to the handle. It's ridiculously inefficient, and imo, p=
retty stupid.
>>>>>
>>>>>>>> and you're still trying to impose a toolset on me.
>>>>>>>
>>>>>>> I didn't think I was - you're the one who seem to be fixed on PHP a=
s the
>>>>>>> only solution, and advocating that it be enhanced to suit your
>>>>>>> purposes.
>>>>>>
>>>>>> no, php is just my toolset of choice, and i think it should grow wit=
h
>>>>>> the times and support threading and shared memory.
>>>>>> maybe even a few cool features to enable use-as-a-cloud.
>>>>>
>>>>> PHP is a hammer, and a bloody good one at that, but you seem to want =
it to be a tool shed. Accept that it's a hammer, go visit a DIY store, find=
the right tool for the job and get on with your life!
>>>>>
>>>>> The fact is that even if we all agree that PHP needs threading, and o=
ne or more people start working on putting it into the core, it will likely=
be many months before you see any sight of a working version, and even lon=
ger before you see a stable release.
>>>>>
>>>>> -Stuart
>>>>>
>>>>> --
>>>>> http://stut.net/
>>>>
>>>
>>
>> --
>> PHP General Mailing List (http://www.php.net/)
>> To unsubscribe, visit: http://www.php.net/unsub.php
>>
>>
>
>
>
> --
>
> WWW: http://plphp.dk / http://plind.dk
> LinkedIn: http://www.linkedin.com/in/plind
> Flickr: http://www.flickr.com/photos/fake51
> BeWelcome: Fake51
> Couchsurfing: Fake51
>
>
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 10:58:23 von Stut
On 24 Mar 2010, at 09:36, Rene Veerman wrote:
> unless the actual php development team would like to weigh in on this
> matter of course.
>=20
> yes, i do consider it that important.
>=20
> these nay-sayers usually also lobby the dev-team to such extent that
> these features would actually not make it into php.
Frankly I don't give a crap whether threading is supported in PHP, it =
does everything I need it to do. If I need threading I use a language =
that supports it, like Python or C++.
I love the way you call us nay-sayers like it's supposed to be an =
insult. I follow the KISS principle to the nth, and as such threading in =
PHP doesn't make a lot of sense to me. I'm yet to come across a problem =
I couldn't solve with pure PHP, but when the need arises I have no issue =
mixing in a little C++, Python, Ruby, or whatever, to meet my =
performance and scalability goals. I go to the mountain, I don't sit =
there complaining that the mountain ain't moving in my direction!
My opinion, and that of most others who've weighed in, is that you're =
almost certainly looking at the problem from the wrong angle. What you =
haven't done is explicitly explain why you want threading to be =
supported. Give us a real example of why you think it should be =
supported and I guarantee we can come up with a way to get you what you =
want without requiring massive changes to the core of your chosen tool. =
And if we can't then you may actually convince us that threading would =
be a valuable feature to have available.
You mentioned Facebook as an example of a popular application. Are you =
aware that they only recently started using their compiler in =
production, and that prior to that they were happily running PHP to =
serve their front end without ever complaining that it didn't support =
threading? Even now, with hip-hop, individual requests are served in a =
single thread, so the language itself still doesn't support threading, =
and I don't hear them complaining that it's costing them a fortune. Why? =
Because it's not. And if it was they would have added it by now.
One final thing... if threading is this important to you, then I'm sure =
there are a number of developers who would happily add it in a fork of =
the core for suitable compensation. Once implemented it's possible the =
internals team would accept it for addition to the official version. If =
you really believe it has the potential to save you a butt-load of cash, =
the economics of paying for it should stack up.
Oh, and feel free to escalate this to anyone you please. Nobody cares. =
Threading has been discussed before, both on this list and on internals =
(Google can tell you all about it), and every time it's been dismissed =
because the cost-benefit calculations just don't add up.
> On Wed, Mar 24, 2010 at 11:31 AM, Rene Veerman =
wrote:
>> php is not a hammer, its a programming language.
>>=20
And bravo on the metaphor appreciation failure. Love it!
-Stuart
--=20
http://stut.net/=
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 11:03:36 von Tommy Pham
What I find funny is that one of opponents of PHP threads earlier
mentioned that how silly it would be to be using C in a web app. Now
I hear people mentioning C when they need "productivity" or "speed"...
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 11:04:13 von Per Jessen
Rene Veerman wrote:
> unless the actual php development team would like to weigh in on this=
> matter of course.
>=20
> yes, i do consider it that important.
>=20
> these nay-sayers usually also lobby the dev-team to such extent that
> these features would actually not make it into php.
I for one will not be lobbying anyone in that regard. I've stated my
opinion and argued it, that's all.=20
--=20
Per Jessen, Zürich (11.2°C)
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 11:06:05 von Per Jessen
Stuart Dallas wrote:
> I love the way you call us nay-sayers like it's supposed to be an
> insult. I follow the KISS principle to the nth, and as such threading=
> in PHP doesn't make a lot of sense to me. I'm yet to come across a
> problem I couldn't solve with pure PHP, but when the need arises I
> have no issue mixing in a little C++, Python, Ruby, or whatever, to
> meet my performance and scalability goals. I go to the mountain, I
> don't sit there complaining that the mountain ain't moving in my
> direction!
+1.
--=20
Per Jessen, Zürich (11.2°C)
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 11:20:38 von Per Jessen
Tommy Pham wrote:
> What I find funny is that one of opponents of PHP threads earlier
> mentioned that how silly it would be to be using C in a web app. Now=
> I hear people mentioning C when they need "productivity" or "speed"..=
..
>=20
I think I was the one to mention the latter, but as I started out
saying, and as others have said too, it's about the right tool for the
right job. When choosing a tool, there are a number of factors to
consider - developer productivity, available skills, future
maintenance, performance, scalability, portability, parallelism,
performance etcetera. =20
--=20
Per Jessen, Zürich (11.4°C)
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 11:24:12 von Tommy Pham
On Wed, Mar 24, 2010 at 2:58 AM, Stuart Dallas wrote:
> On 24 Mar 2010, at 09:36, Rene Veerman wrote:
>
>> unless the actual php development team would like to weigh in on this
>> matter of course.
>>
>> yes, i do consider it that important.
>>
>> these nay-sayers usually also lobby the dev-team to such extent that
>> these features would actually not make it into php.
>
> Frankly I don't give a crap whether threading is supported in PHP, it doe=
s everything I need it to do. If I need threading I use a language that sup=
ports it, like Python or C++.
>
> I love the way you call us nay-sayers like it's supposed to be an insult.=
I follow the KISS principle to the nth, and as such threading in PHP doesn=
't make a lot of sense to me. I'm yet to come across a problem I couldn't s=
olve with pure PHP, but when the need arises I have no issue mixing in a li=
ttle C++, Python, Ruby, or whatever, to meet my performance and scalability=
goals. I go to the mountain, I don't sit there complaining that the mounta=
in ain't moving in my direction!
>
> My opinion, and that of most others who've weighed in, is that you're alm=
ost certainly looking at the problem from the wrong angle. What you haven't=
done is explicitly explain why you want threading to be supported. Give us=
a real example of why you think it should be supported and I guarantee we =
can come up with a way to get you what you want without requiring massive c=
hanges to the core of your chosen tool. And if we can't then you may actual=
ly convince us that threading would be a valuable feature to have available=
..
I did give a real life example, ie e-commerce site mentioned earlier.
Amazon has the similar features of my example except they have about
30 million products without (i18n). Their I18n is different web
server & db & site layout which is completely different from my
example. Setting I18n aside, having the same features as my example
with about 30 million products to response in about 3 seconds is very
good. Even though my example only have about 750,000 products, the
translations for the requested languages makes it into 750,000 * 6 =3D
4,500,000 rows of product descriptions. This is e-commerce site not a
data warehouse/mining. What would happen then if the site has over
20,000,000 product skus with similar language translations for the
descriptions? 20,000,000 * 6 =3D ... big number to me...
>
> You mentioned Facebook as an example of a popular application. Are you aw=
are that they only recently started using their compiler in production, and=
that prior to that they were happily running PHP to serve their front end =
without ever complaining that it didn't support threading? Even now, with h=
ip-hop, individual requests are served in a single thread, so the language =
itself still doesn't support threading, and I don't hear them complaining t=
hat it's costing them a fortune. Why? Because it's not. And if it was they =
would have added it by now.
>
> One final thing... if threading is this important to you, then I'm sure t=
here are a number of developers who would happily add it in a fork of the c=
ore for suitable compensation. Once implemented it's possible the internals=
team would accept it for addition to the official version. If you really b=
elieve it has the potential to save you a butt-load of cash, the economics =
of paying for it should stack up.
>
> Oh, and feel free to escalate this to anyone you please. Nobody cares. Th=
reading has been discussed before, both on this list and on internals (Goog=
le can tell you all about it), and every time it's been dismissed because t=
he cost-benefit calculations just don't add up.
>
>> On Wed, Mar 24, 2010 at 11:31 AM, Rene Veerman wrot=
e:
>>> php is not a hammer, its a programming language.
>>>
>
> And bravo on the metaphor appreciation failure. Love it!
>
> -Stuart
>
> --
> http://stut.net/
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 11:28:57 von Tommy Pham
On Wed, Mar 24, 2010 at 3:20 AM, Per Jessen wrote:
> Tommy Pham wrote:
>
>> What I find funny is that one of opponents of PHP threads earlier
>> mentioned that how silly it would be to be using C in a web app. Â N=
ow
>> I hear people mentioning C when they need "productivity" or "speed"...
>>
>
> I think I was the one to mention the latter, but as I started out
> saying, and as others have said too, it's about the right tool for the
> right job. Â When choosing a tool, there are a number of factors to
> consider - developer productivity, available skills, future
> maintenance, performance, scalability, portability, parallelism,
> performance etcetera.
>
Funny you should mention all that. Let's say that you're longer with
that company, either by direct employment or contract consultant.
You've implemented C because you need 'thread'. Now your replacement
comes in and has no clue about C even though your replacement is a PHP
guru. How much headache is maintenance gonna be? Scalability?
Portability? wow....
>
>
> --
> Per Jessen, Zürich (11.4°C)
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 11:31:37 von Stut
On 24 Mar 2010, at 10:24, Tommy Pham wrote:
> On Wed, Mar 24, 2010 at 2:58 AM, Stuart Dallas =
wrote:
>> On 24 Mar 2010, at 09:36, Rene Veerman wrote:
>>=20
>>> unless the actual php development team would like to weigh in on =
this
>>> matter of course.
>>>=20
>>> yes, i do consider it that important.
>>>=20
>>> these nay-sayers usually also lobby the dev-team to such extent that
>>> these features would actually not make it into php.
>>=20
>> Frankly I don't give a crap whether threading is supported in PHP, it =
does everything I need it to do. If I need threading I use a language =
that supports it, like Python or C++.
>>=20
>> I love the way you call us nay-sayers like it's supposed to be an =
insult. I follow the KISS principle to the nth, and as such threading in =
PHP doesn't make a lot of sense to me. I'm yet to come across a problem =
I couldn't solve with pure PHP, but when the need arises I have no issue =
mixing in a little C++, Python, Ruby, or whatever, to meet my =
performance and scalability goals. I go to the mountain, I don't sit =
there complaining that the mountain ain't moving in my direction!
>>=20
>> My opinion, and that of most others who've weighed in, is that you're =
almost certainly looking at the problem from the wrong angle. What you =
haven't done is explicitly explain why you want threading to be =
supported. Give us a real example of why you think it should be =
supported and I guarantee we can come up with a way to get you what you =
want without requiring massive changes to the core of your chosen tool. =
And if we can't then you may actually convince us that threading would =
be a valuable feature to have available.
>=20
> I did give a real life example, ie e-commerce site mentioned earlier.
> Amazon has the similar features of my example except they have about
> 30 million products without (i18n). Their I18n is different web
> server & db & site layout which is completely different from my
> example. Setting I18n aside, having the same features as my example
> with about 30 million products to response in about 3 seconds is very
> good. Even though my example only have about 750,000 products, the
> translations for the requested languages makes it into 750,000 * 6 =3D
> 4,500,000 rows of product descriptions. This is e-commerce site not a
> data warehouse/mining. What would happen then if the site has over
> 20,000,000 product skus with similar language translations for the
> descriptions? 20,000,000 * 6 =3D ... big number to me...
How exactly will threading in PHP help with the size of the database? =
That makes no sense to me, please help me understand how you think =
threading will help in this scenario.
Database size issues are tackled with clustering, caching and DB =
optimisation. Threading in the language accessing the DB has no =
advantage here.
-Stuart
--=20
http://stut.net/=
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 11:34:21 von Rene Veerman
On Wed, Mar 24, 2010 at 12:28 PM, Tommy Pham wrote:
>
> Funny you should mention all that. =A0Let's say that you're longer with
> that company, either by direct employment or contract consultant.
> You've implemented C because you need 'thread'. =A0Now your replacement
> comes in and has no clue about C even though your replacement is a PHP
> guru. =A0How much headache is maintenance gonna be? =A0Scalability?
> Portability? wow....
>
Thanks for posting this before i had to.
+1, +1, +1...
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 11:38:17 von Tommy Pham
On Wed, Mar 24, 2010 at 3:31 AM, Stuart Dallas wrote:
> On 24 Mar 2010, at 10:24, Tommy Pham wrote:
>> On Wed, Mar 24, 2010 at 2:58 AM, Stuart Dallas wrote=
:
>>> On 24 Mar 2010, at 09:36, Rene Veerman wrote:
>>>
>>>> unless the actual php development team would like to weigh in on this
>>>> matter of course.
>>>>
>>>> yes, i do consider it that important.
>>>>
>>>> these nay-sayers usually also lobby the dev-team to such extent that
>>>> these features would actually not make it into php.
>>>
>>> Frankly I don't give a crap whether threading is supported in PHP, it d=
oes everything I need it to do. If I need threading I use a language that s=
upports it, like Python or C++.
>>>
>>> I love the way you call us nay-sayers like it's supposed to be an insul=
t. I follow the KISS principle to the nth, and as such threading in PHP doe=
sn't make a lot of sense to me. I'm yet to come across a problem I couldn't=
solve with pure PHP, but when the need arises I have no issue mixing in a =
little C++, Python, Ruby, or whatever, to meet my performance and scalabili=
ty goals. I go to the mountain, I don't sit there complaining that the moun=
tain ain't moving in my direction!
>>>
>>> My opinion, and that of most others who've weighed in, is that you're a=
lmost certainly looking at the problem from the wrong angle. What you haven=
't done is explicitly explain why you want threading to be supported. Give =
us a real example of why you think it should be supported and I guarantee w=
e can come up with a way to get you what you want without requiring massive=
changes to the core of your chosen tool. And if we can't then you may actu=
ally convince us that threading would be a valuable feature to have availab=
le.
>>
>> I did give a real life example, ie e-commerce site mentioned earlier.
>> Amazon has the similar features of my example except they have about
>> 30 million products without (i18n). Â Their I18n is different web
>> server & db & site layout which is completely different from my
>> example. Â Setting I18n aside, having the same features as my exampl=
e
>> with about 30 million products to response in about 3 seconds is very
>> good. Â Even though my example only have about 750,000 products, the
>> translations for the requested languages makes it into 750,000 * 6 =3D
>> 4,500,000 rows of product descriptions. Â This is e-commerce site no=
t a
>> data warehouse/mining. Â What would happen then if the site has over
>> 20,000,000 product skus with similar language translations for the
>> descriptions? Â 20,000,000 * 6 =3D ... big number to me...
>
> How exactly will threading in PHP help with the size of the database? Tha=
t makes no sense to me, please help me understand how you think threading w=
ill help in this scenario.
Looking at my example, not just the rows.... There are other features
that require queries to a DB for simple request of a category by a
shopper, instead of running those queries in series, running them in
parallel would yield better response time.
> Database size issues are tackled with clustering, caching and DB optimisa=
tion. Threading in the language accessing the DB has no advantage here.
Yes, it does. As mentioned several times, instead of running the
queries in series, run them in parallel. If each of the queries takes
about .05 to .15 seconds. How long would it take to run them in
serial? How long do you it take to run them in parallel?
>
> -Stuart
>
> --
> http://stut.net/
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 11:38:28 von Lester Caine
Per Jessen wrote:
> Rene Veerman wrote:
>
>> what you're suggesting is highly intrusive in my work-style, one that
>> you're not affected by at all.
>
> Hmm, you're the one suggesting a change, I'm suggesting no change. How
> can "no change" be intrusive?
>
>> in fact if you make things more difficult for me, i have less time to
>> release opensource code of my own.
>
> Well, we can't have that, so how about we stick to "no change", thereby
> not making anything more difficult for you. It will remain exactly as
> difficult as it is today.
That sounds very good to me! I'm STILL working through the warnings PHP5.3
introduced. It it improve anything. No ..... 5.2 still works just as well! Ican
well understand why people stayed with PHP4 for so long - but I never used that
myself.
Perhaps we need PHPforDummies and PHPforPros ... I'll stick with the Dummies
version, if I want the pro version I can go back to C++. ;)
--
Lester Caine - G8HFL
-----------------------------
Contact - http://lsces.co.uk/wiki/?page=contact
L.S.Caine Electronic Services - http://lsces.co.uk
EnquirySolve - http://enquirysolve.com/
Model Engineers Digital Workshop - http://medw.co.uk//
Firebird - http://www.firebirdsql.org/index.php
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 11:39:07 von Stut
On 24 Mar 2010, at 10:34, Rene Veerman wrote:
> On Wed, Mar 24, 2010 at 12:28 PM, Tommy Pham =
wrote:
>>=20
>> Funny you should mention all that. Let's say that you're longer with
>> that company, either by direct employment or contract consultant.
>> You've implemented C because you need 'thread'. Now your replacement
>> comes in and has no clue about C even though your replacement is a =
PHP
>> guru. How much headache is maintenance gonna be? Scalability?
>> Portability? wow....
>>=20
> Thanks for posting this before i had to.
>=20
> +1, +1, +1...
You realise, of course, that the same argument applies to using advanced =
features of PHP, such as threading should it ever be supported.
-Stuart
--=20
http://stut.net/=
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 11:40:25 von Rene Veerman
--00151747691604af1504828990ae
Content-Type: text/plain; charset=ISO-8859-1
I subscribe to this list to share tips on software designs.
Getting and keeping your respect i'm not even interested in.
I'm interested in the quality of your tips on problems i post, as tips can
lead faster to products, leads to money, leads to my personal freedom and
options in life.
Respect cannot be used to buy bread and butter.
On Wed, Mar 24, 2010 at 11:55 AM, Ashley Sheridan
wrote:
> On Wed, 2010-03-24 at 11:56 +0200, Rene Veerman wrote:
>
> sad and pathetic? how about "revealing".
>
> i can call your sad and pathetic for:
> - insisting on how others should do their work.
> - group-attacking your opposition, hoping to intimidate by outnumbering.
> - ignoring all valid explanations on why someone would like their fav
> tool to evolve with the market.
> - degrading into petty insults as a way to indicate i'm probably right
> about the claim that led you to petty insults.
>
> i can go on, but i just dont want another political battle on my hands.
>
> i'll find out what the php dev team thinks about this issue, and base
> my descision on whether or not to leave php behind, on that.
>
> but you people truly are worthy of some serious IRL larting for being
> such assholes who think they can determine the habits of others that
> don't affect them.
> i dont usually do this, have never done it to programmers; but you're
> lucky we're not in the same buiding.
> i'd get you to try and punch me, followed by a relatively nonviolent
> yet very public humiliation.
> THATS how strongly i feel about those who determine the lifestyle of
> others when it doesn't even affect them.
>
> Seriously, wars have erupted over this behaviour. The kind where axes
> and such are used to settle the issue.
>
>
>
> Sorry Rene, but this has just made me lose all respect for you. I shan't be
> too sad if you do jump ship.
>
>
> Thanks,
> Ash
> http://www.ashleysheridan.co.uk
>
>
>
--00151747691604af1504828990ae--
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 11:40:56 von Ashley Sheridan
--=-THg2p9Xq7giwjKtKjC9V
Content-Type: text/plain
Content-Transfer-Encoding: 7bit
On Wed, 2010-03-24 at 03:38 -0700, Tommy Pham wrote:
> On Wed, Mar 24, 2010 at 3:31 AM, Stuart Dallas wrote:
> > On 24 Mar 2010, at 10:24, Tommy Pham wrote:
> >> On Wed, Mar 24, 2010 at 2:58 AM, Stuart Dallas wrote:
> >>> On 24 Mar 2010, at 09:36, Rene Veerman wrote:
> >>>
> >>>> unless the actual php development team would like to weigh in on this
> >>>> matter of course.
> >>>>
> >>>> yes, i do consider it that important.
> >>>>
> >>>> these nay-sayers usually also lobby the dev-team to such extent that
> >>>> these features would actually not make it into php.
> >>>
> >>> Frankly I don't give a crap whether threading is supported in PHP, it does everything I need it to do. If I need threading I use a language that supports it, like Python or C++.
> >>>
> >>> I love the way you call us nay-sayers like it's supposed to be an insult. I follow the KISS principle to the nth, and as such threading in PHP doesn't make a lot of sense to me. I'm yet to come across a problem I couldn't solve with pure PHP, but when the need arises I have no issue mixing in a little C++, Python, Ruby, or whatever, to meet my performance and scalability goals. I go to the mountain, I don't sit there complaining that the mountain ain't moving in my direction!
> >>>
> >>> My opinion, and that of most others who've weighed in, is that you're almost certainly looking at the problem from the wrong angle. What you haven't done is explicitly explain why you want threading to be supported. Give us a real example of why you think it should be supported and I guarantee we can come up with a way to get you what you want without requiring massive changes to the core of your chosen tool. And if we can't then you may actually convince us that threading would be a valuable feature to have available.
> >>
> >> I did give a real life example, ie e-commerce site mentioned earlier.
> >> Amazon has the similar features of my example except they have about
> >> 30 million products without (i18n). Their I18n is different web
> >> server & db & site layout which is completely different from my
> >> example. Setting I18n aside, having the same features as my example
> >> with about 30 million products to response in about 3 seconds is very
> >> good. Even though my example only have about 750,000 products, the
> >> translations for the requested languages makes it into 750,000 * 6 =
> >> 4,500,000 rows of product descriptions. This is e-commerce site not a
> >> data warehouse/mining. What would happen then if the site has over
> >> 20,000,000 product skus with similar language translations for the
> >> descriptions? 20,000,000 * 6 = ... big number to me...
> >
> > How exactly will threading in PHP help with the size of the database? That makes no sense to me, please help me understand how you think threading will help in this scenario.
>
> Looking at my example, not just the rows.... There are other features
> that require queries to a DB for simple request of a category by a
> shopper, instead of running those queries in series, running them in
> parallel would yield better response time.
>
>
> > Database size issues are tackled with clustering, caching and DB optimisation. Threading in the language accessing the DB has no advantage here.
>
> Yes, it does. As mentioned several times, instead of running the
> queries in series, run them in parallel. If each of the queries takes
> about .05 to .15 seconds. How long would it take to run them in
> serial? How long do you it take to run them in parallel?
>
> >
> > -Stuart
> >
> > --
> > http://stut.net/
>
The database is still a bottleneck. Now instead of processing one query
at a time for a PHP script, it's processing 3 because you want them
processed in parallel. Now the database is struggling with 3 times the
work to complete in the same amount of time.
Threading hasn't helped that much here, you've just moved the problem to
an area which is already generally considered the bottleneck in most
applications.
Thanks,
Ash
http://www.ashleysheridan.co.uk
--=-THg2p9Xq7giwjKtKjC9V--
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 11:42:17 von Per Jessen
Tommy Pham wrote:
> On Wed, Mar 24, 2010 at 2:58 AM, Stuart Dallas
> wrote:
>> Give us a real example of why you think it should be
>> supported and I guarantee we can come up with a way to get you what
>> you want without requiring massive changes to the core of your chose=
n
>> tool. And if we can't then you may actually convince us that
>> threading would be a valuable feature to have available.
>=20
> I did give a real life example, ie e-commerce site mentioned earlier.=
How many _concurrent_ users do you expect - which order of magnitude:
10,100,1000,10000?
> Amazon has the similar features of my example except they have about
> 30 million products without (i18n). Their I18n is different web
> server & db & site layout which is completely different from my
> example.=20
Understood.
> Setting I18n aside, having the same features as my example=20
> with about 30 million products to response in about 3 seconds is very=
> good. Even though my example only have about 750,000 products, the
> translations for the requested languages makes it into 750,000 * 6 =3D=
> 4,500,000 rows of product descriptions. This is e-commerce site not =
a
> data warehouse/mining. What would happen then if the site has over
> 20,000,000 product skus with similar language translations for the
> descriptions? 20,000,000 * 6 =3D ... big number to me...
Thinking out loud - maybe it would make sense to have a separate
database instance/machine per language? That would enable to you to
start them all on one machine, but shift to another once the load
increases. (not dynamically, but with time).
If that's not a feasible option, maybe a mysql cluster or a very large
database server? =20
--=20
Per Jessen, Zürich (12.2°C)
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 11:44:47 von Per Jessen
Tommy Pham wrote:
> On Wed, Mar 24, 2010 at 3:20 AM, Per Jessen wrote:=
>> Tommy Pham wrote:
>>
>>> What I find funny is that one of opponents of PHP threads earlier
>>> mentioned that how silly it would be to be using C in a web app.=20=
>>> Now I hear people mentioning C when they need "productivity" or
>>> "speed"...
>>>
>>
>> I think I was the one to mention the latter, but as I started out
>> saying, and as others have said too, it's about the right tool for
>> the right job. Â When choosing a tool, there are a number of fac=
tors
>> to consider - developer productivity, available skills, future
>> maintenance, performance, scalability, portability, parallelism,
>> performance etcetera.
>>
>=20
> Funny you should mention all that. Let's say that you're longer with=
> that company, either by direct employment or contract consultant.
> You've implemented C because you need 'thread'. Now your replacement=
> comes in and has no clue about C even though your replacement is a PH=
P
> guru. How much headache is maintenance gonna be? Scalability?
> Portability? wow....
Who was the idi... who hired someone who wasn't suited for the job?=20
Tommy, that's a moot argument. You can't fit a square peg in a round
hole. =20
--=20
Per Jessen, Zürich (12.5°C)
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 11:46:03 von Rene Veerman
On Wed, Mar 24, 2010 at 11:58 AM, Stuart Dallas wrote:
> On 24 Mar 2010, at 09:36, Rene Veerman wrote:
>
>> unless the actual php development team would like to weigh in on this
>> matter of course.
>>
>> yes, i do consider it that important.
>>
>> these nay-sayers usually also lobby the dev-team to such extent that
>> these features would actually not make it into php.
>
> Frankly I don't give a crap whether threading is supported in PHP, it doe=
s everything I need it to do. If I need threading I use a language that sup=
ports it, like Python or C++.
good, so we'll put you down as a "neutral"... despite what follows;
>
> I love the way you call us nay-sayers like it's supposed to be an insult.=
I follow the KISS principle to the nth, and as such threading in PHP doesn=
't make a lot of sense to me. I'm yet to come across a problem I couldn't s=
olve with pure PHP, but when the need arises I have no issue mixing in a li=
ttle C++, Python, Ruby, or whatever, to meet my performance and scalability=
goals. I go to the mountain, I don't sit there complaining that the mounta=
in ain't moving in my direction!
your metaphor is funny but inaccurate. therefore invalid.
>
> My opinion, and that of most others who've weighed in, is that you're alm=
ost certainly looking at the problem from the wrong angle. What you haven't=
done is explicitly explain why you want threading to be supported. Give us=
a real example of why you think it should be supported and I guarantee we =
can come up with a way to get you what you want without requiring massive c=
hanges to the core of your chosen tool. And if we can't then you may actual=
ly convince us that threading would be a valuable feature to have available=
..
no sorry i don't have to. all i'll say is: realtime systems with real
work to do, are often better implemented with a non-sql solution that
can use threading and shared memory support. period.
it's so blatantly obvious that i don't feel like i have to spell out a
complete example, which YOU can then say: "ah, but there's different
ways of doing that!".
STOP TRYING TO DETERMINE MY HABITS AND CHOICE OF TOOLS.
> You mentioned Facebook as an example of a popular application. Are you aw=
are that they only recently started using their compiler in production, and=
that prior to that they were happily running PHP to serve their front end =
without ever complaining that it didn't support threading? Even now, with h=
ip-hop, individual requests are served in a single thread, so the language =
itself still doesn't support threading, and I don't hear them complaining t=
hat it's costing them a fortune. Why? Because it's not. And if it was they =
would have added it by now.
yea, they didn't complain, they had the cash income to build the
hip-hop compiler.
i thank 'm for it.
>
> One final thing... if threading is this important to you, then I'm sure t=
here are a number of developers who would happily add it in a fork of the c=
ore for suitable compensation. Once implemented it's possible the internals=
team would accept it for addition to the official version. If you really b=
elieve it has the potential to save you a butt-load of cash, the economics =
of paying for it should stack up.
I dont feel i need to pay for a programming language keeping up with the ti=
mes.
Then i'll indeed find another language to use.
>
>> On Wed, Mar 24, 2010 at 11:31 AM, Rene Veerman wrot=
e:
>>> php is not a hammer, its a programming language.
>>>
>
> And bravo on the metaphor appreciation failure. Love it!
>
> -Stuart
>
> --
> http://stut.net/
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 11:47:09 von Stut
On 24 Mar 2010, at 10:38, Tommy Pham wrote:
> On Wed, Mar 24, 2010 at 3:31 AM, Stuart Dallas =
wrote:
>> On 24 Mar 2010, at 10:24, Tommy Pham wrote:
>>> I did give a real life example, ie e-commerce site mentioned =
earlier.
>>> Amazon has the similar features of my example except they have about
>>> 30 million products without (i18n). Their I18n is different web
>>> server & db & site layout which is completely different from my
>>> example. Setting I18n aside, having the same features as my example
>>> with about 30 million products to response in about 3 seconds is =
very
>>> good. Even though my example only have about 750,000 products, the
>>> translations for the requested languages makes it into 750,000 * 6 =3D=
>>> 4,500,000 rows of product descriptions. This is e-commerce site not =
a
>>> data warehouse/mining. What would happen then if the site has over
>>> 20,000,000 product skus with similar language translations for the
>>> descriptions? 20,000,000 * 6 =3D ... big number to me...
>>=20
>> How exactly will threading in PHP help with the size of the database? =
That makes no sense to me, please help me understand how you think =
threading will help in this scenario.
>=20
> Looking at my example, not just the rows.... There are other features
> that require queries to a DB for simple request of a category by a
> shopper, instead of running those queries in series, running them in
> parallel would yield better response time.
I can see that argument, but your comment above only stated issues of =
database size, and said nothing about running queries in parallel, hence =
my confusion.
Threading would indeed allow you to run the queries in parallel, but at =
what cost? Personally I would focus on modifying the database structure =
and introducing caching to minimise the number of queries being =
executed. Threading would be my last resort if this was my major =
bottleneck.
-Stuart
--=20
http://stut.net/
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 11:48:12 von Tommy Pham
On Wed, Mar 24, 2010 at 3:39 AM, Stuart Dallas wrote:
>
> On 24 Mar 2010, at 10:34, Rene Veerman wrote:
>
>> On Wed, Mar 24, 2010 at 12:28 PM, Tommy Pham wrote:
>>>
>>> Funny you should mention all that. Â Let's say that you're longer w=
ith
>>> that company, either by direct employment or contract consultant.
>>> You've implemented C because you need 'thread'. Â Now your replacem=
ent
>>> comes in and has no clue about C even though your replacement is a PHP
>>> guru. Â How much headache is maintenance gonna be? Â Scalabilit=
y?
>>> Portability? wow....
>>>
>> Thanks for posting this before i had to.
>>
>> +1, +1, +1...
>
> You realise, of course, that the same argument applies to using advanced =
features of PHP, such as threading should it ever be supported.
>
> -Stuart
>
Thanks for supporting PHP thread. Thus, it would be a lot easier for
any PHP guru to scale, make it portable, or integrate into other PHP
apps without having to juggle C, Ruby, Python... and whatever else is
out there...
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 11:52:06 von Lester Caine
Tommy Pham wrote:
>> How exactly will threading in PHP help with the size of the database? That makes no sense to me, please help me understand how you think threading will help in this scenario.
>
> Looking at my example, not just the rows.... There are other features
> that require queries to a DB for simple request of a category by a
> shopper, instead of running those queries in series, running them in
> parallel would yield better response time.
>
>> Database size issues are tackled with clustering, caching and DB optimisation. Threading in the language accessing the DB has no advantage here.
>
> Yes, it does. As mentioned several times, instead of running the
> queries in series, run them in parallel. If each of the queries takes
> about .05 to .15 seconds. How long would it take to run them in
> serial? How long do you it take to run them in parallel?
Any you have a database that can actually handle that?
If the database is taking 0.1 seconds per query, and you have 10 queries, then
getting the data is going to take 1 second to generate. If you want some slow
query to be started, and come back for the data later, then I thought we already
had that? But again this is part of the database driver anyway. No need to add
threading to PHP to get the database connection to pull data in the most
efficient way. And one does not write the driver in PHP? We are using C there
already?
--
Lester Caine - G8HFL
-----------------------------
Contact - http://lsces.co.uk/wiki/?page=contact
L.S.Caine Electronic Services - http://lsces.co.uk
EnquirySolve - http://enquirysolve.com/
Model Engineers Digital Workshop - http://medw.co.uk//
Firebird - http://www.firebirdsql.org/index.php
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 11:53:49 von Tommy Pham
On Wed, Mar 24, 2010 at 3:44 AM, Per Jessen wrote:
> Tommy Pham wrote:
>
>> On Wed, Mar 24, 2010 at 3:20 AM, Per Jessen wrote:
>>> Tommy Pham wrote:
>>>
>>>> What I find funny is that one of opponents of PHP threads earlier
>>>> mentioned that how silly it would be to be using C in a web app.
>>>> Now I hear people mentioning C when they need "productivity" or
>>>> "speed"...
>>>>
>>>
>>> I think I was the one to mention the latter, but as I started out
>>> saying, and as others have said too, it's about the right tool for
>>> the right job. Â When choosing a tool, there are a number of factor=
s
>>> to consider - developer productivity, available skills, future
>>> maintenance, performance, scalability, portability, parallelism,
>>> performance etcetera.
>>>
>>
>> Funny you should mention all that. Â Let's say that you're longer wi=
th
>> that company, either by direct employment or contract consultant.
>> You've implemented C because you need 'thread'. Â Now your replaceme=
nt
>> comes in and has no clue about C even though your replacement is a PHP
>> guru. Â How much headache is maintenance gonna be? Â Scalability=
?
>> Portability? wow....
>
> Who was the idi... who hired someone who wasn't suited for the job?
> Tommy, that's a moot argument. Â You can't fit a square peg in a roun=
d
> hole.
>
>
>
> --
> Per Jessen, Zürich (12.5°C)
>
>
Suited for the job? You mean introduce more complexity to a problem
that what could be avoided to begin with if PHP has thread support?
hmmm....
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 11:59:31 von Tommy Pham
On Wed, Mar 24, 2010 at 3:40 AM, Ashley Sheridan
wrote:
>
> On Wed, 2010-03-24 at 03:38 -0700, Tommy Pham wrote:
>
> On Wed, Mar 24, 2010 at 3:31 AM, Stuart Dallas wrote:
> > On 24 Mar 2010, at 10:24, Tommy Pham wrote:
> >> On Wed, Mar 24, 2010 at 2:58 AM, Stuart Dallas wro=
te:
> >>> On 24 Mar 2010, at 09:36, Rene Veerman wrote:
> >>>
> >>>> unless the actual php development team would like to weigh in on thi=
s
> >>>> matter of course.
> >>>>
> >>>> yes, i do consider it that important.
> >>>>
> >>>> these nay-sayers usually also lobby the dev-team to such extent that
> >>>> these features would actually not make it into php.
> >>>
> >>> Frankly I don't give a crap whether threading is supported in PHP, it=
does everything I need it to do. If I need threading I use a language that=
supports it, like Python or C++.
> >>>
> >>> I love the way you call us nay-sayers like it's supposed to be an ins=
ult. I follow the KISS principle to the nth, and as such threading in PHP d=
oesn't make a lot of sense to me. I'm yet to come across a problem I couldn=
't solve with pure PHP, but when the need arises I have no issue mixing in =
a little C++, Python, Ruby, or whatever, to meet my performance and scalabi=
lity goals. I go to the mountain, I don't sit there complaining that the mo=
untain ain't moving in my direction!
> >>>
> >>> My opinion, and that of most others who've weighed in, is that you're=
almost certainly looking at the problem from the wrong angle. What you hav=
en't done is explicitly explain why you want threading to be supported. Giv=
e us a real example of why you think it should be supported and I guarantee=
we can come up with a way to get you what you want without requiring massi=
ve changes to the core of your chosen tool. And if we can't then you may ac=
tually convince us that threading would be a valuable feature to have avail=
able.
> >>
> >> I did give a real life example, ie e-commerce site mentioned earlier.
> >> Amazon has the similar features of my example except they have about
> >> 30 million products without (i18n). Â Their I18n is different web
> >> server & db & site layout which is completely different from my
> >> example. Â Setting I18n aside, having the same features as my exam=
ple
> >> with about 30 million products to response in about 3 seconds is very
> >> good. Â Even though my example only have about 750,000 products, t=
he
> >> translations for the requested languages makes it into 750,000 * 6 =3D
> >> 4,500,000 rows of product descriptions. Â This is e-commerce site =
not a
> >> data warehouse/mining. Â What would happen then if the site has ov=
er
> >> 20,000,000 product skus with similar language translations for the
> >> descriptions? Â 20,000,000 * 6 =3D ... big number to me...
> >
> > How exactly will threading in PHP help with the size of the database? T=
hat makes no sense to me, please help me understand how you think threading=
will help in this scenario.
>
> Looking at my example, not just the rows.... There are other features
> that require queries to a DB for simple request of a category by a
> shopper, instead of running those queries in series, running them in
> parallel would yield better response time.
>
>
> > Database size issues are tackled with clustering, caching and DB optimi=
sation. Threading in the language accessing the DB has no advantage here.
>
> Yes, it does. As mentioned several times, instead of running the
> queries in series, run them in parallel. If each of the queries takes
> about .05 to .15 seconds. How long would it take to run them in
> serial? How long do you it take to run them in parallel?
>
> >
> > -Stuart
> >
> > --
> > http://stut.net/
>
>
> The database is still a bottleneck. Now instead of processing one query a=
t a time for a PHP script, it's processing 3 because you want them processe=
d in parallel. Now the database is struggling with 3 times the work to comp=
lete in the same amount of time.
>
> Threading hasn't helped that much here, you've just moved the problem to =
an area which is already generally considered the bottleneck in most applic=
ations.
>
> Thanks,
> Ash
> http://www.ashleysheridan.co.uk
>
>
Take your current project. Look at the page where the most queries
are executed. Time how long it would take to run each of those
queries in your SQL GUI Tool. Add the numbers together. Now think
how long it would take to run those same queries under the same
conditions in parallel. ... :)
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 12:04:00 von Tommy Pham
On Wed, Mar 24, 2010 at 3:52 AM, Lester Caine wrote:
> Tommy Pham wrote:
>>>
>>> How exactly will threading in PHP help with the size of the database?
>>> That makes no sense to me, please help me understand how you think thre=
ading
>>> will help in this scenario.
>>
>> Looking at my example, not just the rows.... Â There are other featu=
res
>> that require queries to a DB for simple request of a category by a
>> shopper, Â instead of running those queries in series, running them =
in
>> parallel would yield better response time.
>>
>>> Database size issues are tackled with clustering, caching and DB
>>> optimisation. Threading in the language accessing the DB has no advanta=
ge
>>> here.
>>
>> Yes, it does. Â As mentioned several times, instead of running the
>> queries in series, run them in parallel. Â If each of the queries ta=
kes
>> about .05 to .15 seconds. Â How long would it take to run them in
>> serial? Â How long do you it take to run them in parallel?
>
> Any you have a database that can actually handle that?
> If the database is taking 0.1 seconds per query, and you have 10 queries,
> then getting the data is going to take 1 second to generate. If you want
> some slow query to be started, and come back for the data later, then I
> thought we already had that? But again this is part of the database drive=
r
> anyway. No need to add threading to PHP to get the database connection to
> pull data in the most efficient way. And one does not write the driver in
> PHP? We are using C there already?
>
> --
> Lester Caine - G8HFL
> -----------------------------
> Contact - http://lsces.co.uk/wiki/?page=3Dcontact
> L.S.Caine Electronic Services - http://lsces.co.uk
> EnquirySolve - http://enquirysolve.com/
> Model Engineers Digital Workshop - http://medw.co.uk//
> Firebird - http://www.firebirdsql.org/index.php
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>
Exactly my point. 10 queries taking .1 second each running in serial
is 1 second total. How long would it take to run all those same
queries simultaneously??? What's so difficult about the concept of
serial vs parallel?
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 12:04:43 von Peter Lind
On 24 March 2010 11:53, Tommy Pham wrote:
> On Wed, Mar 24, 2010 at 3:44 AM, Per Jessen wrote:
>> Tommy Pham wrote:
>>
>>> On Wed, Mar 24, 2010 at 3:20 AM, Per Jessen wrote:
>>>> Tommy Pham wrote:
>>>>
>>>>> What I find funny is that one of opponents of PHP threads earlier
>>>>> mentioned that how silly it would be to be using C in a web app.
>>>>> Now I hear people mentioning C when they need "productivity" or
>>>>> "speed"...
>>>>>
>>>>
>>>> I think I was the one to mention the latter, but as I started out
>>>> saying, and as others have said too, it's about the right tool for
>>>> the right job. Â When choosing a tool, there are a number of facto=
rs
>>>> to consider - developer productivity, available skills, future
>>>> maintenance, performance, scalability, portability, parallelism,
>>>> performance etcetera.
>>>>
>>>
>>> Funny you should mention all that. Â Let's say that you're longer w=
ith
>>> that company, either by direct employment or contract consultant.
>>> You've implemented C because you need 'thread'. Â Now your replacem=
ent
>>> comes in and has no clue about C even though your replacement is a PHP
>>> guru. Â How much headache is maintenance gonna be? Â Scalabilit=
y?
>>> Portability? wow....
>>
>> Who was the idi... who hired someone who wasn't suited for the job?
>> Tommy, that's a moot argument. Â You can't fit a square peg in a rou=
nd
>> hole.
>>
>>
>>
>> --
>> Per Jessen, Zürich (12.5°C)
>>
>>
>
> Suited for the job? Â You mean introduce more complexity to a problem
> that what could be avoided to begin with if PHP has thread support?
> hmmm....
Except, you already introduced complexity into the problem. You see,
working with threads is another requirement, whether it be done in PHP
or not. Hence, hiring the right guy is independent of whether you have
threads in PHP or not - your problem is no less nor no more complex
whether you do threading inside or outside PHP. You just assume that
adding thread support to PHP will solve the problem, but there's no
actual basis to believe this.
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>
--=20
WWW: http://plphp.dk / http://plind.dk
LinkedIn: http://www.linkedin.com/in/plind
Flickr: http://www.flickr.com/photos/fake51
BeWelcome: Fake51
Couchsurfing: Fake51
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 12:09:35 von Peter Lind
On 24 March 2010 12:04, Tommy Pham wrote:
> On Wed, Mar 24, 2010 at 3:52 AM, Lester Caine wrote:
>> Tommy Pham wrote:
>>>>
>>>> How exactly will threading in PHP help with the size of the database?
>>>> That makes no sense to me, please help me understand how you think thr=
eading
>>>> will help in this scenario.
>>>
>>> Looking at my example, not just the rows.... Â There are other feat=
ures
>>> that require queries to a DB for simple request of a category by a
>>> shopper, Â instead of running those queries in series, running them=
in
>>> parallel would yield better response time.
>>>
>>>> Database size issues are tackled with clustering, caching and DB
>>>> optimisation. Threading in the language accessing the DB has no advant=
age
>>>> here.
>>>
>>> Yes, it does. Â As mentioned several times, instead of running the
>>> queries in series, run them in parallel. Â If each of the queries t=
akes
>>> about .05 to .15 seconds. Â How long would it take to run them in
>>> serial? Â How long do you it take to run them in parallel?
>>
>> Any you have a database that can actually handle that?
>> If the database is taking 0.1 seconds per query, and you have 10 queries=
,
>> then getting the data is going to take 1 second to generate. If you want
>> some slow query to be started, and come back for the data later, then I
>> thought we already had that? But again this is part of the database driv=
er
>> anyway. No need to add threading to PHP to get the database connection t=
o
>> pull data in the most efficient way. And one does not write the driver i=
n
>> PHP? We are using C there already?
>>
>> --
>> Lester Caine - G8HFL
>> -----------------------------
>> Contact - http://lsces.co.uk/wiki/?page=3Dcontact
>> L.S.Caine Electronic Services - http://lsces.co.uk
>> EnquirySolve - http://enquirysolve.com/
>> Model Engineers Digital Workshop - http://medw.co.uk//
>> Firebird - http://www.firebirdsql.org/index.php
>>
>> --
>> PHP General Mailing List (http://www.php.net/)
>> To unsubscribe, visit: http://www.php.net/unsub.php
>>
>>
>
> Exactly my point. Â 10 queries taking .1 second each running in seria=
l
> is 1 second total. Â How long would it take to run all those same
> queries simultaneously??? What's so difficult about the concept of
> serial vs parallel?
Hmm, just wondering, but how long do you think it will take your
high-traffic site to buckle under the load of the database queries you
want to execute when now you want all of them to execute at the same
time? Going with the "10 queries of .1 second each" ... how far do you
think you can scale that before you overload your database server? I'm
just wondering here, I could be completely off the bat.
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>
--=20
WWW: http://plphp.dk / http://plind.dk
LinkedIn: http://www.linkedin.com/in/plind
Flickr: http://www.flickr.com/photos/fake51
BeWelcome: Fake51
Couchsurfing: Fake51
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 12:13:06 von Rene Veerman
yea right..
i really want to keep my code base in 1 language, because that
simplifies everything later on imo.
you people, who are against the evolotion of php towards cloud
computing, would force me to do mixed-languages projects or even
rewrite large sections of my codebase if as i want, i keep my codebase
in 1 language.
maybe now you understand why i'm so pissed off with you know-it-alls.
On Wed, Mar 24, 2010 at 1:04 PM, Peter Lind wrote:
> On 24 March 2010 11:53, Tommy Pham wrote:
>> On Wed, Mar 24, 2010 at 3:44 AM, Per Jessen wrote:
>>> Tommy Pham wrote:
>>>
>>>> On Wed, Mar 24, 2010 at 3:20 AM, Per Jessen wrote:
>>>>> Tommy Pham wrote:
>>>>>
>>>>>> What I find funny is that one of opponents of PHP threads earlier
>>>>>> mentioned that how silly it would be to be using C in a web app.
>>>>>> Now I hear people mentioning C when they need "productivity" or
>>>>>> "speed"...
>>>>>>
>>>>>
>>>>> I think I was the one to mention the latter, but as I started out
>>>>> saying, and as others have said too, it's about the right tool for
>>>>> the right job. =A0When choosing a tool, there are a number of factors
>>>>> to consider - developer productivity, available skills, future
>>>>> maintenance, performance, scalability, portability, parallelism,
>>>>> performance etcetera.
>>>>>
>>>>
>>>> Funny you should mention all that. =A0Let's say that you're longer wit=
h
>>>> that company, either by direct employment or contract consultant.
>>>> You've implemented C because you need 'thread'. =A0Now your replacemen=
t
>>>> comes in and has no clue about C even though your replacement is a PHP
>>>> guru. =A0How much headache is maintenance gonna be? =A0Scalability?
>>>> Portability? wow....
>>>
>>> Who was the idi... who hired someone who wasn't suited for the job?
>>> Tommy, that's a moot argument. =A0You can't fit a square peg in a round
>>> hole.
>>>
>>>
>>>
>>> --
>>> Per Jessen, Zürich (12.5°C)
>>>
>>>
>>
>> Suited for the job? =A0You mean introduce more complexity to a problem
>> that what could be avoided to begin with if PHP has thread support?
>> hmmm....
>
> Except, you already introduced complexity into the problem. You see,
> working with threads is another requirement, whether it be done in PHP
> or not. Hence, hiring the right guy is independent of whether you have
> threads in PHP or not - your problem is no less nor no more complex
> whether you do threading inside or outside PHP. You just assume that
> adding thread support to PHP will solve the problem, but there's no
> actual basis to believe this.
>
>
>> --
>> PHP General Mailing List (http://www.php.net/)
>> To unsubscribe, visit: http://www.php.net/unsub.php
>>
>>
>
>
>
> --
>
> WWW: http://plphp.dk / http://plind.dk
> LinkedIn: http://www.linkedin.com/in/plind
> Flickr: http://www.flickr.com/photos/fake51
> BeWelcome: Fake51
> Couchsurfing: Fake51
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 12:13:08 von Stut
On 24 Mar 2010, at 10:46, Rene Veerman wrote:
> On Wed, Mar 24, 2010 at 11:58 AM, Stuart Dallas =
wrote:
>> On 24 Mar 2010, at 09:36, Rene Veerman wrote:
>>=20
>>> unless the actual php development team would like to weigh in on =
this
>>> matter of course.
>>>=20
>>> yes, i do consider it that important.
>>>=20
>>> these nay-sayers usually also lobby the dev-team to such extent that
>>> these features would actually not make it into php.
>>=20
>> Frankly I don't give a crap whether threading is supported in PHP, it =
does everything I need it to do. If I need threading I use a language =
that supports it, like Python or C++.
>=20
> good, so we'll put you down as a "neutral"... despite what follows;
I'm not neutral, I just ultimately don't care either way. I'll deal with =
whatever happens rather than trying to control everything.
>> I love the way you call us nay-sayers like it's supposed to be an =
insult. I follow the KISS principle to the nth, and as such threading in =
PHP doesn't make a lot of sense to me. I'm yet to come across a problem =
I couldn't solve with pure PHP, but when the need arises I have no issue =
mixing in a little C++, Python, Ruby, or whatever, to meet my =
performance and scalability goals. I go to the mountain, I don't sit =
there complaining that the mountain ain't moving in my direction!
>=20
> your metaphor is funny but inaccurate. therefore invalid.
You say it's inaccurate, therefore invalid, but offer no argument as to =
why. You want the tools to change to fit the way you want to work, =
rather than adapting to the tools you have available. I stand by my =
metaphor, both the humour and the message.
>> My opinion, and that of most others who've weighed in, is that you're =
almost certainly looking at the problem from the wrong angle. What you =
haven't done is explicitly explain why you want threading to be =
supported. Give us a real example of why you think it should be =
supported and I guarantee we can come up with a way to get you what you =
want without requiring massive changes to the core of your chosen tool. =
And if we can't then you may actually convince us that threading would =
be a valuable feature to have available.
>=20
>=20
> no sorry i don't have to. all i'll say is: realtime systems with real
Indeed you don't have to, I never said you did.
> work to do, are often better implemented with a non-sql solution that
> can use threading and shared memory support. period.
I completely agree, but I wouldn't go near PHP for a realtime system in =
a million years. It's the wrong tool for the job.
> it's so blatantly obvious that i don't feel like i have to spell out a
> complete example, which YOU can then say: "ah, but there's different
> ways of doing that!".
> STOP TRYING TO DETERMINE MY HABITS AND CHOICE OF TOOLS.
I'm not. You seem to think we all care whether you use PHP or not. I =
don't, and I'm pretty sure nobody else does either. I'm not trying to =
tell you what to use, I'm simply pointing out that you appear to be =
fixed on PHP for some reason and I don't understand why. It makes no =
sense to me, but frankly I don't care.
>> You mentioned Facebook as an example of a popular application. Are =
you aware that they only recently started using their compiler in =
production, and that prior to that they were happily running PHP to =
serve their front end without ever complaining that it didn't support =
threading? Even now, with hip-hop, individual requests are served in a =
single thread, so the language itself still doesn't support threading, =
and I don't hear them complaining that it's costing them a fortune. Why? =
Because it's not. And if it was they would have added it by now.
>=20
> yea, they didn't complain, they had the cash income to build the
> hip-hop compiler.
> i thank 'm for it.
Way to skip over my point. Facebook is pretty much guaranteed to be a =
bigger site in terms of data size and concurrent users than anything you =
or I are ever going to be involved in, and yet they don't think =
threading in PHP is important. That was my point.
>> One final thing... if threading is this important to you, then I'm =
sure there are a number of developers who would happily add it in a fork =
of the core for suitable compensation. Once implemented it's possible =
the internals team would accept it for addition to the official version. =
If you really believe it has the potential to save you a butt-load of =
cash, the economics of paying for it should stack up.
>=20
> I dont feel i need to pay for a programming language keeping up with =
the times.
> Then i'll indeed find another language to use.
I find it curious and amusing that you think the lack of threading =
support means PHP is somehow living in the dark ages. But yeah, =
complaining that the FREE tool you've CHOSEN to use doesn't support the =
feature YOU want... yeah, that's the way to go.
-Stuart
--=20
http://stut.net/
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 12:14:35 von Tommy Pham
On Wed, Mar 24, 2010 at 4:09 AM, Peter Lind wrote:
> On 24 March 2010 12:04, Tommy Pham wrote:
>> On Wed, Mar 24, 2010 at 3:52 AM, Lester Caine wrote=
:
>>> Tommy Pham wrote:
>>>>>
>>>>> How exactly will threading in PHP help with the size of the database?
>>>>> That makes no sense to me, please help me understand how you think th=
reading
>>>>> will help in this scenario.
>>>>
>>>> Looking at my example, not just the rows.... Â There are other fea=
tures
>>>> that require queries to a DB for simple request of a category by a
>>>> shopper, Â instead of running those queries in series, running the=
m in
>>>> parallel would yield better response time.
>>>>
>>>>> Database size issues are tackled with clustering, caching and DB
>>>>> optimisation. Threading in the language accessing the DB has no advan=
tage
>>>>> here.
>>>>
>>>> Yes, it does. Â As mentioned several times, instead of running the
>>>> queries in series, run them in parallel. Â If each of the queries =
takes
>>>> about .05 to .15 seconds. Â How long would it take to run them in
>>>> serial? Â How long do you it take to run them in parallel?
>>>
>>> Any you have a database that can actually handle that?
>>> If the database is taking 0.1 seconds per query, and you have 10 querie=
s,
>>> then getting the data is going to take 1 second to generate. If you wan=
t
>>> some slow query to be started, and come back for the data later, then I
>>> thought we already had that? But again this is part of the database dri=
ver
>>> anyway. No need to add threading to PHP to get the database connection =
to
>>> pull data in the most efficient way. And one does not write the driver =
in
>>> PHP? We are using C there already?
>>>
>>> --
>>> Lester Caine - G8HFL
>>> -----------------------------
>>> Contact - http://lsces.co.uk/wiki/?page=3Dcontact
>>> L.S.Caine Electronic Services - http://lsces.co.uk
>>> EnquirySolve - http://enquirysolve.com/
>>> Model Engineers Digital Workshop - http://medw.co.uk//
>>> Firebird - http://www.firebirdsql.org/index.php
>>>
>>> --
>>> PHP General Mailing List (http://www.php.net/)
>>> To unsubscribe, visit: http://www.php.net/unsub.php
>>>
>>>
>>
>> Exactly my point. Â 10 queries taking .1 second each running in seri=
al
>> is 1 second total. Â How long would it take to run all those same
>> queries simultaneously??? What's so difficult about the concept of
>> serial vs parallel?
>
> Hmm, just wondering, but how long do you think it will take your
> high-traffic site to buckle under the load of the database queries you
> want to execute when now you want all of them to execute at the same
> time? Going with the "10 queries of .1 second each" ... how far do you
> think you can scale that before you overload your database server? I'm
> just wondering here, I could be completely off the bat.
IIRC, one of opponents of PHP thread mention load balancer/cluster or
another opponent mention 'throw money into the hardware problem'
>
>> --
>> PHP General Mailing List (http://www.php.net/)
>> To unsubscribe, visit: http://www.php.net/unsub.php
>>
>>
>
>
>
> --
>
> WWW: http://plphp.dk / http://plind.dk
> LinkedIn: http://www.linkedin.com/in/plind
> Flickr: http://www.flickr.com/photos/fake51
> BeWelcome: Fake51
> Couchsurfing: Fake51
>
>
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 12:15:36 von Stut
On 24 Mar 2010, at 10:48, Tommy Pham wrote:
> On Wed, Mar 24, 2010 at 3:39 AM, Stuart Dallas =
wrote:
>>=20
>> On 24 Mar 2010, at 10:34, Rene Veerman wrote:
>>=20
>>> On Wed, Mar 24, 2010 at 12:28 PM, Tommy Pham =
wrote:
>>>>=20
>>>> Funny you should mention all that. Let's say that you're longer =
with
>>>> that company, either by direct employment or contract consultant.
>>>> You've implemented C because you need 'thread'. Now your =
replacement
>>>> comes in and has no clue about C even though your replacement is a =
PHP
>>>> guru. How much headache is maintenance gonna be? Scalability?
>>>> Portability? wow....
>>>>=20
>>> Thanks for posting this before i had to.
>>>=20
>>> +1, +1, +1...
>>=20
>> You realise, of course, that the same argument applies to using =
advanced features of PHP, such as threading should it ever be supported.
>>=20
>> -Stuart
>>=20
>=20
> Thanks for supporting PHP thread. Thus, it would be a lot easier for
> any PHP guru to scale, make it portable, or integrate into other PHP
> apps without having to juggle C, Ruby, Python... and whatever else is
> out there...
I don't believe I did support PHP threading. My point was that using =
advanced features like threading will limit your employee choices in =
exactly the same way as having a multi-language environment.
-Stuart
--=20
http://stut.net/
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 12:19:57 von Per Jessen
Stuart Dallas wrote:
>>> I love the way you call us nay-sayers like it's supposed to be an
>>> insult. I follow the KISS principle to the nth, and as such
>>> threading in PHP doesn't make a lot of sense to me. I'm yet to come=
>>> across a problem I couldn't solve with pure PHP, but when the need
>>> arises I have no issue mixing in a little C++, Python, Ruby, or
>>> whatever, to meet my performance and scalability goals. I go to the=
>>> mountain, I don't sit there complaining that the mountain ain't
>>> moving in my direction!
>>=20
>> your metaphor is funny but inaccurate. therefore invalid.
>=20
> You say it's inaccurate, therefore invalid, but offer no argument as
> to why. You want the tools to change to fit the way you want to work,=
> rather than adapting to the tools you have available. I stand by my
> metaphor, both the humour and the message.
FWIW, I thought your metaphor was spot on. Programming is a craft,
craftsmen use tools, whether hammers or PHP.
>> work to do, are often better implemented with a non-sql solution tha=
t
>> can use threading and shared memory support. period.
>=20
> I completely agree, but I wouldn't go near PHP for a realtime system
> in a million years. It's the wrong tool for the job.
+1.=20
--=20
Per Jessen, Zürich (13.2°C)
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 12:21:36 von Lester Caine
Peter Lind wrote:
>>> Any you have a database that can actually handle that?
>>> If the database is taking 0.1 seconds per query, and you have 10 queries,
>>> then getting the data is going to take 1 second to generate. If you want
>>> some slow query to be started, and come back for the data later, then I
>>> thought we already had that? But again this is part of the database driver
>>> anyway. No need to add threading to PHP to get the database connection to
>>> pull data in the most efficient way. And one does not write the driver in
>>> PHP? We are using C there already?
>> Exactly my point. 10 queries taking .1 second each running in serial
>> is 1 second total. How long would it take to run all those same
>> queries simultaneously??? What's so difficult about the concept of
>> serial vs parallel?
>
> Hmm, just wondering, but how long do you think it will take your
> high-traffic site to buckle under the load of the database queries you
> want to execute when now you want all of them to execute at the same
> time? Going with the "10 queries of .1 second each" ... how far do you
> think you can scale that before you overload your database server? I'm
> just wondering here, I could be completely off the bat.
No you are not off bat. That was the point I was trying to make but not very
well. A database connection will normally handle one query at a time, so they
have to be serial anyway unles you can create multiple connections. What I was
asking Tommy was how he expected the database to handle 10 queries in parallel.
Yes ten cores could possibly parallel up the work, but on the whole, the
database end is going to serialise a lot of that work, so what is the real gain?
--
Lester Caine - G8HFL
-----------------------------
Contact - http://lsces.co.uk/wiki/?page=contact
L.S.Caine Electronic Services - http://lsces.co.uk
EnquirySolve - http://enquirysolve.com/
Model Engineers Digital Workshop - http://medw.co.uk//
Firebird - http://www.firebirdsql.org/index.php
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 12:27:19 von Rene Veerman
On Wed, Mar 24, 2010 at 1:13 PM, Stuart Dallas
> I find it curious and amusing that you think the lack of threading support means PHP is somehow living in the dark ages. But yeah, complaining that the FREE tool you've CHOSEN to use doesn't support the feature YOU want... yeah, that's the way to go.
>
a) i'm not the only 1 who wants that feature, or would appreciate it
when it's made available.
b) to me it's a matter of keeping php attuned with the market trends.
this thread forces me to reconsider my choice of language, because i
do code to maybe get as big as facebook one day.
it really really helps to have my codebase in a simple language like
php, and yet be able to build blackboxes in that language that do
threading and use shared memory..
imo, it saves significant time (money) and headaches (risk) when
growing from 1 server to thousands of servers.
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 12:28:09 von Per Jessen
Tommy Pham wrote:
> On Wed, Mar 24, 2010 at 3:44 AM, Per Jessen wrote:=
>> Tommy Pham wrote:
>>
>>> On Wed, Mar 24, 2010 at 3:20 AM, Per Jessen
>>> wrote:
>>>> Tommy Pham wrote:
>>>>
>>>>> What I find funny is that one of opponents of PHP threads earlier=
>>>>> mentioned that how silly it would be to be using C in a web app.
>>>>> Now I hear people mentioning C when they need "productivity" or
>>>>> "speed"...
>>>>>
>>>>
>>>> I think I was the one to mention the latter, but as I started out
>>>> saying, and as others have said too, it's about the right tool for=
>>>> the right job. Â When choosing a tool, there are a number of f=
actors
>>>> to consider - developer productivity, available skills, future
>>>> maintenance, performance, scalability, portability, parallelism,
>>>> performance etcetera.
>>>>
>>>
>>> Funny you should mention all that. Â Let's say that you're long=
er
>>> with that company, either by direct employment or contract
>>> consultant. You've implemented C because you need 'thread'. Â N=
ow
>>> your replacement comes in and has no clue about C even though your
>>> replacement is a PHP guru. Â How much headache is maintenance g=
onna
>>> be? Â Scalability? Portability? wow....
>>
>> Who was the idi... who hired someone who wasn't suited for the job?
>> Tommy, that's a moot argument. Â You can't fit a square peg in a=
round
>> hole.
>>
>> --
>> Per Jessen, Zürich (12.5°C)
>>
>=20
> Suited for the job? You mean introduce more complexity to a problem
> that what could be avoided to begin with if PHP has thread support?
> hmmm....
Tommy, it's perfectly simple: in my company we hire people with C
skills for C programming jobs. We hire people with database skills to
be database administrators. We hire people with Linux skills to work
on Linux systems. We explicitly do _not_ hire PHP web-programmers to
maintain our C code. And vice versa for that matter. No problem, no
complexity.=20
--=20
Per Jessen, Zürich (13.4°C)
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 12:31:50 von Rene Veerman
how about having a threaded php server query 10 mysql servers at the
same time? 10 results in .1 seconds!
and dont start with 'apache will handle that', there are cases where
you're best off doing it in php, so you can gather/calculate relations
from the data off 10 different servers.
On Wed, Mar 24, 2010 at 1:09 PM, Peter Lind wrote:
> On 24 March 2010 12:04, Tommy Pham wrote:
>> On Wed, Mar 24, 2010 at 3:52 AM, Lester Caine wrote=
:
>>> Tommy Pham wrote:
>>>>>
>>>>> How exactly will threading in PHP help with the size of the database?
>>>>> That makes no sense to me, please help me understand how you think th=
reading
>>>>> will help in this scenario.
>>>>
>>>> Looking at my example, not just the rows.... =A0There are other featur=
es
>>>> that require queries to a DB for simple request of a category by a
>>>> shopper, =A0instead of running those queries in series, running them i=
n
>>>> parallel would yield better response time.
>>>>
>>>>> Database size issues are tackled with clustering, caching and DB
>>>>> optimisation. Threading in the language accessing the DB has no advan=
tage
>>>>> here.
>>>>
>>>> Yes, it does. =A0As mentioned several times, instead of running the
>>>> queries in series, run them in parallel. =A0If each of the queries tak=
es
>>>> about .05 to .15 seconds. =A0How long would it take to run them in
>>>> serial? =A0How long do you it take to run them in parallel?
>>>
>>> Any you have a database that can actually handle that?
>>> If the database is taking 0.1 seconds per query, and you have 10 querie=
s,
>>> then getting the data is going to take 1 second to generate. If you wan=
t
>>> some slow query to be started, and come back for the data later, then I
>>> thought we already had that? But again this is part of the database dri=
ver
>>> anyway. No need to add threading to PHP to get the database connection =
to
>>> pull data in the most efficient way. And one does not write the driver =
in
>>> PHP? We are using C there already?
>>>
>>> --
>>> Lester Caine - G8HFL
>>> -----------------------------
>>> Contact - http://lsces.co.uk/wiki/?page=3Dcontact
>>> L.S.Caine Electronic Services - http://lsces.co.uk
>>> EnquirySolve - http://enquirysolve.com/
>>> Model Engineers Digital Workshop - http://medw.co.uk//
>>> Firebird - http://www.firebirdsql.org/index.php
>>>
>>> --
>>> PHP General Mailing List (http://www.php.net/)
>>> To unsubscribe, visit: http://www.php.net/unsub.php
>>>
>>>
>>
>> Exactly my point. =A010 queries taking .1 second each running in serial
>> is 1 second total. =A0How long would it take to run all those same
>> queries simultaneously??? What's so difficult about the concept of
>> serial vs parallel?
>
> Hmm, just wondering, but how long do you think it will take your
> high-traffic site to buckle under the load of the database queries you
> want to execute when now you want all of them to execute at the same
> time? Going with the "10 queries of .1 second each" ... how far do you
> think you can scale that before you overload your database server? I'm
> just wondering here, I could be completely off the bat.
>
>> --
>> PHP General Mailing List (http://www.php.net/)
>> To unsubscribe, visit: http://www.php.net/unsub.php
>>
>>
>
>
>
> --
>
> WWW: http://plphp.dk / http://plind.dk
> LinkedIn: http://www.linkedin.com/in/plind
> Flickr: http://www.flickr.com/photos/fake51
> BeWelcome: Fake51
> Couchsurfing: Fake51
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 12:34:55 von Per Jessen
Rene Veerman wrote:
> i really want to keep my code base in 1 language, because that
> simplifies everything later on imo.
Yes, generally speaking that's a good idea. Not always the optimal
choice when you weigh up the requirements and the available skillsets,
but nonetheless.=20
--=20
Per Jessen, Zürich (13.4°C)
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 12:42:20 von Per Jessen
Rene Veerman wrote:
> b) to me it's a matter of keeping php attuned with the market trends.=
> this thread forces me to reconsider my choice of language, because i
> do code to maybe get as big as facebook one day.
Nothing wrong with that, nothing at all. The keyword is scalability,
and that is measured by how much performance you gain by adding another=
box. You appear to be far more concerned with how much you can get out=
of a single, small box, and that's the wrong focus, IMHO.=20
--=20
Per Jessen, Zürich (13.7°C)
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 12:44:37 von Daniel Egeberg
On Wed, Mar 24, 2010 at 12:27, Rene Veerman wrote:
> On Wed, Mar 24, 2010 at 1:13 PM, Stuart Dallas
>> I find it curious and amusing that you think the lack of threading support means PHP is somehow living in the dark ages. But yeah, complaining that the FREE tool you've CHOSEN to use doesn't support the feature YOU want... yeah, that's the way to go.
>>
>
> a) i'm not the only 1 who wants that feature, or would appreciate it
> when it's made available.
>
> b) to me it's a matter of keeping php attuned with the market trends.
> this thread forces me to reconsider my choice of language, because i
> do code to maybe get as big as facebook one day.
> it really really helps to have my codebase in a simple language like
> php, and yet be able to build blackboxes in that language that do
> threading and use shared memory..
> imo, it saves significant time (money) and headaches (risk) when
> growing from 1 server to thousands of servers.
If you believe you have the chance of becoming as big as Facebook and
that you would save loads of money by having PHP support
multi-threading, what's preventing you from hiring people to add that
to PHP? You can complain all you want, but even with the most
compelling reasons in the world it will not be done if there is not
enough manpower to do it.
I'm not even sure why you are complaining about this on the general
list. Why don't you write an RFC and send it to internals for
discussion? I'm sure someone would be happy to give you write access
to the rfc namespace on the wiki if you sign up for an account there.
Seeing as it's apparently so crucial to the operation of your
business, I don't think it's unreasonable that you commit some
resources to it. I don't think anyone is *against* that PHP supports
multi-threading. I think people are against having multi-threading if
it will stall other development in the PHP core. It's not like you can
implement it just like that. There is just a limit on how much that
can be done with the resources that are available.
--
Daniel Egeberg
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 12:48:17 von Rene Veerman
well i have this very strong gut feeling that at least some php apps
stand to gain so much efficiency per box with threading and shared
memory that they'll save not only their operators a lot of headaches,
but also significant money and energy. that in turn benefits those
outside the company using php.
On Wed, Mar 24, 2010 at 1:42 PM, Per Jessen wrote:
> Rene Veerman wrote:
>
>> b) to me it's a matter of keeping php attuned with the market trends.
>> this thread forces me to reconsider my choice of language, because i
>> do code to maybe get as big as facebook one day.
>
> Nothing wrong with that, nothing at all. =A0The keyword is scalability,
> and that is measured by how much performance you gain by adding another
> box. =A0You appear to be far more concerned with how much you can get out
> of a single, small box, and that's the wrong focus, IMHO.
>
>
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 12:50:04 von Per Jessen
Rene Veerman wrote:
> how about having a threaded php server query 10 mysql servers at the
> same time? 10 results in .1 seconds!
>=20
How about using mysqlnd? AFAIK, it has support for asynchronous
queries.=20
--=20
Per Jessen, Zürich (14.2°C)
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 12:52:31 von Rene Veerman
again; i have neither the expertise ready, nor the time nor the money
atm, to implement it myself.
i'm hoping the php-dev team will agree with me that scalability of php
driven apps should be put on the agenda.
threading and shared memory are only a part of that discussion..
i'm opening a new thread to discuss this wider issue.
On Wed, Mar 24, 2010 at 1:44 PM, Daniel Egeberg wrote:
> On Wed, Mar 24, 2010 at 12:27, Rene Veerman wrote:
>> On Wed, Mar 24, 2010 at 1:13 PM, Stuart Dallas
>>> I find it curious and amusing that you think the lack of threading support means PHP is somehow living in the dark ages. But yeah, complaining that the FREE tool you've CHOSEN to use doesn't support the feature YOU want... yeah, that's the way to go.
>>>
>>
>> a) i'm not the only 1 who wants that feature, or would appreciate it
>> when it's made available.
>>
>> b) to me it's a matter of keeping php attuned with the market trends.
>> this thread forces me to reconsider my choice of language, because i
>> do code to maybe get as big as facebook one day.
>> it really really helps to have my codebase in a simple language like
>> php, and yet be able to build blackboxes in that language that do
>> threading and use shared memory..
>> imo, it saves significant time (money) and headaches (risk) when
>> growing from 1 server to thousands of servers.
>
> If you believe you have the chance of becoming as big as Facebook and
> that you would save loads of money by having PHP support
> multi-threading, what's preventing you from hiring people to add that
> to PHP? You can complain all you want, but even with the most
> compelling reasons in the world it will not be done if there is not
> enough manpower to do it.
>
> I'm not even sure why you are complaining about this on the general
> list. Why don't you write an RFC and send it to internals for
> discussion? I'm sure someone would be happy to give you write access
> to the rfc namespace on the wiki if you sign up for an account there.
>
> Seeing as it's apparently so crucial to the operation of your
> business, I don't think it's unreasonable that you commit some
> resources to it. I don't think anyone is *against* that PHP supports
> multi-threading. I think people are against having multi-threading if
> it will stall other development in the PHP core. It's not like you can
> implement it just like that. There is just a limit on how much that
> can be done with the resources that are available.
>
> --
> Daniel Egeberg
>
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 13:01:43 von Peter Lind
On 24 March 2010 12:14, Tommy Pham wrote:
> On Wed, Mar 24, 2010 at 4:09 AM, Peter Lind wrot=
e:
>> On 24 March 2010 12:04, Tommy Pham wrote:
>>> On Wed, Mar 24, 2010 at 3:52 AM, Lester Caine wrot=
e:
>>>> Tommy Pham wrote:
>>>>>>
>>>>>> How exactly will threading in PHP help with the size of the database=
?
>>>>>> That makes no sense to me, please help me understand how you think t=
hreading
>>>>>> will help in this scenario.
>>>>>
>>>>> Looking at my example, not just the rows.... Â There are other fe=
atures
>>>>> that require queries to a DB for simple request of a category by a
>>>>> shopper, Â instead of running those queries in series, running th=
em in
>>>>> parallel would yield better response time.
>>>>>
>>>>>> Database size issues are tackled with clustering, caching and DB
>>>>>> optimisation. Threading in the language accessing the DB has no adva=
ntage
>>>>>> here.
>>>>>
>>>>> Yes, it does. Â As mentioned several times, instead of running th=
e
>>>>> queries in series, run them in parallel. Â If each of the queries=
takes
>>>>> about .05 to .15 seconds. Â How long would it take to run them in
>>>>> serial? Â How long do you it take to run them in parallel?
>>>>
>>>> Any you have a database that can actually handle that?
>>>> If the database is taking 0.1 seconds per query, and you have 10 queri=
es,
>>>> then getting the data is going to take 1 second to generate. If you wa=
nt
>>>> some slow query to be started, and come back for the data later, then =
I
>>>> thought we already had that? But again this is part of the database dr=
iver
>>>> anyway. No need to add threading to PHP to get the database connection=
to
>>>> pull data in the most efficient way. And one does not write the driver=
in
>>>> PHP? We are using C there already?
>>>>
>>>> --
>>>> Lester Caine - G8HFL
>>>> -----------------------------
>>>> Contact - http://lsces.co.uk/wiki/?page=3Dcontact
>>>> L.S.Caine Electronic Services - http://lsces.co.uk
>>>> EnquirySolve - http://enquirysolve.com/
>>>> Model Engineers Digital Workshop - http://medw.co.uk//
>>>> Firebird - http://www.firebirdsql.org/index.php
>>>>
>>>> --
>>>> PHP General Mailing List (http://www.php.net/)
>>>> To unsubscribe, visit: http://www.php.net/unsub.php
>>>>
>>>>
>>>
>>> Exactly my point. Â 10 queries taking .1 second each running in ser=
ial
>>> is 1 second total. Â How long would it take to run all those same
>>> queries simultaneously??? What's so difficult about the concept of
>>> serial vs parallel?
>>
>> Hmm, just wondering, but how long do you think it will take your
>> high-traffic site to buckle under the load of the database queries you
>> want to execute when now you want all of them to execute at the same
>> time? Going with the "10 queries of .1 second each" ... how far do you
>> think you can scale that before you overload your database server? I'm
>> just wondering here, I could be completely off the bat.
>
> IIRC, one of opponents of PHP thread mention load balancer/cluster or
> another opponent mention 'throw money into the hardware problem'
Yes. If you can accept that solution for this problem, why not for the
other problem?
Please keep in mind that I'm not for or against threads in PHP. I
think they can solve some problems and I think they'll create a host
of others - currently I have no idea if the benefits would outweigh
the costs.
I just have a huge problem understanding why alternative solutions to
problems are thrown out with "No! That won't work" when they haven't
been shown to be problematic. So far, we've seen no examples of
situations where PHP would be the best choice of language and would
need threads to solve the problem at hand.
Assuming that you have a right to use a threaded version of PHP
amounts to walking into your favourite tool-store and demanding that
you get a hammer that doubles as a phone. And when none are available,
you start yelling at other customers for suggesting the use of a phone
and hammer in combination.
>>
>>> --
>>> PHP General Mailing List (http://www.php.net/)
>>> To unsubscribe, visit: http://www.php.net/unsub.php
>>>
>>>
>>
>>
>>
>> --
>>
>> WWW: http://plphp.dk / http://plind.dk
>> LinkedIn: http://www.linkedin.com/in/plind
>> Flickr: http://www.flickr.com/photos/fake51
>> BeWelcome: Fake51
>> Couchsurfing: Fake51
>>
>>
>
--=20
WWW: http://plphp.dk / http://plind.dk
LinkedIn: http://www.linkedin.com/in/plind
Flickr: http://www.flickr.com/photos/fake51
BeWelcome: Fake51
Couchsurfing: Fake51
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 14:06:25 von Robert Cummings
Per Jessen wrote:
> Rene Veerman wrote:
>
>> stop bashing the people who DO have a use for threading and other
>> advanced concepts eh.
>
> I'm not bashing anyone.
>
>> just because you don't have a use for it, it shouldn't be included?!
>> kinda arrogant.
>
> Feel free to think so - I never said I don't have a use for it
> (threading), I just said thread-support doesn't belong in PHP.
This is a more interesting statement since this thread started with
"douche-bag". I disagree with your assertion that it doesn't belong in
PHP, I think threading has its merits, but the kinds of problems thrown
at this thread so far don't seem particularly solved by threading. 500
requests each with 10 threads hitting the database is 5000 queries.
Threading isn't going to make a whole hell of a lot of difference versus
10 serial queries sent by the same 500 web server requests-- multi core
system or otherwise. Facebook and other popular sites get along well
with PHP. Note that Facebook created a compiler for PHP, they didn't add
support for threading. This suggests that threading is not the golden
hammer being sought in this thread.
However, threading certainly would be great for doing more desktoppy
stuff :)
Cheers,
Rob.
--
http://www.interjinn.com
Application and Templating Framework for PHP
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 14:11:59 von Robert Cummings
Rene Veerman wrote:
> popular : facebook youtube etc
I doubt very much you're popular like facebook. Nothing is as popular as
facebook.
http://www.fastcompany.com/1584920/facebook-now-more-popular -than-google-let-the-ad-wars-begin
Unless you're actually a facebook developer... which I doubt.
> and you're still trying to impose a toolset on me. i think it's not
> strange to ask a programming language support basic hardware
> architecture features as they evolve into mainstream.
No, you've imposed the toolset and now you want to change the set.
Nothing wrong with wanting a new tool in your bag, but you're current
arguments aren't really passing muster.
Cheers,
Rob.
--
http://www.interjinn.com
Application and Templating Framework for PHP
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 14:13:28 von Robert Cummings
Rene Veerman wrote:
> talk to me about this some other time.
>
> atm i'm having an argument with per and his kind about their very very
> annoying behaviour of determining my toolset for me.
> keeping a thread on topic is also ettiquette from the mailinglist rules eh?
>
> you might wanna consider just how much it pisses me off to have strangers
> determining my toolset and/or lifestyle for me.
> that's why i got rude. no other reason.
Umm... you or your boss/client chose PHP. That means one of those two
determined your toolset. Maybe next time you might want to pony up for a
requirements analysis to determine if the toolset is right for the job.
Cheers,
Rob.
--
http://www.interjinn.com
Application and Templating Framework for PHP
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 14:14:45 von Robert Cummings
Rene Veerman wrote:
> On Wed, Mar 24, 2010 at 10:36 AM, Per Jessen wrote:
>
>> By advocating that thread support does not belong in PHP, I am in no way
>> determining what you (or anyone else) may or may not do. You are a
>> free individual and free to choose the programming language and
>> paradigm that is best suited to your purposes.
>
> right! that's saying "you're free to leave behind the tool you've
> chosen for another one, because really, that tool should not start to
> support things that i dont happen to have a use for."
Are you saying you are not free? You are free to do so much in this
world, all it takes is backbone to make the choice sometimes.
Cheers,
Rob.
--
http://www.interjinn.com
Application and Templating Framework for PHP
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 14:16:42 von Robert Cummings
Rene Veerman wrote:
> On Wed, Mar 24, 2010 at 10:47 AM, Per Jessen wrote:
>> Rene Veerman wrote:
>>
>>> popular : facebook youtube etc
>>>
>> Rene, I must be missing something here. That sort of size implies
>> millions in advertising revenue, so why are we discussing how much
>> performance we can squeeze out of a single box? I mean, I'm all for
>> efficient use of system resources, but if I have a semi-scalable
>> application, it's a lot easier just getting another box than trying to
>> change the implementation language. OTOH, if my design is not
>> scalable, it's probably also easier to redo it than trying to change
>> the implementation language.
>
> again:
> a) you're determining the contents of my toolset, without it affecting
> you at all. the way you want it php will degrade into a toy language.
> b) i will aim for all possible decreases in development time and
> operating costs during, not only in the grow phase but also in hard
> economic times. any business person knows why.
>
>>> and you're still trying to impose a toolset on me.
>> I didn't think I was - you're the one who seem to be fixed on PHP as the
>> only solution, and advocating that it be enhanced to suit your
>> purposes.
>
> no, php is just my toolset of choice, and i think it should grow with
> the times and support threading and shared memory.
> maybe even a few cool features to enable use-as-a-cloud.
Why are you imposing a toolset on the developers of PHP? Are you even
subscribed to internals? Have you even thought of creating a patch? It's
one thing to debate the merits of a tool, it's another to insist that it
be added because you think php needs to "grow up".
Cheers,
Rob.
--
http://www.interjinn.com
Application and Templating Framework for PHP
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 14:18:26 von Robert Cummings
Rene Veerman wrote:
> exactly. the knock-on problems you mentioned are well solved and well
> documented.
> realtime programmers using threads have to get their heads around it
> on their first realtime project.
>
> i don't like doing my code in c(++), or worse; having to interface
> between c(++) and php.
> i chose php because my code can stay close to simple english that way.
> what you're suggesting is highly intrusive in my work-style, one that
> you're not affected by at all.
> in fact if you make things more difficult for me, i have less time to
> release opensource code of my own.
Someone call a Waaaaaaaaaaaaaaaaaaah-mbulance!
Cheers,
Rob.
--
http://www.interjinn.com
Application and Templating Framework for PHP
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 14:20:08 von Robert Cummings
Per Jessen wrote:
> Rene Veerman wrote:
>
>> again:
>> a) you're determining the contents of my toolset, without it affecting
>> you at all. the way you want it php will degrade into a toy language.
>
> Rene, it seems to me that you and I are advocating two opposite
> positions on the topic of threading in PHP, so aren't we both trying to
> determine the contents of each others toolset?
*bingo* It should be a debate about the merits of each position. Not a
pissing contest.
>> b) i will aim for all possible decreases in development time and
>> operating costs during, not only in the grow phase but also in hard
>> economic times. any business person knows why.
>
> Given that the lifetime effort (=cost) of any software project is
> divided into 25% development and 75% maintenance, you really ought to
> focus on the latter. If you want more performance at a minimal cost,
> surely you should opt to write in a compiled language where you'll get
> far more bang for the buck.
Oh no, now you're suggesting he change his management focus :)
Cheers,
Rob.
--
http://www.interjinn.com
Application and Templating Framework for PHP
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 14:22:05 von Robert Cummings
Rene Veerman wrote:
> On Wed, Mar 24, 2010 at 11:13 AM, Per Jessen wrote:
>> Rene Veerman wrote:
>>
>>> again:
>>> a) you're determining the contents of my toolset, without it affecting
>>> you at all. the way you want it php will degrade into a toy language.
>> Rene, it seems to me that you and I are advocating two opposite
>> positions on the topic of threading in PHP, so aren't we both trying to
>> determine the contents of each others toolset?
>>
>
> Per: that's EXACTLY the point.
> You are determining it for me, i'm not for you.
> Simply because you dont have to use the language features you atm
> think you don't need in php.
Actually, no. You are determine aspects of the toolset as it stands. To
add threading is not a benign additon because we can choose to use it or
not. If added it would affect the future irrevocably since undoubtedly
we would need to maintain someone's code that contains threads because
they didn't understand the shared nothing nature of PHP.
Cheers,
Rob.
--
http://www.interjinn.com
Application and Templating Framework for PHP
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 14:25:22 von Robert Cummings
Rene Veerman wrote:
> php is not a hammer, its a programming language.
It's hard to discuss anything with someone who doesn't comprehend a
metaphor.
> one that i feel needs to stay ahead of the computing trend if it is to
> be considered a language for large scale applications.
Personification of PHP doesn't make your argument any more salient. PHP
isn't trying to stay ahead of anything. People are using it to solve
problems, not to meet some phantom ideal of a "computing trend" threshold.
> but you nay-sayers here have convinced me; i'll be shopping for
> another language with which to serve my applications and the weboutput
> they produce..
>
> thanks for opening my eyes and telling to abandon ship in time.
Obviously we didn't open your eyes.
Cheers,
Rob.
--
http://www.interjinn.com
Application and Templating Framework for PHP
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 14:29:24 von Robert Cummings
Rene Veerman wrote:
> unless the actual php development team would like to weigh in on this
> matter of course.
Wrong list. Subscribe to internals.
> yes, i do consider it that important.
> these nay-sayers usually also lobby the dev-team to such extent that
> these features would actually not make it into php.
It's a debate. The dev team consider proposals and weigh in on the
merits. I was a proponent for goto support during the development of PHP
5. We now have it. If you arguments are valid and there's no technical
issue preventing it, and there's someone with time and skill to created
the functionality, then it will happen. If not then it won't. I've seen
many things added to PHP and I've watched and participated in the
threads on internals that have lead to many new features. This is open
source, opinions matter, but personal attacks and poor argument do not
really make the cut.
Cheers,
Rob.
--
http://www.interjinn.com
Application and Templating Framework for PHP
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 14:31:25 von Robert Cummings
Arno Kuhl wrote:
> -----Original Message-----
> From: Rene Veerman [mailto:rene7705@gmail.com]
> Sent: 24 March 2010 11:31 AM
> Subject: Re: [PHP] Will PHP ever "grow up" and have threading?
>
> thanks for opening my eyes and telling to abandon ship in time.
>
> ===============================
>
> Bye, enjoy the swim...
>
> Maybe by the time you get back to shore you'll realise how dumb it would be
> if a sailor complained that his yatch didn't behave like a hovercraft, or
> his passenger ship couldn't carry a million barrels of oil, or his tug boat
> was useless at pulling a skier... Just how much (or little) development
> experience do you have?
Hmmm... he had trouble with metaphors earlier, I'm not sure he'll
understand the above :)
Cheers,
Rob.
--
http://www.interjinn.com
Application and Templating Framework for PHP
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 14:34:00 von Robert Cummings
Tommy Pham wrote:
> What I find funny is that one of opponents of PHP threads earlier
> mentioned that how silly it would be to be using C in a web app. Now
> I hear people mentioning C when they need "productivity" or "speed"...
PHP has excellent support for extensions. I've written several C
extensions int he past for my own personal use. Even facebook punts some
stuff to C extensions that they just plug right into PHP.
Cheers,
Rob.
--
http://www.interjinn.com
Application and Templating Framework for PHP
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 14:37:26 von Jochem Maas
Op 3/24/10 10:40 AM, Rene Veerman schreef:
> I subscribe to this list to share tips on software designs.
>
> Getting and keeping your respect i'm not even interested in.
>
> I'm interested in the quality of your tips on problems i post, as tips can
> lead faster to products, leads to money, leads to my personal freedom and
> options in life.
> Respect cannot be used to buy bread and butter.
>
Someone who respects you will buy you a sandwich if you need it.
But seemingly you're only interested in leveraging other peoples time and
experience to further your own career, good luck with that around here.
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 14:38:10 von Robert Cummings
Rene Veerman wrote:
> I subscribe to this list to share tips on software designs.
>
> Getting and keeping your respect i'm not even interested in.
>
> I'm interested in the quality of your tips on problems i post, as tips can
> lead faster to products, leads to money, leads to my personal freedom and
> options in life.
> Respect cannot be used to buy bread and butter.
Then you haven't heard about how much value goodwill can add when
selling a company :)
Cheers,
Rob.
--
http://www.interjinn.com
Application and Templating Framework for PHP
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 14:40:03 von Robert Cummings
Per Jessen wrote:
> Tommy Pham wrote:
>
>> On Wed, Mar 24, 2010 at 2:58 AM, Stuart Dallas
>> wrote:
>>> Give us a real example of why you think it should be
>>> supported and I guarantee we can come up with a way to get you what
>>> you want without requiring massive changes to the core of your chosen
>>> tool. And if we can't then you may actually convince us that
>>> threading would be a valuable feature to have available.
>> I did give a real life example, ie e-commerce site mentioned earlier.
>
> How many _concurrent_ users do you expect - which order of magnitude:
> 10,100,1000,10000?
>
>> Amazon has the similar features of my example except they have about
>> 30 million products without (i18n). Their I18n is different web
>> server & db & site layout which is completely different from my
>> example.
>
> Understood.
>
>> Setting I18n aside, having the same features as my example
>> with about 30 million products to response in about 3 seconds is very
>> good. Even though my example only have about 750,000 products, the
>> translations for the requested languages makes it into 750,000 * 6 =
>> 4,500,000 rows of product descriptions. This is e-commerce site not a
>> data warehouse/mining. What would happen then if the site has over
>> 20,000,000 product skus with similar language translations for the
>> descriptions? 20,000,000 * 6 = ... big number to me...
>
> Thinking out loud - maybe it would make sense to have a separate
> database instance/machine per language? That would enable to you to
> start them all on one machine, but shift to another once the load
> increases. (not dynamically, but with time).
> If that's not a feasible option, maybe a mysql cluster or a very large
> database server?
Stick it in the same machine, use replication. Force specific language
read queries to specific machines so that the database server cache is
primed for that language. This way you're still only maintaining one
database.
Cheers,
Rob.
--
http://www.interjinn.com
Application and Templating Framework for PHP
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 14:46:34 von Robert Cummings
Tommy Pham wrote:
> On Wed, Mar 24, 2010 at 3:52 AM, Lester Caine wrote:
>> Tommy Pham wrote:
>>>> How exactly will threading in PHP help with the size of the database?
>>>> That makes no sense to me, please help me understand how you think threading
>>>> will help in this scenario.
>>> Looking at my example, not just the rows.... There are other features
>>> that require queries to a DB for simple request of a category by a
>>> shopper, instead of running those queries in series, running them in
>>> parallel would yield better response time.
>>>
>>>> Database size issues are tackled with clustering, caching and DB
>>>> optimisation. Threading in the language accessing the DB has no advantage
>>>> here.
>>> Yes, it does. As mentioned several times, instead of running the
>>> queries in series, run them in parallel. If each of the queries takes
>>> about .05 to .15 seconds. How long would it take to run them in
>>> serial? How long do you it take to run them in parallel?
>> Any you have a database that can actually handle that?
>> If the database is taking 0.1 seconds per query, and you have 10 queries,
>> then getting the data is going to take 1 second to generate. If you want
>> some slow query to be started, and come back for the data later, then I
>> thought we already had that? But again this is part of the database driver
>> anyway. No need to add threading to PHP to get the database connection to
>> pull data in the most efficient way. And one does not write the driver in
>> PHP? We are using C there already?
>>
>> --
>> Lester Caine - G8HFL
>> -----------------------------
>
> Exactly my point. 10 queries taking .1 second each running in serial
> is 1 second total. How long would it take to run all those same
> queries simultaneously??? What's so difficult about the concept of
> serial vs parallel?
You seem to think that those 10 queries are happening in isolation. What
about the other 100 concurrent users all smacking the db server with 10
queries. The db server is just going to queue them and serially process
them as each of it's own processing threads become free. In high
concurrency situations threading isn't going to make much difference, in
fact it's very likely to decrease performance because now you've added
the overhead of thread concurrency handling in PHP when the db server is
already handling this issue between the multiple web server requests.
Cheers,
Rob.
--
http://www.interjinn.com
Application and Templating Framework for PHP
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 14:51:39 von Robert Cummings
Rene Veerman wrote:
> well i have this very strong gut feeling that at least some php apps
> stand to gain so much efficiency per box with threading and shared
> memory that they'll save not only their operators a lot of headaches,
> but also significant money and energy. that in turn benefits those
> outside the company using php.
Sometimes when I have a gut feeling, it's indigestion >:D
Cheers,
Rob.
--
http://www.interjinn.com
Application and Templating Framework for PHP
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
RE: Will PHP ever "grow up" and have threading?
am 24.03.2010 15:03:20 von Bob McConnell
From: larry at garfieldtech dot com
> On 3/23/10 6:04 PM, Tommy Pham wrote:
>> If throwing hardware at it won't work because of the above mentioned,
>> then you would change the design right? How long would that take?
>> What if PHP has threads, how long would it take you implement threads
>> with minor changes versus and overhaul of application design, coding,
>> QA, etc... In summary, you're saying that PHP can not grow/evolve
with
>> business right? If the company started small and want to use
>> available open source solutions, then grow quickly because of their
>> unique and quality products and services, and become enterprise level
>> with-in a few years, what then? Slow down business growth just so
>> that IT can migrate everything to another language? Of all the
>> enterprise applications I've seen, they used threads.
>=20
> But let's consider what adding threads to PHP would take. That would=20
> mean making PHP a shared-memory architecture, so that different
requests=20
> now operated in the same memory space. That means RAM-based=20
> persistence. That means needing to write thread-safe PHP libraries.=20
> (Not the ones in C; I mean the millions of lines of code of PHP
already=20
> out there.)
>=20
> In short, adding threading support to PHP means PHP is no longer PHP.=20
> It's Java with dollarsigns. It's a complete and total rewrite of the=20
> entire language runtime and environment, and all of the code build
atop it.
>=20
> The idea that you could "just add threads" to PHP and make it=20
> "enterprise-ready" is so naive it's mind boggling.
This pretty much describes the path the Perl community took several
years back. While they didn't end up looking like Java, they still
actively discourage the use of threads in Perl because nobody has a good
handle on which portions of CPAN are actually thread safe. It will
likely take them several more years before they find and fix all of the
libraries and modules that aren't.
Bob McConnell
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 16:04:33 von ahlin.hans
2010/3/24 Rene Veerman :
> yea right..
>
> i really want to keep my code base in 1 language, because that
> simplifies everything later on imo.
> you people, who are against the evolotion of php towards cloud
> computing, would force me to do mixed-languages projects or even
> rewrite large sections of my codebase if as i want, i keep my codebase
> in 1 language.
>
> maybe now you understand why i'm so pissed off with you know-it-alls.
>
>
Why did you chose PHP in the first place?
And as a programmer you have to be flexible despite the chosen
language. C++/C programmer sometimes must use assembler, in
asp/dot.net have to switch between VB,C# and so on. nothing new. thats
why languages now days are mainly based on C/C++ to make it easier to
jump between languages.
(PHP, Perl, Java, JavaScript is based on C/C++ aso)
--=20
MvH / Hans Ã
hlin
Tel: +46761488019
http//www.kronan-net.com/
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 16:34:56 von TedD
Hi gang:
When I'm confronted with a large number of emails to read under one
subject (like this one), I put on the "Robert, Stuart, Brown" Filter.
As such, I only read their post and everything gets to the point
quicker and makes more sense.
Cheers,
tedd
--
-------
http://sperling.com http://ancientstones.com http://earthstones.com
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 17:37:58 von Adam Richardson
--00c09f8c22508f70d004828e8d29
Content-Type: text/plain; charset=ISO-8859-1
>
>
> Rene, I don't want you to jump ship. You've been helpful to many other
posters, and I appreciate various points of view on all subjects, yours
included. Please bottom post in the future now that you know of their
preference, and please step back for a few and take some time to relax.
No harm, no foul (a phrase I appreciate more and more as I slow down on the
court ;)
I will confess that I understand why Rene feels ganged up on. While the
words used to counter him have been quite restrained, his request for a
feature has been consistently met with "You must be doing the other stuff
wrong" responses. That doesn't speak to the heart of the issue, and Rene
from previous posts has shown that he's quite capable on many fronts.
Requesting a new feature does not necessarily mean that somebody isn't best
using the current features.
For example, in the past, PHP considered a new array syntax, but those
against it expressed the belief that the current syntax was sufficient:
http://markmail.org/message/rsi4welftwou24p3
Sufficient, PHP often is, but it's competing within a diverse eco-system of
increasingly capable languages, and I hope we all keep focused on how it can
continue to improve. The value of our skill set is largely dependent on the
strength of the other PHP developers out there, the availability of PHP,
etc.
Whether it's a new array syntax, threading, or any other new feature, I hope
we all carefully deliberate on what the feature may do to attract new PHP
developers and keep existing PHP developers.
True, developers can mix and match languages as needed, but I find I hear
phrases like "Well, if language X doesn't support Y, then why not use
langauge Z for everything." That doesn't mean I agree with that approach,
but sentiment among executives does exist.
For the record, I liked the alternative array syntax suggested in my
example, and I've said earlier in this thread that I'd like threading.
My example is my web framework. It doesn't use front- or
page-level-controllers, but rather micro-controllers with embedded views.
Autonomous views could be elegantly processed in parallel, speeding the
rendering of the page. And, in F# and Clojure, this is exactly what I'm
doing. It would be really nice to do this in PHP, too, as I really do love
PHP. And in many examples, caching is not the answer (information is often
user specific and/or time specific.) Perhaps some of you won't agree with
this need, but that doesn't mean it's not playing a role in the value
proposition of PHP in my work.
That said, this is not the only reason I'd be for threading, as I believe
PHP is directly competing with several other very nice languages in many
situations (Python, Ruby, Scala, C#, F#, Scala, etc.), and they all offer
some form of threading, and I hope PHP continues to attract a broad range of
talents amongst the alternatives.
Now, do I expect threading in the near future? NO. PHP does present some
special issues for this feature. However, I hope we all will carefully
consider where we want PHP to be in the future language market whenever we
consider any new features, be they arrays, threading, or mind control ;)
I'll not speak anything further on this thread.
Adam
--
Nephtali: PHP web framework that functions beautifully
http://nephtaliproject.com
--00c09f8c22508f70d004828e8d29--
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 17:48:12 von Adam Richardson
--00504502d03727008104828eb20f
Content-Type: text/plain; charset=ISO-8859-1
On Wed, Mar 24, 2010 at 6:34 AM, Rene Veerman wrote:
> On Wed, Mar 24, 2010 at 12:28 PM, Tommy Pham wrote:
> >
> > Funny you should mention all that. Let's say that you're longer with
> > that company, either by direct employment or contract consultant.
> > You've implemented C because you need 'thread'. Now your replacement
> > comes in and has no clue about C even though your replacement is a PHP
> > guru. How much headache is maintenance gonna be? Scalability?
> > Portability? wow....
> >
> Thanks for posting this before i had to.
>
> +1, +1, +1...
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>
[Sorry for posting here, my earlier response went to a partial thread]
Rene, I don't want you to jump ship. You've been helpful to many other
posters, and I appreciate various points of view on all subjects, yours
included. Please bottom post in the future now that you know of their
preference, and please step back for a few and take some time to relax.
No harm, no foul (a phrase I appreciate more and more as I slow down on the
court ;)
I will confess that I understand why Rene feels ganged up on. While the
words used to counter him have been quite restrained, his request for a
feature has been consistently met with "You must be doing the other stuff
wrong" responses. That doesn't speak to the heart of the issue, and Rene
from previous posts has shown that he's quite capable on many fronts.
Requesting a new feature does not necessarily mean that somebody isn't best
using the current features.
For example, in the past, PHP considered a new array syntax, but those
against it expressed the belief that the current syntax was sufficient:
http://markmail.org/message/rsi4welftwou24p3
Sufficient, PHP often is, but it's competing within a diverse eco-system of
increasingly capable languages, and I hope we all keep focused on how it can
continue to improve. The value of our skill set is largely dependent on the
strength of the other PHP developers out there, the availability of PHP,
etc.
Whether it's a new array syntax, threading, or any other new feature, I hope
we all carefully deliberate on what the feature may do to attract new PHP
developers and keep existing PHP developers.
True, developers can mix and match languages as needed, but I find I hear
phrases like "Well, if language X doesn't support Y, then why not use
langauge Z for everything." That doesn't mean I agree with that approach,
but sentiment among executives does exist.
For the record, I liked the alternative array syntax suggested in my
example, and I've said earlier in this thread that I'd like threading.
My example is my web framework. It doesn't use front- or
page-level-controllers, but rather micro-controllers with embedded views.
Autonomous views could be elegantly processed in parallel, speeding the
rendering of the page. And, in F# and Clojure, this is exactly what I'm
doing. It would be really nice to do this in PHP, too, as I really do love
PHP. And in many examples, caching is not the answer (information is often
user specific and/or time specific.) Perhaps some of you won't agree with
this need, but that doesn't mean it's not playing a role in the value
proposition of PHP in my work.
That said, this is not the only reason I'd be for threading, as I believe
PHP is directly competing with several other very nice languages in many
situations (Python, Ruby, Scala, C#, F#, Scala, etc.), and they all offer
some form of threading, and I hope PHP continues to attract a broad range of
talents amongst the alternatives.
Now, do I expect threading in the near future? NO. PHP does present some
special issues for this feature. However, I hope we all will carefully
consider where we want PHP to be in the future language market whenever we
consider any new features, be they arrays, threading, or mind control ;)
I'll not speak anything further on this thread.
Adam
--
Nephtali: PHP web framework that functions beautifully
http://nephtaliproject.com
--00504502d03727008104828eb20f--
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 18:18:25 von Sancar Saran
On Wednesday 24 March 2010 03:17:56 Tommy Pham wrote:
> Let's go back to my 1st e-commerce example. The manufacturers list is
> about 3,700. The categories is about about 2,400. The products list
> is right now at 500,000 and expected to be around 750,000. The site
> is only in English. The store owner wants to expand and be I18n:
> Chinese, French, German, Korean, Spanish. You see how big and complex
> that database gets? The store owners want to have this happens when a
> customer clicks on a category:
>
> * show all subcategories for that category, if any
> * show all products for that category, if any,
> * show all manufacturers, used as filtering, for that category and
> subcategories * show price range filter for that category
> * show features & specifications filter for that category
> * show 10 top sellers for that category and related subcategories
> * the shopper can then select/deselect any of those filters and
> ability to sort by manufacturers, prices, user rating, popularity
> (purchased quantity)
> * have the ability to switch to another language translation on the fly
> * from the moment the shopper click on a link, the response time (when
> web browser saids "Done" in the status bar) is 5 seconds or less.
> Preferably 2-3 seconds. Will be using stopwatch for the timer.
>
> Now show me a website that meets those requirements and uses PHP, I'll
> be glad to support your argument about PHP w/o threads :) BTW, this
> is not even enterprise requirement. I may have another possible
> project where # products is over 10 million easily. With similar
> requirements when the user click on category. Do you think this site,
> which currently isn't, can run on PHP?
>
> Regards,
> Tommy
If you design and code correctly. Yes.
If you want to use someting alredy. Try TYPO3.
PS: Your arguments are something about implementation not something about
platform abilities. You can do this things any server side programming with
enough hardware.
Regards
Sancar
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 20:05:38 von Michael Peters
Tommy Pham wrote:
>
> The response time, max 5 seconds, will be tested on local gigabit LAN
> to ensure the adequate response (optimized DB & code & proper
> hardware) without worrying about users' connection limit and site's
> upload bandwidth limit (which can easily rectify). Then thereafter
> will be doing stress test of about 10 concurrent users. As for the
> major queries, that's where threads come in, IMO, because those
> queries depend on 1 primary parameter (category ID) and 1 secondary
> parameter (language ID). This particular site starts with 500
> products about 15 categories, without many of those mentioned filters,
> later grew to its current state.
>
I don't know about the proposed scenario you give.
But I do know when my own site felt a little sluggish, I implemented APC
and a cron job that preloads all the queries at the beginning of the
day. Any changes to a table dump the cache and reload it. Site is now
fast and the database is only pounded in the early AM cache preload
(which may actually not even be necessary, but I do it just in case
there are any scenarios where I change DB and forget to nuke cache for
effected queries).
If database is your bottleneck, APC (or other caching methods) is your
friend.
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 20:16:14 von Rene Veerman
On Wed, Mar 24, 2010 at 3:13 PM, Robert Cummings wrote:
> Rene Veerman wrote:
>>
>> talk to me about this some other time.
>>
>> atm i'm having an argument with per and his kind about their very very
>> annoying behaviour of determining my toolset for me.
>> keeping a thread on topic is also ettiquette from the mailinglist rules
>> eh?
>>
>> you might wanna consider just how much it pisses me off to have strangers
>> determining my toolset and/or lifestyle for me.
>> that's why i got rude. no other reason.
>
> Umm... you or your boss/client chose PHP. That means one of those two
> determined your toolset. Maybe next time you might want to pony up for a
> requirements analysis to determine if the toolset is right for the job.
>
you've never heard of feature-creep, changing environments and
requirements, etc?
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 20:22:54 von Rene Veerman
On Wed, Mar 24, 2010 at 3:37 PM, Jochem Maas wrote:
>
> Someone who respects you will buy you a sandwich if you need it.
i'd rather build products that are useful enough to be sold, than to
wait for anti-starvation handouts gained from respect.
>
> But seemingly you're only interested in leveraging other peoples time and
> experience to further your own career, good luck with that around here.
>
i've spent quite a bit of time on this list writing replies of my own
to other people's software problems here.
in fact i think i've spent more time on other's problems for free than
i've received back in useful tips. and i'm not bitching about that.
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 20:24:47 von Rene Veerman
On Wed, Mar 24, 2010 at 3:25 PM, Robert Cummings wrote:
> Rene Veerman wrote:
>>
>> php is not a hammer, its a programming language.
>
> It's hard to discuss anything with someone who doesn't comprehend a
> metaphor.
haha. "comprehend". you mean "accept".
that metaphor is stretched to breaking point as far as i'm concerned.
>
>> one that i feel needs to stay ahead of the computing trend if it is to
>> be considered a language for large scale applications.
>
> Personification of PHP doesn't make your argument any more salient. PHP
> isn't trying to stay ahead of anything. People are using it to solve
> problems, not to meet some phantom ideal of a "computing trend" threshold.
>
>> but you nay-sayers here have convinced me; i'll be shopping for
>> another language with which to serve my applications and the weboutput
>> they produce..
>>
>> thanks for opening my eyes and telling to abandon ship in time.
>
> Obviously we didn't open your eyes.
>
Well excuse me for not dumping 50-100k lines of my own cms code
instantly now that i realize that in order to scale it, i could really
use features like threading and shared memory.
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 20:25:48 von Rene Veerman
On Wed, Mar 24, 2010 at 3:22 PM, Robert Cummings wrote:
> Rene Veerman wrote:
>>
>> On Wed, Mar 24, 2010 at 11:13 AM, Per Jessen wrote:
>>>
>>> Rene Veerman wrote:
>>>
>>>> again:
>>>> a) you're determining the contents of my toolset, without it affecting
>>>> you at all. the way you want it php will degrade into a toy language.
>>>
>>> Rene, it seems to me that you and I are advocating two opposite
>>> positions on the topic of threading in PHP, so aren't we both trying to
>>> determine the contents of each others toolset?
>>>
>>
>> Per: that's EXACTLY the point.
>> You are determining it for me, i'm not for you.
>> Simply because you dont have to use the language features you atm
>> think you don't need in php.
>
> Actually, no. You are determine aspects of the toolset as it stands. To add
> threading is not a benign additon because we can choose to use it or not. If
> added it would affect the future irrevocably since undoubtedly we would need
> to maintain someone's code that contains threads because they didn't
> understand the shared nothing nature of PHP.
yes you may encounter bad code. it happens now too.
but most realtime programmers know not to use threads unless necessary.
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 20:30:01 von Robert Cummings
Rene Veerman wrote:
> On Wed, Mar 24, 2010 at 3:13 PM, Robert Cummings wrote:
>> Rene Veerman wrote:
>>> talk to me about this some other time.
>>>
>>> atm i'm having an argument with per and his kind about their very very
>>> annoying behaviour of determining my toolset for me.
>>> keeping a thread on topic is also ettiquette from the mailinglist rules
>>> eh?
>>>
>>> you might wanna consider just how much it pisses me off to have strangers
>>> determining my toolset and/or lifestyle for me.
>>> that's why i got rude. no other reason.
>> Umm... you or your boss/client chose PHP. That means one of those two
>> determined your toolset. Maybe next time you might want to pony up for a
>> requirements analysis to determine if the toolset is right for the job.
>>
>
> you've never heard of feature-creep, changing environments and
> requirements, etc?
Not usually, at the level of the language choice, is an about turn done
after a requirements analysis has been completed. Feature creep is a
management issue.
Cheers,
Rob.
--
http://www.interjinn.com
Application and Templating Framework for PHP
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 20:31:24 von Robert Cummings
Rene Veerman wrote:
> On Wed, Mar 24, 2010 at 3:25 PM, Robert Cummings wrote:
>> Rene Veerman wrote:
>>> php is not a hammer, its a programming language.
>> It's hard to discuss anything with someone who doesn't comprehend a
>> metaphor.
>
> haha. "comprehend". you mean "accept".
> that metaphor is stretched to breaking point as far as i'm concerned.
>
>>> one that i feel needs to stay ahead of the computing trend if it is to
>>> be considered a language for large scale applications.
>> Personification of PHP doesn't make your argument any more salient. PHP
>> isn't trying to stay ahead of anything. People are using it to solve
>> problems, not to meet some phantom ideal of a "computing trend" threshold.
>>
>>> but you nay-sayers here have convinced me; i'll be shopping for
>>> another language with which to serve my applications and the weboutput
>>> they produce..
>>>
>>> thanks for opening my eyes and telling to abandon ship in time.
>> Obviously we didn't open your eyes.
>>
>
> Well excuse me for not dumping 50-100k lines of my own cms code
> instantly now that i realize that in order to scale it, i could really
> use features like threading and shared memory.
Actually, you are th eone suggesting dumping your code since you said
you were jumping ship. Many of us suggested that your problems can
almost certainly be mitigated without threading.
Cheers,
Rob.
--
http://www.interjinn.com
Application and Templating Framework for PHP
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 20:33:00 von Rene Veerman
On Wed, Mar 24, 2010 at 3:29 PM, Robert Cummings wrote:
> Rene Veerman wrote:
>>
>> unless the actual php development team would like to weigh in on this
>> matter of course.
>
> Wrong list. Subscribe to internals.
>
>> yes, i do consider it that important.
>
>> these nay-sayers usually also lobby the dev-team to such extent that
>> these features would actually not make it into php.
>
> It's a debate. The dev team consider proposals and weigh in on the merits. I
> was a proponent for goto support during the development of PHP 5. We now
> have it. If you arguments are valid and there's no technical issue
> preventing it, and there's someone with time and skill to created the
> functionality, then it will happen. If not then it won't. I've seen many
> things added to PHP and I've watched and participated in the threads on
> internals that have lead to many new features. This is open source, opinions
> matter, but personal attacks and poor argument do not really make the cut.
>
hahaha... you dismiss what i believe to be valid explanations without
any counter-argument besides "more sql hardware!", not just by me but
by all advocates of threading&shared memory in php.
for some reason, which is still not clear to me, you nay-sayers refuse
to let a PROGRAMMING LANGUAGE (not a "hammer", not a "fishing boat")
evolve to stay useful, relevant even, in a changing market.
and you're blatantly telling me to use a different kind of "hammer",
one that would force me to rewrite large sections of my existing
code-base, and one that i have told you i would find for many other
_valid_ reasons not optimal.
basically, you're determining my choice of options without me ever
having forced you to do something a certain way..
so you'll have to excuse my strong language.
it's just letting you know that you shouldn't butt into other peoples
business when it doesn't really affect you.
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 20:33:44 von Rene Veerman
On Wed, Mar 24, 2010 at 9:30 PM, Robert Cummings wrote:
>
>
> Rene Veerman wrote:
>>
>> On Wed, Mar 24, 2010 at 3:13 PM, Robert Cummings
>> wrote:
>>>
>>> Rene Veerman wrote:
>>>>
>>>> talk to me about this some other time.
>>>>
>>>> atm i'm having an argument with per and his kind about their very very
>>>> annoying behaviour of determining my toolset for me.
>>>> keeping a thread on topic is also ettiquette from the mailinglist rules
>>>> eh?
>>>>
>>>> you might wanna consider just how much it pisses me off to have
>>>> strangers
>>>> determining my toolset and/or lifestyle for me.
>>>> that's why i got rude. no other reason.
>>>
>>> Umm... you or your boss/client chose PHP. That means one of those two
>>> determined your toolset. Maybe next time you might want to pony up for a
>>> requirements analysis to determine if the toolset is right for the job.
>>>
>>
>> you've never heard of feature-creep, changing environments and
>> requirements, etc?
>
> Not usually, at the level of the language choice, is an about turn done
> after a requirements analysis has been completed. Feature creep is a
> management issue.
>
it's a managment issue only because it's a fact of life.
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 20:35:45 von Rene Veerman
On Wed, Mar 24, 2010 at 9:31 PM, Robert Cummings wrote:
>
>
> Rene Veerman wrote:
>>
>> On Wed, Mar 24, 2010 at 3:25 PM, Robert Cummings
>> wrote:
>>>
>>> Rene Veerman wrote:
>>>>
>>>> php is not a hammer, its a programming language.
>>>
>>> It's hard to discuss anything with someone who doesn't comprehend a
>>> metaphor.
>>
>> haha. "comprehend". you mean "accept".
>> that metaphor is stretched to breaking point as far as i'm concerned.
>>
>>>> one that i feel needs to stay ahead of the computing trend if it is to
>>>> be considered a language for large scale applications.
>>>
>>> Personification of PHP doesn't make your argument any more salient. PHP
>>> isn't trying to stay ahead of anything. People are using it to solve
>>> problems, not to meet some phantom ideal of a "computing trend"
>>> threshold.
>>>
>>>> but you nay-sayers here have convinced me; i'll be shopping for
>>>> another language with which to serve my applications and the weboutput
>>>> they produce..
>>>>
>>>> thanks for opening my eyes and telling to abandon ship in time.
>>>
>>> Obviously we didn't open your eyes.
>>>
>>
>> Well excuse me for not dumping 50-100k lines of my own cms code
>> instantly now that i realize that in order to scale it, i could really
>> use features like threading and shared memory.
>
> Actually, you are th eone suggesting dumping your code since you said you
> were jumping ship. Many of us suggested that your problems can almost
> certainly be mitigated without threading.
>
"almost certainly". at least you're acknowledging that you might be wrong.
take this example, sorry for the crosspost;
my main concern atm is my own cms (50-100k lines of my own); it's
graphics-heavy, does fairly complicated db based logic, and if it ever
is to be used for a site like facebook, it'll get large dataflows that
have to be distributed over the servers used to generate html and
accessoiries for end-users.
i've built a layer into it that caches the output of oft-used pages
(like articles and their comments).
but adding many comments / minute to an article would result in quite
a bit of overhead, to update the html for that page and distribute it
(fast enough) to the relevant servers.
i'm worried about php's single-threaded nature; each request has to
fetch html updated in the last few seconds, or generate it from a list
of comments. that's also a big query from a big table for every
end-user.. :(
i'd rather keep them comments for an article in shared memory.....
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
RE: Will PHP ever "grow up" and have threading?
am 24.03.2010 20:36:59 von Bob McConnell
From: Rene Veerman
> i've spent quite a bit of time on this list writing replies of my own
> to other people's software problems here.
> in fact i think i've spent more time on other's problems for free than
> i've received back in useful tips. and i'm not bitching about that.
That describes a lot of people here, but I think of it as my payment for
PHP. Our continued input helps to draw others into the community, which
increases the knowledge and experience pool using the language and
answering questions. Which means there may be more help available the
next time I run into a thorny issue.
Yes, it's a continuous cycle of growth, like rolling a snowball downhill
in wet snow. But every little bit helps.
Bob McConnell
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 20:41:23 von Robert Cummings
Rene Veerman wrote:
> On Wed, Mar 24, 2010 at 3:29 PM, Robert Cummings wrote:
>> Rene Veerman wrote:
>>> unless the actual php development team would like to weigh in on this
>>> matter of course.
>> Wrong list. Subscribe to internals.
>>
>>> yes, i do consider it that important.
>>> these nay-sayers usually also lobby the dev-team to such extent that
>>> these features would actually not make it into php.
>> It's a debate. The dev team consider proposals and weigh in on the merits. I
>> was a proponent for goto support during the development of PHP 5. We now
>> have it. If you arguments are valid and there's no technical issue
>> preventing it, and there's someone with time and skill to created the
>> functionality, then it will happen. If not then it won't. I've seen many
>> things added to PHP and I've watched and participated in the threads on
>> internals that have lead to many new features. This is open source, opinions
>> matter, but personal attacks and poor argument do not really make the cut.
>>
>
> hahaha... you dismiss what i believe to be valid explanations without
> any counter-argument besides "more sql hardware!", not just by me but
> by all advocates of threading&shared memory in php.
>
> for some reason, which is still not clear to me, you nay-sayers refuse
> to let a PROGRAMMING LANGUAGE (not a "hammer", not a "fishing boat")
> evolve to stay useful, relevant even, in a changing market.
>
> and you're blatantly telling me to use a different kind of "hammer",
> one that would force me to rewrite large sections of my existing
> code-base, and one that i have told you i would find for many other
> _valid_ reasons not optimal.
>
> basically, you're determining my choice of options without me ever
> having forced you to do something a certain way..
>
> so you'll have to excuse my strong language.
> it's just letting you know that you shouldn't butt into other peoples
> business when it doesn't really affect you.
We can't be determining your choice of options since threading is not
currently an option. If you want it, do as I suggested, subscribe to
internals and engage in due process.
Cheers,
Rob.
--
http://www.interjinn.com
Application and Templating Framework for PHP
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 20:41:47 von Robert Cummings
Rene Veerman wrote:
> On Wed, Mar 24, 2010 at 9:30 PM, Robert Cummings wrote:
>>
>> Rene Veerman wrote:
>>> On Wed, Mar 24, 2010 at 3:13 PM, Robert Cummings
>>> wrote:
>>>> Rene Veerman wrote:
>>>>> talk to me about this some other time.
>>>>>
>>>>> atm i'm having an argument with per and his kind about their very very
>>>>> annoying behaviour of determining my toolset for me.
>>>>> keeping a thread on topic is also ettiquette from the mailinglist rules
>>>>> eh?
>>>>>
>>>>> you might wanna consider just how much it pisses me off to have
>>>>> strangers
>>>>> determining my toolset and/or lifestyle for me.
>>>>> that's why i got rude. no other reason.
>>>> Umm... you or your boss/client chose PHP. That means one of those two
>>>> determined your toolset. Maybe next time you might want to pony up for a
>>>> requirements analysis to determine if the toolset is right for the job.
>>>>
>>> you've never heard of feature-creep, changing environments and
>>> requirements, etc?
>> Not usually, at the level of the language choice, is an about turn done
>> after a requirements analysis has been completed. Feature creep is a
>> management issue.
>>
> it's a managment issue only because it's a fact of life.
A billable one.
Cheers,
Rob.
--
http://www.interjinn.com
Application and Templating Framework for PHP
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 20:42:53 von Tommy Pham
On Wed, Mar 24, 2010 at 10:18 AM, Sancar Saran wr=
ote:
> On Wednesday 24 March 2010 03:17:56 Tommy Pham wrote:
>> Let's go back to my 1st e-commerce example. Â The manufacturers list=
is
>> about 3,700. Â The categories is about about 2,400. Â The produc=
ts list
>> is right now at 500,000 and expected to be around 750,000. Â The sit=
e
>> is only in English. Â The store owner wants to expand and be I18n:
>> Chinese, French, German, Korean, Spanish. Â You see how big and comp=
lex
>> that database gets? Â The store owners want to have this happens whe=
n a
>> customer clicks on a category:
>>
>> * show all subcategories for that category, if any
>> * show all products for that category, if any,
>> * show all manufacturers, used as filtering, for that category and
>> subcategories * show price range filter for that category
>> * show features & specifications filter for that category
>> * show 10 top sellers for that category and related subcategories
>> * the shopper can then select/deselect any of those filters and
>> ability to sort by manufacturers, prices, user rating, popularity
>> (purchased quantity)
>> * have the ability to switch to another language translation on the fly
>> * from the moment the shopper click on a link, the response time (when
>> web browser saids "Done" in the status bar) is 5 seconds or less.
>> Preferably 2-3 seconds. Will be using stopwatch for the timer.
>>
>> Now show me a website that meets those requirements and uses PHP, I'll
>> be glad to support your argument about PHP w/o threads :) Â BTW, thi=
s
>> is not even enterprise requirement. Â I may have another possible
>> project where # products is over 10 million easily. Â With similar
>> requirements when the user click on category. Â Do you think this si=
te,
>> which currently isn't, can run on PHP?
>>
>> Regards,
>> Tommy
>
>
> If you design and code correctly. Yes.
>
>
> If you want to use someting alredy. Try TYPO3.
>
> PS: Your arguments are something about implementation not something about
> platform abilities. You can do this things any server side programming wi=
th
> enough hardware.
>
> Regards
>
> Sancar
>
>
Platform abilities =3D PHP with/without threads.
Implementation =3D If PHP has threads, how do I implement it. If not,
what work around / hacks do I need to do.
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 20:43:08 von Rene Veerman
On Wed, Mar 24, 2010 at 9:41 PM, Robert Cummings wro=
te:
>
>
> Rene Veerman wrote:
>>
>> On Wed, Mar 24, 2010 at 9:30 PM, Robert Cummings
>> wrote:
>>>
>>> Rene Veerman wrote:
>>>>
>>>> On Wed, Mar 24, 2010 at 3:13 PM, Robert Cummings
>
>>>> wrote:
>>>>>
>>>>> Rene Veerman wrote:
>>>>>>
>>>>>> talk to me about this some other time.
>>>>>>
>>>>>> atm i'm having an argument with per and his kind about their very ve=
ry
>>>>>> annoying behaviour of determining my toolset for me.
>>>>>> keeping a thread on topic is also ettiquette from the mailinglist
>>>>>> rules
>>>>>> eh?
>>>>>>
>>>>>> you might wanna consider just how much it pisses me off to have
>>>>>> strangers
>>>>>> determining my toolset and/or lifestyle for me.
>>>>>> that's why i got rude. no other reason.
>>>>>
>>>>> Umm... you or your boss/client chose PHP. That means one of those two
>>>>> determined your toolset. Maybe next time you might want to pony up fo=
r
>>>>> a
>>>>> requirements analysis to determine if the toolset is right for the jo=
b.
>>>>>
>>>> you've never heard of feature-creep, changing environments and
>>>> requirements, etc?
>>>
>>> Not usually, at the level of the language choice, is an about turn done
>>> after a requirements analysis has been completed. Feature creep is a
>>> management issue.
>>>
>> it's a managment issue only =A0because it's a fact of life.
>
> A billable one.
>
i prefer to reduce my headaches and bill size at the same time with
up-to-date tools.
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 20:45:09 von Larry Garfield
On 3/24/10 2:33 PM, Rene Veerman wrote:
>> It's a debate. The dev team consider proposals and weigh in on the merits. I
>> was a proponent for goto support during the development of PHP 5. We now
>> have it. If you arguments are valid and there's no technical issue
>> preventing it, and there's someone with time and skill to created the
>> functionality, then it will happen. If not then it won't. I've seen many
>> things added to PHP and I've watched and participated in the threads on
>> internals that have lead to many new features. This is open source, opinions
>> matter, but personal attacks and poor argument do not really make the cut.
>>
>
> hahaha... you dismiss what i believe to be valid explanations without
> any counter-argument besides "more sql hardware!", not just by me but
> by all advocates of threading&shared memory in php.
>
> for some reason, which is still not clear to me, you nay-sayers refuse
> to let a PROGRAMMING LANGUAGE (not a "hammer", not a "fishing boat")
> evolve to stay useful, relevant even, in a changing market.
>
> and you're blatantly telling me to use a different kind of "hammer",
> one that would force me to rewrite large sections of my existing
> code-base, and one that i have told you i would find for many other
> _valid_ reasons not optimal.
And what you seem to be missing is that making PHP userspace threaded is
such a major change to the underlying code base and architecture that it
would essentially be a total and complete rewrite, and would require
people to rewrite large portions of their existing PHP userspace code.
So it's either you adjust your code to fit the paradigm that PHP is
built for from the ground up, or the entire rest of the world adjusts
its code to fit the paradigm that you think you want to have.
> basically, you're determining my choice of options without me ever
> having forced you to do something a certain way..
>
> so you'll have to excuse my strong language.
> it's just letting you know that you shouldn't butt into other peoples
> business when it doesn't really affect you.
Except having to rewrite all of my code to be thread safe would affect me.
If you didn't want to have a discussion, which by nature has differing
view points, you shouldn't be on a discussion list.
--Larry Garfield
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 20:45:25 von Robert Cummings
Rene Veerman wrote:
> On Wed, Mar 24, 2010 at 9:31 PM, Robert Cummings wrote:
>>
>> Rene Veerman wrote:
>>> On Wed, Mar 24, 2010 at 3:25 PM, Robert Cummings
>>> wrote:
>>>> Rene Veerman wrote:
>>>>> php is not a hammer, its a programming language.
>>>> It's hard to discuss anything with someone who doesn't comprehend a
>>>> metaphor.
>>> haha. "comprehend". you mean "accept".
>>> that metaphor is stretched to breaking point as far as i'm concerned.
>>>
>>>>> one that i feel needs to stay ahead of the computing trend if it is to
>>>>> be considered a language for large scale applications.
>>>> Personification of PHP doesn't make your argument any more salient. PHP
>>>> isn't trying to stay ahead of anything. People are using it to solve
>>>> problems, not to meet some phantom ideal of a "computing trend"
>>>> threshold.
>>>>
>>>>> but you nay-sayers here have convinced me; i'll be shopping for
>>>>> another language with which to serve my applications and the weboutput
>>>>> they produce..
>>>>>
>>>>> thanks for opening my eyes and telling to abandon ship in time.
>>>> Obviously we didn't open your eyes.
>>>>
>>> Well excuse me for not dumping 50-100k lines of my own cms code
>>> instantly now that i realize that in order to scale it, i could really
>>> use features like threading and shared memory.
>> Actually, you are th eone suggesting dumping your code since you said you
>> were jumping ship. Many of us suggested that your problems can almost
>> certainly be mitigated without threading.
>>
>
> "almost certainly". at least you're acknowledging that you might be wrong.
I'm certianly not right all the time. once I thought I was but I was wrong.
> take this example, sorry for the crosspost;
>
> my main concern atm is my own cms (50-100k lines of my own); it's
> graphics-heavy, does fairly complicated db based logic, and if it ever
> is to be used for a site like facebook, it'll get large dataflows that
> have to be distributed over the servers used to generate html and
> accessoiries for end-users.
> i've built a layer into it that caches the output of oft-used pages
> (like articles and their comments).
> but adding many comments / minute to an article would result in quite
> a bit of overhead, to update the html for that page and distribute it
> (fast enough) to the relevant servers.
>
> i'm worried about php's single-threaded nature; each request has to
> fetch html updated in the last few seconds, or generate it from a list
> of comments. that's also a big query from a big table for every
> end-user.. :(
> i'd rather keep them comments for an article in shared memory.....
I think you'll find when you get even close to the size of facebook,
everything you think you know now about how it all stays running will be
thrown out the window. But then, I'm not a fan of early optimization of
this magnitude. A good design is usually flexible enough to allow
redesign without recoding everything. Baby steps to the moon IMHO.
Cheers,
Rob.
--
http://www.interjinn.com
Application and Templating Framework for PHP
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 20:47:26 von Robert Cummings
Rene Veerman wrote:
> On Wed, Mar 24, 2010 at 9:41 PM, Robert Cummings wrote:
>>
>> Rene Veerman wrote:
>>> On Wed, Mar 24, 2010 at 9:30 PM, Robert Cummings
>>> wrote:
>>>> Rene Veerman wrote:
>>>>> On Wed, Mar 24, 2010 at 3:13 PM, Robert Cummings
>>>>> wrote:
>>>>>> Rene Veerman wrote:
>>>>>>> talk to me about this some other time.
>>>>>>>
>>>>>>> atm i'm having an argument with per and his kind about their very very
>>>>>>> annoying behaviour of determining my toolset for me.
>>>>>>> keeping a thread on topic is also ettiquette from the mailinglist
>>>>>>> rules
>>>>>>> eh?
>>>>>>>
>>>>>>> you might wanna consider just how much it pisses me off to have
>>>>>>> strangers
>>>>>>> determining my toolset and/or lifestyle for me.
>>>>>>> that's why i got rude. no other reason.
>>>>>> Umm... you or your boss/client chose PHP. That means one of those two
>>>>>> determined your toolset. Maybe next time you might want to pony up for
>>>>>> a
>>>>>> requirements analysis to determine if the toolset is right for the job.
>>>>>>
>>>>> you've never heard of feature-creep, changing environments and
>>>>> requirements, etc?
>>>> Not usually, at the level of the language choice, is an about turn done
>>>> after a requirements analysis has been completed. Feature creep is a
>>>> management issue.
>>>>
>>> it's a managment issue only because it's a fact of life.
>> A billable one.
>>
> i prefer to reduce my headaches and bill size at the same time with
> up-to-date tools.
Your tools are up to date. Threading is in the future if at all... it's
certainly not in the present.
Cheers,
Rob.
--
http://www.interjinn.com
Application and Templating Framework for PHP
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 20:50:15 von Rene Veerman
On Wed, Mar 24, 2010 at 9:45 PM, Robert Cummings wrote:
> Rene Veerman wrote:
>>
>> On Wed, Mar 24, 2010 at 9:31 PM, Robert Cummings
>> wrote:
>>>
>>> Rene Veerman wrote:
>>>>
>>>> On Wed, Mar 24, 2010 at 3:25 PM, Robert Cummings
>>>> wrote:
>>>>>
>>>>> Rene Veerman wrote:
>>>>>>
>>>>>> php is not a hammer, its a programming language.
>>>>>
>>>>> It's hard to discuss anything with someone who doesn't comprehend a
>>>>> metaphor.
>>>>
>>>> haha. "comprehend". you mean "accept".
>>>> that metaphor is stretched to breaking point as far as i'm concerned.
>>>>
>>>>>> one that i feel needs to stay ahead of the computing trend if it is to
>>>>>> be considered a language for large scale applications.
>>>>>
>>>>> Personification of PHP doesn't make your argument any more salient. PHP
>>>>> isn't trying to stay ahead of anything. People are using it to solve
>>>>> problems, not to meet some phantom ideal of a "computing trend"
>>>>> threshold.
>>>>>
>>>>>> but you nay-sayers here have convinced me; i'll be shopping for
>>>>>> another language with which to serve my applications and the weboutput
>>>>>> they produce..
>>>>>>
>>>>>> thanks for opening my eyes and telling to abandon ship in time.
>>>>>
>>>>> Obviously we didn't open your eyes.
>>>>>
>>>> Well excuse me for not dumping 50-100k lines of my own cms code
>>>> instantly now that i realize that in order to scale it, i could really
>>>> use features like threading and shared memory.
>>>
>>> Actually, you are th eone suggesting dumping your code since you said you
>>> were jumping ship. Many of us suggested that your problems can almost
>>> certainly be mitigated without threading.
>>>
>>
>> "almost certainly". at least you're acknowledging that you might be wrong.
>
> I'm certianly not right all the time. once I thought I was but I was wrong.
>
>> take this example, sorry for the crosspost;
>>
>> my main concern atm is my own cms (50-100k lines of my own); it's
>> graphics-heavy, does fairly complicated db based logic, and if it ever
>> is to be used for a site like facebook, it'll get large dataflows that
>> have to be distributed over the servers used to generate html and
>> accessoiries for end-users.
>> i've built a layer into it that caches the output of oft-used pages
>> (like articles and their comments).
>> but adding many comments / minute to an article would result in quite
>> a bit of overhead, to update the html for that page and distribute it
>> (fast enough) to the relevant servers.
>>
>> i'm worried about php's single-threaded nature; each request has to
>> fetch html updated in the last few seconds, or generate it from a list
>> of comments. that's also a big query from a big table for every
>> end-user.. :(
>> i'd rather keep them comments for an article in shared memory.....
>
> I think you'll find when you get even close to the size of facebook,
> everything you think you know now about how it all stays running will be
> thrown out the window. But then, I'm not a fan of early optimization of this
> magnitude. A good design is usually flexible enough to allow redesign
> without recoding everything. Baby steps to the moon IMHO.
>
yea, well, if i'm going to keep using php i need a path towards
scalability, for this particular problem.
i'd like to code the kinds of applications with big dataflows.
call me a golddigger all you want, it's what i am ;)
just not in the sexual sense hehe..
>Your tools are up to date. Threading is in the future if at all... it's certainly not in the present.
True, lets _keep_ 'm up-to-date, please.
And you'd enable other uses of PHP besides helping this
real-time-web-scalability problem.
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 20:54:21 von Ashley Sheridan
--=-J2fl78WF7ZsIVth67eN1
Content-Type: text/plain
Content-Transfer-Encoding: 7bit
On Wed, 2010-03-24 at 21:50 +0200, Rene Veerman wrote:
> On Wed, Mar 24, 2010 at 9:45 PM, Robert Cummings wrote:
> > Rene Veerman wrote:
> >>
> >> On Wed, Mar 24, 2010 at 9:31 PM, Robert Cummings
> >> wrote:
> >>>
> >>> Rene Veerman wrote:
> >>>>
> >>>> On Wed, Mar 24, 2010 at 3:25 PM, Robert Cummings
> >>>> wrote:
> >>>>>
> >>>>> Rene Veerman wrote:
> >>>>>>
> >>>>>> php is not a hammer, its a programming language.
> >>>>>
> >>>>> It's hard to discuss anything with someone who doesn't comprehend a
> >>>>> metaphor.
> >>>>
> >>>> haha. "comprehend". you mean "accept".
> >>>> that metaphor is stretched to breaking point as far as i'm concerned.
> >>>>
> >>>>>> one that i feel needs to stay ahead of the computing trend if it is to
> >>>>>> be considered a language for large scale applications.
> >>>>>
> >>>>> Personification of PHP doesn't make your argument any more salient. PHP
> >>>>> isn't trying to stay ahead of anything. People are using it to solve
> >>>>> problems, not to meet some phantom ideal of a "computing trend"
> >>>>> threshold.
> >>>>>
> >>>>>> but you nay-sayers here have convinced me; i'll be shopping for
> >>>>>> another language with which to serve my applications and the weboutput
> >>>>>> they produce..
> >>>>>>
> >>>>>> thanks for opening my eyes and telling to abandon ship in time.
> >>>>>
> >>>>> Obviously we didn't open your eyes.
> >>>>>
> >>>> Well excuse me for not dumping 50-100k lines of my own cms code
> >>>> instantly now that i realize that in order to scale it, i could really
> >>>> use features like threading and shared memory.
> >>>
> >>> Actually, you are th eone suggesting dumping your code since you said you
> >>> were jumping ship. Many of us suggested that your problems can almost
> >>> certainly be mitigated without threading.
> >>>
> >>
> >> "almost certainly". at least you're acknowledging that you might be wrong.
> >
> > I'm certianly not right all the time. once I thought I was but I was wrong.
> >
> >> take this example, sorry for the crosspost;
> >>
> >> my main concern atm is my own cms (50-100k lines of my own); it's
> >> graphics-heavy, does fairly complicated db based logic, and if it ever
> >> is to be used for a site like facebook, it'll get large dataflows that
> >> have to be distributed over the servers used to generate html and
> >> accessoiries for end-users.
> >> i've built a layer into it that caches the output of oft-used pages
> >> (like articles and their comments).
> >> but adding many comments / minute to an article would result in quite
> >> a bit of overhead, to update the html for that page and distribute it
> >> (fast enough) to the relevant servers.
> >>
> >> i'm worried about php's single-threaded nature; each request has to
> >> fetch html updated in the last few seconds, or generate it from a list
> >> of comments. that's also a big query from a big table for every
> >> end-user.. :(
> >> i'd rather keep them comments for an article in shared memory.....
> >
> > I think you'll find when you get even close to the size of facebook,
> > everything you think you know now about how it all stays running will be
> > thrown out the window. But then, I'm not a fan of early optimization of this
> > magnitude. A good design is usually flexible enough to allow redesign
> > without recoding everything. Baby steps to the moon IMHO.
> >
> yea, well, if i'm going to keep using php i need a path towards
> scalability, for this particular problem.
>
> i'd like to code the kinds of applications with big dataflows.
> call me a golddigger all you want, it's what i am ;)
> just not in the sexual sense hehe..
>
> >Your tools are up to date. Threading is in the future if at all... it's certainly not in the present.
>
> True, lets _keep_ 'm up-to-date, please.
>
> And you'd enable other uses of PHP besides helping this
> real-time-web-scalability problem.
>
Why don't you set up a vote to see how many developers actually *want*
threading. That would be a good indication of whether or not it is
actually worth the PHP development team spending a lot of time on it at
the loss of other features which people want more.
Thanks,
Ash
http://www.ashleysheridan.co.uk
--=-J2fl78WF7ZsIVth67eN1--
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 20:59:45 von Rene Veerman
On Wed, Mar 24, 2010 at 9:45 PM, larry@garfieldtech.com
wrote:
> On 3/24/10 2:33 PM, Rene Veerman wrote:
>
>>> It's a debate. The dev team consider proposals and weigh in on the
>>> merits. I
>>> was a proponent for goto support during the development of PHP 5. We now
>>> have it. If you arguments are valid and there's no technical issue
>>> preventing it, and there's someone with time and skill to created the
>>> functionality, then it will happen. If not then it won't. I've seen many
>>> things added to PHP and I've watched and participated in the threads on
>>> internals that have lead to many new features. This is open source,
>>> opinions
>>> matter, but personal attacks and poor argument do not really make the
>>> cut.
>>>
>>
>> hahaha... you dismiss what i believe to be valid explanations without
>> any counter-argument besides "more sql hardware!", not just by me but
>> by all advocates of threading&shared memory in php.
>>
>> for some reason, which is still not clear to me, you nay-sayers refuse
>> to let a PROGRAMMING LANGUAGE (not a "hammer", not a "fishing boat")
>> evolve to stay useful, relevant even, in a changing market.
>>
>> and you're blatantly telling me to use a different kind of "hammer",
>> one that would force me to rewrite large sections of my existing
>> code-base, and one that i have told you i would find for many other
>> _valid_ reasons not optimal.
>
> And what you seem to be missing is that making PHP userspace threaded is
> such a major change to the underlying code base and architecture that it
> would essentially be a total and complete rewrite, and would require people
> to rewrite large portions of their existing PHP userspace code.
ehm, my newsscraper does threading via a fopen($threadURLonOwnServer)
-> fread(threads,2048)+check for feof($thread) + usleep(50ms) -> if
feof($thread) process($threadResults).
so with a hack, you can let apache handle the threading, today.
i suppose i could write something for shared memory in C++ but doing
so would also be a hack that has to be installed on each server,
rather than having it neatly as part of php.
yet if i can code 'm as addons, it must not be hard to include it in the core.
the paradigm "shared nothing" may still be the preferred default if
you want, but fact is _current_ PHP can set_time_limit(0) and
usleep(50ms) until it has something to do again.
so i refute it would require a rewrite of php.
both features i request for php6/7 can be put in as addons.
>
> So it's either you adjust your code to fit the paradigm that PHP is built
> for from the ground up, or the entire rest of the world adjusts its code to
> fit the paradigm that you think you want to have.
that's just not the case imo.
>
>> basically, you're determining my choice of options without me ever
>> having forced you to do something a certain way..
>>
>> so you'll have to excuse my strong language.
>> it's just letting you know that you shouldn't butt into other peoples
>> business when it doesn't really affect you.
>
> Except having to rewrite all of my code to be thread safe would affect me.
>
> If you didn't want to have a discussion, which by nature has differing view
> points, you shouldn't be on a discussion list.
>
> --Larry Garfield
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 20:59:55 von Tommy Pham
On Wed, Mar 24, 2010 at 4:28 AM, Per Jessen wrote:
> Tommy Pham wrote:
>
>> On Wed, Mar 24, 2010 at 3:44 AM, Per Jessen wrote:
>>> Tommy Pham wrote:
>>>
>>>> On Wed, Mar 24, 2010 at 3:20 AM, Per Jessen
>>>> wrote:
>>>>> Tommy Pham wrote:
>>>>>
>>>>>> What I find funny is that one of opponents of PHP threads earlier
>>>>>> mentioned that how silly it would be to be using C in a web app.
>>>>>> Now I hear people mentioning C when they need "productivity" or
>>>>>> "speed"...
>>>>>>
>>>>>
>>>>> I think I was the one to mention the latter, but as I started out
>>>>> saying, and as others have said too, it's about the right tool for
>>>>> the right job. Â When choosing a tool, there are a number of fact=
ors
>>>>> to consider - developer productivity, available skills, future
>>>>> maintenance, performance, scalability, portability, parallelism,
>>>>> performance etcetera.
>>>>>
>>>>
>>>> Funny you should mention all that. Â Let's say that you're longer
>>>> with that company, either by direct employment or contract
>>>> consultant. You've implemented C because you need 'thread'. Â Now
>>>> your replacement comes in and has no clue about C even though your
>>>> replacement is a PHP guru. Â How much headache is maintenance gonn=
a
>>>> be? Â Scalability? Portability? wow....
>>>
>>> Who was the idi... who hired someone who wasn't suited for the job?
>>> Tommy, that's a moot argument. Â You can't fit a square peg in a ro=
und
>>> hole.
>>>
>>> --
>>> Per Jessen, Zürich (12.5°C)
>>>
>>
>> Suited for the job? Â You mean introduce more complexity to a proble=
m
>> that what could be avoided to begin with if PHP has thread support?
>> hmmm....
>
> Tommy, it's perfectly simple: Â in my company we hire people with C
> skills for C programming jobs. We hire people with database skills to
> be database administrators. Â We hire people with Linux skills to wor=
k
> on Linux systems. Â We explicitly do _not_ hire PHP web-programmers t=
o
> maintain our C code. Â And vice versa for that matter. Â No probl=
em, no
> complexity.
>
>
> --
> Per Jessen, Zürich (13.4°C)
>
>
That may just work out fine if you work directly for the company with
all the proper staffing. But some of us work as consultants or for
companies without the proper staffing. As such, let's dissect what
you mentioned:
1) PHP with internal thread support
2) PHP with external C/C++ thread support
* Performance - having external thread support, now you have to call
an extension (more memory usage and CPU cycles). If you happen to
have a C/C++ guru who can then code that thread support into PHP
extension, wouldn't it still perform better at the core vs as an
extension because it's not talking to a 'middle man'? Having said
that, not everyone has access to a C/C++ guru. Thus not mass
availability.
* Portability - if you're currently running PHP on Windows, but manage
to convince management to switch to *BSD/Linux, then you'd have to
rewrite that external thread support. But for us consultants, we may
have 1 project the runs on Windows, the next may be *BSD/Linux. PHP
code snippets goes a lot further versus your custom work around.
* Managability - should your need to upgrade PHP for either bug fix,
new features you'd want to implement to add more functionality to your
site, will that then break your custom external solution? How much
more manageable is it if it's done under 1 language versus 2+?
Regards,
Tommy
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 21:05:05 von Ashley Sheridan
--=-pCz7XZm1p1Bp9alMrByX
Content-Type: text/plain
Content-Transfer-Encoding: 7bit
On Wed, 2010-03-24 at 22:05 +0200, Rene Veerman wrote:
> On Wed, Mar 24, 2010 at 9:54 PM, Ashley Sheridan
> wrote:
>
> > On Wed, 2010-03-24 at 21:50 +0200, Rene Veerman wrote:
> >
> > On Wed, Mar 24, 2010 at 9:45 PM, Robert Cummings wrote:
> > > Rene Veerman wrote:
> > >>
> > >> On Wed, Mar 24, 2010 at 9:31 PM, Robert Cummings
> > >> wrote:
> > >>>
> > >>> Rene Veerman wrote:
> > >>>>
> > >>>> On Wed, Mar 24, 2010 at 3:25 PM, Robert Cummings
> > >>>> wrote:
> > >>>>>
> > >>>>> Rene Veerman wrote:
> > >>>>>>
> > >>>>>> php is not a hammer, its a programming language.
> > >>>>>
> > >>>>> It's hard to discuss anything with someone who doesn't comprehend a
> > >>>>> metaphor.
> > >>>>
> > >>>> haha. "comprehend". you mean "accept".
> > >>>> that metaphor is stretched to breaking point as far as i'm concerned.
> > >>>>
> > >>>>>> one that i feel needs to stay ahead of the computing trend if it is to
> > >>>>>> be considered a language for large scale applications.
> > >>>>>
> > >>>>> Personification of PHP doesn't make your argument any more salient. PHP
> > >>>>> isn't trying to stay ahead of anything. People are using it to solve
> > >>>>> problems, not to meet some phantom ideal of a "computing trend"
> > >>>>> threshold.
> > >>>>>
> > >>>>>> but you nay-sayers here have convinced me; i'll be shopping for
> > >>>>>> another language with which to serve my applications and the weboutput
> > >>>>>> they produce..
> > >>>>>>
> > >>>>>> thanks for opening my eyes and telling to abandon ship in time.
> > >>>>>
> > >>>>> Obviously we didn't open your eyes.
> > >>>>>
> > >>>> Well excuse me for not dumping 50-100k lines of my own cms code
> > >>>> instantly now that i realize that in order to scale it, i could really
> > >>>> use features like threading and shared memory.
> > >>>
> > >>> Actually, you are th eone suggesting dumping your code since you said you
> > >>> were jumping ship. Many of us suggested that your problems can almost
> > >>> certainly be mitigated without threading.
> > >>>
> > >>
> > >> "almost certainly". at least you're acknowledging that you might be wrong.
> > >
> > > I'm certianly not right all the time. once I thought I was but I was wrong.
> > >
> > >> take this example, sorry for the crosspost;
> > >>
> > >> my main concern atm is my own cms (50-100k lines of my own); it's
> > >> graphics-heavy, does fairly complicated db based logic, and if it ever
> > >> is to be used for a site like facebook, it'll get large dataflows that
> > >> have to be distributed over the servers used to generate html and
> > >> accessoiries for end-users.
> > >> i've built a layer into it that caches the output of oft-used pages
> > >> (like articles and their comments).
> > >> but adding many comments / minute to an article would result in quite
> > >> a bit of overhead, to update the html for that page and distribute it
> > >> (fast enough) to the relevant servers.
> > >>
> > >> i'm worried about php's single-threaded nature; each request has to
> > >> fetch html updated in the last few seconds, or generate it from a list
> > >> of comments. that's also a big query from a big table for every
> > >> end-user.. :(
> > >> i'd rather keep them comments for an article in shared memory.....
> > >
> > > I think you'll find when you get even close to the size of facebook,
> > > everything you think you know now about how it all stays running will be
> > > thrown out the window. But then, I'm not a fan of early optimization of this
> > > magnitude. A good design is usually flexible enough to allow redesign
> > > without recoding everything. Baby steps to the moon IMHO.
> > >
> > yea, well, if i'm going to keep using php i need a path towards
> > scalability, for this particular problem.
> >
> > i'd like to code the kinds of applications with big dataflows.
> > call me a golddigger all you want, it's what i am ;)
> > just not in the sexual sense hehe..
> >
> > >Your tools are up to date. Threading is in the future if at all... it's certainly not in the present.
> >
> > True, lets _keep_ 'm up-to-date, please.
> >
> > And you'd enable other uses of PHP besides helping this
> > real-time-web-scalability problem.
> >
> >
> >
> > Why don't you set up a vote to see how many developers actually *want*
> > threading. That would be a good indication of whether or not it is actually
> > worth the PHP development team spending a lot of time on it at the loss of
> > other features which people want more.
> >
>
> we'd probably lose that vote because so many of you other php programmers
> refuse to see that we do have good uses for it, and you don't. yet.
>
> but ultimately it's a matter of the php dev's team time and effort, so when
> this thread has run it's course i may go to the internals list and raise it
> -diplomatically- there.
So you're basically saying that you'd discount anyone who opposes you
purely because you think you know best?
Nice attitude.
Thanks,
Ash
http://www.ashleysheridan.co.uk
--=-pCz7XZm1p1Bp9alMrByX--
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 21:05:23 von Rene Veerman
--0015174766ac8b35aa04829174b3
Content-Type: text/plain; charset=ISO-8859-1
On Wed, Mar 24, 2010 at 9:54 PM, Ashley Sheridan
wrote:
> On Wed, 2010-03-24 at 21:50 +0200, Rene Veerman wrote:
>
> On Wed, Mar 24, 2010 at 9:45 PM, Robert Cummings wrote:
> > Rene Veerman wrote:
> >>
> >> On Wed, Mar 24, 2010 at 9:31 PM, Robert Cummings
> >> wrote:
> >>>
> >>> Rene Veerman wrote:
> >>>>
> >>>> On Wed, Mar 24, 2010 at 3:25 PM, Robert Cummings
> >>>> wrote:
> >>>>>
> >>>>> Rene Veerman wrote:
> >>>>>>
> >>>>>> php is not a hammer, its a programming language.
> >>>>>
> >>>>> It's hard to discuss anything with someone who doesn't comprehend a
> >>>>> metaphor.
> >>>>
> >>>> haha. "comprehend". you mean "accept".
> >>>> that metaphor is stretched to breaking point as far as i'm concerned.
> >>>>
> >>>>>> one that i feel needs to stay ahead of the computing trend if it is to
> >>>>>> be considered a language for large scale applications.
> >>>>>
> >>>>> Personification of PHP doesn't make your argument any more salient. PHP
> >>>>> isn't trying to stay ahead of anything. People are using it to solve
> >>>>> problems, not to meet some phantom ideal of a "computing trend"
> >>>>> threshold.
> >>>>>
> >>>>>> but you nay-sayers here have convinced me; i'll be shopping for
> >>>>>> another language with which to serve my applications and the weboutput
> >>>>>> they produce..
> >>>>>>
> >>>>>> thanks for opening my eyes and telling to abandon ship in time.
> >>>>>
> >>>>> Obviously we didn't open your eyes.
> >>>>>
> >>>> Well excuse me for not dumping 50-100k lines of my own cms code
> >>>> instantly now that i realize that in order to scale it, i could really
> >>>> use features like threading and shared memory.
> >>>
> >>> Actually, you are th eone suggesting dumping your code since you said you
> >>> were jumping ship. Many of us suggested that your problems can almost
> >>> certainly be mitigated without threading.
> >>>
> >>
> >> "almost certainly". at least you're acknowledging that you might be wrong.
> >
> > I'm certianly not right all the time. once I thought I was but I was wrong.
> >
> >> take this example, sorry for the crosspost;
> >>
> >> my main concern atm is my own cms (50-100k lines of my own); it's
> >> graphics-heavy, does fairly complicated db based logic, and if it ever
> >> is to be used for a site like facebook, it'll get large dataflows that
> >> have to be distributed over the servers used to generate html and
> >> accessoiries for end-users.
> >> i've built a layer into it that caches the output of oft-used pages
> >> (like articles and their comments).
> >> but adding many comments / minute to an article would result in quite
> >> a bit of overhead, to update the html for that page and distribute it
> >> (fast enough) to the relevant servers.
> >>
> >> i'm worried about php's single-threaded nature; each request has to
> >> fetch html updated in the last few seconds, or generate it from a list
> >> of comments. that's also a big query from a big table for every
> >> end-user.. :(
> >> i'd rather keep them comments for an article in shared memory.....
> >
> > I think you'll find when you get even close to the size of facebook,
> > everything you think you know now about how it all stays running will be
> > thrown out the window. But then, I'm not a fan of early optimization of this
> > magnitude. A good design is usually flexible enough to allow redesign
> > without recoding everything. Baby steps to the moon IMHO.
> >
> yea, well, if i'm going to keep using php i need a path towards
> scalability, for this particular problem.
>
> i'd like to code the kinds of applications with big dataflows.
> call me a golddigger all you want, it's what i am ;)
> just not in the sexual sense hehe..
>
> >Your tools are up to date. Threading is in the future if at all... it's certainly not in the present.
>
> True, lets _keep_ 'm up-to-date, please.
>
> And you'd enable other uses of PHP besides helping this
> real-time-web-scalability problem.
>
>
>
> Why don't you set up a vote to see how many developers actually *want*
> threading. That would be a good indication of whether or not it is actually
> worth the PHP development team spending a lot of time on it at the loss of
> other features which people want more.
>
we'd probably lose that vote because so many of you other php programmers
refuse to see that we do have good uses for it, and you don't. yet.
but ultimately it's a matter of the php dev's team time and effort, so when
this thread has run it's course i may go to the internals list and raise it
-diplomatically- there.
--0015174766ac8b35aa04829174b3--
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 21:15:06 von Rene Veerman
--001517402a0a4327e20482919788
Content-Type: text/plain; charset=ISO-8859-1
On Wed, Mar 24, 2010 at 10:05 PM, Ashley Sheridan
wrote:
>
>
> So you're basically saying that you'd discount anyone who opposes you
> purely because you think you know best?
>
> Nice attitude.
>
I ain't saying that at all, nor did i intend to imply it.
In fact it's the anti-threading/shared-mem camp that thinks they know
everything best with their instistance that "throw more hardware at it, more
sql servers, more programming languages in a single project" will solve all
software design / growth problems with enough efficiency.
In this case, you still haven't given me any other reason to oppose the
evolution of php with the market trend, other than that it would cost
php-dev team time that can be spent on other things.
you (that camp) haven't even told me what features you want 'm to spend time
on instead.
--001517402a0a4327e20482919788--
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 21:19:54 von Ashley Sheridan
--=-kajPCLY5acxaumq/smoa
Content-Type: text/plain
Content-Transfer-Encoding: 7bit
On Wed, 2010-03-24 at 22:15 +0200, Rene Veerman wrote:
> On Wed, Mar 24, 2010 at 10:05 PM, Ashley Sheridan
> wrote:
>
> >
> >
> > So you're basically saying that you'd discount anyone who opposes you
> > purely because you think you know best?
> >
> > Nice attitude.
> >
>
> I ain't saying that at all, nor did i intend to imply it.
>
> In fact it's the anti-threading/shared-mem camp that thinks they know
> everything best with their instistance that "throw more hardware at it, more
> sql servers, more programming languages in a single project" will solve all
> software design / growth problems with enough efficiency.
They're offering the alternative. You keep disagreeing with their
viewpoint because you seem to think you know best on this matter and
won't even concede on a point.
>
> In this case, you still haven't given me any other reason to oppose the
> evolution of php with the market trend
Do you have any proof of this 'market trend'? I suggested a vote, but
you 'nay-sayed' it on the basis that you'd lose to people who couldn't
possibly know as much as you do.
> , other than that it would cost
> php-dev team time that can be spent on other things.
> you (that camp) haven't even told me what features you want 'm to spend time
> on instead.
There are no new features that *I* can think of that *I* need in PHP,
which is not to say that there aren't any that *other* people want.
Again, I did suggest some sort of vote on this, which would give the
internals team an idea of how keen people were to see this in the near
future, but you said that too many people would oppose it. This comes
round to the fact again that you seem to know best, and if the majority
of people oppose your suggestion then they must be wrong, so any vote
wouldn't count.
I wouldn't say I belonged to any particular camp at the start of this
thread, but now, having read what my betters have said, I'm inclined to
agree that threading isn't the magic wand that you seem to think it is.
I personally see one of the largest sites in the world running on PHP
without needing threading and without insulting half the list to attempt
to get it.
Thanks,
Ash
http://www.ashleysheridan.co.uk
--=-kajPCLY5acxaumq/smoa--
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 21:21:21 von Robert Cummings
Rene Veerman wrote:
> On Wed, Mar 24, 2010 at 9:45 PM, Robert Cummings wrote:
>> Rene Veerman wrote:
>>> On Wed, Mar 24, 2010 at 9:31 PM, Robert Cummings
>>> wrote:
>>>> Rene Veerman wrote:
>>>>> On Wed, Mar 24, 2010 at 3:25 PM, Robert Cummings
>>>>> wrote:
>>>>>> Rene Veerman wrote:
>>>>>>> php is not a hammer, its a programming language.
>>>>>> It's hard to discuss anything with someone who doesn't comprehend a
>>>>>> metaphor.
>>>>> haha. "comprehend". you mean "accept".
>>>>> that metaphor is stretched to breaking point as far as i'm concerned.
>>>>>
>>>>>>> one that i feel needs to stay ahead of the computing trend if it is to
>>>>>>> be considered a language for large scale applications.
>>>>>> Personification of PHP doesn't make your argument any more salient. PHP
>>>>>> isn't trying to stay ahead of anything. People are using it to solve
>>>>>> problems, not to meet some phantom ideal of a "computing trend"
>>>>>> threshold.
>>>>>>
>>>>>>> but you nay-sayers here have convinced me; i'll be shopping for
>>>>>>> another language with which to serve my applications and the weboutput
>>>>>>> they produce..
>>>>>>>
>>>>>>> thanks for opening my eyes and telling to abandon ship in time.
>>>>>> Obviously we didn't open your eyes.
>>>>>>
>>>>> Well excuse me for not dumping 50-100k lines of my own cms code
>>>>> instantly now that i realize that in order to scale it, i could really
>>>>> use features like threading and shared memory.
>>>> Actually, you are th eone suggesting dumping your code since you said you
>>>> were jumping ship. Many of us suggested that your problems can almost
>>>> certainly be mitigated without threading.
>>>>
>>> "almost certainly". at least you're acknowledging that you might be wrong.
>> I'm certianly not right all the time. once I thought I was but I was wrong.
>>
>>> take this example, sorry for the crosspost;
>>>
>>> my main concern atm is my own cms (50-100k lines of my own); it's
>>> graphics-heavy, does fairly complicated db based logic, and if it ever
>>> is to be used for a site like facebook, it'll get large dataflows that
>>> have to be distributed over the servers used to generate html and
>>> accessoiries for end-users.
>>> i've built a layer into it that caches the output of oft-used pages
>>> (like articles and their comments).
>>> but adding many comments / minute to an article would result in quite
>>> a bit of overhead, to update the html for that page and distribute it
>>> (fast enough) to the relevant servers.
>>>
>>> i'm worried about php's single-threaded nature; each request has to
>>> fetch html updated in the last few seconds, or generate it from a list
>>> of comments. that's also a big query from a big table for every
>>> end-user.. :(
>>> i'd rather keep them comments for an article in shared memory.....
>> I think you'll find when you get even close to the size of facebook,
>> everything you think you know now about how it all stays running will be
>> thrown out the window. But then, I'm not a fan of early optimization of this
>> magnitude. A good design is usually flexible enough to allow redesign
>> without recoding everything. Baby steps to the moon IMHO.
>>
> yea, well, if i'm going to keep using php i need a path towards
> scalability, for this particular problem.
>
> i'd like to code the kinds of applications with big dataflows.
> call me a golddigger all you want, it's what i am ;)
> just not in the sexual sense hehe..
>
>> Your tools are up to date. Threading is in the future if at all... it's certainly not in the present.
>
> True, lets _keep_ 'm up-to-date, please.
It is up to date. You mean make it have all the features you want. PHP
is by it's very existence and ongoing development "up to date".
Cheers,
Rob.
--
http://www.interjinn.com
Application and Templating Framework for PHP
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 21:21:59 von Paul M Foster
On Wed, Mar 24, 2010 at 09:50:15PM +0200, Rene Veerman wrote:
> On Wed, Mar 24, 2010 at 9:45 PM, Robert Cummings
> wrote:
>
> > Your tools are up to date. Threading is in the future if at all... it's
> > certainly not in the present.
>
> True, lets _keep_ 'm up-to-date, please.
>
> And you'd enable other uses of PHP besides helping this
> real-time-web-scalability problem.
Rene: You've been told you have two choices. Handle this with the PHP
developers, or use a different language. Clearly, you're not making any
converts on *this* list, and no one here can help you.
Everyone else: Rene is baiting you, and drawing out the "discussion".
He's simply thrashing about, trying to make you wrong for disagreeing
with him. There is no more blood to be gained from the turnip of this
thread. If you'd like to see it ended sometime this century, stop
replying to him (in this and his other thread) and let him go bother the
PHP developers, or use some other language.
Paul
--
Paul M. Foster
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 21:22:24 von Robert Cummings
Rene Veerman wrote:
> On Wed, Mar 24, 2010 at 9:45 PM, larry@garfieldtech.com
> wrote:
>> On 3/24/10 2:33 PM, Rene Veerman wrote:
>>
>>>> It's a debate. The dev team consider proposals and weigh in on the
>>>> merits. I
>>>> was a proponent for goto support during the development of PHP 5. We now
>>>> have it. If you arguments are valid and there's no technical issue
>>>> preventing it, and there's someone with time and skill to created the
>>>> functionality, then it will happen. If not then it won't. I've seen many
>>>> things added to PHP and I've watched and participated in the threads on
>>>> internals that have lead to many new features. This is open source,
>>>> opinions
>>>> matter, but personal attacks and poor argument do not really make the
>>>> cut.
>>>>
>>> hahaha... you dismiss what i believe to be valid explanations without
>>> any counter-argument besides "more sql hardware!", not just by me but
>>> by all advocates of threading&shared memory in php.
>>>
>>> for some reason, which is still not clear to me, you nay-sayers refuse
>>> to let a PROGRAMMING LANGUAGE (not a "hammer", not a "fishing boat")
>>> evolve to stay useful, relevant even, in a changing market.
>>>
>>> and you're blatantly telling me to use a different kind of "hammer",
>>> one that would force me to rewrite large sections of my existing
>>> code-base, and one that i have told you i would find for many other
>>> _valid_ reasons not optimal.
>> And what you seem to be missing is that making PHP userspace threaded is
>> such a major change to the underlying code base and architecture that it
>> would essentially be a total and complete rewrite, and would require people
>> to rewrite large portions of their existing PHP userspace code.
>
>
> ehm, my newsscraper does threading via a fopen($threadURLonOwnServer)
> -> fread(threads,2048)+check for feof($thread) + usleep(50ms) -> if
> feof($thread) process($threadResults).
>
> so with a hack, you can let apache handle the threading, today.
>
> i suppose i could write something for shared memory in C++ but doing
> so would also be a hack that has to be installed on each server,
> rather than having it neatly as part of php.
See PECL.
Cheers,
Rob.
--
http://www.interjinn.com
Application and Templating Framework for PHP
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 21:24:52 von Robert Cummings
Tommy Pham wrote:
> On Wed, Mar 24, 2010 at 4:28 AM, Per Jessen wrote:
>> Tommy Pham wrote:
>>
>>> On Wed, Mar 24, 2010 at 3:44 AM, Per Jessen wrote:
>>>> Tommy Pham wrote:
>>>>
>>>>> On Wed, Mar 24, 2010 at 3:20 AM, Per Jessen
>>>>> wrote:
>>>>>> Tommy Pham wrote:
>>>>>>
>>>>>>> What I find funny is that one of opponents of PHP threads earlier
>>>>>>> mentioned that how silly it would be to be using C in a web app.
>>>>>>> Now I hear people mentioning C when they need "productivity" or
>>>>>>> "speed"...
>>>>>>>
>>>>>> I think I was the one to mention the latter, but as I started out
>>>>>> saying, and as others have said too, it's about the right tool for
>>>>>> the right job. When choosing a tool, there are a number of factors
>>>>>> to consider - developer productivity, available skills, future
>>>>>> maintenance, performance, scalability, portability, parallelism,
>>>>>> performance etcetera.
>>>>>>
>>>>> Funny you should mention all that. Let's say that you're longer
>>>>> with that company, either by direct employment or contract
>>>>> consultant. You've implemented C because you need 'thread'. Now
>>>>> your replacement comes in and has no clue about C even though your
>>>>> replacement is a PHP guru. How much headache is maintenance gonna
>>>>> be? Scalability? Portability? wow....
>>>> Who was the idi... who hired someone who wasn't suited for the job?
>>>> Tommy, that's a moot argument. You can't fit a square peg in a round
>>>> hole.
>>>>
>>>> --
>>>> Per Jessen, Zürich (12.5°C)
>>>>
>>> Suited for the job? You mean introduce more complexity to a problem
>>> that what could be avoided to begin with if PHP has thread support?
>>> hmmm....
>> Tommy, it's perfectly simple: in my company we hire people with C
>> skills for C programming jobs. We hire people with database skills to
>> be database administrators. We hire people with Linux skills to work
>> on Linux systems. We explicitly do _not_ hire PHP web-programmers to
>> maintain our C code. And vice versa for that matter. No problem, no
>> complexity.
>>
>>
>> --
>> Per Jessen, Zürich (13.4°C)
>>
>>
>
> That may just work out fine if you work directly for the company with
> all the proper staffing. But some of us work as consultants or for
> companies without the proper staffing. As such, let's dissect what
> you mentioned:
>
> 1) PHP with internal thread support
> 2) PHP with external C/C++ thread support
>
> * Performance - having external thread support, now you have to call
> an extension (more memory usage and CPU cycles). If you happen to
> have a C/C++ guru who can then code that thread support into PHP
> extension, wouldn't it still perform better at the core vs as an
> extension because it's not talking to a 'middle man'? Having said
> that, not everyone has access to a C/C++ guru. Thus not mass
> availability.
Are you suggesting that you need to be a guru in C to write threaded C
code? I think the word you're looking for is competent.
> * Portability - if you're currently running PHP on Windows, but manage
> to convince management to switch to *BSD/Linux, then you'd have to
> rewrite that external thread support. But for us consultants, we may
> have 1 project the runs on Windows, the next may be *BSD/Linux. PHP
> code snippets goes a lot further versus your custom work around.
> * Managability - should your need to upgrade PHP for either bug fix,
> new features you'd want to implement to add more functionality to your
> site, will that then break your custom external solution? How much
> more manageable is it if it's done under 1 language versus 2+?
Are you suggesting cross platform thread libraries don't exist? I wonder
how Apache does it... or MySQL... or any number of open source
cross-platform systems. If they implement their own, then by the virtue
of the source being open, you can feel free to incorporate.
Cheers,
Rob.
--
http://www.interjinn.com
Application and Templating Framework for PHP
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 21:25:33 von Rene Veerman
On Wed, Mar 24, 2010 at 10:21 PM, Robert Cummings wrote:
>
>
> Rene Veerman wrote:
>>
>> On Wed, Mar 24, 2010 at 9:45 PM, Robert Cummings
>> wrote:
>>>
>>> Rene Veerman wrote:
>>>>
>>>> On Wed, Mar 24, 2010 at 9:31 PM, Robert Cummings
>>>> wrote:
>>>>>
>>>>> Rene Veerman wrote:
>>>>>>
>>>>>> On Wed, Mar 24, 2010 at 3:25 PM, Robert Cummings
>>>>>>
>>>>>> wrote:
>>>>>>>
>>>>>>> Rene Veerman wrote:
>>>>>>>>
>>>>>>>> php is not a hammer, its a programming language.
>>>>>>>
>>>>>>> It's hard to discuss anything with someone who doesn't comprehend a
>>>>>>> metaphor.
>>>>>>
>>>>>> haha. "comprehend". you mean "accept".
>>>>>> that metaphor is stretched to breaking point as far as i'm concerned.
>>>>>>
>>>>>>>> one that i feel needs to stay ahead of the computing trend if it is
>>>>>>>> to
>>>>>>>> be considered a language for large scale applications.
>>>>>>>
>>>>>>> Personification of PHP doesn't make your argument any more salient.
>>>>>>> PHP
>>>>>>> isn't trying to stay ahead of anything. People are using it to solve
>>>>>>> problems, not to meet some phantom ideal of a "computing trend"
>>>>>>> threshold.
>>>>>>>
>>>>>>>> but you nay-sayers here have convinced me; i'll be shopping for
>>>>>>>> another language with which to serve my applications and the
>>>>>>>> weboutput
>>>>>>>> they produce..
>>>>>>>>
>>>>>>>> thanks for opening my eyes and telling to abandon ship in time.
>>>>>>>
>>>>>>> Obviously we didn't open your eyes.
>>>>>>>
>>>>>> Well excuse me for not dumping 50-100k lines of my own cms code
>>>>>> instantly now that i realize that in order to scale it, i could really
>>>>>> use features like threading and shared memory.
>>>>>
>>>>> Actually, you are th eone suggesting dumping your code since you said
>>>>> you
>>>>> were jumping ship. Many of us suggested that your problems can almost
>>>>> certainly be mitigated without threading.
>>>>>
>>>> "almost certainly". at least you're acknowledging that you might be
>>>> wrong.
>>>
>>> I'm certianly not right all the time. once I thought I was but I was
>>> wrong.
>>>
>>>> take this example, sorry for the crosspost;
>>>>
>>>> my main concern atm is my own cms (50-100k lines of my own); it's
>>>> graphics-heavy, does fairly complicated db based logic, and if it ever
>>>> is to be used for a site like facebook, it'll get large dataflows that
>>>> have to be distributed over the servers used to generate html and
>>>> accessoiries for end-users.
>>>> i've built a layer into it that caches the output of oft-used pages
>>>> (like articles and their comments).
>>>> but adding many comments / minute to an article would result in quite
>>>> a bit of overhead, to update the html for that page and distribute it
>>>> (fast enough) to the relevant servers.
>>>>
>>>> i'm worried about php's single-threaded nature; each request has to
>>>> fetch html updated in the last few seconds, or generate it from a list
>>>> of comments. that's also a big query from a big table for every
>>>> end-user.. :(
>>>> i'd rather keep them comments for an article in shared memory.....
>>>
>>> I think you'll find when you get even close to the size of facebook,
>>> everything you think you know now about how it all stays running will be
>>> thrown out the window. But then, I'm not a fan of early optimization of
>>> this
>>> magnitude. A good design is usually flexible enough to allow redesign
>>> without recoding everything. Baby steps to the moon IMHO.
>>>
>> yea, well, if i'm going to keep using php i need a path towards
>> scalability, for this particular problem.
>>
>> i'd like to code the kinds of applications with big dataflows.
>> call me a golddigger all you want, it's what i am ;)
>> just not in the sexual sense hehe..
>>
>>> Your tools are up to date. Threading is in the future if at all... it's
>>> certainly not in the present.
>>
>> True, lets _keep_ 'm up-to-date, please.
>
> It is up to date. You mean make it have all the features you want. PHP is by
> it's very existence and ongoing development "up to date".
>
yet you seem to oppose said development into the threading/shared-mem corner.
without giving an alternative way to implement my previous case
description (facebook/twitter level commenting to graphics-heavy pages
at busy times).
and that's just 1 case description. hundreds if not thousands more can
be thought up or simply the best solution in the near future.
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 21:28:12 von Robert Cummings
Rene Veerman wrote:
> On Wed, Mar 24, 2010 at 10:21 PM, Robert Cummings wrote:
>>
>> Rene Veerman wrote:
>>> On Wed, Mar 24, 2010 at 9:45 PM, Robert Cummings
>>> wrote:
>>>> Rene Veerman wrote:
>>>>> On Wed, Mar 24, 2010 at 9:31 PM, Robert Cummings
>>>>> wrote:
>>>>>> Rene Veerman wrote:
>>>>>>> On Wed, Mar 24, 2010 at 3:25 PM, Robert Cummings
>>>>>>>
>>>>>>> wrote:
>>>>>>>> Rene Veerman wrote:
>>>>>>>>> php is not a hammer, its a programming language.
>>>>>>>> It's hard to discuss anything with someone who doesn't comprehend a
>>>>>>>> metaphor.
>>>>>>> haha. "comprehend". you mean "accept".
>>>>>>> that metaphor is stretched to breaking point as far as i'm concerned.
>>>>>>>
>>>>>>>>> one that i feel needs to stay ahead of the computing trend if it is
>>>>>>>>> to
>>>>>>>>> be considered a language for large scale applications.
>>>>>>>> Personification of PHP doesn't make your argument any more salient.
>>>>>>>> PHP
>>>>>>>> isn't trying to stay ahead of anything. People are using it to solve
>>>>>>>> problems, not to meet some phantom ideal of a "computing trend"
>>>>>>>> threshold.
>>>>>>>>
>>>>>>>>> but you nay-sayers here have convinced me; i'll be shopping for
>>>>>>>>> another language with which to serve my applications and the
>>>>>>>>> weboutput
>>>>>>>>> they produce..
>>>>>>>>>
>>>>>>>>> thanks for opening my eyes and telling to abandon ship in time.
>>>>>>>> Obviously we didn't open your eyes.
>>>>>>>>
>>>>>>> Well excuse me for not dumping 50-100k lines of my own cms code
>>>>>>> instantly now that i realize that in order to scale it, i could really
>>>>>>> use features like threading and shared memory.
>>>>>> Actually, you are th eone suggesting dumping your code since you said
>>>>>> you
>>>>>> were jumping ship. Many of us suggested that your problems can almost
>>>>>> certainly be mitigated without threading.
>>>>>>
>>>>> "almost certainly". at least you're acknowledging that you might be
>>>>> wrong.
>>>> I'm certianly not right all the time. once I thought I was but I was
>>>> wrong.
>>>>
>>>>> take this example, sorry for the crosspost;
>>>>>
>>>>> my main concern atm is my own cms (50-100k lines of my own); it's
>>>>> graphics-heavy, does fairly complicated db based logic, and if it ever
>>>>> is to be used for a site like facebook, it'll get large dataflows that
>>>>> have to be distributed over the servers used to generate html and
>>>>> accessoiries for end-users.
>>>>> i've built a layer into it that caches the output of oft-used pages
>>>>> (like articles and their comments).
>>>>> but adding many comments / minute to an article would result in quite
>>>>> a bit of overhead, to update the html for that page and distribute it
>>>>> (fast enough) to the relevant servers.
>>>>>
>>>>> i'm worried about php's single-threaded nature; each request has to
>>>>> fetch html updated in the last few seconds, or generate it from a list
>>>>> of comments. that's also a big query from a big table for every
>>>>> end-user.. :(
>>>>> i'd rather keep them comments for an article in shared memory.....
>>>> I think you'll find when you get even close to the size of facebook,
>>>> everything you think you know now about how it all stays running will be
>>>> thrown out the window. But then, I'm not a fan of early optimization of
>>>> this
>>>> magnitude. A good design is usually flexible enough to allow redesign
>>>> without recoding everything. Baby steps to the moon IMHO.
>>>>
>>> yea, well, if i'm going to keep using php i need a path towards
>>> scalability, for this particular problem.
>>>
>>> i'd like to code the kinds of applications with big dataflows.
>>> call me a golddigger all you want, it's what i am ;)
>>> just not in the sexual sense hehe..
>>>
>>>> Your tools are up to date. Threading is in the future if at all... it's
>>>> certainly not in the present.
>>> True, lets _keep_ 'm up-to-date, please.
>> It is up to date. You mean make it have all the features you want. PHP is by
>> it's very existence and ongoing development "up to date".
>>
>
> yet you seem to oppose said development into the threading/shared-mem corner.
>
> without giving an alternative way to implement my previous case
> description (facebook/twitter level commenting to graphics-heavy pages
> at busy times).
>
> and that's just 1 case description. hundreds if not thousands more can
> be thought up or simply the best solution in the near future.
I'm not sure why you think I'm opposed to such development. I've already
told you to subscribe to internals or write your own patch. Do you need
me to use a larger font?
Cheers,
Rob.
--
http://www.interjinn.com
Application and Templating Framework for PHP
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 21:34:13 von Rene Veerman
--001517476916a402d7048291db0f
Content-Type: text/plain; charset=ISO-8859-1
On Wed, Mar 24, 2010 at 10:19 PM, Ashley Sheridan
wrote:
> On Wed, 2010-03-24 at 22:15 +0200, Rene Veerman wrote:
>
> On Wed, Mar 24, 2010 at 10:05 PM, Ashley Sheridan
> wrote:
>
> >
> >
> > So you're basically saying that you'd discount anyone who opposes you
> > purely because you think you know best?
> >
> > Nice attitude.
> >
>
> I ain't saying that at all, nor did i intend to imply it.
>
> In fact it's the anti-threading/shared-mem camp that thinks they know
> everything best with their instistance that "throw more hardware at it, more
> sql servers, more programming languages in a single project" will solve all
> software design / growth problems with enough efficiency.
>
> They're offering the alternative. You keep disagreeing with their viewpoint
> because you seem to think you know best on this matter and won't even
> concede on a point.
>
they're offering an alternative that would not solve the use-case i could
think of within 1 day..
and they also say 'add more hardware' which means more overhead of every
kind, resulting in wasteful business practices.
> In this case, you still haven't given me any other reason to oppose the
> evolution of php with the market trend
>
> Do you have any proof of this 'market trend'? I suggested a vote, but you
> 'nay-sayed' it on the basis that you'd lose to people who couldn't possibly
> know as much as you do.
>
yes, twitter. facebook. the fact that a graphics upgrade would likely
increase business for the first ones on that popularity level to implement
it.
that's the proof i have for the market trend.
oh, and the fact "cloud computing" is becoming more and more of a buzzword
in the industry.
>
> I wouldn't say I belonged to any particular camp at the start of this
> thread, but now, having read what my betters have said, I'm inclined to
> agree that threading isn't the magic wand that you seem to think it is. I
> personally see one of the largest sites in the world running on PHP without
> needing threading and without insulting half the list to attempt to get it.
>
>
you haven't offered me any description at all of how i'd solve the
large-scale realtime-web-app with existing techniques.
and if i explain why i'd need the features we've discussed, you dismiss it
by accepting a generalized "that can be solved with more sql servers" answer
that is admitted to increase costs in every department, including energy
consumption. on a non-linear scale btw.
--001517476916a402d7048291db0f--
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 21:34:19 von Sancar Saran
On Wednesday 24 March 2010 21:42:53 Tommy Pham wrote:
> On Wed, Mar 24, 2010 at 10:18 AM, Sancar Saran
wrote:
> > On Wednesday 24 March 2010 03:17:56 Tommy Pham wrote:
> >> Let's go back to my 1st e-commerce example. The manufacturers list is
> >> about 3,700. The categories is about about 2,400. The products list
> >> is right now at 500,000 and expected to be around 750,000. The site
> >> is only in English. The store owner wants to expand and be I18n:
> >> Chinese, French, German, Korean, Spanish. You see how big and complex
> >> that database gets? The store owners want to have this happens when a
> >> customer clicks on a category:
> >>
> >> * show all subcategories for that category, if any
> >> * show all products for that category, if any,
> >> * show all manufacturers, used as filtering, for that category and
> >> subcategories * show price range filter for that category
> >> * show features & specifications filter for that category
> >> * show 10 top sellers for that category and related subcategories
> >> * the shopper can then select/deselect any of those filters and
> >> ability to sort by manufacturers, prices, user rating, popularity
> >> (purchased quantity)
> >> * have the ability to switch to another language translation on the fly
> >> * from the moment the shopper click on a link, the response time (when
> >> web browser saids "Done" in the status bar) is 5 seconds or less.
> >> Preferably 2-3 seconds. Will be using stopwatch for the timer.
> >>
> >> Now show me a website that meets those requirements and uses PHP, I'll
> >> be glad to support your argument about PHP w/o threads :) BTW, this
> >> is not even enterprise requirement. I may have another possible
> >> project where # products is over 10 million easily. With similar
> >> requirements when the user click on category. Do you think this site,
> >> which currently isn't, can run on PHP?
> >>
> >> Regards,
> >> Tommy
> >
> > If you design and code correctly. Yes.
> >
> >
> > If you want to use someting alredy. Try TYPO3.
> >
> > PS: Your arguments are something about implementation not something about
> > platform abilities. You can do this things any server side programming
> > with enough hardware.
> >
> > Regards
> >
> > Sancar
>
> Platform abilities = PHP with/without threads.
> Implementation = If PHP has threads, how do I implement it. If not,
> what work around / hacks do I need to do.
Please forgive my low ability on English and you sound like.
"I can drive a car, if it has a diesel engine and we want Ferrari for our
need. Is there any way to fit a diesel engine in Ferrari ?"
Your problem isn't php, You problem is your way to think...
You are trying to bend php to fit your way of the building web sites.
I'm sorry, things does not work like that.
You are trying to represent your business logic as "ENTERPRISE SOFTWARE
STANDARTS".
I'm sorry, it wont !
Even with provocative subject, it still business logic at large.
On Large Web sites, Site has own standards which enterprise must have to
obey.. (like Facebook or any other uber number cruncher you name it)
Anyway...
You want to build a damn huge web site with damn huge data set and damn huge
requests per second.
and you still want to use that SQL for primary data store for reading.
ARE YOU NUTS ???
With this kind of approach,
You will be in deep trouble with any language, with any Reational SQL Server.
If your customers need that kind of thing. You need lots of sophisticated
people which know how to handle big things under web enviroment.
Good luck to you.
Regards
Sancar
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 21:39:25 von Rene Veerman
On Wed, Mar 24, 2010 at 10:24 PM, Robert Cummings wrote:
> Are you suggesting that you need to be a guru in C to write threaded C code?
> I think the word you're looking for is competent.
plz dont make me repeat myself, i've already indicated my reasons as
to why i want to keep my codebase in 1 language, and why i would like
to keep my large existing code base in php, and have php evolve with
the times, and allow applications written in it to grow easily to
large scale use.
it would expand the user base of php as well i think.
> Are you suggesting cross platform thread libraries don't exist? I wonder how
> Apache does it... or MySQL... or any number of open source cross-platform
> systems. If they implement their own, then by the virtue of the source being
> open, you can feel free to incorporate.
adding all these things as custom extensions that are hard to maintain
and increase software complexity, is not what i want.
the reason i chose php is for it's simplicity of use.
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 21:42:17 von Rene Veerman
On Wed, Mar 24, 2010 at 10:34 PM, Sancar Saran wr=
ote:
> On Wednesday 24 March 2010 21:42:53 Tommy Pham wrote:
>> On Wed, Mar 24, 2010 at 10:18 AM, Sancar Saran
> wrote:
>> > On Wednesday 24 March 2010 03:17:56 Tommy Pham wrote:
>> >> Let's go back to my 1st e-commerce example. =A0The manufacturers list=
is
>> >> about 3,700. =A0The categories is about about 2,400. =A0The products =
list
>> >> is right now at 500,000 and expected to be around 750,000. =A0The sit=
e
>> >> is only in English. =A0The store owner wants to expand and be I18n:
>> >> Chinese, French, German, Korean, Spanish. =A0You see how big and comp=
lex
>> >> that database gets? =A0The store owners want to have this happens whe=
n a
>> >> customer clicks on a category:
>> >>
>> >> * show all subcategories for that category, if any
>> >> * show all products for that category, if any,
>> >> * show all manufacturers, used as filtering, for that category and
>> >> subcategories * show price range filter for that category
>> >> * show features & specifications filter for that category
>> >> * show 10 top sellers for that category and related subcategories
>> >> * the shopper can then select/deselect any of those filters and
>> >> ability to sort by manufacturers, prices, user rating, popularity
>> >> (purchased quantity)
>> >> * have the ability to switch to another language translation on the f=
ly
>> >> * from the moment the shopper click on a link, the response time (whe=
n
>> >> web browser saids "Done" in the status bar) is 5 seconds or less.
>> >> Preferably 2-3 seconds. Will be using stopwatch for the timer.
>> >>
>> >> Now show me a website that meets those requirements and uses PHP, I'l=
l
>> >> be glad to support your argument about PHP w/o threads :) =A0BTW, thi=
s
>> >> is not even enterprise requirement. =A0I may have another possible
>> >> project where # products is over 10 million easily. =A0With similar
>> >> requirements when the user click on category. =A0Do you think this si=
te,
>> >> which currently isn't, can run on PHP?
>> >>
>> >> Regards,
>> >> Tommy
>> >
>> > If you design and code correctly. Yes.
>> >
>> >
>> > If you want to use someting alredy. Try TYPO3.
>> >
>> > PS: Your arguments are something about implementation not something ab=
out
>> > platform abilities. You can do this things any server side programming
>> > with enough hardware.
>> >
>> > Regards
>> >
>> > Sancar
>>
>> Platform abilities =3D PHP with/without threads.
>> Implementation =3D If PHP has threads, how do I implement it. =A0If not,
>> what work around / hacks do I need to do.
>
>
> Please forgive my low ability on English and you sound like.
>
> "I can drive a car, if it has a diesel engine and we want Ferrari for our
> need. Is there any way to fit a diesel engine in Ferrari =A0?"
>
> Your problem isn't php, You problem is your way to think...
>
> You are trying to bend php to fit your way of the building web sites.
>
> I'm sorry, things does not work like that.
>
> You are trying to represent your business logic as "ENTERPRISE SOFTWARE
> STANDARTS".
>
> I'm sorry, it wont !
>
> Even with provocative subject, it still business logic at large.
>
> On Large Web sites, Site has own standards which enterprise must have to
> obey.. (like Facebook or any other uber number cruncher you name it)
>
> Anyway...
>
> You want to build a damn huge web site with damn huge data set and damn h=
uge
> requests per second.
>
> and =A0you still want to use that SQL for primary data store for reading.
>
> ARE YOU NUTS ???
>
> With this kind of approach,
>
> You will be in deep trouble with any language, with any Reational SQL Ser=
ver.
>
> If your customers need that kind of thing. You need lots of sophisticated
> people which know how to handle big things under web enviroment.
>
> Good luck to you.
>
> Regards
>
how dramatic.
how elitist.
and btw, use of sql where other solutions (like shared mem and
threading!) is exactly what i'm against.
if you ppl just stop barracading, you'll see that with relatively
minimal effort php can evolve with the times and make such things
possible for us mere mortals.
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 21:44:37 von Rene Veerman
Rene:
>and btw, use of sql where other solutions (like shared mem and threading!)=
is exactly what i'm against.
should read "where other solutions (...) are very likely to work
better / more efficiently"..
On Wed, Mar 24, 2010 at 10:42 PM, Rene Veerman wrote:
> On Wed, Mar 24, 2010 at 10:34 PM, Sancar Saran =
wrote:
>> On Wednesday 24 March 2010 21:42:53 Tommy Pham wrote:
>>> On Wed, Mar 24, 2010 at 10:18 AM, Sancar Saran
>
>> wrote:
>>> > On Wednesday 24 March 2010 03:17:56 Tommy Pham wrote:
>>> >> Let's go back to my 1st e-commerce example. =A0The manufacturers lis=
t is
>>> >> about 3,700. =A0The categories is about about 2,400. =A0The products=
list
>>> >> is right now at 500,000 and expected to be around 750,000. =A0The si=
te
>>> >> is only in English. =A0The store owner wants to expand and be I18n:
>>> >> Chinese, French, German, Korean, Spanish. =A0You see how big and com=
plex
>>> >> that database gets? =A0The store owners want to have this happens wh=
en a
>>> >> customer clicks on a category:
>>> >>
>>> >> * show all subcategories for that category, if any
>>> >> * show all products for that category, if any,
>>> >> * show all manufacturers, used as filtering, for that category and
>>> >> subcategories * show price range filter for that category
>>> >> * show features & specifications filter for that category
>>> >> * show 10 top sellers for that category and related subcategories
>>> >> * the shopper can then select/deselect any of those filters and
>>> >> ability to sort by manufacturers, prices, user rating, popularity
>>> >> (purchased quantity)
>>> >> * have the ability to switch to another language translation on the =
fly
>>> >> * from the moment the shopper click on a link, the response time (wh=
en
>>> >> web browser saids "Done" in the status bar) is 5 seconds or less.
>>> >> Preferably 2-3 seconds. Will be using stopwatch for the timer.
>>> >>
>>> >> Now show me a website that meets those requirements and uses PHP, I'=
ll
>>> >> be glad to support your argument about PHP w/o threads :) =A0BTW, th=
is
>>> >> is not even enterprise requirement. =A0I may have another possible
>>> >> project where # products is over 10 million easily. =A0With similar
>>> >> requirements when the user click on category. =A0Do you think this s=
ite,
>>> >> which currently isn't, can run on PHP?
>>> >>
>>> >> Regards,
>>> >> Tommy
>>> >
>>> > If you design and code correctly. Yes.
>>> >
>>> >
>>> > If you want to use someting alredy. Try TYPO3.
>>> >
>>> > PS: Your arguments are something about implementation not something a=
bout
>>> > platform abilities. You can do this things any server side programmin=
g
>>> > with enough hardware.
>>> >
>>> > Regards
>>> >
>>> > Sancar
>>>
>>> Platform abilities =3D PHP with/without threads.
>>> Implementation =3D If PHP has threads, how do I implement it. =A0If not=
,
>>> what work around / hacks do I need to do.
>>
>>
>> Please forgive my low ability on English and you sound like.
>>
>> "I can drive a car, if it has a diesel engine and we want Ferrari for ou=
r
>> need. Is there any way to fit a diesel engine in Ferrari =A0?"
>>
>> Your problem isn't php, You problem is your way to think...
>>
>> You are trying to bend php to fit your way of the building web sites.
>>
>> I'm sorry, things does not work like that.
>>
>> You are trying to represent your business logic as "ENTERPRISE SOFTWARE
>> STANDARTS".
>>
>> I'm sorry, it wont !
>>
>> Even with provocative subject, it still business logic at large.
>>
>> On Large Web sites, Site has own standards which enterprise must have to
>> obey.. (like Facebook or any other uber number cruncher you name it)
>>
>> Anyway...
>>
>> You want to build a damn huge web site with damn huge data set and damn =
huge
>> requests per second.
>>
>> and =A0you still want to use that SQL for primary data store for reading=
..
>>
>> ARE YOU NUTS ???
>>
>> With this kind of approach,
>>
>> You will be in deep trouble with any language, with any Reational SQL Se=
rver.
>>
>> If your customers need that kind of thing. You need lots of sophisticate=
d
>> people which know how to handle big things under web enviroment.
>>
>> Good luck to you.
>>
>> Regards
>>
>
> how dramatic.
> how elitist.
>
> and btw, use of sql where other solutions (like shared mem and
> threading!) is exactly what i'm against.
>
> if you ppl just stop barracading, you'll see that with relatively
> minimal effort php can evolve with the times and make such things
> possible for us mere mortals.
>
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 21:58:03 von Robert Cummings
Rene Veerman wrote:
> On Wed, Mar 24, 2010 at 10:24 PM, Robert Cummings wrote:
>
>> Are you suggesting that you need to be a guru in C to write threaded C code?
>> I think the word you're looking for is competent.
>
> plz dont make me repeat myself, i've already indicated my reasons as
> to why i want to keep my codebase in 1 language,
The above comment did not address your codebase and 1 language issue. It
addressed the assertion that you need a C guru to write threaded C code.
> and why i would like
> to keep my large existing code base in php, and have php evolve with
> the times, and allow applications written in it to grow easily to
> large scale use.
>
> it would expand the user base of php as well i think.
I think I'm going to win the lottery some day... I think.
>> Are you suggesting cross platform thread libraries don't exist? I wonder how
>> Apache does it... or MySQL... or any number of open source cross-platform
>> systems. If they implement their own, then by the virtue of the source being
>> open, you can feel free to incorporate.
>
> adding all these things as custom extensions that are hard to maintain
> and increase software complexity, is not what i want.
>
> the reason i chose php is for it's simplicity of use.
Perhaps you should have chosen based on the functionality YOU want. PHP
remains simple for a reason.
I think this will be me last comment to you. Your responses don't stay
on track, they keep leading back to your constant "I want, I want, I
want" screams. Let's list a few:
I want to use PHP.
I want threading in PHP.
I want someone else to do it.
I want to not have to change my designs.
I want everyone to stop having their own opinion.
I want to have my cake and eat it too.
Ummm... so yeah... I can see why the discussion is mostly degenerative.
Have you even subscribed to the internals list yet?
Cheers,
Rob.
--
http://www.interjinn.com
Application and Templating Framework for PHP
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 21:58:26 von Sancar Saran
On Wednesday 24 March 2010 22:42:17 Rene Veerman wrote:
> On Wed, Mar 24, 2010 at 10:34 PM, Sancar Saran
wrote:
> > On Wednesday 24 March 2010 21:42:53 Tommy Pham wrote:
> >> On Wed, Mar 24, 2010 at 10:18 AM, Sancar Saran
> >
> > wrote:
> >> > On Wednesday 24 March 2010 03:17:56 Tommy Pham wrote:
> >> >> Let's go back to my 1st e-commerce example. The manufacturers list
> >> >> is about 3,700. The categories is about about 2,400. The products
> >> >> list is right now at 500,000 and expected to be around 750,000. The
> >> >> site is only in English. The store owner wants to expand and be
> >> >> I18n: Chinese, French, German, Korean, Spanish. You see how big and
> >> >> complex that database gets? The store owners want to have this
> >> >> happens when a customer clicks on a category:
> >> >>
> >> >> * show all subcategories for that category, if any
> >> >> * show all products for that category, if any,
> >> >> * show all manufacturers, used as filtering, for that category and
> >> >> subcategories * show price range filter for that category
> >> >> * show features & specifications filter for that category
> >> >> * show 10 top sellers for that category and related subcategories
> >> >> * the shopper can then select/deselect any of those filters and
> >> >> ability to sort by manufacturers, prices, user rating, popularity
> >> >> (purchased quantity)
> >> >> * have the ability to switch to another language translation on the
> >> >> fly * from the moment the shopper click on a link, the response time
> >> >> (when web browser saids "Done" in the status bar) is 5 seconds or
> >> >> less. Preferably 2-3 seconds. Will be using stopwatch for the timer.
> >> >>
> >> >> Now show me a website that meets those requirements and uses PHP,
> >> >> I'll be glad to support your argument about PHP w/o threads :) BTW,
> >> >> this is not even enterprise requirement. I may have another
> >> >> possible project where # products is over 10 million easily. With
> >> >> similar requirements when the user click on category. Do you think
> >> >> this site, which currently isn't, can run on PHP?
> >> >>
> >> >> Regards,
> >> >> Tommy
> >> >
> >> > If you design and code correctly. Yes.
> >> >
> >> >
> >> > If you want to use someting alredy. Try TYPO3.
> >> >
> >> > PS: Your arguments are something about implementation not something
> >> > about platform abilities. You can do this things any server side
> >> > programming with enough hardware.
> >> >
> >> > Regards
> >> >
> >> > Sancar
> >>
> >> Platform abilities = PHP with/without threads.
> >> Implementation = If PHP has threads, how do I implement it. If not,
> >> what work around / hacks do I need to do.
> >
> > Please forgive my low ability on English and you sound like.
> >
> > "I can drive a car, if it has a diesel engine and we want Ferrari for our
> > need. Is there any way to fit a diesel engine in Ferrari ?"
> >
> > Your problem isn't php, You problem is your way to think...
> >
> > You are trying to bend php to fit your way of the building web sites.
> >
> > I'm sorry, things does not work like that.
> >
> > You are trying to represent your business logic as "ENTERPRISE SOFTWARE
> > STANDARTS".
> >
> > I'm sorry, it wont !
> >
> > Even with provocative subject, it still business logic at large.
> >
> > On Large Web sites, Site has own standards which enterprise must have to
> > obey.. (like Facebook or any other uber number cruncher you name it)
> >
> > Anyway...
> >
> > You want to build a damn huge web site with damn huge data set and damn
> > huge requests per second.
> >
> > and you still want to use that SQL for primary data store for reading.
> >
> > ARE YOU NUTS ???
> >
> > With this kind of approach,
> >
> > You will be in deep trouble with any language, with any Reational SQL
> > Server.
> >
> > If your customers need that kind of thing. You need lots of sophisticated
> > people which know how to handle big things under web enviroment.
> >
> > Good luck to you.
> >
> > Regards
>
> how dramatic.
> how elitist.
>
> and btw, use of sql where other solutions (like shared mem and
> threading!) is exactly what i'm against.
>
> if you ppl just stop barracading, you'll see that with relatively
> minimal effort php can evolve with the times and make such things
> possible for us mere mortals.
Alright. Lets think different.
And please don't take things personal...
If the only problem is threading...
Will Python with mod wsgi solve the problem ? with this programming approach ?
Regards
Sancar...
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 22:23:38 von Stut
On 24 Mar 2010, at 19:35, Rene Veerman wrote:
>=20
> take this example, sorry for the crosspost;
>=20
> my main concern atm is my own cms (50-100k lines of my own); it's
> graphics-heavy, does fairly complicated db based logic, and if it ever
> is to be used for a site like facebook, it'll get large dataflows that
> have to be distributed over the servers used to generate html and
> accessoiries for end-users.
> i've built a layer into it that caches the output of oft-used pages
> (like articles and their comments).
> but adding many comments / minute to an article would result in quite
> a bit of overhead, to update the html for that page and distribute it
> (fast enough) to the relevant servers.
>=20
> i'm worried about php's single-threaded nature; each request has to
> fetch html updated in the last few seconds, or generate it from a list
> of comments. that's also a big query from a big table for every
> end-user.. :(
> i'd rather keep them comments for an article in shared memory.....
Shared memory in PHP generally means memcached. Look it up - it does =
exactly what you need here, and with the right usage strategy it's more =
than capable of handling data that changes many times a second.
I think I'll need to spell this out, and I really hope you'll read this =
one properly. Use memcached to store data in the format in which you =
need to access it, update it when something changes not when requested =
and use the DB as permanent storage only. I've written highly scalable =
systems using this strategy, and the possibility that threading could =
improve the performance of said systems has never spent longer than a =
few seconds crossing my mind.
And, if you don't mind me asking, when you say graphics-heavy do you =
mean it uses a lot of images? And if so, how the hell does that affect =
the scalability of PHP?
-Stuart
--=20
http://stut.net/=
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 22:31:06 von Stut
On 24 Mar 2010, at 19:42, Tommy Pham wrote:
> On Wed, Mar 24, 2010 at 10:18 AM, Sancar Saran =
wrote:
>> On Wednesday 24 March 2010 03:17:56 Tommy Pham wrote:
>>> Let's go back to my 1st e-commerce example. The manufacturers list =
is
>>> about 3,700. The categories is about about 2,400. The products =
list
>>> is right now at 500,000 and expected to be around 750,000. The site
>>> is only in English. The store owner wants to expand and be I18n:
>>> Chinese, French, German, Korean, Spanish. You see how big and =
complex
>>> that database gets? The store owners want to have this happens when =
a
>>> customer clicks on a category:
>>>=20
>>> * show all subcategories for that category, if any
Cache it in something like memcached - I doubt these change very often.
>>> * show all products for that category, if any,
Cache it in something like memcached, and update that cache when =
products change.
>>> * show all manufacturers, used as filtering, for that category and
>>> subcategories
Cache it.
>>> * show price range filter for that category
No need to cache this.
>>> * show features & specifications filter for that category
Cache it.
>>> * show 10 top sellers for that category and related subcategories
Generate offline and cache it.
>>> * the shopper can then select/deselect any of those filters and
>>> ability to sort by manufacturers, prices, user rating, popularity
>>> (purchased quantity)
Use something like Sphinx to handle searching the data. It's far quicker =
for doing filtering like this than SQL.
>>> * have the ability to switch to another language translation on the =
fly
Doing this would simply change a prefix to the cache keys.
>>> * from the moment the shopper click on a link, the response time =
(when
>>> web browser saids "Done" in the status bar) is 5 seconds or less.
>>> Preferably 2-3 seconds. Will be using stopwatch for the timer.
I run a site that does very similar operations to this and response =
times average around 0.1s with the cache on, and 3-5ss with it off.
Oh, and using a stopwatch doesn't take into account network latency or =
external dependencies. If you want an accurate timings you need to add =
that functionality into the code.
>>> Now show me a website that meets those requirements and uses PHP, =
I'll
>>> be glad to support your argument about PHP w/o threads :) BTW, this
>>> is not even enterprise requirement. I may have another possible
>>> project where # products is over 10 million easily. With similar
>>> requirements when the user click on category. Do you think this =
site,
>>> which currently isn't, can run on PHP?
You want an example? Facebook!
-Stuart
--=20
http://stut.net/
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 22:42:04 von Stut
On 24 Mar 2010, at 20:34, Rene Veerman wrote:
>=20
> On Wed, Mar 24, 2010 at 10:19 PM, Ashley Sheridan =
wrote:
> On Wed, 2010-03-24 at 22:15 +0200, Rene Veerman wrote:
> Do you have any proof of this 'market trend'? I suggested a vote, but =
you 'nay-sayed' it on the basis that you'd lose to people who couldn't =
possibly know as much as you do.
> =20
> =20
> yes, twitter. facebook. the fact that a graphics upgrade would likely =
increase business for the first ones on that popularity level to =
implement it.
> that's the proof i have for the market trend.
Again, improving the graphical content of a website has absolutely no =
effect on the performance of PHP. The additional time the page takes to =
load is all about network latency and how well you've arranged your =
static file serving.
> oh, and the fact "cloud computing" is becoming more and more of a =
buzzword in the industry.
Cloud computing really doesn't mean what you think it means.
>> I wouldn't say I belonged to any particular camp at the start of this =
thread, but now, having read what my betters have said, I'm inclined to =
agree that threading isn't the magic wand that you seem to think it is. =
I personally see one of the largest sites in the world running on PHP =
without needing threading and without insulting half the list to attempt =
to get it.
> =20
> you haven't offered me any description at all of how i'd solve the =
large-scale realtime-web-app with existing techniques.
By "realtime-web-app" you mean something like Facebook? They use a =
combination of PHP, Memcached (and lots of it), MySQL and lots of other =
layers in-between to do what they do, and threaded PHP is not one of =
them.
> and if i explain why i'd need the features we've discussed, you =
dismiss it by accepting a generalized "that can be solved with more sql =
servers" answer that is admitted to increase costs in every department, =
including energy consumption. on a non-linear scale btw.
What I'm getting here is that you want everything without paying for it. =
When it comes to scalability it's cheaper to achieve it by adding =
servers than it is to squeeze every last drop of performance out of a =
single box. The cost in development time alone to implement effective =
threading strategies would far outstrip the cost of adding a couple of =
servers and ensuring that your app is scalable.
What you seem to be ignoring is the fact that these issues have been =
solved already, and the techniques that exist are more than adequate to =
build systems that scale as well as Facebook. What will it take to get =
you to accept that the way you want to skin the cat is exceedingly =
messy?
-Stuart
--=20
http://stut.net/
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 22:46:50 von Stut
On 24 Mar 2010, at 20:42, Rene Veerman wrote:
>=20
> if you ppl just stop barracading, you'll see that with relatively
> minimal effort php can evolve with the times and make such things
> possible for us mere mortals.
Minimal effort? You clearly have no understanding of what would be =
involved to get threading into the PHP core. It's not a minimal amount =
of effort, it means severe upheaval, not only for the core itself but =
also for every extension in existence, and potentially a fair amount of =
userland code that's out there.
Oh, and I absolutely love the fact you think it's we who are =
barricading. Love it!
-Stuart
--=20
http://stut.net/
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 23:29:22 von Tommy Pham
On Wed, Mar 24, 2010 at 1:24 PM, Robert Cummings wro=
te:
>
>
> Tommy Pham wrote:
>>
>> On Wed, Mar 24, 2010 at 4:28 AM, Per Jessen wrote:
>>>
>>> Tommy Pham wrote:
>>>
>>>> On Wed, Mar 24, 2010 at 3:44 AM, Per Jessen wrote:
>>>>>
>>>>> Tommy Pham wrote:
>>>>>
>>>>>> On Wed, Mar 24, 2010 at 3:20 AM, Per Jessen
>>>>>> wrote:
>>>>>>>
>>>>>>> Tommy Pham wrote:
>>>>>>>
>>>>>>>> What I find funny is that one of opponents of PHP threads earlier
>>>>>>>> mentioned that how silly it would be to be using C in a web app.
>>>>>>>> Now I hear people mentioning C when they need "productivity" or
>>>>>>>> "speed"...
>>>>>>>>
>>>>>>> I think I was the one to mention the latter, but as I started out
>>>>>>> saying, and as others have said too, it's about the right tool for
>>>>>>> the right job. Â When choosing a tool, there are a number of fa=
ctors
>>>>>>> to consider - developer productivity, available skills, future
>>>>>>> maintenance, performance, scalability, portability, parallelism,
>>>>>>> performance etcetera.
>>>>>>>
>>>>>> Funny you should mention all that. Â Let's say that you're longe=
r
>>>>>> with that company, either by direct employment or contract
>>>>>> consultant. You've implemented C because you need 'thread'. Â No=
w
>>>>>> your replacement comes in and has no clue about C even though your
>>>>>> replacement is a PHP guru. Â How much headache is maintenance go=
nna
>>>>>> be? Â Scalability? Portability? wow....
>>>>>
>>>>> Who was the idi... who hired someone who wasn't suited for the job?
>>>>> Tommy, that's a moot argument. Â You can't fit a square peg in a =
round
>>>>> hole.
>>>>>
>>>>> --
>>>>> Per Jessen, Zürich (12.5°C)
>>>>>
>>>> Suited for the job? Â You mean introduce more complexity to a prob=
lem
>>>> that what could be avoided to begin with if PHP has thread support?
>>>> hmmm....
>>>
>>> Tommy, it's perfectly simple: Â in my company we hire people with C
>>> skills for C programming jobs. We hire people with database skills to
>>> be database administrators. Â We hire people with Linux skills to w=
ork
>>> on Linux systems. Â We explicitly do _not_ hire PHP web-programmers=
to
>>> maintain our C code. Â And vice versa for that matter. Â No pro=
blem, no
>>> complexity.
>>>
>>>
>>> --
>>> Per Jessen, Zürich (13.4°C)
>>>
>>>
>>
>> That may just work out fine if you work directly for the company with
>> all the proper staffing. Â But some of us work as consultants or for
>> companies without the proper staffing. Â As such, let's dissect what
>> you mentioned:
>>
>> 1) PHP with internal thread support
>> 2) PHP with external C/C++ thread support
>>
>> * Performance - having external thread support, now you have to call
>> an extension (more memory usage and CPU cycles). Â If you happen to
>> have a C/C++ guru who can then code that thread support into PHP
>> extension, wouldn't it still perform better at the core vs as an
>> extension because it's not talking to a 'middle man'? Â Having said
>> that, not everyone has access to a C/C++ guru. Â Thus not mass
>> availability.
>
> Are you suggesting that you need to be a guru in C to write threaded C co=
de?
> I think the word you're looking for is competent.
>
>> * Portability - if you're currently running PHP on Windows, but manage
>> to convince management to switch to *BSD/Linux, then you'd have to
>> rewrite that external thread support. Â But for us consultants, we m=
ay
>> have 1 project the runs on Windows, the next may be *BSD/Linux. Â PH=
P
>> code snippets goes a lot further versus your custom work around.
>> * Managability - should your need to upgrade PHP for either bug fix,
>> new features you'd want to implement to add more functionality to your
>> site, will that then break your custom external solution? Â How much
>> more manageable is it if it's done under 1 language versus 2+?
>
> Are you suggesting cross platform thread libraries don't exist? I wonder =
how
> Apache does it... or MySQL... or any number of open source cross-platform
> systems. If they implement their own, then by the virtue of the source be=
ing
> open, you can feel free to incorporate.
>
> Cheers,
> Rob.
> --
> http://www.interjinn.com
> Application and Templating Framework for PHP
>
Suppose I have an idea and make it a project. I'd then want to make
it open source and offer it to the world. With your custom thread
solution, how much acceptance is it going to be for a decent PHP
programmer to implement versus something that's already in pure PHP.
Unzip/rar/tar > minor config for DB > Live. How does that sound for
portability? Now that you mention cross platform threading, do you
think you can take the MySQL compiled for linux and make it work under
BSD withouth BSD's linux binaries compatibility, nevermind Windows?
Have you looked at the source of PHP? For whatever OS PHP compiles
for, it uses the header library pertaining to that OS. So if I want
to implement thread solution similar to Per's solution, I'd have to be
an expert at Windows, Linux, and *BSD just to make my PHP open source
project to be readily acceptable to the world. I'll pass on that.
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 23:34:04 von Robert Cummings
Tommy Pham wrote:
> On Wed, Mar 24, 2010 at 1:24 PM, Robert Cummings wrote:
>>
>> Tommy Pham wrote:
>>> On Wed, Mar 24, 2010 at 4:28 AM, Per Jessen wrote:
>>>> Tommy Pham wrote:
>>>>
>>>>> On Wed, Mar 24, 2010 at 3:44 AM, Per Jessen wrote:
>>>>>> Tommy Pham wrote:
>>>>>>
>>>>>>> On Wed, Mar 24, 2010 at 3:20 AM, Per Jessen
>>>>>>> wrote:
>>>>>>>> Tommy Pham wrote:
>>>>>>>>
>>>>>>>>> What I find funny is that one of opponents of PHP threads earlier
>>>>>>>>> mentioned that how silly it would be to be using C in a web app.
>>>>>>>>> Now I hear people mentioning C when they need "productivity" or
>>>>>>>>> "speed"...
>>>>>>>>>
>>>>>>>> I think I was the one to mention the latter, but as I started out
>>>>>>>> saying, and as others have said too, it's about the right tool for
>>>>>>>> the right job. When choosing a tool, there are a number of factors
>>>>>>>> to consider - developer productivity, available skills, future
>>>>>>>> maintenance, performance, scalability, portability, parallelism,
>>>>>>>> performance etcetera.
>>>>>>>>
>>>>>>> Funny you should mention all that. Let's say that you're longer
>>>>>>> with that company, either by direct employment or contract
>>>>>>> consultant. You've implemented C because you need 'thread'. Now
>>>>>>> your replacement comes in and has no clue about C even though your
>>>>>>> replacement is a PHP guru. How much headache is maintenance gonna
>>>>>>> be? Scalability? Portability? wow....
>>>>>> Who was the idi... who hired someone who wasn't suited for the job?
>>>>>> Tommy, that's a moot argument. You can't fit a square peg in a round
>>>>>> hole.
>>>>>>
>>>>>> --
>>>>>> Per Jessen, Zürich (12.5°C)
>>>>>>
>>>>> Suited for the job? You mean introduce more complexity to a problem
>>>>> that what could be avoided to begin with if PHP has thread support?
>>>>> hmmm....
>>>> Tommy, it's perfectly simple: in my company we hire people with C
>>>> skills for C programming jobs. We hire people with database skills to
>>>> be database administrators. We hire people with Linux skills to work
>>>> on Linux systems. We explicitly do _not_ hire PHP web-programmers to
>>>> maintain our C code. And vice versa for that matter. No problem, no
>>>> complexity.
>>>>
>>>>
>>>> --
>>>> Per Jessen, Zürich (13.4°C)
>>>>
>>>>
>>> That may just work out fine if you work directly for the company with
>>> all the proper staffing. But some of us work as consultants or for
>>> companies without the proper staffing. As such, let's dissect what
>>> you mentioned:
>>>
>>> 1) PHP with internal thread support
>>> 2) PHP with external C/C++ thread support
>>>
>>> * Performance - having external thread support, now you have to call
>>> an extension (more memory usage and CPU cycles). If you happen to
>>> have a C/C++ guru who can then code that thread support into PHP
>>> extension, wouldn't it still perform better at the core vs as an
>>> extension because it's not talking to a 'middle man'? Having said
>>> that, not everyone has access to a C/C++ guru. Thus not mass
>>> availability.
>> Are you suggesting that you need to be a guru in C to write threaded C code?
>> I think the word you're looking for is competent.
>>
>>> * Portability - if you're currently running PHP on Windows, but manage
>>> to convince management to switch to *BSD/Linux, then you'd have to
>>> rewrite that external thread support. But for us consultants, we may
>>> have 1 project the runs on Windows, the next may be *BSD/Linux. PHP
>>> code snippets goes a lot further versus your custom work around.
>>> * Managability - should your need to upgrade PHP for either bug fix,
>>> new features you'd want to implement to add more functionality to your
>>> site, will that then break your custom external solution? How much
>>> more manageable is it if it's done under 1 language versus 2+?
>> Are you suggesting cross platform thread libraries don't exist? I wonder how
>> Apache does it... or MySQL... or any number of open source cross-platform
>> systems. If they implement their own, then by the virtue of the source being
>> open, you can feel free to incorporate.
>>
>> Cheers,
>> Rob.
>> --
>> http://www.interjinn.com
>> Application and Templating Framework for PHP
>>
>
> Suppose I have an idea and make it a project. I'd then want to make
> it open source and offer it to the world. With your custom thread
> solution, how much acceptance is it going to be for a decent PHP
> programmer to implement versus something that's already in pure PHP.
> Unzip/rar/tar > minor config for DB > Live. How does that sound for
> portability? Now that you mention cross platform threading, do you
> think you can take the MySQL compiled for linux and make it work under
> BSD withouth BSD's linux binaries compatibility, nevermind Windows?
> Have you looked at the source of PHP? For whatever OS PHP compiles
> for, it uses the header library pertaining to that OS. So if I want
> to implement thread solution similar to Per's solution, I'd have to be
> an expert at Windows, Linux, and *BSD just to make my PHP open source
> project to be readily acceptable to the world. I'll pass on that.
Many open source projects are itches being scratched. More often than
not you will not be alone in your desire to scratch. When that happens,
and if you're a good sort of chap or gal, then others will come along
and help you scratch. Soon, with the right kind of leadership and
gameplan, you'll be fully embroiled in a scratching orgy with key
members scratching the right part of the itch. Do you think one person
writes all the compatibility stuff for any of the above listed systems?
No, there's just a lot of scratching happening.
Cheers,
Rob.
--
http://www.interjinn.com
Application and Templating Framework for PHP
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 23:49:40 von Tommy Pham
On Wed, Mar 24, 2010 at 3:34 PM, Robert Cummings wro=
te:
> Tommy Pham wrote:
>>
>> On Wed, Mar 24, 2010 at 1:24 PM, Robert Cummings
>> wrote:
>>>
>>> Tommy Pham wrote:
>>>>
>>>> On Wed, Mar 24, 2010 at 4:28 AM, Per Jessen wrote:
>>>>>
>>>>> Tommy Pham wrote:
>>>>>
>>>>>> On Wed, Mar 24, 2010 at 3:44 AM, Per Jessen wrote=
:
>>>>>>>
>>>>>>> Tommy Pham wrote:
>>>>>>>
>>>>>>>> On Wed, Mar 24, 2010 at 3:20 AM, Per Jessen
>>>>>>>> wrote:
>>>>>>>>>
>>>>>>>>> Tommy Pham wrote:
>>>>>>>>>
>>>>>>>>>> What I find funny is that one of opponents of PHP threads earlie=
r
>>>>>>>>>> mentioned that how silly it would be to be using C in a web app.
>>>>>>>>>> Now I hear people mentioning C when they need "productivity" or
>>>>>>>>>> "speed"...
>>>>>>>>>>
>>>>>>>>> I think I was the one to mention the latter, but as I started out
>>>>>>>>> saying, and as others have said too, it's about the right tool fo=
r
>>>>>>>>> the right job. Â When choosing a tool, there are a number of =
factors
>>>>>>>>> to consider - developer productivity, available skills, future
>>>>>>>>> maintenance, performance, scalability, portability, parallelism,
>>>>>>>>> performance etcetera.
>>>>>>>>>
>>>>>>>> Funny you should mention all that. Â Let's say that you're lon=
ger
>>>>>>>> with that company, either by direct employment or contract
>>>>>>>> consultant. You've implemented C because you need 'thread'. Â =
Now
>>>>>>>> your replacement comes in and has no clue about C even though your
>>>>>>>> replacement is a PHP guru. Â How much headache is maintenance =
gonna
>>>>>>>> be? Â Scalability? Portability? wow....
>>>>>>>
>>>>>>> Who was the idi... who hired someone who wasn't suited for the job?
>>>>>>> Tommy, that's a moot argument. Â You can't fit a square peg in =
a round
>>>>>>> hole.
>>>>>>>
>>>>>>> --
>>>>>>> Per Jessen, Zürich (12.5°C)
>>>>>>>
>>>>>> Suited for the job? Â You mean introduce more complexity to a pr=
oblem
>>>>>> that what could be avoided to begin with if PHP has thread support?
>>>>>> hmmm....
>>>>>
>>>>> Tommy, it's perfectly simple: Â in my company we hire people with=
C
>>>>> skills for C programming jobs. We hire people with database skills to
>>>>> be database administrators. Â We hire people with Linux skills to=
work
>>>>> on Linux systems. Â We explicitly do _not_ hire PHP web-programme=
rs to
>>>>> maintain our C code. Â And vice versa for that matter. Â No p=
roblem, no
>>>>> complexity.
>>>>>
>>>>>
>>>>> --
>>>>> Per Jessen, Zürich (13.4°C)
>>>>>
>>>>>
>>>> That may just work out fine if you work directly for the company with
>>>> all the proper staffing. Â But some of us work as consultants or f=
or
>>>> companies without the proper staffing. Â As such, let's dissect wh=
at
>>>> you mentioned:
>>>>
>>>> 1) PHP with internal thread support
>>>> 2) PHP with external C/C++ thread support
>>>>
>>>> * Performance - having external thread support, now you have to call
>>>> an extension (more memory usage and CPU cycles). Â If you happen t=
o
>>>> have a C/C++ guru who can then code that thread support into PHP
>>>> extension, wouldn't it still perform better at the core vs as an
>>>> extension because it's not talking to a 'middle man'? Â Having sai=
d
>>>> that, not everyone has access to a C/C++ guru. Â Thus not mass
>>>> availability.
>>>
>>> Are you suggesting that you need to be a guru in C to write threaded C
>>> code?
>>> I think the word you're looking for is competent.
>>>
>>>> * Portability - if you're currently running PHP on Windows, but manage
>>>> to convince management to switch to *BSD/Linux, then you'd have to
>>>> rewrite that external thread support. Â But for us consultants, we=
may
>>>> have 1 project the runs on Windows, the next may be *BSD/Linux. Â =
PHP
>>>> code snippets goes a lot further versus your custom work around.
>>>> * Managability - should your need to upgrade PHP for either bug fix,
>>>> new features you'd want to implement to add more functionality to your
>>>> site, will that then break your custom external solution? Â How mu=
ch
>>>> more manageable is it if it's done under 1 language versus 2+?
>>>
>>> Are you suggesting cross platform thread libraries don't exist? I wonde=
r
>>> how
>>> Apache does it... or MySQL... or any number of open source cross-platfo=
rm
>>> systems. If they implement their own, then by the virtue of the source
>>> being
>>> open, you can feel free to incorporate.
>>>
>>> Cheers,
>>> Rob.
>>> --
>>> http://www.interjinn.com
>>> Application and Templating Framework for PHP
>>>
>>
>> Suppose I have an idea and make it a project. Â I'd then want to mak=
e
>> it open source and offer it to the world. Â With your custom thread
>> solution, how much acceptance is it going to be for a decent PHP
>> programmer to implement versus something that's already in pure PHP.
>> Unzip/rar/tar > minor config for DB > Live. Â How does that sound fo=
r
>> portability? Â Now that you mention cross platform threading, do you
>> think you can take the MySQL compiled for linux and make it work under
>> BSD withouth BSD's linux binaries compatibility, nevermind Windows?
>> Have you looked at the source of PHP? For whatever OS PHP compiles
>> for, it uses the header library pertaining to that OS. Â So if I wan=
t
>> to implement thread solution similar to Per's solution, I'd have to be
>> an expert at Windows, Linux, and *BSD just to make my PHP open source
>> project to be readily acceptable to the world. Â I'll pass on that.
>
> Many open source projects are itches being scratched. More often than not
> you will not be alone in your desire to scratch. When that happens, and i=
f
> you're a good sort of chap or gal, then others will come along and help y=
ou
> scratch. Soon, with the right kind of leadership and gameplan, you'll be
> fully embroiled in a scratching orgy with key members scratching the righ=
t
> part of the itch. Do you think one person writes all the compatibility st=
uff
> for any of the above listed systems? No, there's just a lot of scratching
> happening.
>
> Cheers,
> Rob.
> --
> http://www.interjinn.com
> Application and Templating Framework for PHP
>
Then the process at which to implement requested features becomes a
crawl because now the project needs to consider the fact how some of
the requested features will it be affected on Windows, Linux, *BSD
versus on just how to realize (PHP coding) those features. I don't
use Linux nor an expert in it but implementing custom thread solution
like that means understanding about SELinux vs AppArmor vs Grsecurity
or am I wrong? Look at your project(s) now, if you take your PHP code
and deploy to other platforms that you're currently not using, how
portable is that? If a particular project happens to depends on
platform/OS specifics, what then?
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 24.03.2010 23:53:49 von Tommy Pham
On Wed, Mar 24, 2010 at 3:49 PM, Tommy Pham wrote:
> On Wed, Mar 24, 2010 at 3:34 PM, Robert Cummings w=
rote:
>> Tommy Pham wrote:
>>>
>>> On Wed, Mar 24, 2010 at 1:24 PM, Robert Cummings
>>> wrote:
>>>>
>>>> Tommy Pham wrote:
>>>>>
>>>>> On Wed, Mar 24, 2010 at 4:28 AM, Per Jessen wrote:
>>>>>>
>>>>>> Tommy Pham wrote:
>>>>>>
>>>>>>> On Wed, Mar 24, 2010 at 3:44 AM, Per Jessen wrot=
e:
>>>>>>>>
>>>>>>>> Tommy Pham wrote:
>>>>>>>>
>>>>>>>>> On Wed, Mar 24, 2010 at 3:20 AM, Per Jessen
>>>>>>>>> wrote:
>>>>>>>>>>
>>>>>>>>>> Tommy Pham wrote:
>>>>>>>>>>
>>>>>>>>>>> What I find funny is that one of opponents of PHP threads earli=
er
>>>>>>>>>>> mentioned that how silly it would be to be using C in a web app=
..
>>>>>>>>>>> Now I hear people mentioning C when they need "productivity" or
>>>>>>>>>>> "speed"...
>>>>>>>>>>>
>>>>>>>>>> I think I was the one to mention the latter, but as I started ou=
t
>>>>>>>>>> saying, and as others have said too, it's about the right tool f=
or
>>>>>>>>>> the right job. Â When choosing a tool, there are a number of=
factors
>>>>>>>>>> to consider - developer productivity, available skills, future
>>>>>>>>>> maintenance, performance, scalability, portability, parallelism,
>>>>>>>>>> performance etcetera.
>>>>>>>>>>
>>>>>>>>> Funny you should mention all that. Â Let's say that you're lo=
nger
>>>>>>>>> with that company, either by direct employment or contract
>>>>>>>>> consultant. You've implemented C because you need 'thread'. =C2=
=A0Now
>>>>>>>>> your replacement comes in and has no clue about C even though you=
r
>>>>>>>>> replacement is a PHP guru. Â How much headache is maintenance=
gonna
>>>>>>>>> be? Â Scalability? Portability? wow....
>>>>>>>>
>>>>>>>> Who was the idi... who hired someone who wasn't suited for the job=
?
>>>>>>>> Tommy, that's a moot argument. Â You can't fit a square peg in=
a round
>>>>>>>> hole.
>>>>>>>>
>>>>>>>> --
>>>>>>>> Per Jessen, Zürich (12.5°C)
>>>>>>>>
>>>>>>> Suited for the job? Â You mean introduce more complexity to a p=
roblem
>>>>>>> that what could be avoided to begin with if PHP has thread support?
>>>>>>> hmmm....
>>>>>>
>>>>>> Tommy, it's perfectly simple: Â in my company we hire people wit=
h C
>>>>>> skills for C programming jobs. We hire people with database skills t=
o
>>>>>> be database administrators. Â We hire people with Linux skills t=
o work
>>>>>> on Linux systems. Â We explicitly do _not_ hire PHP web-programm=
ers to
>>>>>> maintain our C code. Â And vice versa for that matter. Â No =
problem, no
>>>>>> complexity.
>>>>>>
>>>>>>
>>>>>> --
>>>>>> Per Jessen, Zürich (13.4°C)
>>>>>>
>>>>>>
>>>>> That may just work out fine if you work directly for the company with
>>>>> all the proper staffing. Â But some of us work as consultants or =
for
>>>>> companies without the proper staffing. Â As such, let's dissect w=
hat
>>>>> you mentioned:
>>>>>
>>>>> 1) PHP with internal thread support
>>>>> 2) PHP with external C/C++ thread support
>>>>>
>>>>> * Performance - having external thread support, now you have to call
>>>>> an extension (more memory usage and CPU cycles). Â If you happen =
to
>>>>> have a C/C++ guru who can then code that thread support into PHP
>>>>> extension, wouldn't it still perform better at the core vs as an
>>>>> extension because it's not talking to a 'middle man'? Â Having sa=
id
>>>>> that, not everyone has access to a C/C++ guru. Â Thus not mass
>>>>> availability.
>>>>
>>>> Are you suggesting that you need to be a guru in C to write threaded C
>>>> code?
>>>> I think the word you're looking for is competent.
>>>>
>>>>> * Portability - if you're currently running PHP on Windows, but manag=
e
>>>>> to convince management to switch to *BSD/Linux, then you'd have to
>>>>> rewrite that external thread support. Â But for us consultants, w=
e may
>>>>> have 1 project the runs on Windows, the next may be *BSD/Linux. =C2=
=A0PHP
>>>>> code snippets goes a lot further versus your custom work around.
>>>>> * Managability - should your need to upgrade PHP for either bug fix,
>>>>> new features you'd want to implement to add more functionality to you=
r
>>>>> site, will that then break your custom external solution? Â How m=
uch
>>>>> more manageable is it if it's done under 1 language versus 2+?
>>>>
>>>> Are you suggesting cross platform thread libraries don't exist? I wond=
er
>>>> how
>>>> Apache does it... or MySQL... or any number of open source cross-platf=
orm
>>>> systems. If they implement their own, then by the virtue of the source
>>>> being
>>>> open, you can feel free to incorporate.
>>>>
>>>> Cheers,
>>>> Rob.
>>>> --
>>>> http://www.interjinn.com
>>>> Application and Templating Framework for PHP
>>>>
>>>
>>> Suppose I have an idea and make it a project. Â I'd then want to ma=
ke
>>> it open source and offer it to the world. Â With your custom thread
>>> solution, how much acceptance is it going to be for a decent PHP
>>> programmer to implement versus something that's already in pure PHP.
>>> Unzip/rar/tar > minor config for DB > Live. Â How does that sound f=
or
>>> portability? Â Now that you mention cross platform threading, do yo=
u
>>> think you can take the MySQL compiled for linux and make it work under
>>> BSD withouth BSD's linux binaries compatibility, nevermind Windows?
>>> Have you looked at the source of PHP? For whatever OS PHP compiles
>>> for, it uses the header library pertaining to that OS. Â So if I wa=
nt
>>> to implement thread solution similar to Per's solution, I'd have to be
>>> an expert at Windows, Linux, and *BSD just to make my PHP open source
>>> project to be readily acceptable to the world. Â I'll pass on that.
>>
>> Many open source projects are itches being scratched. More often than no=
t
>> you will not be alone in your desire to scratch. When that happens, and =
if
>> you're a good sort of chap or gal, then others will come along and help =
you
>> scratch. Soon, with the right kind of leadership and gameplan, you'll be
>> fully embroiled in a scratching orgy with key members scratching the rig=
ht
>> part of the itch. Do you think one person writes all the compatibility s=
tuff
>> for any of the above listed systems? No, there's just a lot of scratchin=
g
>> happening.
>>
>> Cheers,
>> Rob.
>> --
>> http://www.interjinn.com
>> Application and Templating Framework for PHP
>>
>
> Then the process at which to implement requested features becomes a
> crawl because now the project needs to consider the fact how some of
> the requested features will it be affected on Windows, Linux, *BSD
> versus on just how to realize (PHP coding) those features. Â I don't
> use Linux nor an expert in it but implementing custom thread solution
> like that means understanding about SELinux vs AppArmor vs Grsecurity
> or am I wrong? Â Look at your project(s) now, if you take your PHP co=
de
> and deploy to other platforms that you're currently not using, how
> portable is that? Â If a particular project happens to depends on
> platform/OS specifics, what then?
>
Also, what happens then when the OS gets a patch for security bug? Is
it going to break that non native PHP thread solution?
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 25.03.2010 00:04:00 von Robert Cummings
Tommy Pham wrote:
> On Wed, Mar 24, 2010 at 3:34 PM, Robert Cummings wrote:
>> Tommy Pham wrote:
>>> On Wed, Mar 24, 2010 at 1:24 PM, Robert Cummings
>>> wrote:
>>>> Tommy Pham wrote:
>>>>> On Wed, Mar 24, 2010 at 4:28 AM, Per Jessen wrote:
>>>>>> Tommy Pham wrote:
>>>>>>
>>>>>>> On Wed, Mar 24, 2010 at 3:44 AM, Per Jessen wrote:
>>>>>>>> Tommy Pham wrote:
>>>>>>>>
>>>>>>>>> On Wed, Mar 24, 2010 at 3:20 AM, Per Jessen
>>>>>>>>> wrote:
>>>>>>>>>> Tommy Pham wrote:
>>>>>>>>>>
>>>>>>>>>>> What I find funny is that one of opponents of PHP threads earlier
>>>>>>>>>>> mentioned that how silly it would be to be using C in a web app.
>>>>>>>>>>> Now I hear people mentioning C when they need "productivity" or
>>>>>>>>>>> "speed"...
>>>>>>>>>>>
>>>>>>>>>> I think I was the one to mention the latter, but as I started out
>>>>>>>>>> saying, and as others have said too, it's about the right tool for
>>>>>>>>>> the right job. When choosing a tool, there are a number of factors
>>>>>>>>>> to consider - developer productivity, available skills, future
>>>>>>>>>> maintenance, performance, scalability, portability, parallelism,
>>>>>>>>>> performance etcetera.
>>>>>>>>>>
>>>>>>>>> Funny you should mention all that. Let's say that you're longer
>>>>>>>>> with that company, either by direct employment or contract
>>>>>>>>> consultant. You've implemented C because you need 'thread'. Now
>>>>>>>>> your replacement comes in and has no clue about C even though your
>>>>>>>>> replacement is a PHP guru. How much headache is maintenance gonna
>>>>>>>>> be? Scalability? Portability? wow....
>>>>>>>> Who was the idi... who hired someone who wasn't suited for the job?
>>>>>>>> Tommy, that's a moot argument. You can't fit a square peg in a round
>>>>>>>> hole.
>>>>>>>>
>>>>>>>> --
>>>>>>>> Per Jessen, Zürich (12.5°C)
>>>>>>>>
>>>>>>> Suited for the job? You mean introduce more complexity to a problem
>>>>>>> that what could be avoided to begin with if PHP has thread support?
>>>>>>> hmmm....
>>>>>> Tommy, it's perfectly simple: in my company we hire people with C
>>>>>> skills for C programming jobs. We hire people with database skills to
>>>>>> be database administrators. We hire people with Linux skills to work
>>>>>> on Linux systems. We explicitly do _not_ hire PHP web-programmers to
>>>>>> maintain our C code. And vice versa for that matter. No problem, no
>>>>>> complexity.
>>>>>>
>>>>>>
>>>>>> --
>>>>>> Per Jessen, Zürich (13.4°C)
>>>>>>
>>>>>>
>>>>> That may just work out fine if you work directly for the company with
>>>>> all the proper staffing. But some of us work as consultants or for
>>>>> companies without the proper staffing. As such, let's dissect what
>>>>> you mentioned:
>>>>>
>>>>> 1) PHP with internal thread support
>>>>> 2) PHP with external C/C++ thread support
>>>>>
>>>>> * Performance - having external thread support, now you have to call
>>>>> an extension (more memory usage and CPU cycles). If you happen to
>>>>> have a C/C++ guru who can then code that thread support into PHP
>>>>> extension, wouldn't it still perform better at the core vs as an
>>>>> extension because it's not talking to a 'middle man'? Having said
>>>>> that, not everyone has access to a C/C++ guru. Thus not mass
>>>>> availability.
>>>> Are you suggesting that you need to be a guru in C to write threaded C
>>>> code?
>>>> I think the word you're looking for is competent.
>>>>
>>>>> * Portability - if you're currently running PHP on Windows, but manage
>>>>> to convince management to switch to *BSD/Linux, then you'd have to
>>>>> rewrite that external thread support. But for us consultants, we may
>>>>> have 1 project the runs on Windows, the next may be *BSD/Linux. PHP
>>>>> code snippets goes a lot further versus your custom work around.
>>>>> * Managability - should your need to upgrade PHP for either bug fix,
>>>>> new features you'd want to implement to add more functionality to your
>>>>> site, will that then break your custom external solution? How much
>>>>> more manageable is it if it's done under 1 language versus 2+?
>>>> Are you suggesting cross platform thread libraries don't exist? I wonder
>>>> how
>>>> Apache does it... or MySQL... or any number of open source cross-platform
>>>> systems. If they implement their own, then by the virtue of the source
>>>> being
>>>> open, you can feel free to incorporate.
>>>>
>>>> Cheers,
>>>> Rob.
>>>> --
>>>> http://www.interjinn.com
>>>> Application and Templating Framework for PHP
>>>>
>>> Suppose I have an idea and make it a project. I'd then want to make
>>> it open source and offer it to the world. With your custom thread
>>> solution, how much acceptance is it going to be for a decent PHP
>>> programmer to implement versus something that's already in pure PHP.
>>> Unzip/rar/tar > minor config for DB > Live. How does that sound for
>>> portability? Now that you mention cross platform threading, do you
>>> think you can take the MySQL compiled for linux and make it work under
>>> BSD withouth BSD's linux binaries compatibility, nevermind Windows?
>>> Have you looked at the source of PHP? For whatever OS PHP compiles
>>> for, it uses the header library pertaining to that OS. So if I want
>>> to implement thread solution similar to Per's solution, I'd have to be
>>> an expert at Windows, Linux, and *BSD just to make my PHP open source
>>> project to be readily acceptable to the world. I'll pass on that.
>> Many open source projects are itches being scratched. More often than not
>> you will not be alone in your desire to scratch. When that happens, and if
>> you're a good sort of chap or gal, then others will come along and help you
>> scratch. Soon, with the right kind of leadership and gameplan, you'll be
>> fully embroiled in a scratching orgy with key members scratching the right
>> part of the itch. Do you think one person writes all the compatibility stuff
>> for any of the above listed systems? No, there's just a lot of scratching
>> happening.
>>
>> Cheers,
>> Rob.
>> --
>> http://www.interjinn.com
>> Application and Templating Framework for PHP
>>
>
> Then the process at which to implement requested features becomes a
> crawl because now the project needs to consider the fact how some of
> the requested features will it be affected on Windows, Linux, *BSD
> versus on just how to realize (PHP coding) those features. I don't
> use Linux nor an expert in it but implementing custom thread solution
> like that means understanding about SELinux vs AppArmor vs Grsecurity
> or am I wrong? Look at your project(s) now, if you take your PHP code
> and deploy to other platforms that you're currently not using, how
> portable is that? If a particular project happens to depends on
> platform/OS specifics, what then?
A crawl is better than a standstill. I have C extensions for PHP that
work in both Linux and Windows. I didn't actually have to do anything
special since I used very standard C code. A threading library is
probably a bit of a different beast, but I wouldn't doubt cross platform
libraries exist. In fact a quick google of "cross platform C threading"
brought up the following Apache Portable Runtime Project:
http://apr.apache.org/
This has a thread module:
http://apr.apache.org/docs/apr/1.3/group__apr__os__thread.ht ml
And so the major legwork is already done. The thing about PHP is that
the PHP core is purportedly thread safe, in fact they even list a
thread-safe version. The problem is that the extensions and libraries
upon which the extensions are based are very often NOT thread safe. And
so if your PHP code doesn't plan on making use of these libraries then
using threads in PHP shouldn't be an issue. But first you need ot get an
extension going. There appears ot have been a threads extension on PECL
at one point, but it doesn't appear to be accessible anymore.
Cheers,
Rob.
--
http://www.interjinn.com
Application and Templating Framework for PHP
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 25.03.2010 00:31:56 von Tommy Pham
As some of you mention that implementing threads will make the DB work
harder than the standard serial operations queries, let me ask you
these then:
* How often does your DB server(s)/cluster utilizes 100% CPU (SMP/MC),
memory, and disk IO?
* How long is the duration when 100% utilization occurs?
* If you could implement threads and run those same queries in 2+
threads, the total time saved from queries execution is 1/2 sec or
more, which is pass along as the total response time reduced. Is it
worth it for you implement threads if you're a speed freak? (I
remember a list member, not mentioning his name, does optimization of
PHP coding for just microseconds. Do you think how much more he'd
benefit from this?)
* If the requests are executed in parallel, the sooner the request
fulfillment completes, the faster it is to move to the next request
and complete it right?
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
RE: Will PHP ever "grow up" and have threading?
am 25.03.2010 01:59:21 von Daevid Vincent
> -----Original Message-----
> And what you seem to be missing is that making PHP userspace
> threaded is
> such a major change to the underlying code base and
> architecture that it
> would essentially be a total and complete rewrite, and would require
> people to rewrite large portions of their existing PHP userspace code.
>
> So it's either you adjust your code to fit the paradigm that PHP is
> built for from the ground up, or the entire rest of the world adjusts
> its code to fit the paradigm that you think you want to have.
Very well said.
Isn't this only a factor for code that actually USES the threads though?
Wouldn't all code just keep working the same as always if no threads are
introduced in any part of it (which by default would be all existing code
to date?
-Daevid.
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
RE: Will PHP ever "grow up" and have threading? - vote.
am 25.03.2010 02:01:28 von Daevid Vincent
> Why don't you set up a vote to see how many developers actually *want*
> threading. That would be a good indication of whether or not it is
> actually worth the PHP development team spending a lot of
> time on it at the loss of other features which people want more.
I already did that with the initial post!
http://www.rapidpoll.net/show.aspx?id=awp1ocy
And so far, as I expected, the majority is for threading.
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
RE: Will PHP ever "grow up" and have threading?
am 25.03.2010 02:13:49 von Daevid Vincent
Well, since I was the one that started this shit-storm, I'll chime in =
for a
minute... ;-)
> If you added threading to the bag of tricks it already has,=20
> you're getting
> into areas that make it more difficult to pick up for=20
> beginners (and that's
> not to mention the technical elements involved in actually=20
> adding threading
> to PHP) Currently the only other 'easy' language I know for=20
> beginners is
> ColdFusion, and that's just horrible. You wouldn't want to be=20
> responsible
> for sending the newbies down that path would you?! :p
I'm sorry. I didn't realize PHP was designed for "beginers".
You do realize that just b/c PHP would have threading in it, doesn't =
mean
you actually have to use it right? My PHP has all sorts of other =
libraries
in it that I don't use.
> Funny you should mention all that. Let's say that you're longer with
> that company, either by direct employment or contract consultant.
> You've implemented C because you need 'thread'. Now your replacement
> comes in and has no clue about C even though your replacement is a PHP
> guru. How much headache is maintenance gonna be? Scalability?
> Portability? wow....
[And related]
> Thanks for supporting PHP thread. Thus, it would be a lot easier for
> any PHP guru to scale, make it portable, or integrate into other PHP
> apps without having to juggle C, Ruby, Python... and whatever else is
> out there...
Amen. Case in point. I had a developer who wrote our back end in Ruby. =
It's
nearly impossible to find an expert ruby developer. You can't swing a =
dead
cat without hitting a Rails guy these days, but they don't know the nuts
and bolts Ruby (we don't use Rails. We use PHP for the front end).
> Except, you already introduced complexity into the problem. You see,
> working with threads is another requirement, whether it be done in PHP
> or not. Hence, hiring the right guy is independent of whether you have
> threads in PHP or not - your problem is no less nor no more complex
> whether you do threading inside or outside PHP.=20
Uh. Learning the concept of threads is TRIVIAL compared to learning an
ENTIRE NEW LANGUAGE! Are you serious? Come on now guy. This argument is
just contrived.
> i really want to keep my code base in 1 language, because that
> simplifies everything later on imo.
> you people, who are against the evolotion of php towards cloud
> computing, would force me to do mixed-languages projects or even
> rewrite large sections of my codebase if as i want, i keep my codebase
> in 1 language.
Absolutely spot on. My company is standing still right now because we =
can't
find a damn Ruby guy that can code to this level! Had PHP had threading,
then we could have just used that for the back-end and front end. =
....right
tool for the job my ass.
At a previous company I watched nearly the same thing happen. We were
supposed to be sold for $25MM and when the due diligence came along and
they saw we had written things in two languages (Ruby and PHP again
actually, they declined on the last day and the company folded). They =
said
it was too difficult to integrate into their software which used a third
language.
> You mentioned Facebook as an example of a popular=20
> application. Are you aware that they only recently started=20
> using their compiler in production, and that prior to that=20
> they were happily running PHP to serve their front end=20
> without ever complaining that it didn't support threading?=20
> Even now, with hip-hop, individual requests are served in a=20
> single thread, so the language itself still doesn't support=20
> threading, and I don't hear them complaining that it's=20
> costing them a fortune. Why? Because it's not. And if it was=20
> they would have added it by now.
You all think to shallow and narrow minded. You keep thinking in terms =
of
using PHP as simply a web language. You need to think in terms of using =
it
like Perl, Python, Ruby, Java, C/++, etc. Computers do a lot more than =
just
spit out web pages these days. I know most of you seem to only think in
terms of "the cloud" and other stupid technologies like that, but =
there's a
great big world of computing that doesn't. There's no reason that PHP
shouldn't be a viable language to use in those arenas either.
> for some reason, which is still not clear to me, you nay-sayers refuse
> to let a PROGRAMMING LANGUAGE (not a "hammer", not a "fishing boat")
> evolve to stay useful, relevant even, in a changing market.
>=20
> and you're blatantly telling me to use a different kind of "hammer",
> one that would force me to rewrite large sections of my existing
> code-base, and one that i have told you i would find for many other
> _valid_ reasons not optimal.
Spot on again. I have maybe 12 YEARS of PHP expertise, knowledge,
libraries, tools, code snippets, etc that are battle tested and hardened
and improved constantly. Now I'd have to toss all that out just to write
some things in a language that has threading -- something that is a =
given
in most EVERY other language.
> The database is still a bottleneck. Now instead of processing=20
> one query
> at a time for a PHP script, it's processing 3 because you want them
> processed in parallel. Now the database is struggling with 3 times the
> work to complete in the same amount of time.
>=20
> Threading hasn't helped that much here, you've just moved the=20
> problem to an area which is already generally considered the =
bottleneck=20
> in most applications.
Not entirely true. You could have several slave databases in a pool and
therefore each thread would connect to another slave (and BTW, each =
slave
does NOT have to be a separate box either, just instances on one box or
VMs). Thereby retaining your parallelism and speed.
> portability? Now that you mention cross platform threading, do you
> think you can take the MySQL compiled for linux and make it work under
> BSD withouth BSD's linux binaries compatibility, nevermind Windows?
> Have you looked at the source of PHP? For whatever OS PHP compiles
> for, it uses the header library pertaining to that OS. So if I want
> to implement thread solution similar to Per's solution, I'd have to be
> an expert at Windows, Linux, and *BSD just to make my PHP open source
> project to be readily acceptable to the world. I'll pass on that.
Don=92t give a shit. LAMP is the only real setup out there. And I'm =
perfectly
happy with a "PHP --with-threads-on-linux-only" option. It's trivial to
setup a LAMP box if you need threads. I don't care if it works on OSX, =
BSD,
Windows or anything else. That's not elitist, that's just quashing this
argument with a viable solution. Just as people code their web pages to
work on IE and Firefox and don't worry about the other fringe browsers, =
so
it could follow that the threading only works on PHP for Linux. There =
are
currently several functions and differences in PHP now that "only work =
on
Windows" or "only works on Unix". Nobody's complaining too loudly that =
I'm
aware of.
And, to those that believe throwing more hardware at the problem is the
solution, you must work for Microsoft or something as that's their
philosophy too. [a] think about the effect on the environment that has =
(not
only in energy, but also landfill E-waste), [b] think of how much it =
costs
to put a rack in data-center. Space is limited you know. [c] why =
wouldn't
you squeeze every microsecond of performance you can from existing =
hardware
before spending wasted money, time and resources on new hardware? You
either work for a huge mega-corp where they're used to blowing wads of
cache, or you are have not worked for a startup where every single =
dollar
is someone else's and they want to know how and why you're spending it.=20
P.S. I HATE bottom posting. WTF do I have to scroll all the way down =
past
hundreds of useless lines just to read a "me too" or some other comment. =
If
it's at the top, I can simply just keep moving from header to header in
Outlook (or your email GUI of choice). DELETE as I go. Easy. Simple.
Efficient.
ÐÆ5ÏÐ=20
http://daevid.com
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 25.03.2010 02:20:16 von Matt Giddings
------=_Part_232628_388978427.1269480016658
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: 7bit
unsubscribe
------=_Part_232628_388978427.1269480016658--
Re: Will PHP ever "grow up" and have threading?
am 25.03.2010 02:21:35 von Matt Giddings
------=_Part_232634_1538012788.1269480095816
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: 7bit
ok, how do I get off this list?
------=_Part_232634_1538012788.1269480095816--
Re: Will PHP ever "grow up" and have threading?
am 25.03.2010 02:22:21 von Robert Cummings
Matt Giddings wrote:
> unsubscribe
*lol*
--
http://www.interjinn.com
Application and Templating Framework for PHP
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
RE: Will PHP ever "grow up" and have threading?
am 25.03.2010 02:23:13 von Daevid Vincent
You don't. It's like hotel california. You can check out any time you like,
but you can never leave. ;-)
> -----Original Message-----
> From: Matt Giddings [mailto:mcgiddin@svsu.edu]
> Sent: Wednesday, March 24, 2010 6:22 PM
> To: Matt Giddings
> Cc: php-general@lists.php.net
> Subject: Re: [PHP] Will PHP ever "grow up" and have threading?
>
> ok, how do I get off this list?
>
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 25.03.2010 02:27:17 von Joseph Masoud
--00151744790e88ab8c048295f201
Content-Type: text/plain; charset=ISO-8859-1
>
> P.S. I HATE bottom posting. WTF do I have to scroll all the way down past
> hundreds of useless lines just to read a "me too" or some other comment. If
> it's at the top, I can simply just keep moving from header to header in
> Outlook (or your email GUI of choice). DELETE as I go. Easy. Simple.
> Efficient.
>
http://www.netmeister.org/news/learn2quote.html
--00151744790e88ab8c048295f201--
Re: Will PHP ever "grow up" and have threading?
am 25.03.2010 02:28:02 von Ashley Sheridan
--=-2MHwXG5ApjtkByKXEpVB
Content-Type: text/plain
Content-Transfer-Encoding: 7bit
On Wed, 2010-03-24 at 21:21 -0400, Matt Giddings wrote:
> ok, how do I get off this list?
you either follow the instructions on the page that you used to sign up
to the list, or send an email to the email address listed in header of
all emails from the list.
Thanks,
Ash
http://www.ashleysheridan.co.uk
--=-2MHwXG5ApjtkByKXEpVB--
Re: Will PHP ever "grow up" and have threading?
am 25.03.2010 02:45:00 von Michelle Konzack
--=_samba3-11461-1269481501-0001-2
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable
Hello Teus,
You are a NOOB! ;-)
You have not understood what he want.
Am 2010-03-24 06:55:56, hacktest Du folgendes herunter:
> Well, the multiple answers for a simple request per user as in your
> example, seem to be a lot of information to display all on one page, and
> present all that information to the user in one request. I would
> probably resolve it, IMHO, by using pagers. That is, only part of the
> information is shown to the user at one time, and the user can page
> through that information so as to get to other bits of information. If
> only part is shown, then the database query becomes so much faster
> (hopefully), and PHP still can do all of it in one thread.
He need threading because if you transform SAO Image (the NASA program)
into a WebApp, you have to multi-query a 28 TByte Database and if ou
make sequetial queries it take 24 hours to run and you get a server
timout. using multi-threading will give you the result in 1 minutes but
a serverload of 100% with an loadaverage of 50 should for him no problem
Hell, I run a bunch of small Sun Fire X4100M2 with 3 SAS drives of 76 GB
and it can handel a 10 GE Internet access plus a PostgreSQL cluster
behind it with more then 25000 requets per second...
I was never thinking off adding threading to PHP.
It realy sounds braindamaged
For such things here are optimized languages.
Thanks, Greetings and nice Day/Evening
Michelle Konzack
Systemadministrator
24V Electronic Engineer
Tamay Dogan Network
Debian GNU/Linux Consultant
--=20
Linux-User #280138 with the Linux Counter, http://counter.li.org/
##################### Debian GNU/Linux Consultant #####################
Michelle Konzack
Apt. 917
50, rue de Soultz
Jabber linux4michelle@jabber.ccc.de 67100 Strabourg/France
IRC #Debian (irc.icq.com) Tel. DE: +49 177 9351947
ICQ #328449886 Tel. FR: +33 6 61925193
--=_samba3-11461-1269481501-0001-2
Content-Type: application/pgp-signature; name="signature.pgp"
Content-Transfer-Encoding: 7bit
Content-Description: Digital signature
Content-Disposition: inline
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (GNU/Linux)
iD8DBQFLqsAcC0FPBMSS+BIRAolcAKDKEbl6UbFUMhQEYTxw+/VNxB7uLACg tRq7
f7r2/M7vlhzGQZzqqdB021c=
=7aVP
-----END PGP SIGNATURE-----
--=_samba3-11461-1269481501-0001-2--
Re: Will PHP ever "grow up" and have threading?
am 25.03.2010 03:03:13 von Michelle Konzack
--=_samba3-25814-1269482594-0001-2
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable
Hello Tommy Pham,
Am 2010-03-23 18:17:56, hacktest Du folgendes herunter:
> Let's go back to my 1st e-commerce example. The manufacturers list is
> about 3,700. The categories is about about 2,400. The products list
> is right now at 500,000 and expected to be around 750,000. The site
> is only in English. The store owner wants to expand and be I18n:
> Chinese, French, German, Korean, Spanish. You see how big and complex
> that database gets? The store owners want to have this happens when a
> customer clicks on a category:
I have something like this similar but my database is arround 2 TByte
and stored on seven Sun Fire X4150 and I have only two X4100M2 as
redunant Front-End.
Your 750.000 items look a little bit like a gadget database...
I habe several 10 million rows and 200 columns and this is why I splited
the Database into seven Severs.
Even threading would not work on this database, because the botleneck is
the Disk-IO.
A query about the "Irak-War" and "Backwater" would kill a singel server.
> * show all subcategories for that category, if any
> * show all products for that category, if any,
> * show all manufacturers, used as filtering, for that category and subcat=
egories
> * show price range filter for that category
> * show features & specifications filter for that category
> * show 10 top sellers for that category and related subcategories
> * the shopper can then select/deselect any of those filters and
> ability to sort by manufacturers, prices, user rating, popularity
> (purchased quantity)
> * have the ability to switch to another language translation on the fly
> * from the moment the shopper click on a link, the response time (when
> web browser saids "Done" in the status bar) is 5 seconds or less.
> Preferably 2-3 seconds. Will be using stopwatch for the timer.
Nothing special...
Describtion for the products sould be a seperated server
Q: Do you real mean, you put 750.000 product describtions into
the database and then create a new colum for ech language?
Your Mini-Shop could be done with redunancy using two Database- and two
Web-Servrs.
> is not even enterprise requirement. I may have another possible
> project where # products is over 10 million easily. With similar
More the 10 mio products? Whats this?
I a in the electronic business, and geting 10 mio products, mean, take
ANY western manufacturers of microchip manufacturers, passive parts,
connectors and such into a database?
Put asian manufactures to are arround 30 mio in total.
If you say, you put the FITS data from the ESO into it, I could
understand, but your explanation is a little but to unbelivable.
Thanks, Greetings and nice Day/Evening
Michelle Konzack
Systemadministrator
24V Electronic Engineer
Tamay Dogan Network
Debian GNU/Linux Consultant
--=20
Linux-User #280138 with the Linux Counter, http://counter.li.org/
##################### Debian GNU/Linux Consultant #####################
Michelle Konzack
Apt. 917
50, rue de Soultz
Jabber linux4michelle@jabber.ccc.de 67100 Strabourg/France
IRC #Debian (irc.icq.com) Tel. DE: +49 177 9351947
ICQ #328449886 Tel. FR: +33 6 61925193
--=_samba3-25814-1269482594-0001-2
Content-Type: application/pgp-signature; name="signature.pgp"
Content-Transfer-Encoding: 7bit
Content-Description: Digital signature
Content-Disposition: inline
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (GNU/Linux)
iD8DBQFLqsRhC0FPBMSS+BIRAqOVAJ9lte6PufZDhn+wPeobMBsXHbirLgCg hTtr
Ye2Me4dJTe7J84KA0Xddtwg=
=5Jv2
-----END PGP SIGNATURE-----
--=_samba3-25814-1269482594-0001-2--
Re: Re: Will PHP ever "grow up" and have threading?
am 25.03.2010 03:16:47 von Tommy Pham
On Wed, Mar 24, 2010 at 7:03 PM, Michelle Konzack
wrote:
> Hello Tommy Pham,
>
> Am 2010-03-23 18:17:56, hacktest Du folgendes herunter:
>> Let's go back to my 1st e-commerce example. Â The manufacturers list=
is
>> about 3,700. Â The categories is about about 2,400. Â The produc=
ts list
>> is right now at 500,000 and expected to be around 750,000. Â The sit=
e
>> is only in English. Â The store owner wants to expand and be I18n:
>> Chinese, French, German, Korean, Spanish. Â You see how big and comp=
lex
>> that database gets? Â The store owners want to have this happens whe=
n a
>> customer clicks on a category:
>
> I have something like this similar but my database  is  arround=
 2 TByte
> and stored on seven Sun Fire X4150  and  I  have  onl=
y  two  X4100M2  as
> redunant Front-End.
>
> Your 750.000 items look a little bit like a gadget database...
>
> I habe several 10 million rows and 200 columns and this is why I splited
> the Database into seven Severs.
>
> Even threading would not work on this database, because the botleneck is
> the Disk-IO.
>
> A query about the "Irak-War" and "Backwater" would kill a singel server.
>
>> * show all subcategories for that category, if any
>> * show all products for that category, if any,
>> * show all manufacturers, used as filtering, for that category and subca=
tegories
>> * show price range filter for that category
>> * show features & specifications filter for that category
>> * show 10 top sellers for that category and related subcategories
>> * the shopper can then select/deselect any of those filters and
>> ability to sort by manufacturers, prices, user rating, popularity
>> (purchased quantity)
>> * have the ability to switch to another language translation on the fly
>> * from the moment the shopper click on a link, the response time (when
>> web browser saids "Done" in the status bar) is 5 seconds or less.
>> Preferably 2-3 seconds. Will be using stopwatch for the timer.
>
> Nothing special...
>
> Describtion for the products sould be a seperated server
>
> Q: Â Do you real mean, you put 750.000 product describtions into
> Â Â the database and then create a new colum for ech language?
>
> Your Mini-Shop could be done with redunancy using two Database- and two
> Web-Servrs.
>
>> is not even enterprise requirement. Â I may have another possible
>> project where # products is over 10 million easily. Â With similar
>
> More the 10 mio products? Â Whats this?
>
> I a in the electronic business, and geting 10 mio products, mean, take
> ANY western manufacturers of microchip manufacturers, Â passive =C2=
=A0parts,
> connectors and such into a database?
>
> Put asian manufactures to are arround 30 mio in total.
>
> If you say, you put the  FITS  data  from  the  =
ESO  into  it,  I  could
> understand, but your explanation is a little but to unbelivable.
>
> Thanks, Greetings and nice Day/Evening
> Â Â Michelle Konzack
> Â Â Systemadministrator
> Â Â 24V Electronic Engineer
> Â Â Tamay Dogan Network
> Â Â Debian GNU/Linux Consultant
>
> --
> Linux-User #280138 with the Linux Counter, http://counter.li.org/
> ##################### Debian GNU/Linux Consultant #####################
> Â Â Â Â Â Â =
  Michelle Konzack
> Â Â Â Â Â Â =C2=
=A0 Â Â Apt. 917
> Â Â Â Â Â Â =
 50, rue de Soultz
> Jabber linux4michelle@jabber.ccc.de      67=
100 Strabourg/France
> IRC Â Â #Debian (irc.icq.com) Â Â Â Â Â =
    Tel. DE: +49 177 9351947
> ICQ Â Â #328449886 Â Â Â Â Â Â =C2=
=A0 Â Â Â Â Â Â Â Tel. FR: +33 Â 6 =
 61925193
>
10+ million products is not hard to believe. Look at Amazon (my
future possible project is not related to Amazon nor am I endorsing
it). They sell consumer goods. Their product skus are about 30
million, and that's not all the consumer goods there are either.
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 25.03.2010 03:53:24 von Michelle Konzack
--=_samba3-9120-1269485605-0001-2
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable
Hello Tommy,
Am 2010-03-23 19:08:36, hacktest Du folgendes herunter:
> The response time, max 5 seconds, will be tested on local gigabit LAN
> to ensure the adequate response (optimized DB & code & proper
> hardware) without worrying about users' connection limit and site's
> upload bandwidth limit (which can easily rectify). Then thereafter
> will be doing stress test of about 10 concurrent users. As for the
> major queries, that's where threads come in, IMO, because those
> queries depend on 1 primary parameter (category ID) and 1 secondary
> parameter (language ID). This particular site starts with 500
> products about 15 categories, without many of those mentioned filters,
> later grew to its current state.
Because not a singel OSS OnlineStore software support features I need
for my business, I am coding a whole "Waren Wirtschafts System" with
production checkout and an additional OnlineStore where I sell products
which I have bought in VERY big quantities to get my Endproducts cheaper
in production.
I start with bneary the same requiements as you, have 18 main categories
and each has 5 to 40 sub categories.
Currently I have arround 1700 different products I need for production
but over the tieme I count with 30-50.000 products.
The server I will use is developed by my own using a Marvell Kirkwood
MV78200 with an attached Marvell 8-channel SATA/SAS Raid-0/1/10/5 con-
troller. This pig has 2 GByte DDR2 memory and beat anything I have ever
used in this class. It is an ARM Microcontroller with 1200MHz.
The "Reference Design" I use currently can handel more then 400 requests
at once...
If such small machine can handel this, I realy think, you do not know
what are you talking about...
My software (Apache2, PHP5 and PostgreSQL 8.3; Debian GNU/Linux Lenny)
installed on this Low-Energy (<17W) machine can be scaled by adding
parallel machines to increase performance...
The machine without harddrives cost me in production of 1000 pcs less
then 300 Euro/machine.
I am slightely sure, yo make something wrong...
I will not continue to read ths thread, because it is sick.
Thanks, Greetings and nice Day/Evening
Michelle Konzack
Systemadministrator
24V Electronic Engineer
Tamay Dogan Network
Debian GNU/Linux Consultant
--=20
Linux-User #280138 with the Linux Counter, http://counter.li.org/
##################### Debian GNU/Linux Consultant #####################
Michelle Konzack
Apt. 917
50, rue de Soultz
Jabber linux4michelle@jabber.ccc.de 67100 Strabourg/France
IRC #Debian (irc.icq.com) Tel. DE: +49 177 9351947
ICQ #328449886 Tel. FR: +33 6 61925193
--=_samba3-9120-1269485605-0001-2
Content-Type: application/pgp-signature; name="signature.pgp"
Content-Transfer-Encoding: 7bit
Content-Description: Digital signature
Content-Disposition: inline
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (GNU/Linux)
iD8DBQFLqtAkC0FPBMSS+BIRAtunAKDRHhfjM40DUeCUuzjEXRMRWozAawCe P+9G
pE435rS1vnThWPWd5gVOWNo=
=5yRq
-----END PGP SIGNATURE-----
--=_samba3-9120-1269485605-0001-2--
Re: Re: Will PHP ever "grow up" and have threading?
am 25.03.2010 03:57:28 von Michelle Konzack
--=_samba3-14465-1269485849-0001-2
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable
Hello Tommy,
Am 2010-03-24 19:16:47, hacktest Du folgendes herunter:
> 10+ million products is not hard to believe. Look at Amazon (my
> future possible project is not related to Amazon nor am I endorsing
> it). They sell consumer goods. Their product skus are about 30
> million, and that's not all the consumer goods there are either.
They have a datacenter, a bunch of load balancer and does not run any-
thing on a singel database server. They use more then 1000 servers!
Thanks, Greetings and nice Day/Evening
Michelle Konzack
Systemadministrator
24V Electronic Engineer
Tamay Dogan Network
Debian GNU/Linux Consultant
--=20
Linux-User #280138 with the Linux Counter, http://counter.li.org/
##################### Debian GNU/Linux Consultant #####################
Michelle Konzack
Apt. 917
50, rue de Soultz
Jabber linux4michelle@jabber.ccc.de 67100 Strabourg/France
IRC #Debian (irc.icq.com) Tel. DE: +49 177 9351947
ICQ #328449886 Tel. FR: +33 6 61925193
--=_samba3-14465-1269485849-0001-2
Content-Type: application/pgp-signature; name="signature.pgp"
Content-Transfer-Encoding: 7bit
Content-Description: Digital signature
Content-Disposition: inline
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (GNU/Linux)
iD8DBQFLqtEYC0FPBMSS+BIRAkEFAJ0f76Cy4rEGvDvT7h1jcZDWqV3HlgCb BwLu
U2ZrWTaSxgURYCmqWpL6SGM=
=8g8N
-----END PGP SIGNATURE-----
--=_samba3-14465-1269485849-0001-2--
Re: Will PHP ever "grow up" and have threading?
am 25.03.2010 04:00:25 von Michelle Konzack
--=_samba3-11159-1269486026-0001-2
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable
Hello Matt,
Am 2010-03-24 21:21:35, hacktest Du folgendes herunter:
> ok, how do I get off this list?=20
Realy easy... :-D
You continue reading this thread and then commit suicid! If then your
maibox overflow, you will automaticaly unsubscribed through the bounces.
Thanks, Greetings and nice Day/Evening
Michelle Konzack
Systemadministrator
24V Electronic Engineer
Tamay Dogan Network
Debian GNU/Linux Consultant
--=20
Linux-User #280138 with the Linux Counter, http://counter.li.org/
##################### Debian GNU/Linux Consultant #####################
Michelle Konzack
Apt. 917
50, rue de Soultz
Jabber linux4michelle@jabber.ccc.de 67100 Strabourg/France
IRC #Debian (irc.icq.com) Tel. DE: +49 177 9351947
ICQ #328449886 Tel. FR: +33 6 61925193
--=_samba3-11159-1269486026-0001-2
Content-Type: application/pgp-signature; name="signature.pgp"
Content-Transfer-Encoding: 7bit
Content-Description: Digital signature
Content-Disposition: inline
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (GNU/Linux)
iD8DBQFLqtHJC0FPBMSS+BIRAuPSAJ4tSrYaHwC76X70x5gb5n5RtkVK5ACf ctA6
CR2AaHz0isVQaVdCrkBB+iI=
=sbsb
-----END PGP SIGNATURE-----
--=_samba3-11159-1269486026-0001-2--
Re: Will PHP ever "grow up" and have threading?
am 25.03.2010 04:02:15 von Michelle Konzack
--=_samba3-30524-1269486136-0001-2
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable
Hello Robert,
Am 2010-03-24 21:22:21, hacktest Du folgendes herunter:
> Matt Giddings wrote:
> >unsubscribe
> *lol*
That hit it, -- right?
Thanks, Greetings and nice Day/Evening
Michelle Konzack
Systemadministrator
24V Electronic Engineer
Tamay Dogan Network
Debian GNU/Linux Consultant
--=20
Linux-User #280138 with the Linux Counter, http://counter.li.org/
##################### Debian GNU/Linux Consultant #####################
Michelle Konzack
Apt. 917
50, rue de Soultz
Jabber linux4michelle@jabber.ccc.de 67100 Strabourg/France
IRC #Debian (irc.icq.com) Tel. DE: +49 177 9351947
ICQ #328449886 Tel. FR: +33 6 61925193
--=_samba3-30524-1269486136-0001-2
Content-Type: application/pgp-signature; name="signature.pgp"
Content-Transfer-Encoding: 7bit
Content-Description: Digital signature
Content-Disposition: inline
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (GNU/Linux)
iD8DBQFLqtI3C0FPBMSS+BIRAjsMAKCcoSjA5lkOBBy7JW0jJoGvJ9PODQCg kXZP
/jlPuL0sE9IHktS4H9Hqm6g=
=Ec1g
-----END PGP SIGNATURE-----
--=_samba3-30524-1269486136-0001-2--
Re: Will PHP ever "grow up" and have threading?
am 25.03.2010 04:04:25 von Michelle Konzack
--=_samba3-15674-1269486266-0001-2
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable
Hello Daevid Vincent,
Am 2010-03-24 18:13:49, hacktest Du folgendes herunter:
> P.S. I HATE bottom posting. WTF do I have to scroll all the way down past
> hundreds of useless lines just to read a "me too" or some other comment. =
If
> it's at the top, I can simply just keep moving from header to header in
> Outlook (or your email GUI of choice). DELETE as I go. Easy. Simple.
> Efficient.
Hehehe... It seems there are peoles which dislike you with your idea!
Thanks, Greetings and nice Day/Evening
Michelle Konzack
Systemadministrator
24V Electronic Engineer
Tamay Dogan Network
Debian GNU/Linux Consultant
--=20
Linux-User #280138 with the Linux Counter, http://counter.li.org/
##################### Debian GNU/Linux Consultant #####################
Michelle Konzack
Apt. 917
50, rue de Soultz
Jabber linux4michelle@jabber.ccc.de 67100 Strabourg/France
IRC #Debian (irc.icq.com) Tel. DE: +49 177 9351947
ICQ #328449886 Tel. FR: +33 6 61925193
--=_samba3-15674-1269486266-0001-2
Content-Type: application/pgp-signature; name="signature.pgp"
Content-Transfer-Encoding: 7bit
Content-Description: Digital signature
Content-Disposition: inline
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (GNU/Linux)
iD8DBQFLqtK5C0FPBMSS+BIRAoeCAJ47CgX2qp1sjBvRPFmhlknNs4uaUACg svs8
V9/orcFWOXklM8o18++9oFs=
=60Xx
-----END PGP SIGNATURE-----
--=_samba3-15674-1269486266-0001-2--
Re: Re: Will PHP ever "grow up" and have threading?
am 25.03.2010 04:04:45 von Tommy Pham
On Wed, Mar 24, 2010 at 7:53 PM, Michelle Konzack
wrote:
> Hello Tommy,
>
> Am 2010-03-23 19:08:36, hacktest Du folgendes herunter:
>> The response time, max 5 seconds, will be tested on local gigabit LAN
>> to ensure the adequate response (optimized DB & code & proper
>> hardware) without worrying about users' connection limit and site's
>> upload bandwidth limit (which can easily rectify). Â Then thereafter
>> will be doing stress test of about 10 concurrent users. Â As for the
>> major queries, that's where threads come in, IMO, because those
>> queries depend on 1 primary parameter (category ID) and 1 secondary
>> parameter (language ID). Â This particular site starts with 500
>> products about 15 categories, without many of those mentioned filters,
>> later grew to its current state.
>
> Because not a singel OSS OnlineStore software support  features =C2=
=A0I Â need
> for my business, I am coding  a  whole  "Waren Wirtschafts=
System" Â with
> production checkout and an additional OnlineStore where I sell  prod=
ucts
> which I have bought in VERY big quantities to get my Endproducts cheaper
> in production.
>
> I start with bneary the same requiements as you, have 18 main categories
> and each has 5 to 40 sub categories.
>
> Currently I have arround 1700 different products I need  for  p=
roduction
> but over the tieme I count with 30-50.000 products.
>
> The server I will use is developed by my own using  a  Marvell =
 Kirkwood
> MV78200 with an attached Marvell 8-channel SATA/SAS Â Raid-0/1/10/5 =
 con-
> troller. Â This pig has 2 GByte DDR2 memory and beat anything I have =
ever
> used in this class. Â It is an ARM Microcontroller with 1200MHz.
>
> The "Reference Design" I use currently can handel more then 400 requests
> at once...
>
> If such small machine can handel this, I realy think, you  do  =
not  know
> what are you talking about...
>
> My software (Apache2, PHP5 and PostgreSQL 8.3; Â Debian GNU/Linux =C2=
=A0Lenny)
> installed on this Low-Energy (<17W) machine  can  be  scal=
ed  by  adding
> parallel machines to increase performance...
>
> The machine without harddrives cost me in production  of  1000 =
pcs  less
> then 300 Euro/machine.
>
> I am slightely sure, yo make something wrong...
>
> I will not continue to read ths thread, because it is sick.
>
> Thanks, Greetings and nice Day/Evening
> Â Â Michelle Konzack
> Â Â Systemadministrator
> Â Â 24V Electronic Engineer
> Â Â Tamay Dogan Network
> Â Â Debian GNU/Linux Consultant
>
> --
> Linux-User #280138 with the Linux Counter, http://counter.li.org/
> ##################### Debian GNU/Linux Consultant #####################
> Â Â Â Â Â Â =
  Michelle Konzack
> Â Â Â Â Â Â =C2=
=A0 Â Â Apt. 917
> Â Â Â Â Â Â =
 50, rue de Soultz
> Jabber linux4michelle@jabber.ccc.de      67=
100 Strabourg/France
> IRC Â Â #Debian (irc.icq.com) Â Â Â Â Â =
    Tel. DE: +49 177 9351947
> ICQ Â Â #328449886 Â Â Â Â Â Â =C2=
=A0 Â Â Â Â Â Â Â Tel. FR: +33 Â 6 =
 61925193
>
I think you're missing my point. Given your current hardware,
software, product list, etc... how long does it take to run your
queries in series? If you were able to run them in parallel and
deliver faster response time to the users, would you implement PHP
thread, if it's available?
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Re: Will PHP ever "grow up" and have threading?
am 25.03.2010 05:13:30 von ahlin.hans
Threading, Shared memory and PHP
Do PHP really need support for threads?
When and why is it necessary?
Why should/shouldn't it be implemented in the core?
How can one implement/create similar features right now?
One reason I can imagine it to be useful, is if one has lots of SQL
servers, and would want the script to manage the workload, or that if
the servers might have different data stored that one needs access to.
For example; one SQL server has account information, and another
handles the messaging system, and the third handles generic
information, and the last handles a product catalog with categories.
And with threading, it would be a performance gain to be able to send
the queries simultaneously to different servers.
As for shared memory I think it is safer to use workarounds, but it
would make it easier to create some classes, and would open up a whole
new (high performance) way for classes to access shared data, that
belongs to all objects and sessions.
I also see a problem with shared web hosting, concerning both security
and memory issues.
For example, lets say the host has 10 clients running advanced
systems, that place consistent data in memory, but only 2 clients has
the need for the resources that the host supplies and 1000 connections
at any given time, but the rest of the 10 clients only has 100
connections per day, and uses the same amount of memory as the more
demanding clients.
And then we have the problem with sharing memory across servers.
Then we have the security issue that, if improperly configured/coded,
other user/system can access the data, which arises the need for
sandboxes or access control schemes.
I fund some workarounds to this kind of problem by putting my energy
on the code deign and analysis. I have a feeling that the most of the
ones that yells the most belongs to the power programming group that
skipped the part with architect philosophy.
So basically I don´t need the support of threading or shared memory, I
created the solution that works for me and my partners (with php
only). But I admit that if there were native support for threading I
would use it. But I don´t want the support for threading if it
slowdown the performance.
MvH / Hans Ã
hlin
Tel: +46761488019
http://www.kronan-net.com/
irc://irc.freenode.net:6667 - TheCoin
2010/3/25 Tommy Pham :
> On Wed, Mar 24, 2010 at 7:53 PM, Michelle Konzack
> wrote:
>> Hello Tommy,
>>
>> Am 2010-03-23 19:08:36, hacktest Du folgendes herunter:
>>> The response time, max 5 seconds, will be tested on local gigabit LAN
>>> to ensure the adequate response (optimized DB & code & proper
>>> hardware) without worrying about users' connection limit and site's
>>> upload bandwidth limit (which can easily rectify). Â Then thereafte=
r
>>> will be doing stress test of about 10 concurrent users. Â As for th=
e
>>> major queries, that's where threads come in, IMO, because those
>>> queries depend on 1 primary parameter (category ID) and 1 secondary
>>> parameter (language ID). Â This particular site starts with 500
>>> products about 15 categories, without many of those mentioned filters,
>>> later grew to its current state.
>>
>> Because not a singel OSS OnlineStore software support  features =C2=
=A0I Â need
>> for my business, I am coding  a  whole  "Waren Wirtschaft=
s System" Â with
>> production checkout and an additional OnlineStore where I sell  pro=
ducts
>> which I have bought in VERY big quantities to get my Endproducts cheaper
>> in production.
>>
>> I start with bneary the same requiements as you, have 18 main categories
>> and each has 5 to 40 sub categories.
>>
>> Currently I have arround 1700 different products I need  for  =
production
>> but over the tieme I count with 30-50.000 products.
>>
>> The server I will use is developed by my own using  a  Marvell=
 Kirkwood
>> MV78200 with an attached Marvell 8-channel SATA/SAS Â Raid-0/1/10/5 =
 con-
>> troller. Â This pig has 2 GByte DDR2 memory and beat anything I have=
ever
>> used in this class. Â It is an ARM Microcontroller with 1200MHz.
>>
>> The "Reference Design" I use currently can handel more then 400 requests
>> at once...
>>
>> If such small machine can handel this, I realy think, you  do =C2=
=A0not  know
>> what are you talking about...
>>
>> My software (Apache2, PHP5 and PostgreSQL 8.3; Â Debian GNU/Linux =
 Lenny)
>> installed on this Low-Energy (<17W) machine  can  be  sca=
led  by  adding
>> parallel machines to increase performance...
>>
>> The machine without harddrives cost me in production  of  1000=
pcs  less
>> then 300 Euro/machine.
>>
>> I am slightely sure, yo make something wrong...
>>
>> I will not continue to read ths thread, because it is sick.
>>
>> Thanks, Greetings and nice Day/Evening
>> Â Â Michelle Konzack
>> Â Â Systemadministrator
>> Â Â 24V Electronic Engineer
>> Â Â Tamay Dogan Network
>> Â Â Debian GNU/Linux Consultant
>>
>> --
>> Linux-User #280138 with the Linux Counter, http://counter.li.org/
>> ##################### Debian GNU/Linux Consultant #####################
>> Â Â Â Â Â Â =
  Michelle Konzack
>> Â Â Â Â Â Â =
   Apt. 917
>> Â Â Â Â Â =C2=
=A0 Â 50, rue de Soultz
>> Jabber linux4michelle@jabber.ccc.de      6=
7100 Strabourg/France
>> IRC Â Â #Debian (irc.icq.com) Â Â Â Â =C2=
=A0 Â Â Â Â Tel. DE: +49 177 9351947
>> ICQ Â Â #328449886 Â Â Â Â Â Â =
        Tel. FR: +33  =
6 Â 61925193
>>
>
> I think you're missing my point. Â Given your current hardware,
> software, product list, etc... how long does it take to run your
> queries in series? Â If you were able to run them in parallel and
> deliver faster response time to the users, would you implement PHP
> thread, if it's available?
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Re: Will PHP ever "grow up" and have threading?
am 25.03.2010 06:54:09 von Rene Veerman
On Thu, Mar 25, 2010 at 6:13 AM, Hans =C5hlin w=
rote:
>I admit that if there were native support for threading I
> would use it. But I don=B4t want the support for threading if it
> slowdown the performance.
hmm i bet you can use any feature of php to slow things down..
i think what's been proven by the pro-camp by now is that at least
some application designs would benefit from threading and shared
memory.
imo there's no way to tell up front if threading will be detrimental
or benefitial to all projects built with php.
itsa case-by-case thing... aint it?
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 25.03.2010 07:11:32 von Rene Veerman
On Wed, Mar 24, 2010 at 11:42 PM, Stuart Dallas wrote:
> On 24 Mar 2010, at 20:34, Rene Veerman wrote:
>>
>> On Wed, Mar 24, 2010 at 10:19 PM, Ashley Sheridan
..uk> wrote:
>> On Wed, 2010-03-24 at 22:15 +0200, Rene Veerman wrote:
>> Do you have any proof of this 'market trend'? I suggested a vote, but yo=
u 'nay-sayed' it on the basis that you'd lose to people who couldn't possib=
ly know as much as you do.
>>
>>
>> yes, twitter. facebook. the fact that a graphics upgrade would likely in=
crease business for the first ones on that popularity level to implement it=
..
>> that's the proof i have for the market trend.
>
> Again, improving the graphical content of a website has absolutely no eff=
ect on the performance of PHP. The additional time the page takes to load i=
s all about network latency and how well you've arranged your static file s=
erving.
right now my cms is 2D, and indeed most of the graphics are static then.
but i have plans to lift it into 3D, with "rooms" interacting via
avatars, and then the graphics-selection and avatar-behavior
(animations) selections alone i suspect will put much extra stress on
the servers. especially if i have to use sql servers to handle the
datastreams.
>
>> oh, and the fact "cloud computing" is becoming more and more of a buzzwo=
rd in the industry.
>
> Cloud computing really doesn't mean what you think it means.
its a flexible term eh.. others' definitions are clearly not always
aligned with yours.
>
>>> I wouldn't say I belonged to any particular camp at the start of this t=
hread, but now, having read what my betters have said, I'm inclined to agre=
e that threading isn't the magic wand that you seem to think it is. I perso=
nally see one of the largest sites in the world running on PHP without need=
ing threading and without insulting half the list to attempt to get it.
>>
>> =A0you haven't offered me any description at all of how i'd solve the la=
rge-scale realtime-web-app with existing techniques.
>
> By "realtime-web-app" you mean something like Facebook? They use a combin=
ation of PHP, Memcached (and lots of it), MySQL and lots of other layers in=
-between to do what they do, and threaded PHP is not one of them.
>
i suppose facebook and twitter are the earliest examples of a near-realtime=
-web.
i think the dataflows of the future realtimewebs (in the next 3 to 10
years) will increase quite a bit in size and speed of updates.
>> and if i explain why i'd need the features we've discussed, you dismiss =
it by accepting a generalized "that can be solved with more sql servers" an=
swer that is admitted to increase costs in every department, including ener=
gy consumption. on a non-linear scale btw.
>
> What I'm getting here is that you want everything without paying for it. =
When it comes to scalability it's cheaper to achieve it by adding servers t=
han it is to squeeze every last drop of performance out of a single box. Th=
e cost in development time alone to implement effective threading strategie=
s would far outstrip the cost of adding a couple of servers and ensuring th=
at your app is scalable.
i have this strong gut-feeling that adding more hardware when it's not
needed leads to waste on a non-linear scale.
in particular using sql servers to handle datastreams seems not wise to me.
i'd like to use sql only for permanent storage.
>
> What you seem to be ignoring is the fact that these issues have been solv=
ed already, and the techniques that exist are more than adequate to build s=
ystems that scale as well as Facebook. What will it take to get you to acce=
pt that the way you want to skin the cat is exceedingly messy?
yea, the current facebook and twitter.
but i'm thinking 3 to 10 years ahead, and want threading and shared
mem support in php to save on all my costs, energy consumption, and
risks.
i also think the wastefulness of letting the 'alternative' paradigm of
'more sql servers' is on a non-linear scale.
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading? - vote.
am 25.03.2010 08:44:22 von Lester Caine
Daevid Vincent wrote:
>> Why don't you set up a vote to see how many developers actually *want*
>> threading. That would be a good indication of whether or not it is
>> actually worth the PHP development team spending a lot of
>> time on it at the loss of other features which people want more.
>
> I already did that with the initial post!
>
> http://www.rapidpoll.net/show.aspx?id=awp1ocy
>
> And so far, as I expected, the majority is for threading.
The majority have not voted yet ;)
Although I don not classify 'thread safe' as the same thing as 'provide
threading' so the poll is already skewed.
--
Lester Caine - G8HFL
-----------------------------
Contact - http://lsces.co.uk/wiki/?page=contact
L.S.Caine Electronic Services - http://lsces.co.uk
EnquirySolve - http://enquirysolve.com/
Model Engineers Digital Workshop - http://medw.co.uk//
Firebird - http://www.firebirdsql.org/index.php
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
RE: Will PHP ever "grow up" and have threading?
am 25.03.2010 09:01:30 von Per Jessen
Daevid Vincent wrote:
> Well, since I was the one that started this shit-storm, I'll chime in=
> for a minute... ;-)
>=20
>> If you added threading to the bag of tricks it already has, you're
>> getting into areas that make it more difficult to pick up for
>> beginners (and that's not to mention the technical elements involved=
>> in actually adding threading to PHP) Currently the only other 'easy'=
>> language I know for beginners is ColdFusion, and that's just
>> horrible. You wouldn't want to be responsible for sending the newbie=
s
>> down that path would you?! :p=20
>=20
> I'm sorry. I didn't realize PHP was designed for "beginers".
>=20
There is something about the entire environment that makes coding PHP
for a webpage attractive to beginners. The runtime is your
web-browser, you don't need to compile anything, you just edit, and hit=
F5. Combine that with weak typing and an easy syntax, and you've got
something that is easy to pick up.=20
Contrast that with perhaps Java and j2ee, a language and a framework
often used in large, long term projects with long life expectancies -
not really a beginners sandbox.
> You all think to shallow and narrow minded. You keep thinking in term=
s
> of using PHP as simply a web language. You need to think in terms of
> using it like Perl, Python, Ruby, Java, C/++, etc. Computers do a lot=
> more than just spit out web pages these days. I know most of you seem=
> to only think in terms of "the cloud" and other stupid technologies
> like that, but there's a great big world of computing that doesn't.
> There's no reason that PHP shouldn't be a viable language to use in
> those arenas either.
PHP is perfectly viable for those areas today. I wouldn't personally
use it for anything non-web unless it is less than 1000 lines. My
experience has taught me not to (not just PHP, any script language).
> Spot on again. I have maybe 12 YEARS of PHP expertise, knowledge,
> libraries, tools, code snippets, etc that are battle tested and
> hardened and improved constantly. Now I'd have to toss all that out
> just to write some things in a language that has threading --
> something that is a given in most EVERY other language.
Actually, most don't have it built-in, it usually comes in separate
libraries and is an operating-system feature, not a language feature.
Two notable exceptions I can think of are Ada and PL/1.=20
--=20
Per Jessen, Zürich (11.4°C)
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Re: Will PHP ever "grow up" and have threading?
am 25.03.2010 09:08:41 von ahlin.hans
MvH / Hans Ã
hlin
Tel: +46761488019
http://www.kronan-net.com/
irc://irc.freenode.net:6667 - TheCoin
2010/3/25 Rene Veerman :
> On Thu, Mar 25, 2010 at 6:13 AM, Hans Ã
hlin
om> wrote:
>>I admit that if there were native support for threading I
>> would use it. But I don´t want the support for threading if it
>> slowdown the performance.
>
> hmm i bet you can use any feature of php to slow things down..
>
> i think what's been proven by the pro-camp by now is that at least
> some application designs would benefit from threading and shared
> memory.
>
> imo there's no way to tell up front if threading will be detrimental
> or benefitial to all projects built with php.
> itsa case-by-case thing... aint it?
>
The problem as I understand it, is that the whole language would be affecte=
d,
and project that doesn't use shared memory and/or threading is going
to be affected negatively.
But if there is some way to implement threading and shared memory
without the side effects and keeping the security that php provide to
day, and with the resources that the project have. Then i'm totally
for it.
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Re: Will PHP ever "grow up" and have threading?
am 25.03.2010 09:09:31 von Per Jessen
Tommy Pham wrote:
> I think you're missing my point. Given your current hardware,
> software, product list, etc... how long does it take to run your
> queries in series? If you were able to run them in parallel and
> deliver faster response time to the users, would you implement PHP
> thread, if it's available?
I mentioned it yesterday, but perhaps you overlooked it - the mysqlnd
driver supports asynchronous queries. If you really have an issue with=
the elapse time of sequential, but independent database queries,
executing them asynchronously is the obvious solution. (apart from
tuning the database, but I'm assuming you've already been there).
--=20
Per Jessen, Zürich (11.9°C)
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 25.03.2010 09:31:15 von Per Jessen
Tommy Pham wrote:
> As such, let's dissect what you mentioned:
>=20
> 1) PHP with internal thread support
> 2) PHP with external C/C++ thread support
That's not quite what I mentioned, but I'll accept it for the sake of
argument.=20
> * Performance - having external thread support, now you have to call
> an extension (more memory usage and CPU cycles).=20
Tommy, you are already using millions of more cycles by running PHP
instead of C. It's a reasonable trade-off of course, but "using more
cycles" is not a valid counter-argument.=20
> If you happen to have a C/C++ guru who can then code that thread
> support into PHP extension, wouldn't it still perform better at the
> core vs as an extension because it's not talking to a 'middle man'?=20=
It's another trade-off Tommy - you run two separate processes, talking
to each other over TCP (for instance) to gain 1) performance and 2)
flexibility/scalability. You gain performance by having processes that=
can be independently scheduled by the OS, and you gain flexibility by
being able to move a process to another box (for scalability). You pay
for that with a few thousand cycles. When you decide to use a database=
(e.g. mysql) you also make a trade-off - well-managed data, a
structured query-language and some overhead vs. doing it all in your
own code.=20
> * Portability - if you're currently running PHP on Windows, but manag=
e
> to convince management to switch to *BSD/Linux, then you'd have to
> rewrite that external thread support.=20
If portability is a concern, I'd make sure my threaded backend would ru=
n
on all the platforms I could envision. Portability is merely one of
many factors that affect choice of programming language.=20
> * Managability - should your need to upgrade PHP for either bug fix,
> new features you'd want to implement to add more functionality to you=
r
> site, will that then break your custom external solution? How much
> more manageable is it if it's done under 1 language versus 2+?
I said it yesterday already - having a single implementation language I=
S
a positive, but it may not always be possible due to requirements.=20
--=20
Per Jessen, Zürich (12.3°C)
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 25.03.2010 09:35:58 von Per Jessen
Tommy Pham wrote:
> I don't
> use Linux nor an expert in it but implementing custom thread solution=
> like that means understanding about SELinux vs AppArmor vs Grsecurity=
> or am I wrong?=20
Yes, you are wrong. The Posix thread model implemented in the pthread
library in Linux is easy to pick up for anyone who has studied computer=
science - where he or she will already have been introduced to mutexes,=
semaphores, the Dining Philosophers, race conditions, deadlocks and
such.=20
--=20
Per Jessen, Zürich (12.6°C)
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 25.03.2010 09:46:32 von Per Jessen
Tommy Pham wrote:
> As some of you mention that implementing threads will make the DB wor=
k
> harder than the standard serial operations queries, let me ask you
> these then:
>=20
> * How often does your DB server(s)/cluster utilizes 100% CPU (SMP/MC)=
,
> memory, and disk IO?
Assuming we're talking under heavy load - my database server is an
old(ish) HP Proliant ML570 - 4 x 3GHz Xeons with HT, dual U320 SCSI
busses, 48GB RAM :
CPU 100% - rarely, but it happens.
Memory 100% - all the time.=20
Disk IO 100% - less than all the time, but it's very busy.
> * If you could implement threads and run those same queries in 2+
> threads, the total time saved from queries execution is 1/2 sec or
> more, which is pass along as the total response time reduced. Is it
> worth it for you implement threads if you're a speed freak?=20
Use mysqlnd - asynchronous mysql queries.
> (I remember a list member, not mentioning his name, does optimization=
> of PHP coding for just microseconds. Do you think how much more he'd=
> benefit from this?)
Anyone who optimizes PHP for microseconds has lost touch with reality -=
or at least forgotten that he or she is using an interpreted language.
> * If the requests are executed in parallel, the sooner the request
> fulfillment completes, the faster it is to move to the next request
> and complete it right?
Correct.=20
--=20
Per Jessen, Zürich (12.7°C)
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 25.03.2010 10:23:20 von Per Jessen
Per Jessen wrote:
> CPU 100% - rarely, but it happens.
> Memory 100% - all the time.
> Disk IO 100% - less than all the time, but it's very busy.
FYI, it's actually quite difficult to drive a disk subsystem to
consistent 100% utilization over a period of time. Oracle uses
asynchronous I/O and could probably drive a disk subsystem quite hard,
but AFAIK, mysql doesn't.
--=20
Per Jessen, Zürich (13.9°C)
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 25.03.2010 11:38:48 von Tommy Pham
On Thu, Mar 25, 2010 at 1:46 AM, Per Jessen wrote:
>> * If you could implement threads and run those same queries in 2+
>> threads, the total time saved from queries execution is 1/2 sec or
>> more, which is pass along as the total response time reduced. Â Is i=
t
>> worth it for you implement threads if you're a speed freak?
>
> Use mysqlnd - asynchronous mysql queries.
>
You're assuming that everyone in the PHP world uses MySQL 4.1 or
newer. What about those who don't? Which goes back to being
portability.
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 25.03.2010 11:55:00 von Per Jessen
Tommy Pham wrote:
> On Thu, Mar 25, 2010 at 1:46 AM, Per Jessen wrote:=
>>> * If you could implement threads and run those same queries in 2+
>>> threads, the total time saved from queries execution is 1/2 sec or
>>> more, which is pass along as the total response time reduced. Â =
Is it
>>> worth it for you implement threads if you're a speed freak?
>>
>> Use mysqlnd - asynchronous mysql queries.
>>
>=20
> You're assuming that everyone in the PHP world uses MySQL 4.1 or
> newer. What about those who don't?=20
They don't get to use threading, nor asynchronous mysql queries.=20
Come on, you're asking about a future feature in PHP 7.x , but would
like to support someone who is seriously backlevel on mysql??
--=20
Per Jessen, Zürich (16.9°C)
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 25.03.2010 12:02:20 von Ashley Sheridan
--=-6xJTjq+1BODk18ORGdT7
Content-Type: text/plain
Content-Transfer-Encoding: 7bit
On Thu, 2010-03-25 at 08:11 +0200, Rene Veerman wrote:
> right now my cms is 2D, and indeed most of the graphics are static
> then.
>
> but i have plans to lift it into 3D, with "rooms" interacting via
> avatars, and then the graphics-selection and avatar-behavior
> (animations) selections alone i suspect will put much extra stress on
> the servers. especially if i have to use sql servers to handle the
> datastreams.
Have you had a look at Papervision? It's about the best thing for 3D on
the web right now, and has even garnered some official Adobe support.
Thanks,
Ash
http://www.ashleysheridan.co.uk
--=-6xJTjq+1BODk18ORGdT7--
Re: Will PHP ever "grow up" and have threading?
am 25.03.2010 12:26:52 von Rene Veerman
--00151747b104f9c83104829e53eb
Content-Type: text/plain; charset=ISO-8859-1
On Thu, Mar 25, 2010 at 12:02 PM, Ashley Sheridan
wrote:
> On Thu, 2010-03-25 at 08:11 +0200, Rene Veerman wrote:
>
> right now my cms is 2D, and indeed most of the graphics are static then.
>
> but i have plans to lift it into 3D, with "rooms" interacting via
> avatars, and then the graphics-selection and avatar-behavior
> (animations) selections alone i suspect will put much extra stress on
> the servers. especially if i have to use sql servers to handle the
> datastreams.
>
>
> Have you had a look at Papervision? It's about the best thing for 3D on the
> web right now, and has even garnered some official Adobe support.
>
yup. papervision, away3d, i've had a look at them.
my current thinking is to build an abstraction layer for 3D in
flashdevelop.org that interfaces with either papervision or away3d.. no
telling which'll be the victor in the end of that race.
but the real reason for me to invest in an extra abstraction layer is those
"unlimited detail" guys (http://www.youtube.com/watch?v=Q-ATtrImCx4&ttl=1)
who are likely to change the entire 3D stack (from graphicscard up).
--00151747b104f9c83104829e53eb--
Re: Will PHP ever "grow up" and have threading?
am 25.03.2010 14:24:56 von Robert Cummings
Per Jessen wrote:
> Tommy Pham wrote:
>
>> (I remember a list member, not mentioning his name, does optimization
>> of PHP coding for just microseconds. Do you think how much more he'd
>> benefit from this?)
>
> Anyone who optimizes PHP for microseconds has lost touch with reality -
> or at least forgotten that he or she is using an interpreted language.
But sometimes it's just plain fun to do it here on the list with
everyone further optimizing the last optimized snippet :)
Cheers,
Rob.
--
http://www.interjinn.com
Application and Templating Framework for PHP
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 25.03.2010 19:37:40 von Tommy Pham
On Thu, Mar 25, 2010 at 3:55 AM, Per Jessen wrote:
> Tommy Pham wrote:
>
>> On Thu, Mar 25, 2010 at 1:46 AM, Per Jessen wrote:
>>>> * If you could implement threads and run those same queries in 2+
>>>> threads, the total time saved from queries execution is 1/2 sec or
>>>> more, which is pass along as the total response time reduced. Â Is=
it
>>>> worth it for you implement threads if you're a speed freak?
>>>
>>> Use mysqlnd - asynchronous mysql queries.
>>>
>>
>> You're assuming that everyone in the PHP world uses MySQL 4.1 or
>> newer. Â What about those who don't?
>
> They don't get to use threading, nor asynchronous mysql queries.
>
> Come on, you're asking about a future feature in PHP 7.x , but would
> like to support someone who is seriously backlevel on mysql??
>
>
> --
> Per Jessen, Zürich (16.9°C)
>
I'm not talking about MySQL 4.0 or older. I'm talking about other
RDBMS. I think you should open your eyes a bit wider and take a look
at the bigger picture (Firebird, MSSQL, Oracle, PostgreSQL, etc).
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 25.03.2010 20:02:22 von Peter Lind
On 25 March 2010 19:37, Tommy Pham wrote:
> On Thu, Mar 25, 2010 at 3:55 AM, Per Jessen wrote:
>> Tommy Pham wrote:
>>
>>> On Thu, Mar 25, 2010 at 1:46 AM, Per Jessen wrote:
>>>>> * If you could implement threads and run those same queries in 2+
>>>>> threads, the total time saved from queries execution is 1/2 sec or
>>>>> more, which is pass along as the total response time reduced. Â I=
s it
>>>>> worth it for you implement threads if you're a speed freak?
>>>>
>>>> Use mysqlnd - asynchronous mysql queries.
>>>>
>>>
>>> You're assuming that everyone in the PHP world uses MySQL 4.1 or
>>> newer. Â What about those who don't?
>>
>> They don't get to use threading, nor asynchronous mysql queries.
>>
>> Come on, you're asking about a future feature in PHP 7.x , but would
>> like to support someone who is seriously backlevel on mysql??
>>
>>
>> --
>> Per Jessen, Zürich (16.9°C)
>>
>
> I'm not talking about MySQL 4.0 or older. Â I'm talking about other
> RDBMS. Â I think you should open your eyes a bit wider and take a loo=
k
> at the bigger picture (Firebird, MSSQL, Oracle, PostgreSQL, etc).
http://www.php.net/manual/en/function.pg-send-query.php
Looks to me like the PHP postgresql library already handles that. Not
to mention: you're not presenting an argument for threads, you're
presenting an argument for implementing asynchronous queries in the
other DBMS libraries.
Of course, the problem could also be solved by introducing threads in
PHP. I'd personally guess modifying DBMS libraries would be less
costly, but as I haven't been involved in writing the PHP code my
guess isn't worth much.
Regards
Peter
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>
--=20
WWW: http://plphp.dk / http://plind.dk
LinkedIn: http://www.linkedin.com/in/plind
Flickr: http://www.flickr.com/photos/fake51
BeWelcome: Fake51
Couchsurfing: Fake51
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 25.03.2010 20:09:22 von Tommy Pham
On Thu, Mar 25, 2010 at 12:02 PM, Peter Lind wrote=
:
> On 25 March 2010 19:37, Tommy Pham wrote:
>> On Thu, Mar 25, 2010 at 3:55 AM, Per Jessen wrote:
>>> Tommy Pham wrote:
>>>
>>>> On Thu, Mar 25, 2010 at 1:46 AM, Per Jessen wrote:
>>>>>> * If you could implement threads and run those same queries in 2+
>>>>>> threads, the total time saved from queries execution is 1/2 sec or
>>>>>> more, which is pass along as the total response time reduced. Â =
Is it
>>>>>> worth it for you implement threads if you're a speed freak?
>>>>>
>>>>> Use mysqlnd - asynchronous mysql queries.
>>>>>
>>>>
>>>> You're assuming that everyone in the PHP world uses MySQL 4.1 or
>>>> newer. Â What about those who don't?
>>>
>>> They don't get to use threading, nor asynchronous mysql queries.
>>>
>>> Come on, you're asking about a future feature in PHP 7.x , but would
>>> like to support someone who is seriously backlevel on mysql??
>>>
>>>
>>> --
>>> Per Jessen, Zürich (16.9°C)
>>>
>>
>> I'm not talking about MySQL 4.0 or older. Â I'm talking about other
>> RDBMS. Â I think you should open your eyes a bit wider and take a lo=
ok
>> at the bigger picture (Firebird, MSSQL, Oracle, PostgreSQL, etc).
>
> http://www.php.net/manual/en/function.pg-send-query.php
>
> Looks to me like the PHP postgresql library already handles that. Not
> to mention: you're not presenting an argument for threads, you're
> presenting an argument for implementing asynchronous queries in the
> other DBMS libraries.
>
> Of course, the problem could also be solved by introducing threads in
> PHP. I'd personally guess modifying DBMS libraries would be less
> costly, but as I haven't been involved in writing the PHP code my
> guess isn't worth much.
>
> Regards
> Peter
>
I'm presenting the argument for threading. Per is presenting the work
around using asynchronous queries via mysqlnd. I did read that link a
few days ago, "Although the user can send multiple queries at once,
multiple queries cannot be sent over a busy connection. If a query is
sent while the connection is busy, it waits until the last query is
finished and discards all its results." Which sounds like threads ->
multiple connections to not run into that problem.
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 25.03.2010 20:11:42 von Ashley Sheridan
--=-eA8XgUw0Mmd35Rdqu2ya
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
On Thu, 2010-03-25 at 12:09 -0700, Tommy Pham wrote:
> On Thu, Mar 25, 2010 at 12:02 PM, Peter Lind wro=
te:
> > On 25 March 2010 19:37, Tommy Pham wrote:
> >> On Thu, Mar 25, 2010 at 3:55 AM, Per Jessen wrote:
> >>> Tommy Pham wrote:
> >>>
> >>>> On Thu, Mar 25, 2010 at 1:46 AM, Per Jessen wrote=
:
> >>>>>> * If you could implement threads and run those same queries in 2+
> >>>>>> threads, the total time saved from queries execution is 1/2 sec or
> >>>>>> more, which is pass along as the total response time reduced. Is =
it
> >>>>>> worth it for you implement threads if you're a speed freak?
> >>>>>
> >>>>> Use mysqlnd - asynchronous mysql queries.
> >>>>>
> >>>>
> >>>> You're assuming that everyone in the PHP world uses MySQL 4.1 or
> >>>> newer. What about those who don't?
> >>>
> >>> They don't get to use threading, nor asynchronous mysql queries.
> >>>
> >>> Come on, you're asking about a future feature in PHP 7.x , but would
> >>> like to support someone who is seriously backlevel on mysql??
> >>>
> >>>
> >>> --
> >>> Per Jessen, Zürich (16.9°C)
> >>>
> >>
> >> I'm not talking about MySQL 4.0 or older. I'm talking about other
> >> RDBMS. I think you should open your eyes a bit wider and take a look
> >> at the bigger picture (Firebird, MSSQL, Oracle, PostgreSQL, etc).
> >
> > http://www.php.net/manual/en/function.pg-send-query.php
> >
> > Looks to me like the PHP postgresql library already handles that. Not
> > to mention: you're not presenting an argument for threads, you're
> > presenting an argument for implementing asynchronous queries in the
> > other DBMS libraries.
> >
> > Of course, the problem could also be solved by introducing threads in
> > PHP. I'd personally guess modifying DBMS libraries would be less
> > costly, but as I haven't been involved in writing the PHP code my
> > guess isn't worth much.
> >
> > Regards
> > Peter
> >
>=20
> I'm presenting the argument for threading. Per is presenting the work
> around using asynchronous queries via mysqlnd. I did read that link a
> few days ago, "Although the user can send multiple queries at once,
> multiple queries cannot be sent over a busy connection. If a query is
> sent while the connection is busy, it waits until the last query is
> finished and discards all its results." Which sounds like threads ->
> multiple connections to not run into that problem.
>=20
Wouldn't there still be the same issue though?
If several threads of PHP are all trying to connect to to a database
that can only handle a finite number of connections, the database must
still wait until a query has been pushed off of it's queue before it can
process another. As far as I can see, this isn't an issue that can be
solved by threading in PHP, but by allowing more concurrent connections
in the database.
Thanks,
Ash
http://www.ashleysheridan.co.uk
--=-eA8XgUw0Mmd35Rdqu2ya--
Re: Will PHP ever "grow up" and have threading?
am 25.03.2010 20:13:11 von Peter Lind
On 25 March 2010 20:09, Tommy Pham wrote:
> On Thu, Mar 25, 2010 at 12:02 PM, Peter Lind wro=
te:
>> On 25 March 2010 19:37, Tommy Pham wrote:
>>> On Thu, Mar 25, 2010 at 3:55 AM, Per Jessen wrote:
>>>> Tommy Pham wrote:
>>>>
>>>>> On Thu, Mar 25, 2010 at 1:46 AM, Per Jessen wrote:
>>>>>>> * If you could implement threads and run those same queries in 2+
>>>>>>> threads, the total time saved from queries execution is 1/2 sec or
>>>>>>> more, which is pass along as the total response time reduced. =C2=
=A0Is it
>>>>>>> worth it for you implement threads if you're a speed freak?
>>>>>>
>>>>>> Use mysqlnd - asynchronous mysql queries.
>>>>>>
>>>>>
>>>>> You're assuming that everyone in the PHP world uses MySQL 4.1 or
>>>>> newer. Â What about those who don't?
>>>>
>>>> They don't get to use threading, nor asynchronous mysql queries.
>>>>
>>>> Come on, you're asking about a future feature in PHP 7.x , but would
>>>> like to support someone who is seriously backlevel on mysql??
>>>>
>>>>
>>>> --
>>>> Per Jessen, Zürich (16.9°C)
>>>>
>>>
>>> I'm not talking about MySQL 4.0 or older. Â I'm talking about other
>>> RDBMS. Â I think you should open your eyes a bit wider and take a l=
ook
>>> at the bigger picture (Firebird, MSSQL, Oracle, PostgreSQL, etc).
>>
>> http://www.php.net/manual/en/function.pg-send-query.php
>>
>> Looks to me like the PHP postgresql library already handles that. Not
>> to mention: you're not presenting an argument for threads, you're
>> presenting an argument for implementing asynchronous queries in the
>> other DBMS libraries.
>>
>> Of course, the problem could also be solved by introducing threads in
>> PHP. I'd personally guess modifying DBMS libraries would be less
>> costly, but as I haven't been involved in writing the PHP code my
>> guess isn't worth much.
>>
>> Regards
>> Peter
>>
>
> I'm presenting the argument for threading. Â Per is presenting the wo=
rk
> around using asynchronous queries via mysqlnd. Â I did read that link=
a
> few days ago, "Although the user can send multiple queries at once,
> multiple queries cannot be sent over a busy connection. If a query is
> sent while the connection is busy, it waits until the last query is
> finished and discards all its results." Â Which sounds like threads -=
>
> multiple connections to not run into that problem.
>
Have you looked into what it would cost in development to improve the
library? Have you compared that to the cost in development to
introduce threads into PHP? No, I don't think you're presenting the
argument for threading - but I don't expect you to see it that way.
--=20
WWW: http://plphp.dk / http://plind.dk
LinkedIn: http://www.linkedin.com/in/plind
Flickr: http://www.flickr.com/photos/fake51
BeWelcome: Fake51
Couchsurfing: Fake51
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 25.03.2010 20:19:33 von Tommy Pham
On Thu, Mar 25, 2010 at 12:13 PM, Peter Lind wrote=
:
> On 25 March 2010 20:09, Tommy Pham wrote:
>> On Thu, Mar 25, 2010 at 12:02 PM, Peter Lind wr=
ote:
>>> On 25 March 2010 19:37, Tommy Pham wrote:
>>>> On Thu, Mar 25, 2010 at 3:55 AM, Per Jessen wrote:
>>>>> Tommy Pham wrote:
>>>>>
>>>>>> On Thu, Mar 25, 2010 at 1:46 AM, Per Jessen wrote=
:
>>>>>>>> * If you could implement threads and run those same queries in 2+
>>>>>>>> threads, the total time saved from queries execution is 1/2 sec or
>>>>>>>> more, which is pass along as the total response time reduced. =C2=
=A0Is it
>>>>>>>> worth it for you implement threads if you're a speed freak?
>>>>>>>
>>>>>>> Use mysqlnd - asynchronous mysql queries.
>>>>>>>
>>>>>>
>>>>>> You're assuming that everyone in the PHP world uses MySQL 4.1 or
>>>>>> newer. Â What about those who don't?
>>>>>
>>>>> They don't get to use threading, nor asynchronous mysql queries.
>>>>>
>>>>> Come on, you're asking about a future feature in PHP 7.x , but would
>>>>> like to support someone who is seriously backlevel on mysql??
>>>>>
>>>>>
>>>>> --
>>>>> Per Jessen, Zürich (16.9°C)
>>>>>
>>>>
>>>> I'm not talking about MySQL 4.0 or older. Â I'm talking about othe=
r
>>>> RDBMS. Â I think you should open your eyes a bit wider and take a =
look
>>>> at the bigger picture (Firebird, MSSQL, Oracle, PostgreSQL, etc).
>>>
>>> http://www.php.net/manual/en/function.pg-send-query.php
>>>
>>> Looks to me like the PHP postgresql library already handles that. Not
>>> to mention: you're not presenting an argument for threads, you're
>>> presenting an argument for implementing asynchronous queries in the
>>> other DBMS libraries.
>>>
>>> Of course, the problem could also be solved by introducing threads in
>>> PHP. I'd personally guess modifying DBMS libraries would be less
>>> costly, but as I haven't been involved in writing the PHP code my
>>> guess isn't worth much.
>>>
>>> Regards
>>> Peter
>>>
>>
>> I'm presenting the argument for threading. Â Per is presenting the w=
ork
>> around using asynchronous queries via mysqlnd. Â I did read that lin=
k a
>> few days ago, "Although the user can send multiple queries at once,
>> multiple queries cannot be sent over a busy connection. If a query is
>> sent while the connection is busy, it waits until the last query is
>> finished and discards all its results." Â Which sounds like threads =
->
>> multiple connections to not run into that problem.
>>
>
> Have you looked into what it would cost in development to improve the
> library? Have you compared that to the cost in development to
> introduce threads into PHP? No, I don't think you're presenting the
> argument for threading - but I don't expect you to see it that way.
>
Aren't all feature requests must be analyzed the same way? Example,
namespace, how many of us actually uses it now when there is an
alternative solution- subfolders - that we've been using since who
knows how long. I don't know if threads was asked a feature prior
namespace was implemented.
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 25.03.2010 20:25:47 von Tommy Pham
On Thu, Mar 25, 2010 at 12:11 PM, Ashley Sheridan
wrote:
>
> On Thu, 2010-03-25 at 12:09 -0700, Tommy Pham wrote:
>
> On Thu, Mar 25, 2010 at 12:02 PM, Peter Lind wro=
te:
> > On 25 March 2010 19:37, Tommy Pham wrote:
> >> On Thu, Mar 25, 2010 at 3:55 AM, Per Jessen wrote:
> >>> Tommy Pham wrote:
> >>>
> >>>> On Thu, Mar 25, 2010 at 1:46 AM, Per Jessen wrote=
:
> >>>>>> * If you could implement threads and run those same queries in 2+
> >>>>>> threads, the total time saved from queries execution is 1/2 sec or
> >>>>>> more, which is pass along as the total response time reduced. =C2=
=A0Is it
> >>>>>> worth it for you implement threads if you're a speed freak?
> >>>>>
> >>>>> Use mysqlnd - asynchronous mysql queries.
> >>>>>
> >>>>
> >>>> You're assuming that everyone in the PHP world uses MySQL 4.1 or
> >>>> newer. Â What about those who don't?
> >>>
> >>> They don't get to use threading, nor asynchronous mysql queries.
> >>>
> >>> Come on, you're asking about a future feature in PHP 7.x , but would
> >>> like to support someone who is seriously backlevel on mysql??
> >>>
> >>>
> >>> --
> >>> Per Jessen, Zürich (16.9°C)
> >>>
> >>
> >> I'm not talking about MySQL 4.0 or older. Â I'm talking about othe=
r
> >> RDBMS. Â I think you should open your eyes a bit wider and take a =
look
> >> at the bigger picture (Firebird, MSSQL, Oracle, PostgreSQL, etc).
> >
> > http://www.php.net/manual/en/function.pg-send-query.php
> >
> > Looks to me like the PHP postgresql library already handles that. Not
> > to mention: you're not presenting an argument for threads, you're
> > presenting an argument for implementing asynchronous queries in the
> > other DBMS libraries.
> >
> > Of course, the problem could also be solved by introducing threads in
> > PHP. I'd personally guess modifying DBMS libraries would be less
> > costly, but as I haven't been involved in writing the PHP code my
> > guess isn't worth much.
> >
> > Regards
> > Peter
> >
>
> I'm presenting the argument for threading. Per is presenting the work
> around using asynchronous queries via mysqlnd. I did read that link a
> few days ago, "Although the user can send multiple queries at once,
> multiple queries cannot be sent over a busy connection. If a query is
> sent while the connection is busy, it waits until the last query is
> finished and discards all its results." Which sounds like threads ->
> multiple connections to not run into that problem.
>
>
> Wouldn't there still be the same issue though?
>
> If several threads of PHP are all trying to connect to to a database that=
can only handle a finite number of connections, the database must still wa=
it until a query has been pushed off of it's queue before it can process an=
other. As far as I can see, this isn't an issue that can be solved by threa=
ding in PHP, but by allowing more concurrent connections in the database.
>
> Thanks,
> Ash
> http://www.ashleysheridan.co.uk
>
That's why I asked about the DB utilization earlier. Since the having
the threads can open multiple connections and finish the request
sooner, it can move on to the next request. Since Java & ASP.NET have
connection pooling, this adds to benefit of threads even more. I
don't know if PHP has connection pooling now. I haven't code in PHP a
some years.
Regards,
Tommy
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 25.03.2010 20:28:22 von Peter Lind
On 25 March 2010 20:19, Tommy Pham wrote:
> Aren't all feature requests must be analyzed the same way? Â Example,
> namespace, how many of us actually uses it now when there is an
> alternative solution- subfolders - that we've been using since who
> knows how long. Â I don't know if threads was asked a feature prior
> namespace was implemented.
>
Yes, you're right. But feature requests are not equal: some present a
bigger payoff than others, and some will be more problematic to
implement than others. If a given language can solve the problems it
meets based on it's current structure, should you necessarily
implement new shiny features, that may present problems?
I'm not against threads in PHP per se ... I just haven't seen a very
convincing reason for them yet, which is why I'm not very positive
about the thing. The DB scenario could be handled without threads and
current libraries could be improved ... and as long as that's cheaper
than implementing threads, then - personally - I'd need to see more
powerful reasons for threads.
Luckily, I have no say in the development of PHP, so I won't get in
anyone's way should they choose to implement threads :)
--=20
WWW: http://plphp.dk / http://plind.dk
LinkedIn: http://www.linkedin.com/in/plind
Flickr: http://www.flickr.com/photos/fake51
BeWelcome: Fake51
Couchsurfing: Fake51
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 25.03.2010 20:59:04 von Tommy Pham
On Thu, Mar 25, 2010 at 12:28 PM, Peter Lind wrote=
:
> On 25 March 2010 20:19, Tommy Pham wrote:
>> Aren't all feature requests must be analyzed the same way? Â Example=
,
>> namespace, how many of us actually uses it now when there is an
>> alternative solution- subfolders - that we've been using since who
>> knows how long. Â I don't know if threads was asked a feature prior
>> namespace was implemented.
>>
>
> Yes, you're right. But feature requests are not equal: some present a
> bigger payoff than others, and some will be more problematic to
> implement than others. If a given language can solve the problems it
> meets based on it's current structure, should you necessarily
> implement new shiny features, that may present problems?
>
> I'm not against threads in PHP per se ... I just haven't seen a very
> convincing reason for them yet, which is why I'm not very positive
> about the thing. The DB scenario could be handled without threads and
> current libraries could be improved ... and as long as that's cheaper
> than implementing threads, then - personally - I'd need to see more
> powerful reasons for threads.
>
> Luckily, I have no say in the development of PHP, so I won't get in
> anyone's way should they choose to implement threads :)
>
>
Here's my analysis, let's say that you have 1000 requests / second on
the web server. Each request has multiqueries which take a total of 1
second to complete. In that one second, how many of those 1000 arrive
at the same time (that one instant of micro/nano second)? You see how
threads come in? If you have threads that are able finish the
requests that come in that instant and able to complete them before
the next batch of requests in that same second, wouldn't you agree
then that you're delivering faster response time to all your users?
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 25.03.2010 21:10:58 von Peter Lind
On 25 March 2010 20:59, Tommy Pham wrote:
> On Thu, Mar 25, 2010 at 12:28 PM, Peter Lind wro=
te:
>> On 25 March 2010 20:19, Tommy Pham wrote:
>>> Aren't all feature requests must be analyzed the same way? Â Exampl=
e,
>>> namespace, how many of us actually uses it now when there is an
>>> alternative solution- subfolders - that we've been using since who
>>> knows how long. Â I don't know if threads was asked a feature prior
>>> namespace was implemented.
>>>
>>
>> Yes, you're right. But feature requests are not equal: some present a
>> bigger payoff than others, and some will be more problematic to
>> implement than others. If a given language can solve the problems it
>> meets based on it's current structure, should you necessarily
>> implement new shiny features, that may present problems?
>>
>> I'm not against threads in PHP per se ... I just haven't seen a very
>> convincing reason for them yet, which is why I'm not very positive
>> about the thing. The DB scenario could be handled without threads and
>> current libraries could be improved ... and as long as that's cheaper
>> than implementing threads, then - personally - I'd need to see more
>> powerful reasons for threads.
>>
>> Luckily, I have no say in the development of PHP, so I won't get in
>> anyone's way should they choose to implement threads :)
>>
>>
>
> Here's my analysis, let's say that you have 1000 requests / second on
> the web server. Â Each request has multiqueries which take a total of=
1
> second to complete. Â In that one second, how many of those 1000 arri=
ve
> at the same time (that one instant of micro/nano second)? Â You see h=
ow
> threads come in? Â If you have threads that are able finish the
> requests that come in that instant and able to complete them before
> the next batch of requests in that same second, wouldn't you agree
> then that you're delivering faster response time to all your users?
>
That sounds like your webserver spawning new processes dealing with
requests ... possibly combined with connection pooling and
asynchronous queries and load balancing, etc, etc. So no, I'm not
convinced that PHP with threads would actually deliver much faster
than a properly built setup that makes good usage of technology you'll
have to use anyway.
--=20
WWW: http://plphp.dk / http://plind.dk
LinkedIn: http://www.linkedin.com/in/plind
Flickr: http://www.flickr.com/photos/fake51
BeWelcome: Fake51
Couchsurfing: Fake51
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 25.03.2010 21:50:09 von Per Jessen
Tommy Pham wrote:
> I'm presenting the argument for threading. Per is presenting the wor=
k
> around using asynchronous queries via mysqlnd. I did read that link =
a
> few days ago, "Although the user can send multiple queries at once,
> multiple queries cannot be sent over a busy connection. If a query is=
> sent while the connection is busy, it waits until the last query is
> finished and discards all its results." Which sounds like threads ->=
> multiple connections to not run into that problem.
You must have read the wrong page. This is NOT about multiple queries,=
it's about _asynchronous_ queries.=20
--=20
Per Jessen, Zürich (15.1°C)
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 25.03.2010 21:53:08 von Per Jessen
Peter Lind wrote:
> I'm not against threads in PHP per se ... I just haven't seen a very
> convincing reason for them yet, which is why I'm not very positive
> about the thing.=20
Roughly the same here - I don't think threading belongs in PHP, but if
someone decides it's a good idea, I won't be arguing against someone
volunteering the effort.=20
/Per
--=20
Per Jessen, Zürich (15.7°C)
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 25.03.2010 21:55:55 von Per Jessen
Tommy Pham wrote:
> Here's my analysis, let's say that you have 1000 requests / second on=
> the web server. Each request has multiqueries which take a total of =
1
> second to complete. In that one second, how many of those 1000 arriv=
e
> at the same time (that one instant of micro/nano second)?=20
On average, exactly one per millisecond.=20
/Per
--=20
Per Jessen, Zürich (15.4°C)
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 25.03.2010 22:51:40 von Lester Caine
Per Jessen wrote:
> Tommy Pham wrote:
>
>> I'm presenting the argument for threading. Per is presenting the work
>> around using asynchronous queries via mysqlnd. I did read that link a
>> few days ago, "Although the user can send multiple queries at once,
>> multiple queries cannot be sent over a busy connection. If a query is
>> sent while the connection is busy, it waits until the last query is
>> finished and discards all its results." Which sounds like threads ->
>> multiple connections to not run into that problem.
>
> You must have read the wrong page. This is NOT about multiple queries,
> it's about _asynchronous_ queries.
The only problem here is what the database client can handle. If it can only
handle one active query, then that is all that can be used. It can be started
asynchronously and then you come back to pick up the results later, and so you
can be formating the page ready to insert the results. PDO requires that you
start a different connection in a different transaction for each of these
queries, but that is another hot potato. Running 10 asynchronous queries would
require 10 connections as that is how the database end works. Adding threading
to PHP is going to make no difference?
--
Lester Caine - G8HFL
-----------------------------
Contact - http://lsces.co.uk/wiki/?page=contact
L.S.Caine Electronic Services - http://lsces.co.uk
EnquirySolve - http://enquirysolve.com/
Model Engineers Digital Workshop - http://medw.co.uk//
Firebird - http://www.firebirdsql.org/index.php
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 25.03.2010 22:57:08 von Peter Lind
On 25 March 2010 22:51, Lester Caine wrote:
> Per Jessen wrote:
>>
>> Tommy Pham wrote:
>>
>>> I'm presenting the argument for threading. Â Per is presenting the =
work
>>> around using asynchronous queries via mysqlnd. Â I did read that li=
nk a
>>> few days ago, "Although the user can send multiple queries at once,
>>> multiple queries cannot be sent over a busy connection. If a query is
>>> sent while the connection is busy, it waits until the last query is
>>> finished and discards all its results." Â Which sounds like threads=
->
>>> multiple connections to not run into that problem.
>>
>> You must have read the wrong page. Â This is NOT about multiple quer=
ies,
>> it's about _asynchronous_ queries.
>
> The only problem here is what the database client can handle. If it can o=
nly
> handle one active query, then that is all that can be used. It can be
> started asynchronously and then you come back to pick up the results late=
r,
> and so you can be formating the page ready to insert the results. PDO
> requires that you start a different connection in a different transaction
> for each of these queries, but that is another hot potato. Running 10
> asynchronous queries would require 10 connections as that is how the
> database end works. Adding threading to PHP is going to make no differenc=
e?
Actually, this sounds very close to having 10 threads each opening a
connection to the database and running the query ... which was the
solution to the scenario presented, if memory serves.
> --
> Lester Caine - G8HFL
> -----------------------------
> Contact - http://lsces.co.uk/wiki/?page=3Dcontact
> L.S.Caine Electronic Services - http://lsces.co.uk
> EnquirySolve - http://enquirysolve.com/
> Model Engineers Digital Workshop - http://medw.co.uk//
> Firebird - http://www.firebirdsql.org/index.php
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>
--=20
WWW: http://plphp.dk / http://plind.dk
LinkedIn: http://www.linkedin.com/in/plind
Flickr: http://www.flickr.com/photos/fake51
BeWelcome: Fake51
Couchsurfing: Fake51
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 25.03.2010 23:04:34 von Tommy Pham
On Thu, Mar 25, 2010 at 1:50 PM, Per Jessen wrote:
> Tommy Pham wrote:
>
>> I'm presenting the argument for threading. Â Per is presenting the w=
ork
>> around using asynchronous queries via mysqlnd. Â I did read that lin=
k a
>> few days ago, "Although the user can send multiple queries at once,
>> multiple queries cannot be sent over a busy connection. If a query is
>> sent while the connection is busy, it waits until the last query is
>> finished and discards all its results." Â Which sounds like threads =
->
>> multiple connections to not run into that problem.
>
> You must have read the wrong page. Â This is NOT about multiple queri=
es,
> it's about _asynchronous_ queries.
>
>
That quote is comming directly from that link Peter Lind gave, which
I read a few days ago. Did you read it?
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 25.03.2010 23:10:33 von Tommy Pham
--001636284840caaff30482a75071
Content-Type: text/plain; charset=UTF-8
On Thu, Mar 25, 2010 at 3:04 PM, Tommy Pham wrote:
> On Thu, Mar 25, 2010 at 1:50 PM, Per Jessen wrote:
>> Tommy Pham wrote:
>>
>>> I'm presenting the argument for threading. Per is presenting the work
>>> around using asynchronous queries via mysqlnd. I did read that link a
>>> few days ago, "Although the user can send multiple queries at once,
>>> multiple queries cannot be sent over a busy connection. If a query is
>>> sent while the connection is busy, it waits until the last query is
>>> finished and discards all its results." Which sounds like threads ->
>>> multiple connections to not run into that problem.
>>
>> You must have read the wrong page. This is NOT about multiple queries,
>> it's about _asynchronous_ queries.
>>
>>
> That quote is comming directly from that link Peter Lind gave, which
> I read a few days ago. Did you read it?
>
Here's the entire description:
" pg_send_query() sends a query or queries asynchronously to the connection
.. Unlike pg_query(), it *can send multiple queries at once to PostgreSQL*and
*get the results one by one using pg_get_result().*
Script execution is not blocked while the queries are executing. Use
pg_connection_busy() to check if the connection is busy (i.e. the query is
executing). Queries may be cancelled using pg_cancel_query().
*Although the user can send multiple queries at once, multiple queries
cannot be sent over a busy connection. If a query is sent while the
connection is busy, it waits until the last query is finished and discards
all its results.*"
Any case, that's only workaround for mysql (mysqlnd) & postgresql. What
about those that uses other RDBMS?
--001636284840caaff30482a75071--
Re: Will PHP ever "grow up" and have threading?
am 25.03.2010 23:23:04 von Tommy Pham
  $dbconn =Â=A0pg_connect("dbname=3Dpubli sher") or=
 die("Could not connect");
  if (!pg_connection_busy($dbconn)) {
      pg_send_query($dbconn,=C 2=A0"select=C2=
=A0* from authors; select count(*)
from authors;");
  }
  $res1 =Â=A0pg_get_result($dbconn);
  echo "First call to pg_get_r esult(): $=
res1\n";
  $rows1 =Â=A0pg_num_rows($res1);
  echo "$res1 has $rows1 recor ds\n\n";
  $res2 =Â=A0pg_get_result($dbconn);
  echo "Second call to pg_get_ result(): =
$res2\n";
  $rows2 =Â=A0pg_num_rows($res2);
  echo "$res2 has $rows2 recor ds\n";
?>
There's the code example from that same link. You may have executed
the queries asynchronously, but the process of the results are still
serial. Let's face it, all of our processing of queries are not a
simple echo. We iterate/loop through the results and display them in
the desired format. Having execute the query and the processing of
the result in threads/parallel, you get the real performance boost
which I've been trying to convey the concept of serial versus
parallel.
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 25.03.2010 23:35:00 von Peter Lind
On 25 March 2010 23:23, Tommy Pham wrote:
>
> There's the code example from that same link. Â You may have executed
> the queries asynchronously, but the process of the results are still
> serial. Â Let's face it, all of our processing of queries are not a
> simple echo. Â We iterate/loop through the results and display them i=
n
> the desired format. Â Having execute the query and the processing of
> the result in threads/parallel, you get the real performance boost
> which I've been trying to convey the concept of serial versus
> parallel.
Actually, you haven't mentioned the processing as part of what the
threads do until now. I see your point though: if you split that part
off, you might gain some performance, that would otherwise be hard to
get at.
I wonder though, if the performance is worth it in the tradeoff for
the maintenance nightmare it is when you split out content processing
between 10 different threads. I wouldn't personally touch it unless I
had no other option, but that's just my opinion.
Anyway, I don't think either of us will change point of view much at
this point - so we should probably just give the mailing list a rest
by now. Thanks for the posts, it's been interesting to read :)
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>
--=20
WWW: http://plphp.dk / http://plind.dk
LinkedIn: http://www.linkedin.com/in/plind
Flickr: http://www.flickr.com/photos/fake51
BeWelcome: Fake51
Couchsurfing: Fake51
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 25.03.2010 23:44:56 von Tommy Pham
On Thu, Mar 25, 2010 at 3:35 PM, Peter Lind wrote:
> On 25 March 2010 23:23, Tommy Pham wrote:
>>
>> There's the code example from that same link. Â You may have execute=
d
>> the queries asynchronously, but the process of the results are still
>> serial. Â Let's face it, all of our processing of queries are not a
>> simple echo. Â We iterate/loop through the results and display them =
in
>> the desired format. Â Having execute the query and the processing of
>> the result in threads/parallel, you get the real performance boost
>> which I've been trying to convey the concept of serial versus
>> parallel.
>
> Actually, you haven't mentioned the processing as part of what the
> threads do until now. I see your point though: if you split that part
> off, you might gain some performance, that would otherwise be hard to
> get at.
Because in the past, when someone mention performance issues, the
replies come in with: is DB structure optimized, are queries
optimized, is the code optimized? For those in the field long enough
and have all that optimized and want additional performance boost,
what else are there? Thus, when I mentioned threads/parallel, I don't
mean execution of queries, but of everything in the entire app/project
where the gain is desired.
> Â I wonder though, if the performance is worth it in the tradeoff for
> the maintenance nightmare it is when you split out content processing
> between 10 different threads. I wouldn't personally touch it unless I
> had no other option, but that's just my opinion.
>
> Anyway, I don't think either of us will change point of view much at
> this point - so we should probably just give the mailing list a rest
> by now. Thanks for the posts, it's been interesting to read :)
>
Agreed. :)
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Re: Will PHP ever "grow up" and have threading?
am 26.03.2010 08:40:42 von Per Jessen
Peter Lind wrote:
> Anyway, I don't think either of us will change point of view much at
> this point - so we should probably just give the mailing list a rest
> by now. Thanks for the posts, it's been interesting to read :)
Most of it. +1
--=20
Per Jessen, Zürich (11.6°C)
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php