PG on Java - comments from 2001
paulgraham.com
paulgraham.com
Though his definition of success seems to be "would really good programmers (wizards) ever use this language for sweet projects? If yes, than this language is a success." By that metric I guess he would be correct.
I also don't agree with his criticism of Ada. Yeah, Ada isn't a good choice if you're building a web app that needs to be out next week. But Ada wasn't ever intended to be used for that sort of software. Ada was designed to build absolutely reliable software. I'd rather have the Space Shuttle's control software written in Ada than Java.
Of course, anyone who has worked the civilian side of DoD knows how bureaucratic it is, and I think pg is right to say that if DoD likes it, it's probably not a great sign. For instance, you can't submit invoices (you have to use a convoluted procurement application and enter it through a very 90s looking app). There are paperwork mandated by Congress and administrative agencies (GSA). And let's consider the Goliath that is DFAS. They use Oracle. And Oracle Forms.
That's what I was thinking, too. Was Ada really meant for "other people" to use? I wonder how many people involved in the process went on to write Ada afterward?
I don't know the facts, but I would guess that the critical system software writers in the US are a fairly small group, and anyone on that committee knew they would end up writing a lot of Ada afterward.
I doubt it was the same kind of "make a language for the masses" simply because there aren't masses of people capable of writing software for critical systems. I would guess that it had more to do with a mutual pact: programmers have to add extra annotation for interfaces and constraints; but in return they can absolutely rely on those interfaces and constraints because they know that the compiler enforces them.
Basically for the niche that Java fits in (networked, multi-threaded data-center applications where performance is important), it hits a sweet spot of ease-of-development compared to performance. C++ is a nightmare to code in, comparatively, and the scripting languages are either dog slow, have poor concurrency support or both. YMMV I guess.
You can write corporate drone type stuff in any language -- and you can write awesome code in any language. Java with a lot of immutability, closures (anonymous classes) and ExecutorServices is like a syntactically weird multi-threaded lisp. Very elegant. The language itself has something like 15 keywords, total.
As the person said upthread, you can look at some horrible 2002 EJB webapps (and I'm sure you can find their equivalents in rails), or you can look at projects like Hadoop, Hbase, Cassandra, etc. In general, static languages are probably a bad idea for webapps or scripting -- that doesn't mean they're the province of drones.
People think that languages like Python and Ruby are "cooler" somehow than Java - that's all I was trying to get at.
I don't think that I was making any judgments about the validity of that opinion, but I would say that it is fairly pervasive for better or for worse, and for many of the reasons that PG alluded to.
Really? I'm so out of touch. I always put Java down as something to use when performance wasn't important.
Once HotSpot kicks in, it's a different story.
The computation was really quite simple, but it had to be done a bajillion times. I suspect part of the reason that it was so slow is that the JIT was not inlining something it obviously should have. However, I was unable to find any tools that would help me figure out if that was the case or what the JIT was actually achieving (consulting with Java experts I know didn't give any insight or link to such tools).
If you're telling yourself that "java is good for hi-performance computing", you aren't really concerned with speed or memory.
The bigger problem is that there's no reasonable way of figuring out what the problem might be.
And for the record, said code was a tight loop, created no objects, had the same kind of workload of a sort algorithm; The two nontrivial things about it was that it was accessing multiple simple vectors using the same index (non-idiomatic java), and that one of those vectors was a memory mapped buffer (non-idiomatic java, but essential because of the overuse of memory).
You don't see C++ programmers making thousand-line XML-based build files, or creating FactorySingletonFactoryVisitors.
I think Java's influence on Clojure is fairly small, and mostly visible around the places where the Clojure has to interoperate with Java libraries. I'm not sure what to call this - incidental influence, maybe?
Let's look at what Java has influenced. C# is fairly obvious, but that too is likely a dead-end. I don't (personally) know any good hackers who are excited about C#. Actionscript and PHP seem to have been inspired by Java in their object systems. I don't think either has or will influence future systems, except perhaps as examples of how not to do it. Scala and Clojure show some Java influence, but it's not very strong. That influence is primarily in the form of compromises required for running on the JVM platform, which probably won't be around in its current form in a few decades.
[0] http://www.paulgraham.com/hundred.html
[1] COBOL influenced the syntax of SQL, but I can't think of much else a hacker today would use voluntarily that was influenced by COBOL.
But yes, Microsoft is really doing some awesome conceptual stuff.
"Its daddy is in a pinch... If Sun runs into trouble, they could drag Java down with them."
Hard not to hear an echo of this prediction from 2001 when reading about Apache's decision to drop out of the JCP.
Wicket is pretty much the only apache java project that holds any value, anyway. And they didn't start out as an apache project.
I really appreciate the language, just not crazy about the lack of closures.
http://www.oscon.com/oscon2010/public/schedule/detail/13307
I figured I'd just drop a link to it, because it's interesting to compare with "hacker instinct". Java got the ecosystem rolling really quickly; it would be interesting to compare that kind of growth across different tech.
http://williamkuo.bokee.com/inc/HBR-Strategy_as_Ecology.pdf
This is probably a better reference point.
The fact that all of these turned out to be reasons for Java's success rather than its failure doesn't undermine the validity of the criticisms.
The marketing around Java contributed more to its success than anything else.
And C++ was originally written to help Bjarne, not for a user base. It was accidental that "C with Classes" caught on at all.
I think it's the first one- C++ is a solid language for what it's good for, which is very different from what Java or Lisp or Python are good for. C++ and all its techniques (beyond just being a "better C") can be used in place of C perfectly well.
He didn't say "languages built for their creators are good", he said "good languages are built for their creators."
Worse, he said "Historically, languages designed for other people to use have been bad: Cobol, PL/I, Pascal, Ada, C++." He explicitly included C++ in the list of languages designed for other people.
http://www.xach.com/naggum/articles/3232434814758067@naggum....
http://www.xach.com/naggum/articles/3232480542642559@naggum....
If your argument against someone is that they are immature, it doesn't help to behave immaturely yourself.
And 10 years later, I know a bunch of hackers using Java, and not one single person, even former perl junkies, that is using Perl for anything besides "it's a little too much to do this in awk".
Unsurprisingly, I suppose, I was told that, since I gave it up as a too much trouble, conventions and patterns have emerged that, when followed, make Perl more scalable (in the sense of being usable in the context of large programs) and maintainable.
I would say that Java was a successful language initially because it provided capability that C++ didn't, and remains relevant because the JRE is an attractive server-side development platform, and hackers have found ways to get around the language's bureaucratic aspects-- in some cases even outright substituting a language like Clojure or Scala for Java.
So I'd say the 'radar' was fairly accurate, but incomplete because it did not consider technology apart from language design.
I actually lost some respect for Paul after reading this collection of thoughts.
"The wrong people like Java"
"No one loves it"
"The language was made for people dumber then the creators"
etc.
Ruby was made to be as elegant as possible. There is nothing wrong with that.
And I don't "love" any language, I "love" solving problems. My passion is not coding, it's delivering, and Java has never let me down yet.
So is Java the "best tool" for the job because it's the one you happen to know best?
I am just trying to understand the logic.
In my experience, when people say "best tool for the job", they have a set of very diverse jobs in mind.
My conclusion is based on my experience with learning these languages. I'll pick on ruby since that is the one brought up the most. I built several web sites using Ruby (mainly CRUD stuff) and my conclusion after having built around 5 web sites with Ruby (versus 7-8 at the time with Java) was that Ruby wasn't any faster or better at solving problems then Java. In fact, usually it was worse, multitudes of libraries with poor documentation and in many cases no clear standard. The language syntax was novel, but language syntax isn't a step function in productivity, at least not for me.
So I continued using Java as my main language, and didn't feel like I was missing anything by not using it. I learned a few philosophies which helped my efficiency a bit, including the "convention over configuration" ethos from Ruby/Rails (my Java code generally has zero XML files), but the niche features each language was selling wasn't enough to counterbalance the deficiencies in productivity which came from using them.
And I should say Java may not always be the best tool for every job, but I've worked on a wide variety of problems (scalable web services, high traffic content sites, ecommerce) and in each case Java, the language and the platform, in my opinion - delivers the goods.
Tell your Lisp hacker friends they can use ABCL. It's Common Lisp on the JVM :-)
Good products are lovingly named. Despite Gosling's original name of "Oak," Java was picked at random from a list of words. Even the things that touch Java get ugly names like NetBeans and HotJava.
And then JavaScript is toned down to CoffeeScript by the same people who want nicer looking syntax.
"...let me clarify that I'm not writing here about Java (which I have never used) but about hacker's radar (which I have thought about a lot)."