Taking a little break in my work today, I did some reading about yet another MVC framework that has exceptional performance yada yada yada. That framework is DooPHP. I'm pretty impressed with the performance actually though this is based on what they stated on their site. I couldn't get it to run on my system!
This prompted me to test against my idea of how an MVC approach should work. I ran apache bench (AB) against a fresh install of Codeignitor 1.7 as well as a local copy of Turbine Dump. I was only slightly surprised to find that the The Dump was a bit slower, but then it's connecting to a DB, performing sessions checking, and all kinds of other mumbo jumbo a completely written and functioning application would.
That said, I copied the app to a different directory and disabled all the bells and whistles. I was still doing all the needed includes, but instantiating nothing other then the base Pavelow factory class as well as the sessions class. Just enough (I felt) to have the Dump kick out a ye ole familiar "Hello World" line.
Benchmark time! I ran ab against each framework for 1000 request and a concurrency level of 5.
Now the good news is that the Harvested Framework I use (that i've been calling Leonidas) had an average test result of 4.20 seconds. Cool! 1000 returns from the site in 4.2 seconds? Yeah, I was feeling good.
Codeignitor (CI) turned out the same test with an average result of 8.58 seconds. Now this really isn't that bad when you consider two things.
1) Turbine Dump / Leonidas is actually a procedural MVC approach that relies on a OO Framework I wrote called Pavelow for it's DB, pagination, and error logging processes. CI OTOH is fully OO. That means a good deal of difference in instantiation overhead alone.
2) CI is about the best performing MVC framework out there with the exception of DooPHP (which or course prompted all of this). Others such as Symfony and Cake are positively behemoths. If you remeber or know what RISC and CISC stand for, Cake and Symfony are clearly CISC frameworks.
Anyway, I decided to start reloading and turning things back on to see how these affected performance. Here goes....
1) Just including Pavelow increased the average of the same test to 7.18 seconds! That's significant overhead for simply loading and parsing the files.
2) Including and instantiating the Pavelow Factory brought the test results up to 7.41 seconds.
2) Now it starts to get ugly! Adding the DB Sessions class alone (but no instantiation) shot the average test result up to 12.65 seconds!!!!! This doesn't even include instantiation. Just parsing overhead! Thankfully, instantiation overhead only resulted in additional 1 second (13.86 to be exact). And thankfully yet again, an op-code cache is going to kill this kind of performance penalty.
To put a point on how significant the penalty of the DB Sessions class is, my inclusion of it is essentially my including just one file. OTOH, when including the Pavelow core, it also includes 7 other classes! That said, the up front penalty of parsing all 8 classes is still far below that of DB Sessions. It really does look like I'm going to have to write a db sessions component into Pavelow.
But all of the above said, I can now see that if I ever formalize Leonidas into a package fit for distribution, it'll stomp the OO frameworks in terms of performance.
Saturday, October 31, 2009
Wednesday, October 21, 2009
A Song of Kings
I am I!
Alone in the night time of life
and hurdling forward
faster then all others
I entered alone
and shall die alone
I shall only live once in this earth
and die only once on this earth in this earth
so I shall rule this earth
till the end of this one time.
Alone in the night time of life
and hurdling forward
faster then all others
I entered alone
and shall die alone
I shall only live once in this earth
and die only once on this earth in this earth
so I shall rule this earth
till the end of this one time.
Monday, October 19, 2009
Business certainly is business
This is a rant about those of you doing web development. In particular those of "US" who code more then we design and like to work with others that do the design part. I'm sure there are a good number of you out there that are aware of what I'm talking. I'm also sure that fewer of you are fully aware to the fullest degree of just how much pain this can entail.
In my particular case, the issue has everything to do with being unequally yoked. LOL. I, the developer code geek type guy (yeah, right) working with someone that is a designer first, and in spite of whatever he claims to be after that, is still a designer. Now that by itself may not be such a bad thing, but we're not talking about "by itself here". We're talking about a semi-official business partnership where the result of our work is money right?
So let me just get straight to the heart of this issue. This guy doesn't know enough about anything to call himself a web developer or web designer. He just isn't . He can make some pretty pictures. I'll certainly give him that, but the buck stops hard right there.
You know what, I'm just just going to create a list of things that suck.
Moral of the story kids? Always make sure you are dead certain what you're getting in bed with.
In my particular case, the issue has everything to do with being unequally yoked. LOL. I, the developer code geek type guy (yeah, right) working with someone that is a designer first, and in spite of whatever he claims to be after that, is still a designer. Now that by itself may not be such a bad thing, but we're not talking about "by itself here". We're talking about a semi-official business partnership where the result of our work is money right?
So let me just get straight to the heart of this issue. This guy doesn't know enough about anything to call himself a web developer or web designer. He just isn't . He can make some pretty pictures. I'll certainly give him that, but the buck stops hard right there.
You know what, I'm just just going to create a list of things that suck.
- Knowing Dreamweaver DOES NOT MAKE YOU A WEB DEVELOPER!!!!!! This is by far the most important thing on this list. Positioning in this case is important.
- You don't start work until the specs and design are set in stone! Doing otherwise is nothing short of lunacy.
- The client has no business being able to screw around with stuff while you are building it. None whatsoever. All this does is send the signal to noise ratio through the roof.
- Nobody works on the code while the developer is building it. Doing so is, yup, you guessed it. Lunacy!
- Programmers DON'T TASK SWITCH!!!!! Expecting them to do so shows ignorance and a general lack of experience.
- If you made the design, YOU FIX IT!! Don't expect me or any other programmer that knows better to come back and try to dig through that Dreamweaver crap. It's your creation. Handle it!
- And don't ever try to tell a programmer how long things should take. For those of you out there that think web sites take two weeks, pull your head out of your arse. It's clear that you don't know enough to realize that you don't know enough. Those sites that have been thrown up in two weeks, all smelly and stuff, are based on huge, slow, kludges called frameworks. Very difficult to extend and they don't scale well. You won't find one site out there that is doing significant traffic and relying on crap like Joomla. And when I say "significant", I'm referring to sites that are running load balanced and fault tolerant clusters.
Moral of the story kids? Always make sure you are dead certain what you're getting in bed with.
Tuesday, October 06, 2009
The sow harvest gap
It certainly is a tough thing when you can see the goodness of things to come, but they aren't coming fast enough to help. I'm in this gap right now. It sucks!
Thursday, October 01, 2009
Juxtapositions
As low so high Elvaleethia
I chatted today with the Dragonfly
and hints of those old things reappeared
Paintings by those azure scopes
That starstruck glance
Those days will not come again
fleeting, watery, and long cherished
The sun caressing us
The ocean soothing us
The sand cradling us
I chatted today with the Dragonfly
and hints of those old things reappeared
Paintings by those azure scopes
That starstruck glance
Those days will not come again
fleeting, watery, and long cherished
The sun caressing us
The ocean soothing us
The sand cradling us
Wednesday, September 30, 2009
Funny that
Something that was said in this video....
... reminds me of how I felt when motorcycling.
"The things that appeared extremely important to you yesterday when you left your office will seem unimportant when you land your plane."
Friday, September 25, 2009
Thanx Bruce!
You know, it's becomming more and more obvious as I get older that a lot of the stuff I've learned from others, via publications of some sort, TV or online news media, or even just message boards or word of mouth, IS CRAP! Furthermore, it's consistent across knowledge domains as well. Programming, History or Geo-Politics, and even high performance engine development. We are most often started down a path or direction that is essentially a line of thought only to find that it's only part true and in some cases causes patterns of thought or understanding that is detrimental to further development or growth in that area. (Dayum brah!)
Ultimately, this boils down to the source of the information. This was really brought home to me in a big way just a moment ago while re-discovering my love for Artima.com (I'm not a Java guy, but good converstaion about coding is just plain good for you!) and reading a recent post by Bruce Eckel. In it, he explains succinctly what has been kind of hazy around the fringes of my thoughts via an experience he had. In short, his attitude about the language C++ was largely the
result of James Gosling and others responsible for the creation of the language Java.
... and ...
Accepting the fact that sometimes our information is tainted by the source, we have to then realize that perhaps there is something in us that causes to rest on what we've been given and follow it into the ditch so to speak. What
is it or why is it that we can't be open enough to at least re-appraise what it is we believe or have been told? Large swaths of our population as Americans suffer from this, as well as the entire world. I initially believed that is was simply a question of temperment (some being more open to introspection and self improvement) but I now for a fact that temperment and socialization play big parts in this. How many scientists or inventors have been hindered by Societies, Committees, or Councils with "The World is Flat!" type attitudes? How many of these have gone to their graves without their due honor thanks to these associations of clowns? If you really look into this, you'll find the number is pretty damn high and spread across a good many disciplines. Even war planning and doctrine suffered from this. General LeMay's insistence during WWII that daylight bombing with huge squadrons of B-17's and B-24's would continue to be the way forward was far from the truth. Especially considering that pilots that were actually doing the fighting came to realize that the job could be done with more efficiency and less loss of life by servicing more
targets with Fighter Bombers. This was the very recommendation of General Robin Olds and others during WWII that was scoffed at by the deaf "Flat Earthers", but later accepted as doctrine at a point later in time. How many lives would have been saved had LeMay and others just listened?
Obviously, collections of people that no longer question their knowledge sources are a detriment to society and human endeavor as a whole.
I've encountered this in the high performance community regarding Somender Singh's discovery that grooving quench pads in combustion chambers can dramatically increase turbulence and improve fuel burn to nearly 100% (!) with the side effects of engine oil lasting 5 to 10 times longer, no detonation, and lowered emissions. In spite of this being verified not only by experience from people like me that have actually tried it, but also independent engineers that have tested his claims and found them to be true, there remains a huge flock of derisive zealots that refuse to accept what has been found. In other words, they are clinging to some line of thought that is wrong REGARDLESS OF BEING PRESENTED WITH EVIDENCE TO THE CONTRARY!
This is a downright amazing thing to witness.
I can't help but wonder how much further along or how much things would be different if guys like Babbage, Tesla, Singh, Ataturk, Whittle, Olds, and so on, were listened too WHEN THEY ACTUALLY FIRST HAD OR DEVELOPED THEIR IDEAS.
Getting back on track, how does one avoid not letting themselves become closed to the truth, however it may come? Are you really honest enough to yourself to wonder if you have it wrong or believe it wrong? Do you dismiss other out of hand instead of really considering what is they say?
You HAVE TO BE AN ACTIVE PARTICIPANT in your quest for knowledge! It's a must. If you rest on what's been handed to you, I'm positive you'll find yourself in a ditch. Now this isn't to say that nobody is to be believed, but those worthy of your attention will suffer your questions. And even more so if they do it with a kind attitude.
Ultimately, this boils down to the source of the information. This was really brought home to me in a big way just a moment ago while re-discovering my love for Artima.com (I'm not a Java guy, but good converstaion about coding is just plain good for you!) and reading a recent post by Bruce Eckel. In it, he explains succinctly what has been kind of hazy around the fringes of my thoughts via an experience he had. In short, his attitude about the language C++ was largely the
result of James Gosling and others responsible for the creation of the language Java.
...many people jump to the conclusion that C++ was badly designed, which is far from the truth.
Java fed this perception with its cavalier attitude about language design. I've written about this in Thinking in Java and in many weblogs, so longtime followers already know that Java tweaked me the wrong way from the start, because of the dismissive attitude of Gosling and the language designers.
... and ...
I have no idea how much this formative experience with Gosling influenced my later feelings about his work, but the fact that the attitude about C++ was "we looked at it and it sucked so we decided to whip out a language of our own" didn't help.
Accepting the fact that sometimes our information is tainted by the source, we have to then realize that perhaps there is something in us that causes to rest on what we've been given and follow it into the ditch so to speak. What
is it or why is it that we can't be open enough to at least re-appraise what it is we believe or have been told? Large swaths of our population as Americans suffer from this, as well as the entire world. I initially believed that is was simply a question of temperment (some being more open to introspection and self improvement) but I now for a fact that temperment and socialization play big parts in this. How many scientists or inventors have been hindered by Societies, Committees, or Councils with "The World is Flat!" type attitudes? How many of these have gone to their graves without their due honor thanks to these associations of clowns? If you really look into this, you'll find the number is pretty damn high and spread across a good many disciplines. Even war planning and doctrine suffered from this. General LeMay's insistence during WWII that daylight bombing with huge squadrons of B-17's and B-24's would continue to be the way forward was far from the truth. Especially considering that pilots that were actually doing the fighting came to realize that the job could be done with more efficiency and less loss of life by servicing more
targets with Fighter Bombers. This was the very recommendation of General Robin Olds and others during WWII that was scoffed at by the deaf "Flat Earthers", but later accepted as doctrine at a point later in time. How many lives would have been saved had LeMay and others just listened?
Obviously, collections of people that no longer question their knowledge sources are a detriment to society and human endeavor as a whole.
I've encountered this in the high performance community regarding Somender Singh's discovery that grooving quench pads in combustion chambers can dramatically increase turbulence and improve fuel burn to nearly 100% (!) with the side effects of engine oil lasting 5 to 10 times longer, no detonation, and lowered emissions. In spite of this being verified not only by experience from people like me that have actually tried it, but also independent engineers that have tested his claims and found them to be true, there remains a huge flock of derisive zealots that refuse to accept what has been found. In other words, they are clinging to some line of thought that is wrong REGARDLESS OF BEING PRESENTED WITH EVIDENCE TO THE CONTRARY!
This is a downright amazing thing to witness.
I can't help but wonder how much further along or how much things would be different if guys like Babbage, Tesla, Singh, Ataturk, Whittle, Olds, and so on, were listened too WHEN THEY ACTUALLY FIRST HAD OR DEVELOPED THEIR IDEAS.
Getting back on track, how does one avoid not letting themselves become closed to the truth, however it may come? Are you really honest enough to yourself to wonder if you have it wrong or believe it wrong? Do you dismiss other out of hand instead of really considering what is they say?
You HAVE TO BE AN ACTIVE PARTICIPANT in your quest for knowledge! It's a must. If you rest on what's been handed to you, I'm positive you'll find yourself in a ditch. Now this isn't to say that nobody is to be believed, but those worthy of your attention will suffer your questions. And even more so if they do it with a kind attitude.
Thursday, September 24, 2009
The list grows
To the list of historical figures that can truly be considered great and worthy of mention, I must add Gazi Mustafa Kemal Ataturk. Talk about kickin' some arse, this was the man!
I'm sure most of you won't bat an eye reading this.
I'm sure most of you won't bat an eye reading this.
Monday, September 21, 2009
Some thoughts
There is never an excuse to do wrong.
Not a one.
If you feel the need to do wrong, it's compulsion.
If you feel you have a reason, you are lying to yourself
and it's just in you to do bad.
So if you plan to do bad, at least be honest about you're reasoning,
or what's driving you.
The other option is to stand up to what's wrong
because you're standing up for what's right. Perhaps it's not easier said then done, but it's worth the effort and it's worth it to not cause pain to yourself or anyone else.
Not a one.
If you feel the need to do wrong, it's compulsion.
If you feel you have a reason, you are lying to yourself
and it's just in you to do bad.
So if you plan to do bad, at least be honest about you're reasoning,
or what's driving you.
The other option is to stand up to what's wrong
because you're standing up for what's right. Perhaps it's not easier said then done, but it's worth the effort and it's worth it to not cause pain to yourself or anyone else.
Wednesday, September 16, 2009
I can't say what the Flabbergaster Eagle said, but....
...somebody shoot me please.
Turbine Dump top tip: Make sure business partners are on the same level of understanding and ability you are. IF YOU FAIL TO DO THAT at least take comfort in the fact that suicide is a way out.
And BTW you would be counselors, stewards of my well being, this is closer to the reason FB, and indeed everything, ****'EN SUCKS!
But alas, this is just frustration. A couple of rounds with the Planet Smasher and I'll be just fine. :-)
Turbine Dump top tip: Make sure business partners are on the same level of understanding and ability you are. IF YOU FAIL TO DO THAT at least take comfort in the fact that suicide is a way out.
And BTW you would be counselors, stewards of my well being, this is closer to the reason FB, and indeed everything, ****'EN SUCKS!
But alas, this is just frustration. A couple of rounds with the Planet Smasher and I'll be just fine. :-)
Friday, September 04, 2009
Soon
Ahh yes, this feels like a new dawning
It feels like some people just can't let go
It feels like I'm letting go
I'll soon be cut
Ahh yes, my spirit knows this is that true thing
That fighting thing
That breaking through the shell that all plants must do
I'll soon be lean
Ahh yes, the morning is nigh
And after a long eve of labor
And after a long eve of resolution
I know I'll soon be good
It feels like some people just can't let go
It feels like I'm letting go
I'll soon be cut
Ahh yes, my spirit knows this is that true thing
That fighting thing
That breaking through the shell that all plants must do
I'll soon be lean
Ahh yes, the morning is nigh
And after a long eve of labor
And after a long eve of resolution
I know I'll soon be good
Thursday, August 20, 2009
Home
My home is high and bright
Distant
A speck in the Azure and cumulous
I long to be there
Alone as I have always been
And always will be
In this Earth
And in this aeon
The love I seek is the next age
After the planet stops
And things vibrate anew
And all complexities are held on high and cherished
Distant
A speck in the Azure and cumulous
I long to be there
Alone as I have always been
And always will be
In this Earth
And in this aeon
The love I seek is the next age
After the planet stops
And things vibrate anew
And all complexities are held on high and cherished
Friday, July 10, 2009
Historical lessons un-taught
My meanderings into history and various historical figures in particular seems to suggest that not all populations are READY for the positives these figures bring. But of course, we are too mired in the quagmires of political correctness and the divisive self interest of almost all sub-groups whether they be social, ethnic, religious, or political to accept long term positive change, much less recognize it when we see it.
But hey! What do I know?
But hey! What do I know?
Tuesday, June 23, 2009
Simon in Peru
When a man writes is it with the intent that it will be remembered in time? Is this the reason a man writes? I've never believed that. However, I should qualify that statement, or perhaps restate it and say "I don't believe that a man who writes only to be remembered will ever write something worth remembering!"
That said, I am always moved when I read something worthy of remembrance. I recently came across the below while reading of Simon Bolivars' trials in Peru. He was obviously in a rather dark place and managed to express his feelings in a way that's just plain amazing, tho it may be a bit loquacious for modern tastes. ;-)
Feel free to return to your romance novels now.
That said, I am always moved when I read something worthy of remembrance. I recently came across the below while reading of Simon Bolivars' trials in Peru. He was obviously in a rather dark place and managed to express his feelings in a way that's just plain amazing, tho it may be a bit loquacious for modern tastes. ;-)
Until now I have fought for liberty: in future I will fight for my glory, no matter what it costs. My glory now consists in ruling no more and in thinking of nothing but myself: I have always had this intention but it increases progressively by the day. My years, my ill health, and my disillusion with all the dreams of youth prevent me from taking any other way. The presence of another person kills me: I live amongst the tress of this miserable place on the coast of Peru and I have become a misanthrope overnight. But you must understand that I am not depressed, and this loathing for people and society does not come from a physical cause or from an personal trouble, but from a conviction deep within me. Ambition, says Rousseau, guides men when they reach the age of forty, and I have reached that age. But my ambition has died. I have nothing to hope for and everything to fear. Observe the breakdown in human affairs. At all times the works of men have been ephemeral but in our day they are like the emerging embryo that dies before it even develops. On all sides I hear the sounds of disaster. My ear is one of catastrophes. Everything comes life and dies before my eyes as though struck by lightning. Everything passes and I would be a fool to flatter myself that I can stand firm in the midst of so many upheavals, in the midst of so much destruction, the the midst of the moral subversion of the world. No, my friend, that cannot be! Since death has not decided to take me under it's protective wings, I must hurry to hide my head in the midst of oblivion and silence, before I am struck by blows from heaven and reduced to dust, to ashes, to nothingness. It would be madness on my part to watch the storm and fail to take shelter... Everyone falls, struck by be disgrace, or disaster. Can I remain standing? Impossible. I too must fall.
Feel free to return to your romance novels now.
Saturday, June 13, 2009
And yet more bad code!
I guess it really doesn't matter where the code comes from or how high tech their name sounds. Most of it is just plain bad! I'm now staring down the pipe of more headache with an absolutely terrible code base that reads like a collection of ALL of PHP's (and development in general) bad practices.
Coding is the one place where all of it's practitioners need to be like Monk. That's because all code needs to be well ordered, commented, and laid out. Otherwise, nothing is efficient and nothing is easy to work with. When your guests come over and need towels for the shower do you just say, "Oh they're somewhere back there" with a dollop of uninterested hand waving? More often then not (assuming you care), you tell them where they can find it. Even it it's just "In the closet next to the bathroom", it's a good bet that your closet (once again assuming you actually care) is well ordered enough that Jane Guest can just open it and quickly grok what's going on.
Now I don't claim to be the best or know the most (but I do like my stuff!) but perhaps I should start charging what some of these tossers are for chucking out that crap code. After all...
a) The cream rises to the top.
b) In order to be cream, you must first believe you are cream!
OK.... End rant.
Coding is the one place where all of it's practitioners need to be like Monk. That's because all code needs to be well ordered, commented, and laid out. Otherwise, nothing is efficient and nothing is easy to work with. When your guests come over and need towels for the shower do you just say, "Oh they're somewhere back there" with a dollop of uninterested hand waving? More often then not (assuming you care), you tell them where they can find it. Even it it's just "In the closet next to the bathroom", it's a good bet that your closet (once again assuming you actually care) is well ordered enough that Jane Guest can just open it and quickly grok what's going on.
Now I don't claim to be the best or know the most (but I do like my stuff!) but perhaps I should start charging what some of these tossers are for chucking out that crap code. After all...
a) The cream rises to the top.
b) In order to be cream, you must first believe you are cream!
OK.... End rant.
Friday, June 12, 2009
Thursday, June 11, 2009
Monday, June 08, 2009
Wednesday, June 03, 2009
More bad code woes
And it's not my code this time either. I've been working with Opencart on the behalf of a client and it's really turned out to be a pain in the arse. Much more so then I expected. I initially thought it was fantastic by virtue of it's MVC approach, but jumping into it has really left scratching my head in areas.
But rather then really go in to details, I'm going to complain about one thing that makes less sense then any of the other odditities. In particular, it's how it handles options for products and especially how it updates them. The update method in the model actually deletes the rows in the database then re-inserts all of them regardless of their being any changes. This is an extremely brain dead algorithm and makes extending the feature a trip to hell.
Oh well. Life is going to suck for the rest of this evening.
But rather then really go in to details, I'm going to complain about one thing that makes less sense then any of the other odditities. In particular, it's how it handles options for products and especially how it updates them. The update method in the model actually deletes the rows in the database then re-inserts all of them regardless of their being any changes. This is an extremely brain dead algorithm and makes extending the feature a trip to hell.
Oh well. Life is going to suck for the rest of this evening.
Subscribe to:
Posts (Atom)
