Suns Gosling: New Java Flavors Brewing

 
 
By eweek  |  Posted 2004-07-19
 
 
 

Suns Gosling: New Java Flavors Brewing


James Gosling, the creator of Java, is out of the labs and out in front of Suns software development strategy, as the chief technology officer of Suns Developer Products group. In a candid interview with eWEEK Senior Writer Darryl K. Taft, Gosling lays out his ideas on Java futures, the open-source debate, new languages and the plight of the Java camp. But first Gosling sheds some light on whats possibly behind that sly grin of his, as he shares how his early days as a prankster instilled a respect for security.

How prescient do you think you were in creating Java to be such a platform for building secure applications?

Well, when I talk about the virus code in the Microsoft world today, people look at me … I mean, I was really pretty strong about this a long time ago, that we had to do security. And people look at the virus situation and say, "you were just like prescient" was the word that you used. And I dont actually feel that way. Because the way I look at it …. Well, there was sort of a story that never appeared correctly in the press about me having some great revelation at a Doobie Brothers concert, and that was really about security. It was true but they never got it right.

Back when I was like 15 or 16, one of the things I did for fun was I got really good at manufacturing master keys for doors at large places. And one of the things I did for fun was stuff like rewiring elevator systems in large buildings. Its amazing what you can do when you get into elevator control rooms. You can have a really, really good time (laughter). … Like there was this one physics professor that everybody hated. Not because he was a nasty guy or anything but because he smoked these big cigars that really stank. And so one day he got into an elevator and we trapped him in and sent him up and down, and up and down and made him live in his own smoke in a small enclosed space.

And there was another one where a bunch of us decided to take the second floor of one building and we put like sheetrock over all the doorways and re-plastered them and painted them. We re-did the numbers on the stairwells going up. We rewired the elevator system so that it looked like when you pressed two you went to what used to be No. 3. And we put in fake baseboarding so you couldnt tell where the friggin doors used to be. And for that one I was 18.

And so I tended to be up to a lot of mischief, but with a bunch of people. Theres a part of me that would like to say I was the mastermind of all this, but, nah, mostly not. I hung out with a bunch of fairly nefarious engineering types.

And so Im at this Doobie Brothers concert and somebody had made some comment about digital control of light bulbs in your home. And I went, "Oh, this is stupid." My sister had scored these tickets to this Doobie Brothers concert that were amazing. They were the absolute front row and you could actually put your feet on the stage. The big speakers were on the other side of me and my sister and my brother-in-law so we actually heard the unamplified instruments. And to look up at the Doobie Brothers you had to kind of lean back. And all the stage lighting was basically above us, and they had all this robotic MIDI-controlled lighting. And Im lying there listening to the Doobie Brothers and looking at all this wiring and Im going: "Hmm, thats a MIDI-controlled system and those are all robot lights; if I was a 16-year-old here and I could get control of the lights in this building I could have some real fun!"

So I kind of got this semireligious thing about security, not because I cared about terrorism or anything … I was trying to protect the universe from ME! Sixteen-year-old guys with too much free time are way more dangerous than just about anything else.

Next page: New languages in Suns future?

New languages in


Suns future?">

I understand there could possibly be some new languages coming out of Sun. Is there anything you can say about that?

Sun is a company with no secrets (laughter). We have all been really happy with people doing other languages on top of the Java VM [Virtual Machine]. The Java language itself is pretty good for a lot of things, but the real magic in the Java phenomenon really doesnt have anything to do with the language; its really about the VM and the properties of the VM. And there are a lot of people who have built languages that target the Java VM. We generally havent talked about them a whole lot, for no particularly good or bad reason. And there have been people inside Sun who have done other languages on top of the Java VM, like Ive done a couple.

Weve only got one group thats seriously doing some language stuff, and thats a part of project that targets HPCS, or High Performance Computing Systems. And we have this contract with DARPA [Defense Advanced Research Projects Agency] to do R&D into building high-end numerical computing hardware and software. So weve got some folks working on [it], and its not clear how exactly it will go, but theyre looking at programming language support for doing scientific computing. And thats a research project. Where it will go nobody knows. Its not a product. Theres no FCS [first customer ship] or alpha date. Its just a few guys with propeller heads trying to figure out which way is up.

Click here to read eWEEK Technology Editor Peter Coffees analysis of Javas new direction.

Ive been spending a lot of time with folks who do scientific computing. I had been moderately heavily involved with that group until about 8 months ago. And then I got a real job, which was a mistake (laughter). But the world of people doing scientific computing is pretty tough right now, if only because theres really no economic model to support people doing things like software tools for them because there are so few of them. And yet theyre a population that does things that are really, really important, like predicting the weather.

Well, as a follow-on Id like to know what your reaction was when you heard Microsoft was looking at doing something with high-performance computing?

Kind of like anything else from Microsoft. Its impossible to detect from their press releases what theyre doing. They issue press releases about pretty much absolutely everything. Its kind of hard to believe that theyre really serious about it.

Click here to read more about Microsofts supercomputing plans.

And one of the things that I think is one of the unsung Sun stories is that, depending on how you calculate it and who you ask, somewhere between 15 and 30 percent of Suns revenue is high-performance computing. Most of what we talk about is enterprise stuff, but we sell a lot of stuff to people who do enterprise computing. And one of the problems that people in the software world have had is that you have to have some kind of economic model to support it.

If youre an independent software company and youre trying to do software for people who use scientific computing, theres only like 50 or 100 of them [organizations] in the world that do the really high-end stuff. So you take your up-front engineering and divide it by the size of the market and youve got a really big number for your price tag. And it just doesnt compute.

There are almost no small companies out there, other than two guys-and-a-dog kind of outfits, that are doing anything for scientific computing. And yet at a company like Sun, where we get a lot of hardware revenue, the hardware doesnt sell unless theres software to enable it. And weve kind of been coasting in the HPCS world because most people in the HPCS world have been saying Fortran, Fortran, Fortran, so weve got crews of people that give them Fortran, Fortran, Fortran. But even in the die-hard Fortran crowd thats getting a little hard to live with.

We had an interesting review with a bunch of diehard Fortran folks at Los Alamos [National Laboratory] and they had done some interesting side-by-side comparisons between Fortran and Java, and it was fascinating. Then DARPA has been kind of panicky about how this has been going because theyre really dependent on the existence of numerical computing tools. So they gave us, IBM and Cray big buckets of money that have been firewalled off to do HPCS stuff.

IBM is just building an array of basically taking a bunch of their Linux boards, putting them in a big box and calling it a supercomputer … which doesnt really work. Were actually building machines, so …

Next page: The dangers of aspect-oriented programming.

The dangers of aspect


-oriented programming ">

Speaking of DARPA and technology they have funded, whats your position on aspect-oriented programming?

AOP is kind of a complicated one for me, because AOP is one of these things where the theory sounds really good. I actually mostly like the theory. The way it turns out in practice tends to be pretty dangerous. Its fraught with all kinds of problems. You know when the AOP folks talk about AOP they list you like three or four use cases for AOP and they actually mostly make sense, although they have problems in the details. But there actually arent very many use cases outside of that. And when you find people who are using AOP, the average ones that Ive talked to have been using it for things that are just like incredibly inappropriate. Its like a really, really, really bad idea to be doing what theyre doing. And so I feel very conflicted because on the one hand I basically like the concept, but I dont think that the research community has really figured out how to encapsulate those in a mechanism that really works for people. Its like giving them a chainsaw without any safety instructions.

Marc Fleury of JBoss says he thinks Enterprise JavaBeans 3.0 is an example of AOP in some respects.

Yeah, well there are a lot of things that one can think of as examples of AOP in some respects. The debugging framework in Java is an example of AOP in some respects. Theres a performance monitoring facility in 1.5.1 that looks a lot like AOP—I mean that kind of instantiation of interesting uses … of AOP. And because theyre narrowly focused they actually manage to be really safe and useful. [Otherwise,] it feels like handing razor blades to children. Youve got to have razor blades to shave your beard, but oh my God, dont let five-year-olds do craft projects with them. And of course most of the people out there using AOP arent 5-year-olds doing craft projects, but theyre easily tempted. It just seems to me that that theres just a better way.

Can you talk a little about support for scripting? How is Sun expanding that?

Well, theres a set of APIs for interacting with scripting languages that appeared in 1.5. Lots of people have actually used Java itself as a scripting language. If you build the frameworks right, Java … actually works pretty well as a scripting language. We tend to use all kinds of scripting languages—whatevers out there.

Do you have any favorites? For instance do you like Groovy?

I think Groovy is pretty interesting. I think theyre being fairly conservative. I think they could be a little more outlandish and get a little more interesting.

In what way?

I remember sort of reading through their syntax list and saying, "Oh, why didnt you do this and why didnt you do that?" There were some things about the way that they did sort of the equivalence of declarations and some things about the way they did case switch statements … I sort of felt like writing them this long letter and saying, "What? Why didnt you do it this way?" You know … (laughter). So they actually had some neat stuff in there.

But I like Groovy a lot. We sort of got into political hot water when the whole JavaScript thing happened. So weve tended to try to have sort of an arms length relationship to anything having to do with scripting. Were happy to use scripting; we do a lot of scripting ourselves …. I actually did a pretty nice scripting language; at least I think it was nice, back in the early days. And I threw it in the trash can when the whole JavaScript thing with Netscape happened. And you know, in retrospect, ugh, what a bizarre thing to have done. But, you know, its water under the bridge.

Next page: Will Sun join Eclipse?

Will Sun join Eclipse


?">

How significant is the introduction of annotations to the Java platform? How big a deal is that?

Well, [its] sort of hard to quantify how big a deal annotations are, because in and of themselves theyre actually not very useful because all you can do is add notes to things. And really what annotations are about is giving you a way to kind of hook between the language and meddling with the tools—or things that are bigger and beyond the language. And whether its deployment tools or user interface generation tools or whatever, its a way to build bridges between tools of various sorts and objects or methods or whatever. And I think theres incredible potential for really cool stuff to happen there.

But its a little hard to say whether or not annotations are going to be the greatest thing ever, because its so dependent on how people use them. There are plans right now, for instance, to change the way J2EE [Java 2 Platform, Enterprise Edition] deployment happens … to make the whole construction of deployment descriptors easier. I think that within the J2EE world that could be pretty revolutionary.

And I have a little back-burner project that … Ive been working on that uses annotations as a way to build user interfaces for objects that I think is actually pretty cool, and Im hoping to actually get it out there as an open-source project once its not like totally embarrassing. But I think it could be very cool. So its one of these things where Im really pretty charged about it, but it all depends on what people do with it.

With NetBeans day occurring at JavaOne this year, I have to ask about Eclipse. Is the possibility of a Sun membership still on the table?

Its sort of hard to imagine us joining. I think that maybe Eclipse should join the NetBeans group.

So maybe you can cross-pollinate—no pun intended.

Well, the NetBeans open-source project has been up and running for four years now. It was up and running and running as an open-source project for over a year when IBM unveiled Eclipse. That whole part of it just felt really odd to me.

But when I wear my "church of Java" hat, tools are one of these things where it feels perfectly appropriate for there to be lots of them. And I think its actually a good thing for there to be lots of them. The places where you need to have standards are in interfaces between things. Thats where standards really pay off. And if you say there must only be one developer tool, all of a sudden youve killed innovation. Its a tragedy in the Windows world that there is only one developer tool.

You hear a lot of people say that if the Java camp doesnt get its act together, theyre going to hand the developer space over to Microsoft. Is that even remotely possible or is it a given that diversity is the name of the game?

What do they mean by "get it together"? For me theres "get it together" in different flavors. There are things like standards around interfaces. And I think we do a pretty good job of that. Some of these are pretty chaotic, like all the J2EE stuff. But I think given all the temperatures and pressures of all the various actors involved in that space, I think its astonishing that J2EE standards are in the shape that theyre in when weve got ourselves and IBM and BEA and SAP and Oracle and a whole pile of people who really care about that stuff. And at some level every actor in the J2EE space wants to kill every other actor. And yet they all have this sort of uneasy coming together. And J2EE the standard is wonderful.

Where I have a problem with the whole "get your act together" phrase is that innovation depends on ideas and things mixing and somebody having the idea to go off and do something neat. If somebody cant go off and invent something cool—a developer tool or whatever—the world is a worse place.

I think the world got to a really tragic point when there was essentially one word processor in the entire universe. You cant tell me that for the rest of time all innovation in document production is over because Microsoft Word is the end of it. And in a sense, it had become the end of it because if you had gone to any funding source and said, "Hi, Id like to write a word processor for profit," if youd gone to any VC in Silicon Valley and said, "I want to compete against Microsoft Word," you would have become the stuff of legend at cocktail parties with people laughing so hard. Its such a stupid business plan.

And yet there were these nut cases in Hamburg who built this thing and they couldnt really make it fly. So we bought them and helped them a little and pretty soon it turned into Star Office. So I think its a tremendous disservice to the universe to have only one. The place where you need to have standards is around the interfaces. And if we "got our act together" wed be dead.

To be in the Java world youd have to believe in Darwinism. At some level its chaos, and at some level its innovation, its cleverness and people trying to find a better way. And I guess Im a fan of evolution.

Next page: Open-sourcing Java.

Open


-sourcing Java ">

Ive read responses on this from you, but Ive never asked it: Whats your position on open-sourcing Java?

Its complicated. Its really complicated. In general Im a really big fan of open source. But one of the big values of Java, if you go out and survey people, is the whole thing around interoperability, reliability, and that its solid and you know what it is.

When we try doing surveys of folks we actually get more responses from people saying dont open-source it than saying do open-source it. The people who say do open-source it tend to be really loud. The people who say dont open-source it tend to have big pocketbooks and what they care about is having a stable, reliable platform. So we tend to want to do whatever sort of works best for the developer community. And on average thats about stability.

And I like to think of the way weve handled Java over the last years as being essentially open source. Anybody can go to the java.sun.com Web site and get the source to J2SE [Java 2 Platform, Standard Edition], the whole nine yards. Youve been able to do that for a long time. So the source is certainly available. You can take that source and you can make all kinds of changes to it. All the open-source projects have licenses of some sort and ours has a license. And it basically says you cant redistribute it unless you pass the compatibility tests, because we actually care about compatibility and reliability.

Simon Phipps [Suns chief technology evangelist] basically said that at EclipseCon and I wrote that story and there was a bunch of commotion, including finger-pointing and the open letter from IBM [asking Sun to open source Java]. But he basically said just what you just said.

Right, and so the hidden agendas are everywhere here, and theyre actually not very well hidden. Why did Rod Smith [IBM vice president of emerging technology, who wrote the open letter to Sun] say that? I mean it doesnt make a difference to IBM. Because IBM has all the sources.

The only thing that IBM is constrained by is the compatibility testing. So are they saying that they dont want to be compatible? Now thats the only thing that they would get, is the right to be incompatible. And yet if you push Rod to the wall and say, "So Rod, are you saying you want to be incompatible?" Hed go, "Uh, no." Because you just know that if you went and talked to developers, if he told developers that he wanted to make IBMs Java incompatible with everybody elses Java, the development community would crucify him.

So are you saying its not Rod whos talking?

Its hard to tell whos talking. The problem with any corporation is that its actually a collection of people, and IBM is a huge collection of people. I mean IBMs ten times the size of Sun, with ten times as many people arguing. Never ever mistake a corporation for a coherent entity.

Next page: On the back burner.

On the back burner


">

How much time do you have to do back-burner projects since youve taken on this new role?

Not as much as Id like, but more time than Ill admit to. There are a fair number of meetings on my schedule. But I think I manage about 20 percent of my time to back-burner stuff.

And I mean back-burner things that I specifically work on. I actually spend a lot of time [on back-burner projects]. Sun has a number of folks off in corners doing back-burner projects. I think that one of my more important roles is to help them out and deal with the care and feeding of them.

Often these are things that are making the transition from the labs or back-burner things to real products. Its really like the real-time thing I talked about. Thats something that had been a series of little back-burner projects that coalesced and finally got real funding and now has an actual engineering team, and theyre now doing customer trials and its like, "Ah, cool!"

Any others you can identify?

Well, Looking Glass was one of them. The JOGL API—Java OpenGL API—started as a little back-burner thing. There was one that never went anywhere … called Relator, which was a way to build user interfaces, which I actually quite liked. But it didnt work out. And I actually think that having things not work out is a good thing because it means youre being a little edgy.

Check out eWEEK.coms Developer & Web Services Center at http://developer.eweek.com for the latest news, reviews and analysis in programming environments and developer tools.

Be sure to add our eWEEK.com developer and Web services news feed to your RSS newsreader or My Yahoo page

Rocket Fuel