Category Archives: Programming

JavaOne 2011 Part 1

JavaOne has been good so far, below are some of my random thoughts/observations of some of the sessions that I’ve been to so far.

Technical Keynote

The keynote started off a little boring, to me at least, with a lot of dry nerd humor and talk about how Intel and Oracle have worked together to make improvements to both the JVM and hardware to get the best from each other. Thankfully Mark Reinhold came up next and woke everyone up when he started talking about Java SE 7-9.  (If you haven’t heard Java 7 came up back in July).  Java 7 is a great step forward with features like AutoClosable, String literals in switch statements, multi-catch, and multi-catch, and try-with-resources.  Java 8 looks like it will be a “revolutionary” change with Projects Lambda and Jigsaw (more to come on those).  The  JavaFX was very impressive, as most demos should be, and caught everyone’s attention when they had Duke mirroring the actions of the demonstrator ala Xbox kinect style.  I was also happy to hear them say that the Mac OSX version will be GA soon on the same date as the official Mac Java SE7 is available.  There are a few projects that we have at work which have been needing some TLC and JavaFX might be getting some action soon.

Choosing a Web Framework

I was actually pleasantly surprised at this session.  The presenter did a good job of explaining what all you need to look for when choosing a framework and the repercussions of making the wrong choice.  Most of the requirements should be fairly obvious however the speaker stressed the importance, rightfully so, of longterm planning when choosing your framework.  What really surprised me was the frameworks he compared/scored; Grails (shocker), GWT (another shocker), Tapestry, and Wicket.  Wicket?!  We’re migrating to Wicket at work and while I like the framework it just has never seemed to gather that much community support.

Project Lambda

The Project Lambda presentation given by Alex Buckley was very good.  Being one of those geeks who enjoys the “thought process” discussions I was really into this one.  How some decisions were/are being made and how it will impact future coding and performance.  Lots of good stuff but to quote a college of mine “I’m not sure I want Perl in my Java”.  The syntax will take some getting used to….

Project Jigsaw

The concepts and implementation details behind Jigsaw are interesting.  Generally speaking, it’s taking the best parts of Ruby’s gems, maven, and others and wrapping it all up into the new JDK.  The project is also aiming at modularizing Java which is a good thing since it will help keep the bloat down.  The presenters were wise to avoid even mentioning OSGI since there will be some contention between the two somewhere down the line.  There are a lot of questions that came out of the presentation (like if you get rid of -classpath and everyone is using the module-info.java file how do you handle facades/runtime resources like SLF4j?) and this will be one to watch.

To JavaOne I Go Again

I’m going back to JavaOne again this year!  I enjoyed the conference last September and I’m looking forward to this year’s conference.  A little bummed it’s not in the Mascone Center (again) this year but  overall I thought Oracle did a good job with the Hilton, Niko, and Parc 55.  Sessions are booked, flight reserved, and hotel ready.  San Francisco here I come again!

Picking a language

Every year at work we review our development and performance objectives.  How did we do on them, what are the objectives for this year, etc.  Since I pick my development objectives I’ve decided that one of them will be to learn three new languages/frameworks.  There are plenty of languages and frameworks to choose from, so much in fact that I have had a hard time nailing down which ones I want to try and tackle.  Of the many options to choose from I’ve narrowed down the list to the following six:

  • Grails
  • Python
  • Objective C – really get into it this time especially now that I have my new MacBook Pro :)
  • Scala
  • Ruby On Rails
  • GWT

I actually jump started my goal in the beginning of the year by attending one of the SATJUG meetings which was over Grails.  The presentation at the JUG was enough to grab my attention and bump it up in my list.  Groovy is an interesting language and I’m really liking how the Grails framework makes use of it’s dynamic nature.  There’s also some entertaining value of having a class called GString in the core language.  Scaffolding is nothing new but Grails does it with flair.  Throw GORM into the mix and you have yourself a pretty slick web framework.  Despite all that I don’t see it having a home at work other than for prototyping due to our ‘culture’ which saddens me.  Regardless, this framework has a lot going for it.

I still haven’t picked my next language/framework, I’m open to suggestions, but I hope the next one I pick is as unique and versatile as Groovy/Grails :)

Being Pragmatic

The Pragmatic Programmer

The Pragmatic Programmer

One of my colleges and I were discussing the dynamics of our team and what changes we would like to see.  It was one of those fun conversations where you know something needs to change but you’re not quite sure so you’re left to pure brainstorming.  During our conversation we started talking about “required reading” for our team with the hopes of getting more out of our team.  The Pragmatic Programmer was one of the books that came up that I had not heard of.  If you’re a programmer/developer and do not own this book stop now, click the link, and order it.  Go ahead, I’ll wait.  Don’t let the © 2000 fool you, buy the book!

The Pragmatic Programmer won’t teach you how to program in a specific language or tell you the answers to all of a developer’s life questions.  What it does do, very well I might add, is give you a advice from their experiences that can help you become a better programmer.  If you’ve been programming for a while like myself or just getting into it this book will help guide you along the way.

Learning IntelliJ

A couple months back I landed a free IntelliJIDEA license while attending the SATJUG.  I’ve it installed on my personal computer but just haven’t really used it.  Each time I start to hobby code my mouse instinctively hovers over the Eclipse icon.  It’s not that I’m against using a non-eclipse based IDE, it’s just that I hate trying to learn how to use a new IDE.  I learned how to use Eclipse because it was “the” IDEA at the time and it’s what I use at the office, well actually we use MyEclipse which I despise….  Everything I’ve read about IntelliJ has been positive and looks like I’ll like it, it’s now up to me to learn to use it.

I will learn to use IntelliJ. I will learn to use IntelliJ.  I will learn to use IntelliJ!

JavaOne 2010 Photos

Been meaning to post these. Here are the pictures from JavaOne 2010. I took them with my iPhone so take it for what it’s worth.

Java mascot

Doing the Wicket ‘thang

Wicket in Action Lately I’ve been playing around with Wicket for work.  It’s a very interesting framework that, from my experience at least, you will either love immediately or scratch your head for a time as you unlearn Struts or another framework.

We don’t need no stink’n JSPs!
It seems that with Wicket the days of having to write Java in JSPs are gone, in fact Wicket doesn’t use JSPs, it uses good ol’ fashion HTML files.  This is very nice and allows you to really separate the design of a page from the functionality.  The only downside with how Wicket uses the HTML markup is if you change the structure of the markup, which you will do when developing, you’ll have to reorder your components in code and recompile.  If you make use of Wicket’s markup, which you will, the number of times you have to recompile goes down drastically.

Read more »

JavaOne Sessions

Some of the JavaOne sessions have been posted online, looking forward to them!

WARNING!  Continue reading only if you’re interest in the abstract description of the sessions.  These are just some of the sessions that caught my eye.  There’s a lot to review since we’re finally moving from Java 1.4 to Java 1.6.

Read more »

Android and the Missing GEN Folder

I’ve been playing around with Android now and so far it’s been a good experience save one really annoying thing.

Project ‘Project Name’ is missing required source folder: ‘gen’

Seriously?!  I mean come on, the folder is in the project for crying out loud!  Sadly I’m not the only one who has been plagued by this error.  Many Google searches later and still no hard-fast answer that.  I have found one thing that seems to help although it’s a pain to keep doing it over and over again….

  1. Delete the R.java file under the gen folder
  2. Refresh the project
  3. Build Project, not Clean

This, so far, seems to be the only way to consistently get rid of the missing gen folder message….

Edit:

It seems I’m getting more and more traffic to this post.  Christian provided the correct fix below on how to resolve the missing GEN folder in the comments below.  Set the Java version of the project to 1.6 and you’ll be troubled no more.  Thanks Christian.

Objective C

Makes me want to relearn assembler.