AurosBlog

Technical Blog

Working for The Man? Advice to a young programmer

Working for Google is full of surprises. When I first arrived I started to get to know my office-mate. He’s a laid back, rather cool but studious-looking guy with longish hair. I asked him what he did and learned a lot about how students were taught parallel processing in a cluster environment. Politely he responded with the same question and I started to tell him about Samba and what I was currently working on. “You remember around 1988 when AT&T came out with a file-sharing protocol called RFS (Remote File System) to compete with NFS (Sun’s Network File System)…” I continued.

“I was eight years old in 1988,” he replied.

After I’d finished checking for obvious facial wrinkles in the bathroom, I decided to go on a quest to find other engineers in the building who were at least as old as I was, and felt much better when I found some. But it set me thinking about what kind of advice I would give if I could meet myself at his age, in order to guide the young Allison into a promising engineering career. So, in the best spirit of “The Screwtape Letters,” here is some of what I’ve learned so far about making yourself a career in writing software.
If it’s not what you love, don’t do it

I’ve worked with many programmers during my career. Without a doubt, the only ones who are any good at it are those who see writing code as art, a creative process. I know it’s an obvious lesson, but it’s really important. If you want to make lots of money and retire early, don’t start by writing software; learn about business and start a company instead. I’ve run into so many poor programmers, in both senses of the word, who got into the field because they “wanted to be the next Bill Gates.” Bill Gates didn’t get rich by programming, he got very rich by being very good at running a company. I’ve had to fix code created by these people and it isn’t pretty. Eventually they usually move into management where they might have a chance to find their true calling.
Learn the architecture of the machine

Many programmers, especially those who write for virtual machines such as Java or the .NET CLI, think that low-level machine architecture and processor instructions don’t matter anymore. That’s still not true, and I don’t believe it ever will be. Someone who understands what the machine is really doing underneath all the modern layers of glop such as virtual machines, garbage collection algorithms, network and threading abstractions, will always be able to solve problems better than someone who lets the compiler or the “execution environment” they’re using make all the decisions for them. These days the effects of processor caches and memory bandwidth mean that it’s even more important to understand the lower levels of computer architecture than it used to be in order to be a good programmer. The good news is that modern tools like the amazing free software tool “valgrind” can emulate an entire processor in software and make understanding what is going on at each line of code as simple as looking at a visualization of execution time. Using resources efficiently matters when you’re dealing with modern clusters containing thousands of machines.
Reputation is important

The days of starting at IBM after college and working there in obscurity until you retire are long gone. Any modern programmer will move between many companies in his or her career. It is very important to be able to show your next employer what you have done, and what you are able to do in a team. Free software/open source is the ideal way of doing this. It’s not just a better way of producing software, it’s actually better for the reputation of the people creating it. One of the first things I do when evaluating someone is to look for samples of their code out there on the Internet. If you work on proprietary software you can’t show anyone anything, and real code speaks louder than any list of projects you claim to have worked on.
Proprietary environments are a trap

I used to be a Microsoft Windows programmer, as well as a UNIX/POSIX programmer. The knowledge I’ve gained about programming POSIX is still useful, even though I learned a lot of it over 20 years ago. My Windows knowledge is now rather out of date, and getting more so over the years. It isn’t worth my time anymore to keep up with each increasingly baroque change to the Windows environment. Just as an example, over this time the latest “hot” communication paradigm that Microsoft recommended developers use in Windows changed from NetBEUI, to NetDDE, then OLE, followed by OLE2, then COM, DCE/RPC, DCOM, and now currently seems to be Web Services (SOAP and the like). Meanwhile, in the UNIX world the Berkeley socket API was useful in the 1980′s and is still the core of all communications frameworks in the open standards world. All the UNIX RPC, object and Web Service environments are built on that stable base.

Learn as much about the proprietary environments as you need to be able to help people port programs over to open standards. You’ll never be lost for work. The same is true of any proprietary environment, not just Windows. Windows just happens to be the one I know best. What will get very interesting in the future is the effect a fully open Java platform will have on the software environment in the next 10 years. After initially ignoring Java due to its proprietary restrictions, I now believe Java and its associated libraries have the potential to be the next POSIX.
The network really is the computer

There are now no interesting non-networked applications. Standalone computers are devices for watching stored video or listening to music, usually on airplanes. People doing offline email are simply working in an extreme case of a network disconnect, a rather large network latency if you will. The Internet has become the real computing environment of the next century and all programming will become network programming. This is a more challenging environment than programmers have been used to, with connection, latency and concurrency problems making our work much more interesting than it used to be on the standalone DOS box. All entertainment and communications such as television, radio and the telephone network will move onto the Internet. Poor Sun Microsystems were 20 years too early with their “the network is the computer” slogan, but they will eventually be proven right.
The community is more important than your employer

Are corporations fundamentally amoral? If they can make more money by outsourcing your job to India or China, or recycling employees into fertilizer for the rose garden at corporate headquarters, will they do it? I once had to listen to several high-level executives (for a previous company that shall remain nameless) waiting for the private corporate jet complain how inefficient it was that the country was run by democratically elected politicians as “they just didn’t understand business.”

Corporations are great places to work when things are going well, and I enjoy the perks as well as the next employee, but I’m very careful even in my optimism to not make the mistake of thinking this is the way things will always stay. In the free software/open source community, the people you’re collaborating with and creating code with are the people you can really depend on. While you might not get on with all of them personally, they share your common goal of making sure that the code is the greatest, most beautiful work of art that all of you can create together. Smart corporations, at least the ones you’d want to work for, hire from that pool of people, and even though individual corporations may stumble and fall, if you’re part of our community you should be able to successfully manage your career between the occasional stormy periods of corporate upheaval.

If you come from a coal mining area as I do, you can’t finish a piece like this without paying homage to Merle Travis’s wonderful song about really having to work for a living. No matter how much complai
ning we do, at least we’re not “workin’ for the man” :-) .

You load sixteen tons, what do you get?
Another day older and deeper in debt
Saint Peter don’t you call me ’cause I can’t go
I owe my soul to the company store
— Merle Travis

Good luck young Mr. Allison, and let me know if you have any more advice for him. I’d love to hear it.

Is Flash better than Java?

For various reasons, Java applets have never worked all that well but we some folks use them anyway, for example in business charting and other graphic visualizations. Over the past few years alternatives to Java in and around the browser have been gaining traction, especially Flash. In this article I will argue that it’s time for Java to take a lesson from its competitors (on the client side) and address some of the shortcomings that are allowing them to flourish.

Flash
The most serious competition for webtop Java is Macromedia Flash. Flash started life as a very small footprint (~180K) media plug-in for Internet Explorer and Netscape.Adobe acquired Macromedia a few years ago, and has been pouring resources and marketing into it. Now, Flash 9 is an advanced development platform. Through Flex and ActionScript, you can write sophisticated browser-hosted interactive business applications. The run-time is still relatively small (much smaller than Sun’s Java, about 1MB), it’s frequently updated with “frictionless” installs, supports vector graphics, streaming video, Ajax-y back-end interaction, and many other features that users find appealing.

Flash Lite is extending the Flash ecosystem to mobile devices. What was previously the domain of J2ME (now called Java Micro Edition or Java ME) is now being Flash-enabled. Because Flash is vector-based, applications are easier to port from one screen size to another, and users don’t see jaggies because Flash has always done anti-aliasing. When I read this article from Adobe it really made me think. Even if you don’t do anything with J2ME, Flash Lite is draining more mind-share away from Java.Adobe Apollo brings Flash to desktop applications, in direct competition with Java Swing and Rich Client Platforms. It holds an attractive promise of being able to share code between browser-based, mobile-based, and desktop-based applications. Well, hasn’t Java been doing the same thing for 10 years? Yes, but its execution has been flawed in many ways.

Analysis
Ok, so what does all this mean for developers? The software industry has a tremendous investment in Java code, millions of lines and billions of dollars. We don’t want to move to another language like ActionScript just for the fun of it, right? If there was a good enough reason, then it could be justified. I’m all in favor of new ideas and moving to better, more efficient technologies. In fact I’ve used that argument more than once to move C code to Java or C#. But recoding from Java to ActionScript? There’s no way that qualifies. IMHO, there’s no technical reason that Java can’t do everything that Flash can do, with a little work.

The most serious problem that has allowed alternatives to flourish is the poor Java applet user experience. What if we could toss that out and replace it with something better?

I’m talking about work to make Flash-like small footprint installs of a Java-based run-time. Instant-on and streaming compressed content (no more Java progress bars). Frequent updates, fully backward compatible (no content left behind). Viewer-like security with no scary prompts for the user but no complicated signing either. And so forth. I’m sure you all have lots of ideas about this too.

What about F3?
Some have suggested that the new F3 language is Java’s “Flash killer”. F3 is an experimental declarative scripting language with static typing, type-inference, declarative syntax, data-binding, 2d graphics, declarative anmiation, and more. It demonstrates that the Java platform is highly competitive with competing platforms such as Flash. But F3 is a different language from Java. I’m talking about using Java code that already exists. Also I haven’t seen any demos of F3 running inside the browser, only through Java WebStart (.jnlp). F3 doesn’t address the underlying problems with applets and Java installs that Flash addresses. It can’t be a Flash killer until its user experience is as good as or better than Flash.
Conclusion
For years the industry has waited for Sun to solve this problem and they haven’t. Now, with Java 7 being open source, we could do something about it ourselves. Java experts could work together to build an open community around a new Java-based viewer (which we might not even want to call “Java”), and reverse the brain-drain away from Java technologies, preserving our investment in Java code and expertise.

Is Flash better than Java? No, just far better executed for some important use cases. Failing to address this, and allowing Flash and other alternatives to continue to grow and improve unchecked, is going to lead to competitive disadvantages or needless conversions down the road for Java developers. Instead of participating in endless arguments about esoteric subjects like closures and native code, competition from Flash should light a fire under the Java community and force it to respond with radically better user-facing solutions.