Java 6 and JDBC 4.0

I just migrated a 4,000+ Java class project from Java 1.4.2 to Java 6. I’ve already mentioned some of the issues to be aware of when migrating a large code base to Java 6. In Java 6, enum is a reserved keyword so I had to renaming variables that had that name, I also had to upgrade to a more recent version of Apache Commons Lang for a similar reason. I also had minor issues compilation issues, such as the removal of compareTo(Object obj) method was removed from the String class, and Apache classes that once shipped with the JRE 1.4.2 where removed.

But what irked me the most about Java 6 was recent changes to JDBC 4.0. The ResultSet interface, in Java 6, has 197 methods that need be be implemented if you are working with custom ResultSet implementation. I am just shocked at the sheer number of methods required for a basic ResultSet, most of which are not used, or will ever be used by our custom implementation! This is what is wrong with Java. The good thing is that Eclipse auto code generation features saved me from typing all of those methods but I wished there was a basic ‘do nothing’ abstract adapter like WindowAdapter.

Technorati Tags: , , , , , ,

Enjoy. Share. Be Happy.
  • Twitter
  • Facebook
  • StumbleUpon
  • del.icio.us
  • Tumblr
  • Google Bookmarks
  • FriendFeed
  • Yahoo! Buzz
  • Reddit
  • Digg
  • HackerNews
  • Suggest to Techmeme via Twitter
  • LinkedIn
  • Ping.fm
  • Identi.ca
  • Mixx
  • Furl

Related posts:

  1. Migrating to Java 6
  2. JDBC and SQL Server 2005
  3. Java SE 6 Released
  4. Visual Basic And The Java Platform
  5. Java, Ruby, and even Python Sucks

This entry was posted in Java, Programming, Rant. Bookmark the permalink. Post a comment or leave a trackback: Trackback URL.

Post a Comment

Your email is never published nor shared. Required fields are marked *

*
*