Skip to main content

The Globe and Mail

Canada’s code guru James Gosling is an international star in computing

Former vice-president of Sun Microsystems, James Gosling’s next position will be as a distinguished engineer with Amazon Web Services.

AP

Most Canadians have never heard of James Gosling. But the Alberta-born principal creator of Java – one of the most widely used and longest-lived programming languages in modern computing – is a hero in Silicon Valley.

Java is the foundational software behind Android, the operating system found on most mobile devices. By some measures, Java can be found on 97 per cent of enterprise computer systems, and the virtual-machine systems Mr. Gosling designed for Java are critical to the world of cloud computing. For those who remember the Y2K computing crisis, Java was the main tool used to repair and replace the broken systems.

There are millions of Java programmers the world over, and some of those people still stop Mr. Gosling on the street for selfies – as if he were a movie star – and then thank him for their careers.

Story continues below advertisement

"That tends to weird out your kids. People mostly leave me alone, [but] if there is the wrong kind of conference in San Francisco and I wander around Moscone [the city's main convention centre], it can be a little tough," he says. "If I go to places like India or China it can get seriously tough."

Just a few years ago, Mr. Gosling recalls, he was mobbed by excited Indians during an unscheduled visit to a tourist site in that country (it happens frequently enough that he can't recall the exact details of the city, but it was inside a temple).

Mr. Gosling's story about why he created Java starts with a complaint he and his colleagues at Sun Microsystems Inc. had in the early 1990s as the digital revolution was gaining more traction among consumers.

"We had latched onto the fact that computers were showing up in all kinds of embedded devices, like TVs, VCRs, elevators, locomotives and cellphones and all that. But it was all being done by electrical engineers and they were all reinventing computer science in the most crazy, retro backward way," Mr. Gosling recalls in an interview with The Globe and Mail. "They were inventing network protocols that were just laughably stupid."

The dominant programming languages of the time, C and C++, were also prone to both reliability and security problems and, as the Internet grew and connected more systems together, those weaknesses became more glaring.

"The goal was never just to, like, go off and build a programming language because it's fun. I didn't do programming language stuff in college at all. It was: 'Here's a set of problems. How can I fix them?' It was a situation where the right answer was a programming language so that's what I did."

Describing how computer code and languages work is difficult to summarize, entire libraries of textbooks exist to do so (journalist and developer Paul Ford's 38,000-word Bloomberg essay "What is Code" from 2015 is both a humourously approachable and still-brainy read if you want to bathe in the theory of code).

Story continues below advertisement

Still, the simple explanation for why Java worked and why it still works is that it was both "overengineered" and better than most languages at handling incredibly complex parallel processing.

"A lot of [programming] languages are, 'do this, then do this, then do this,' they are very sequential," says Mr. Gosling. "Java allows for parallelism where you've got multiple things happening at a time."

That's partly why Java developers regard it as a tricky, even ornery, language. Developer forums are filled with despairing jokes about the difficulty of working with Java: "I had a problem so I decided to use Java. … Now I have a ProblemFactory."

That complexity is by design, says Mr. Gosling. "The way that engineering worked at Sun, we put a heavy emphasis into making sure that hard problems were possible to solve … but we didn't work very hard on making easy problems easy to solve," he says, noting that most stock-exchange systems are written in Java. He then throws some shade at an old rival: "What Microsoft tended to do was make the easy problems easy, and hard problems were impossible."

Mr. Gosling has been writing software since he was a teenager growing up in Calgary, and fondly remembers rummaging through the trash outside the University of Calgary's computer lab for account numbers with some time left on them (in the late 1960s and early 70s, such account numbers were how scarce computing resources were doled out to students and researchers). While still in high school, he wrote a program for the university's physics department that was designed to take telemetry data from the Canadian space program's Isis 2 satellite and translate it into photographs.

This experience would set Mr. Gosling's course in life, though in the early 1970s the future was more difficult for him to predict.

Story continues below advertisement

"The whole thought of a career with computers – given that hardly anybody even knew what they were – it wasn't even a concept," Mr. Gosling says. "I had half my family that were farmers, and I was really pretty good at repairing farm equipment. There was certainly a period of time where I would have been happy to do that, just to be a farm equipment repairman in Dalemead, Alberta. My life was just playing with toys. The big lucky thing for me was the toys I was playing with turned out to actually be important. "

He went on to do his undergraduate degree in computer science at Calgary, and a masters and PhD at Carnegie Mellon University, despite knowing almost nothing about the school or the other options in the United States.

"What really drew me to Carnegie Mellon was that there was a book that I loved, written by a professor there," he says. The book was The Design of an Optimizing Compiler, by William Wulf, and Mr. Gosling describes it as the first computer-science book he read that focused less on the math and more on the engineering of code. "I thought, well if people are writing books like this that's probably a really cool place to go. I still have it on my bookshelf somewhere."

At Carnegie, he developed the software approach that would form the core of Java Virtual Machine, which enabled many of the early Web-based applications (programs that work online and do not require a download) and is another foundational technology in the server-delivered applications known as the cloud.

"My adviser was sort of panicked because he had all this software that a bunch of other grad students had written on these machines that were crashing and burning [because the computer maker was going out of business]. He asked me if I had any ideas for how to get them to run on, you know, a different set of machines. I came up with a solution that was kind of weird, and I was actually really surprised at how well it worked," Mr. Gosling recalls. What was originally a side project went on to prepare Mr. Gosling for a similar situation that arose at Sun years later.

But for about five years during the peak of the late 1990s and early 2000s tech boom, Mr. Gosling was physically unable to work as a coder, due to a severe case of carpal tunnel syndrome, a repetitive strain injury commonly associated with typing.

"For a bunch of years, I really couldn't actually do software engineering in any sensible way. I'd gotten to the point where my right hand, it was essentially impossible for me to move," he says. "The nerves were so badly compressed that I had no feeling on the palm of my hand. I mean, you could have pounded a nail through my hand and I wouldn't have been able to feel it. But I really didn't want to get surgery – I was just, like, terrified at the thought of somebody sticking a knife in me."

While trying to deal with his injuries in a non-surgical manner, Mr. Gosling says he became a sort of "Vanna White" spokesperson for Java, evangelizing at conferences and working with Sun's customers, but not writing code for products. When he finally consented to surgery, the results were almost miraculous: "It was just instantaneous relief and absolutely perfect immediately. And I got my hand back. It was amazing. And then six months later I had the other hand back."

But he soon found that software development, a constantly evolving discipline, was not easy to get back into – he had become a figurehead and was attending meetings and dealing with e-mails rather than spending time doing what he really loved. "I stepped back more than I was really comfortable with, in retrospect," he says.

Then came Oracle Corp.'s purchase of Sun in 2010, a marriage of two corporate cultures that couldn't have been more different, especially for Mr. Gosling, who had been with Sun for 26 years. "It's like grabbing your hand onto an electric fence … Oracle is a very painful corporation," he says.

He recounts an infamous story: Even before the acquisition closed, Oracle cancelled an employee appreciation party that Sun's founders had organized, even though Sun had prepaid to book an entire amusement park. Sun was the kind of place that had a closet full of tequila, he said; Oracle was not so loose.

"Oracle does not do employee appreciation events. You get one employee appreciation event every two weeks; it's called a paycheque. My early experiences with it were just, like, really, really, really awful. So I just had to flee. "

After spending some time at Google Inc., he went to work with Liquid Dynamics, a company building ocean-going drones. At Liquid Dynamics, he was back building software to communicate with satellites, and had a whole new set of difficult problems to crack.

Now 62, Mr. Gosling's legacy is more than secure, but he has no plans to retire. "I will never run out of projects. I mean I could live to be 1,000 years old and I would still not see the end of my to-do list," he says, and then quotes a line often associated with Leonardo da Vinci. "Art is never finished, only abandoned."

On May 22, Mr. Gosling returned to the world of big-time software development when he announced he was joining Amazon Web Services (one of the world's leading cloud-computing providers) as a distinguished engineer.

He has been tight-lipped about what he'll be doing at Amazon.com Inc., though he posted this intriguing message on Facebook: "Years ago, I worked at IBM for a while and had to go through 'confidential-information' training. When I came back grumpy, my manager smiled and said, 'IBM's biggest secret is that it has nothing worth keeping secret.' Doesn't apply at Amazon. It looks like it'll be a fun ride."

Video: Commemorative $10 bill marks Canada’s 150th (The Canadian Press)
Report an error Licensing Options
Comments

The Globe invites you to share your views. Please stay on topic and be respectful to everyone. For more information on our commenting policies and how our community-based moderation works, please read our Community Guidelines and our Terms and Conditions.

* We’ve made some technical updates to our commenting software. If you are experiencing any issues posting comments, simply log out and log back in. *

Discussion loading… ✨