How I learned to stop lighting the LAMP and embrace Amazon Elastic Beanstalk

Posted on Posted in Uncategorized

Over the years, whenever I’ve wanted to hack together a quick project or web test, I’ve turned to LAMP, the “easy to use” web stack featuring Linix, Apache, MySQL, and PHP or Perl. Well that part of me is dead now that I’ve discovered Amazon Elastic Beanstalk, part of the AWS suite.

The days of my PHP and Perl proficiency are long gone and these days, I’m much more comfortable in Java so Tomcat is now my go to web server. But setting this up is still a pain. I mean it’s comparitively little when judged side by side with setting up a LAMP stack, including setting up all the necessary Apache modules, configuration, and debugging via log statements, I still have nightmares about editing http conf files. Interpreted languages are great for fast iteration, super easy changes and testing, and good flexibility, but trying to figure out why your dictionary has somehow become a reference to a list of scalars is about as fun as explaining what that means to your parents. It can even make debugging an invalid pointer in C or finding a memory leak seem like a walk in the park. For these reasons, plus the fact I use it day to day, Java is the go to for me. Plus, once you’ve coded with a strongly typed language in a decent IDE like Eclipse (less so with each release) or the increasingly awesome IntelliJ, you won’t want to do your develokment in Vi any more.

So why is Elastic Beanstalk so awesome? Can’t I just set up a Tomcat server myself and begin enjoying sweet web development nirvana you may ask? Not so fast grasshopper. You still have to fight the digital equivalent of a Chinese finger trap that is configuration. For as the great Buddha has told, “port is already in use”.

Elastic beanstalk gives you all this stuff to begin with, plus a brain dead installation and configuration approach that requires Amazon’s famous one click approach to everything. Want to set up a new server with a simple servlet or jsp page? One click in the awesome Eclipse AWS plugin. Apparently Intellij has this also but I haven’t had a chance to play with this yet. 

Want to test your cool new page? One click to deploy it to a local web server for testing, see it in either the IDE or the browser of your choice. Looks good, ready to deploy to prod? One click. Let me reiterate that again. It takes one click to deploy your server to a production instance. Bam, customers are happy with your changes you made at 2am and didn’t have to wait 2 days for your home built deployment solution to kick in. Need more hosts as your customers are telling others and your site is growing. 0 clicks, this is AWS baby and that is automatic! With this, you can spend time actually working on improving your site and features, not hacking build and deployment scripts. Think of how that will change your life.

Wait, isn’t this an old offering that has been around for years, you ask? Where were you 2 years ago when I spent 3 days setting up a Perl server and writting hello world just to test something, I respond. Well now I know about it and I won’t go back.