Break Through Server-side Bias and Surrender to Javascript

You have a server-side bias and you don’t even realize it.  I know this, and you need to know this.  It’s keeping you back a bit. Step one is to admit that you have a problem and that your addiction to easy server-side frameworks is ruining your performance.  You’ve used frameworks like Rails, Django, WordPress, or one of several hundred Java web application frameworks for years and you are resisting this move toward Javascript.  Yes, you’ve “embraced” Javascript throughout your applications, but you might be missing the larger point – Javascript isn’t here to make your server-side applications more “reactive”, it isn’t just a nice feature to add to a larger application.

That Javascript you keep on insisting to serve from your server-side framework…that is the application.  It’s taking over.    Your server-side framework won’t be doing anything resembling templating in a few years because that’s the job of the browser.  Yes, yes, you might have a few “high value” pages or pages that have to be hosted on a server because of security constraints, but if your web site requires a round-trip to a server to render a web page… well that’s old people thinking.

The “geographical center” of your application is no longer on the server-side.  You shouldn’t start your application thinking about what server-side framework it is going to be based on, because it won’t be based on a server-side framework.   In fact, you may use many, but they will only serve to support what will essentially be a client-side Javascript application.

I understand how you feel, you might read this and think – “No, we’re not moving everything to client-side Javascript frameworks, no.”  The willful ignorance you are embracing here is a defense mechanism.  As a Java developer in the middle of the last decade.  I saw the next generation using PHP and Ruby and I tried to explain it away for a few years as just a passing fad.  It wasn’t, and I still see a lot of developers in my age group reflexively resisting dynamic languages.  Resisting change is a mistake – you’ll be obsolete before you can say, “Wait I didn’t realize that the browser could do…”

With the rise of ReactJS, AngularJS, Backbone, and a number of other good client-side Javascript frameworks I’m seeing a new kind of bias – server-side bias.  There are people out there who, for whatever reason, be it ignorance or otherwise – these people fail to realize that the days of having some dynamic templating engine on the server-side merge your data with some HTML… those days are coming to a swift conclusion.   It was fun while it lasted, but this “mail-merge” approach to retrieving a row from a database, packaging it up in some object, and then “merging” it into a template.  The view layer of this is moving client-side, quickly.

And, it’s moving to the client because it’s an order of magnitude faster to serve what is essentially a static AngularJS application from a CDN than it is to muck around with serving the same from some server-farm (even with the help of memcache).  That’s the thing, once you start doing this you realize that you only really need a server-side framework for API calls.  That’s really it.  All your server-side frameworks are doing in five years time? JSON, and maybe futzing around with a few databases.

Don’t get me wrong, there will be people writing Rails RHTML and Java JSPs for many years to come much in the same way that COBOL developers still run systems packed away in government data centers.    But, Ruby and Java developers that fail to embrace this client-side Javascript trend will find themselves confined to internal applications – the Oracle Forms of 2020 is Ruby on Rails.

A Web Developer from 2001 Wouldn’t Even Recognize this World

I work with people much younger that I, but the reality I’m discussing in this article is really just 12 years ago. It feels like another era entirely. This is especially true if you develop anything that touches the web.

When I started my career it was all about web applications that involved full round-trips to a server. You had a browser (or a WAP phone), your browser makes a request for a web page, waits a few seconds (a few seconds!) and you get a fully assembled HTML page in return. It didn’t matter because the Web was still so full of novelty we were just happy enough to be able to do things like read the news online. Maybe your local newspaper had a website, most likely they didn’t. There was no YouTube. Web pages weren’t really connected together in the way they are now. Back then it wasn’t like loading TheStreet.com required a bunch of asynchronous calls out to social networks to populate Like buttons – there was no social network. It was just HTML and Images, and it took forever. It was fine.

My first two jobs were developing an in-house cross promotional tool for an online gaming company named Kesmai in Charlottesville in 1997, and then I moved to New York to work for TheStreet.com in 1999. Web “applications” at that time were just an inch beyond putting some scripts in cgi-bin. At Kesmai it was Perl-based CGI scripts. Between Kesmai and TheStreet I was working on systems that used a proprietary Netscape server product. And, at TheStreet.com we were using Dynamo behind Apache, so we had JHTML and Droplets and that was my first encounter with a site that had to scale. We had a TV show on Fox and maybe something like 600-700 people could use the site at the same time. (Again, that was huge back then, how times have changed?) Everything was template-based, servlets were around, maybe, but I don’t really remember diving into the Servlet API and JSPs until Struts came along maybe in 2001.

Back then, companies like Forbes.com, which I moved to after TheStreet.com, invested a crazy amount of money in hardware infrastructure. There was still a lot of proprietary software involved in the core of a web site – expensive CMS systems, etc. Open source was around, yes – we ran Apache, but it isn’t like it is now. You likely paid a hefty sum of money for a large portion of your production stack. Around 2001 and 2002, a small group of people were starting to focus on speed, and the way you achieved speed at scale back then? Drop a few million on a couple of big Sun servers. It worked. It seems old-fashioned now, but as a developer I’d work with the operations team (then as now, the operations team didn’t know much about Java), and you’d help them size heaps and figure out how to make the best use of 64 GB of RAM on a E450. You’d run multiple JVMs on the thing, someone might install something like Squid to cache things at the web layer.

Back then, you could touch the servers. They were shipped to your offices. Companies like Sun and SGI invested a lot of money to make servers look all fancy. These things were purple they had blue LEDs (remember high-brightness blue LEDs were, at one point, really new to us all). I remember seeing advertisements for servers in programming magazines. Now if you look back at these, it’s as strange as seeing an advertisement for a station wagon in a National Geographic from 1985. These days, I don’t even know who makes the hardware that runs the sites I work on, and with the exception of the database server, I don’t even care if it is even a physical machine. Back then it was like everybody getting all excited about the E4500 that was in the foosball room.

There was no memcache, there was no AJAX, there was no AngularJS, there was no REST, SOAP was new and you probably didn’t use it yet, there was no Google Analytics, remember, Google was still a tiny startup at the time. I remember having a discussion about Ruby in 2001 with a colleague who was excited by it, but Rails didn’t exist yet. Perl and PHP were around, they’ve been around forever, but you really weren’t confronted with systems that spanned several languages. Javascript was around, but you probably weren’t going to dare use it because it wasn’t like there were any standards between browsers. HTML5, huh? This was back when people still used the blink tag. Need to crunch a huge amount of data: well first of all, huge is relative and you didn’t have things like Hadoop. Just didn’t exist yet. Big Data? Yeah, back then if you had 5-10 GBs you were running a huge database. Huge. XML was still a really good idea. Flash was about to really take off.

If we could travel back in time and snatch a web developer from 2001 and drop them into 2013, they’d flip out. They’d look at your production network and wonder what happened. We’d have to tell them things like, “you’ve missed a bunch of things, this kid at Harvard created a system to keep track of friends in PHP and that changed everything. Google now runs the world. Also, the site ‘Dancing Hamster’ isn’t what it used to be.”

I look at people that started working in 2007 or 2008 and I think about how strange it is that none of this is new – because I’m still living in 1993. I’m still amazed at the functionality of Gopher in 1993.

And you can thank Mark Smith for this YouTube video…

Top 10 Phrases at Work: November 19, 2012

This is a list assembled from a scientific poll of 2 million “knowledge workers” conducted via the Information Super Highway.   On November 19, 2012, these were the top 10 phrases uttered in a business setting:

  1. “Is that me or you?”
  2. “Why don’t you try closing some apps?”
  3. “How many people in the office are using Spotify right now, WTF?”
  4. “It isn’t me, I’m on a wired connection.”
  5. “I think it’s you, I just had a great conversation without any of these problems.”
  6. “Maybe we should try Google+?   Are you on Google+?”
  7. “How the hell do I start a Hangout?”
  8. “Do I have to be in this meeting?”
  9. “Can you just call my cell?”
  10. “Ok, my cell signal is very spotty.  Can we move this meeting to email?”
  11. “Do they really want me to fax this to them?”
  12. “Do you know if we even have a Fax machine?”
  13. “Do you have a second, I need someone to show me how to use the Fax machine?”

And, my favorite:

14. “What timezone did you schedule this meeting in?”

Before we get started…

Note: This is another fictional conversation. It isn’t intended to represent any recent conversation. If you recognize parts of this conversation that might remind you of conversations you’ve had with me recently that it isn’t any coincience. Wait, it is a coincidence. Hold on. If you start recognizing something in this post, stop reading it…. Really though, I like PR people, most of them, but a few of them, well…

Me: “Ok, great, so finally we’re all on the conference call line.”

A polite, robotic British woman interrupts: The conference will now be terminated.

Me: “Hello.”

(Silence)

Me: Was it something I said?

(Kenny G starts playing, the phone line is full of highly produced Soprano Sax)

I hang up and call back. A polite British woman asks me for a conference ID. I fumble around trying to find the right browser tab in a stack of 100 on my several desktops. I struggle to switch between Skype, Google Calendar invites, and the numeric keypad on my screen. It takes several attempts to finally convince the polite, robotic British woman that I have the proper conference ID.

Others in a large conference room: “Hello? Who just joined?”

Me: “It’s me again, surprise. So what happened?”

Note: A journalist never talks to a company directly, there’s almost always a PR minder on the phone to ‘manage’ the conversation.

PR minder: “Yes, I’m sorry. I accidentally clicked the End Meeting button. You know what, I really hate this web conferencing service…”

Me: “…right the old, ‘blame it on the conferencing system’ game. If they ever remake Office Space, you’ll be the character that takes secret glee from ending conference calls at random. Can we get started?”

PR minder: “Ok, before we get started, I need to remind you that the information delivered today….”

I interrupt, sounding a little frustrated: “…the information being delivered today is covered under an embargo, not because it’s really that secret but because you are trying to get all these technology news outlets to publish the same boring story on the same day. Even though at least one of these news outlets is going to “accidentally” leak the information on some blog a few days early. I know, don’t worry, I’m playing your game. But, understand that this whole thing is silly.”

PR minder: “You don’t have to be a jerk about it.”

Me: “I don’t, you are right. Between you ending the conference call and this little preamble about being under embargo, I’m ready to just call it a day. Can we get started?”

PR minder: “Ok, today I’d like to introduce….”

PR minder proceeds to introduce seven people who will somehow all talk to me about how awesome their product is in the next 10 minutes. When I say “introduce” I mean it, she’s practically reading a CV for each and talking about how pivotal they were at seriously successful company XYZ. I can’t tell if she’s trying to impress the client or me, but 8 minutes pass.

She concludes with: “Ok, you mentioned that you had already read the presentation and you wanted this to be a Q+A session, but I think our COO still wanted to go through his full presentation.”

Me: “Well sure, I mean we’ve got 12 minutes left at this point, so why don’t you just read the slides I’ve already taken copious notes on. Why don’t we just dispatch with the idea that journalists can do background research and that smart ones might have questions.”

PR minder: “Maybe this isn’t going to work out.”

Me: “Maybe, or maybe we would have made more progress without you.”

Me: “You know, I have a good idea. Why don’t you just pretend I’m not here, I’ll put my screen on record, go get a cup of coffee, and then I’ll get back just in time. At the end of the presentation I’ll say, ‘Wow, that’s some impressive stuff you’ve got going there.'”

PR minder: “I think we’re done.”

Me: “Are we? Let’s ask your client. Charles, I see you used to work for Oxycorp doing CMS work. Is your new product an attempt to build upon the success of your last company? You’ve been working on this idea for 12 years, right?”

Jim, from Fancycorp: “Actually that’s a great question. We’ve been talking to reporters all day and no one’s made that connection. Yes, this product is where I would have taken Oxycorp had I continued to work on it.” He proceeds to talk about his history and motivations for a few minutes.

PR minder: “We should move on to the demo.”

Me: “I’ve seen your demo, one of your marketing partners leaked it on the internet months and months ago. I watched it, I passed it around to a few other people. Your secret’s been out for quite some time.”

PR minder: “Wait this information is under embargo, you can’t….”

Me, interrupting: “I have a strong ability to not give a crap about your embargo. But, I’m not going to publish anything until your magic date. Don’t worry.”

(Silence)

Me, continuing: “Jack is in the room, he does your developer outreach. I’ve been watching you tweet about this stuff for a year. You’ve developed a huge following of users that also use your competitor’s software. Do you think you’ll have an issue once this is launched.

Jack, from Fancycorp: “Interesting, this is not an ordinary interview the last person we spoke to didn’t even know what CMS stood for, you probably know the name of my…

Me, interrupting: “…your son, Jack, yes. Congratulations, I saw you tweet the photo from the nursery. I cover your company, I keep up with your tweets.

Jack, from Fancycorp: “Ok, can I ask you a question, why don’t you follow our corporate Twitter account?”

Me: “Your corporate Twitter account is full of boring announcements and retweets of your company blog. Your feed is much more entertaining and you throw in the occasional curse word. I learn much more about Fancycorp from your feed than that corporate announcement stuff on your corporate Twitter….

PR minder: “I manage that feed and for the record we have over 6500 followers. Our tweetreach is…”

Me: “…your tweetreach is a million unicorns and meaningless. You got most of your followers from an automated follower robot script. You have 6500 followers and you also follow 6500 accounts. That’s a signature of Twitter desperation.”

Me: “It’s been great, but I don’t have enough to work with to write a story. Can you guys call me back when you’ve found a new PR person. I’m on Twitter, just DM me.”