inicio mail me! sindicaci;ón

Archive for March, 2007

Thoughts on PHP

I had lunch today with Terry, we discussed a bunch of things. Many points and counter points were discussed.

One thing that I’ve known for a while and (he’s known for even longer), that I’ve wanted to say is this:

if you have to develop for the web, and you don’t know PHP, you should change that

I’ve used Rails, Java, Python, Perl, and maybe a few others for web development. These projects were prototypes, working projects, or simple hacks. In my experience, PHP has the best architecture for web apps that need to be up and running quickly and then stay up. It runs on just about any inexpensive hosting provider out there. If you put a tiny amount of effort in, it can even scale really, really well. If you want a great example, go check out this billion dollar company. Still not impressed, why not check this site out as well. They are using the same PHP that you have. Need another… how about this site.

The reason this is the case is because PHP was designed to work hand in hand with Apache. The multi-process,+shared nothing architecture wins versus the multi-threaded+stateful dead-end that people continue to follow. I could go on about this (and I think I already did in an older blog post). In a nutshell, shared memory, long running multi-threaded instances end up with all sorts of nasty problems (scheduling issues, dead-locks, containment/failure-isolation, non-linear performance, etc.). The PHP architecture nudges the developer down a path that has the right balance of interface, logic, and persistence. PHP apps will not fail due to resource leakage or heap bloat that long running instances end up with. It isn’t the huge nightmare to hosting providers that other systems are. PHP apps will have a consistent and predictable performance profile. When they do fail (process limits, IO limits, database limits), you can generally just add more hardware at the right layer and scale up. Now, granted, scalability gets more complicated and we can get into queuing models and yada yada, but I think you get the point.

Compare that wiith every other web-app platform that trys to keep some multi-threaded instance running to handle requests (Rails, Java, and Python, etc.). They all have their issues. In fact, I would say that the #1 problem for rails is still that they don’t have a clean, simple, and scalable platform. Mongrel is still not the answer… it is just the best answer.

Another interesting point about PHP which has been true for as long as I can remember (which Terry brought up first). If you can think of an app, it has probably already been written in PHP. Why write a forum system if you can just get vBulletin? Why write your own Digg when there are 3 clones already out there? PHP has a tremendous supply of working code, ready to run.

That reminds me of another popular, high traffic site that everybody uses every day.

So, just to recap before people take this the wrong way:

  • I still love Ruby on Rails quite a bit. It was my first choice at BrightRoll and it was the right choice.
  • I think PHP is excellent at what it does, and would use it even now for simple projects.
  • PHP has issues and criticisms. However, I think the negatives and criticisms for other systems are larger for other systems (think Java or .NET)
  • All of the above still works even for not-so-hot developers. Don’t believe me, just look at the code for some popular PHP apps :-)
  • I think all web developers should learn and understand PHP regardless of what they decide to use If you are choosing to ignore it then you may be going down the wrong path. Why would you want to do that?
  • ALSO, mad props to JackH for pointing out “I think there is something there with this PHP stuff”. His input got me to really look at that tech.

Absolut Art

I smell a bail-out

Today, after the huge draw down on sub-prime lenders, I saw this WSJ article titled:

Goldman Goes Hunting In Battered Loan Sector After a Record Quarter

Hmmm…..

Lets see Hank Paulson, ex CEO of Goldman is in the Treasury.

I smell a bail-out

I’m betting, that just like in the past, the Fed is going to bail-out the big boys (aka friends of the Treasury). Otherwise, why would Goldman eat the risk? How could they feel so sure that there is money there.

Yeah, there isn’t a precedent for this is there? I mean Dick Cheney didn’t give Halliburton any favors, RIGHT???

Vista - The Wow Does Not Start Now

I’ve been watching the Vista release lately.

So far, the execution doesn’t look good.

Here is what I’ve picked up so far:

  • Balmer pulled analysts aside recently and said they will not be meeting expectations. This is telling. I suspect that most corporations are not considering the switch at this time.

  • Evidence from friends tells me that it is not quite baked. Lots of driver issues are common and the overall performance is not stellar (sluggish UI, lots of memory leaks)

  • Dell still doesn’t have support for it on their high-end boxes (the XPS gamer boxes)

Unless I have a pressing need for Vista come up, I can wait 6 months. I wouldn’t risk the big switch at this time. This one needs to sit in the oven a little while longer.

Cel - Web site is back up

A fellow Self enthusiast from France expressed interest in Cel, the prototype-based OO language I created a few years back. I believe he is interested in making a language himself. The web site has been down for years so I promised that I would get it online this weekend.

So, here it is

I don’t intend to spend much time on the language, I’m don’t have the language bug right now. However, it might get a few bug fixes or updates.

Corvus




     *
           *
               C O R V U S    S Y S T E M S

            *       CONSTELLATION  II

      *
             *


Excellent GreaseMonkey Script for Gmail

Recently, I’ve taken the time to learn the keyboard shortcuts in Gmail. If you learn them, you can essentially process your mail purely through the keyboard without having to touch a mouse. As a bonus, they don’t stray to far from good ole vi with ‘j’ and ‘k’ being the down/up keys.

I was feeling productive, but I noticed that I was missing the most important shortcut of all. The Delete key or Trash key. I immediately thought of GreaseMonkey and searched google. Sure enough, someone created a userscript that has the ‘d’ key for the move to trash operation.

Now I can completely process my email with just the keyboard at a much faster pace.

Great Story About A Symbolics Lisp Machine

I read this blog post about a symbolics Lisp Machine and couldn’t help but smile