Wednesday Oct 06, 2010

Hadoop Lab Now Available

I was really surprised at the turn-out for JavaOne this year. Judging by the packed halls and empty goodie carts, I think the conference organizers were a little surprised as well. Excellent! Well done.

As you may have noticed, I always seem to have my fingers in the JavaOne hands-on labs pie. This year my contribution was to bring Cloudera into the fold to run a Hadoop lab. Needless to say, that generated a lot of interest. Well before the conference, the slot we had for the lab was booked solid. Taking that as a sign, I had the conference organizers give us a second slot on Monday for the lab. That slot was also booked solid before the conference even began. Unfortunately, however, that Monday lab slot ended up getting canceled for <INSERT OFFICIAL REASON HERE>. As a concession to the folks who didn't get to attend because of the cancellation, I got the conference organizers to give me permission to have Cloudera host the lab materials from their site before it's available from the official Oracle JavaOne site.

You can find the semi-official JavaOne Hands-on Lab S314413: Extracting Real Value from Your Data With Apache Hadoop here under the training section of the Cloudera site. The file is not yet linked from anywhere but here, but they're working on it.

If you download the zip file, in it you will find a lab workbook. At the back of the workbook, you will find an appendix that describes how to set up your own lab environment. The lab was written for Solaris 11 Express and NetBeans, but the OS and IDE really play little role in the lab. If you refuse to see the light and accept Solaris as the one true OS, you can still do the lab on some other OS with some other IDE (but it won't be as satisfying).

The lab did run in its originally assigned slot at JavaOne, and it was really successful. Turnout was good and the comments were great! I've already incorporated lots of great feedback from that session into the lab materials that Cloudera is now hosting, but I'm always happy to hear any additional comments and/or feedback. Happy coding!

Friday Feb 20, 2009

Executable Web Deja Vu

George Colony spoke in yesterday morning's Omniture Summit 09 keynote, and one of his eight big messages for CEOs was that the web is moving to what he calls "the executable web," meaning that instead of your browser being just a file viewer, it will become an application platform for applications downloaded off the web. Gee. That sounds kinda familiar... like from about a decade ago! Applets anyone? It really ticks me off that "Java™ is dead" while at the same time, everyone is busily trying to recreate Java in JavaScript. Hey, I know! Why not just fragging use Java? JavaScript is ugly and painful. AJAX is an order of magnitude worse. (Don't tell me about how much better Python and Ruby are than Java. That's a different topic.) I know that Sun is notorious for being way too early to the market with its technologies. Yes, applets did suck ten years ago. (Although, ten years ago there wasn't an alternative for RIAs, so at the same time it was revolutionary, cutting-edge technology.) Have you looked at applets lately? Check this out. Let's see you port that to JavaScript. I think it's just silly that with the current state of Java technology people are still thinking about the platform based on impressions from last millennium. Wake up and smell the coffee.

Thursday Jun 05, 2008

JavaOne Hands-on Labs Online

In case you haven't noticed yet, we've posted the JavaOne Hands-on Labs from this year to Among the labs posted there are the Compute Server lab (7410), which includes my old DRMAA lab as an appendix, and the Project Darkstar lab (7400). If you missed them at JavaOne, now's your chance to do them from the comfort of home.

Friday Oct 19, 2007

Great Generics Reference

I just found myself looking for an answer to a picky question about using generic methods on the Java™ platform. After reading through the Generics tutorial, my question was still unanswered. With a little searching, I found Angelika Langer's excellent Java Generics FAQ, and I learned everything I wanted to know. If you want to really understand Generics, give this site a read.

Friday May 11, 2007

JavaOne 12: Friday AM

Friday started with a 2-hour keynote where James Gosling showed a bunch of technology demos, ranging from developer tools to toys to industrial robots. Neat stuff. Suspiciously missing, though, was the winner of the slotcar challenge. Wonder what's up with that...

After the keynote, I put my nose to the grindstone and (finally) hit the sessions hard. First up, Effective Concurrency For the Java™ Platform (TS-2388). As Brian pointed out several times, none of the content was riveting and new, but it pointed out common fallacies and errors. Definitely worth checking out when the content goes online.

And that does it for the AM...

JavaOne 12: Thursday PM

Even though the Darkstar lab was Wednesday night, Thursday morning it was still consuming my time. You see, the fifth exercise in the lab was to extend the MUD in new and creative ways and check in the results. I spent Thursday morning with Jeff assembling the contributions so that we can post them online.

The excuses continue. Between lunch with co-workers, dinner with the Darkstar (et al) team, and various hallway conversations, I only made it to 1/4 of a session on Thursday. I'm kinda bummed about that, but I think this year the social side of JavaOne is more important for me. I'll do better on Friday.

I did catch the last hour of the After Dark event. Not bad. They trucked in a bunch of the champion Battlebots from the television show and let folks from the conference drive them. Gratuitous fun. They closed the night with a Rolling Stones cover band who was decent. Would have been better if the beer weren't so bad.

Thursday May 10, 2007

JavaOne 12: Wednesday PM

I had to be back in Palo Alto for personal reasons on Wednesday morning, so I didn't get back to the conference until the late afternoon. After dealing with some last-minute issues with the Darkstar lab, I went to the Intel general session. Less than thrilling. The Intel spokewoman gave a long spiel on how wonderful Intel chips are and wanted everyone to know that Intel is working with Sun to make sure that Java runs best on Intel. For me there were only two interesting points: 1) Intel has already shipped 1 million quad-core units, whereas AMD hasn't shipped 1, and 2) Intel will provide an Itanium port for Java, and Sun will host it on

After the general session, I caught the NIO talk (TS-2992). What I learned is that I don't know jack about NIO. The 6 tips and tricks the speakers presented didn't mean a thing to me. Oh, well

After that I went to the Java performance BOF (BOF-2366), where people asked very specific questions about API's haven't had a reason to use. What's up with that? I used to be Java savvy. I guess I just haven't had a reason to use some of the newer, deeper APIs yet. That's the trouble with being on the engineering team for a C-based product.

I had to leave the BOF early to be at the Darkstar lab 20 minutes early. The lab went really well. All of the feedback I got was extremely positive. As far as I can tell, we hit it out of the park. Even though the lab was scheduled to end at 22:45, we ended up staying until 0:15. People just didn't want to leave!

Tuesday May 08, 2007

JavaOne 12: Tuesday AM

Welcome to JavaOne! There's a lot of people here! Looking at the schedule, the content looks great.

General Session

  • The JDK is now completely open. (There are actually a couple of small pieces that we couldn't open up yet, but you can get binaries plugs for those pieces until we can get them opened.)
  • The governance model for the JDK community was announced. The board will be Doug Lea, Fabiane Nardon, Simon Phipps, Mark Reinhold, and Dalibor Topič
  • The TCK will also be make available for use by the community.
  • The next several releases of JDK 6 will be focused on execution and startup speed.
  • Rich announced JavaFX, which is a new family of technologies and tools that make it easier to use Java in the consumer space. The first piece is JavaFX Script, formerly known as F3. Consider it a competitor to Flash. The second piece is JavaFX Mobile, which is our new name for the SavaJe technology we recently acquired. It's approximately Java SE for handsets. (Believe it or not, we actually had a female engineer demo JavaFX Mobile on stage!)
  • McNeally talked about Curriki, his pet project for providing free K-12 educational materials online.

And the on-going saga of the Darkstar hands-on lab ate up a couple more hours of my day. Between that, being a proctor for the Realtime Java hands-on-lab, and hanging out in the pavilion, I didn't actually make it to a single session today. Shame on me.

JavaOne 12: Monday PM

Unfortunately, I was only able to go to one session this afternoon. It was the session on the new NetBeans 6.0 features. One word: WOW! I can't freaking wait! Apparently the 6.0 preview release is now available. 6.0 is going to completely change the game.

After the session I had to go try to get the Darkstar lab (LAB-7210, Wednesday at 20:45) in ship shape. Still not done, but I think I've got it on the ropes.

Monday May 07, 2007

JavaOne 12: Monday AM

Like last year, I will be blogging JavaOne again. Fortunately, all the JavaOne materials will be available online after the conference. For the lazy and/or impatient, I will be blogging my summary of the points that I found interesting in the sessions that I attended.

Today I'm attending the CommunityOne JavaOne pre-conference (AKA NetBeans Day).

General Session

  • According to an EU-funded study, Sun is the number one contributor of open source code in the world. More notably, we have contributed three times the number of lines of codes as the number two contributor, IBM.
  • Tim O'Reilly pointed out that while the major Internet properties are based on open-source technologies, almost none of them are themselves open source.
  • Tim O'Reilly's definition of "Web 3.0" is where it builds on the emerging data streams that aren't explicitly provided by the user, such as GPS data, gestural interfaces, etc.
  • Sun is considering how to compensate developers for open source materials that we monetize.
  • Tim O'Reilly reminds me of Dennis Hopper now that he wears a beard.

NetBeans General Session

  • Rich Green reiterated that we need to look at how to compensate the authors of open source content that we're able to monetize. "I'm sure we're going to do that... Real soon now," he said.
  • For Sun, going balls-to-the-wall open source is really just us returning to our roots and re-establishing two-way communications with our developers.
  • Schwartz on Eclipse: "THey may have more market share, but our developers have more fun." He said that we're not concerned with Eclispe. They're our "brothers in arms" against "someone else." In general, the competition has been good for us, and we're really doing well. We hope to be dominant, but we don't want to kill them.
  • There's an plugin for NetBeans for developing OOo extensions.

That's it for now. I'm off to lunch. Look for more this evening.

Friday Apr 06, 2007

Jackpot Redux

The Jackpot API has been updated for the new Java Source API in NetBeans 6.0. The new modules are on the 6.0 Development Update Center. The new API documentation is posted on, as are updated example programs.[Read More]

Friday Feb 09, 2007

Sober Commentary

Just came across this article by Bruce Eckel, the author of Think in Java™, on why the Java platform isn't the platform of choice for rich Internet applications (RIAs). The article is a long but worthy read. Personally, I find it terribly frustrating that the latest "advance" in web technology is to reinvent something that Java's been doing for a decade. I understand that Java's not perfect, but as a developer, I'd much rather be dealing with some installation issues than trying to write code that dynamically adapts itself to the browser du jour. The problem is, and it's Sun's perennial problem, the developers aren't the ones driving the marketplace.

On the bright side, though, it looks like JSF may find a niche as the preferred abstraction for doing AJAX development. See dynafaces and jMaki. I'll be very interested to see how that one plays out.

Tuesday Jan 30, 2007

Java Smackdown Par Russky

There's only about a month left for you to take over the Electric Jungle (or the Электрические Джунгли, as it's known locally). The Electric Jungle is a Sun-sponsored Java™ platform programming competition, where contestants create Java-powered creatures that compete with each other for control of the jungle. At the end of the competition (on February 28th, 2007), the developer(s) of the most effective creature will win some cool prizes.

I really wish we had something like this in the US. I think it would go a long way towards getting folks interested in the Java language, especially if it were a recurring event and had some good prizes. I assume that anyone could participate in the current Electric Jungle, but while the official docs have been translated into English, all of the forum posts are in Russian, so unless you speak the language, I suspect you'd be at a distinct disadvantage.

Wednesday Oct 11, 2006

NetBeans C/C++ Dev Pack Rocks!

I've been testing out the latest build of the C/C++ Dev Pack for NetBeans, and I'm quite impressed. I'm really very excited to finally have full C/C++ integration with NetBeans. Code reformating, go to declaration, a pull-down menu for jumping to functions, a class browser, etc. I can't wait until it get's GA'ed.

The most impressive thing about the dev pack so far is how well it handles macros. Not only is it not confused by complicated ifdef's, it even does macro interpolation on the fly. In the Grid Engine source tree, we have one file that defines a macro that defines a function, and then uses that macro to create a series of functions. When I view that file in the new dev pack, the function pull-down menu shows me each of those dynamicly generated functions instead of an ugly pile of macros. Sweet!

Also, if you hadn't noticed, RC1 of NetBeans 5.5 is now available. So far, I've found it to be much stabler than beta 2.

Thursday Sep 07, 2006

To Finalize Or Not To Finalize

Because of some API work I'm currently doing, I was recently faced with the question of whether or not to use a finalizer to simplify the API. Searching on the Internet turns up lots of articles (mostly from IBM) saying that finalizers are bad and should be avoided. Since I work for Sun, I thought it would be a good idea to find out what our official stance is. This post is a summary of the answers I got.

First off, a little background reading. These articles were recommended to me by Sun engineering:

In addition, I found the following articles helpful:

From those articles and from direct feedback from various Sun engineers, these are the lessons about finalizers that I have gathered:

  1. If there's a way around using a finalizer, and it's not ridiculously more complicated, do it. See Tony Printezis' article for some alternatives to finalizers. In many cases, an explicit dispose() method is the best choice.
  2. Never trust a finalizer to free something that has no other way of being freed. There is no guarantee that a finalizer will ever run. For example, deleting lock files is something that definitely should not happen in a finalizer, unless it also happens somewhere else.
  3. If you're designing an API that may have a JNI-based implementation, either design in explicit dispose() methods, or make sure there's a common clean-up point where held resources can be freed, such as exiting the session, so that implementers are not forced to use finalizers.
  4. The Java language's specification of finalizers has some holes which allow you to do bad things (such as restoring a reference to the object being finalized). If forced to use a finalizer, do so carefully.

In my end, my findings were exactly what my initial searches suggested. It is, however, nice to have confirmation.




« April 2014