Apple OS X Lion Review – Part 2

In my release-day review of Apple’s Mac OS X Lion, I shared my initial impressions of the operating system while highlighting the key differences from previous versions. I also pointed some features users might not like. Now, two weeks later, I am much more appreciative of OS X Lion and wondering how I lived without certain features, such as full-screen mode. There are still some things I am not too fond of, but overall I have a much more favorable view of the new OS X after spending two weeks with it.

1. Full-Screen & Spaces Magic

Apple originally released Spaces with Mac OS Leopard 10.5, but until OS X Lion 10.7 I had never really used it. Spaces utilizes multiple virtual desktops in which to launch applications. The beauty of Apple’s implementation of full-screen mode is that it auto-magically creates and removes Spaces as the user switches into and out of full-screen mode. As a developer, I’m impressed by the clever re-use of existing functionality in an entirely new way. As a user, I like the new interface and beauty with which it works.

I was in the Apple Store over the weekend and compared the new 11″ MacBook Air running Safari in full-screen mode with a 13″ MacBook Air running the same application in windowed mode. Surprisingly, the height of the window was nearly the same. By introducing full-screen mode, Apple has essentially increased the screen size of all existing Macs, making the 11″ feasible as a true laptop replacement for the first time.

The addition of full-screen mode throughout the OS is probably the single most important feature Apple has release in OS X Lion. I only wish more third party applications, such as Microsoft Office and TextMate (the best Mac text editor) supported it automatically, but we will have to wait for a software update from the vendors. For those using Eclipse, Alex Blewitt has provided an unofficial update to support full-screen mode in OS X Lion that works perfectly in Eclipse 3.7 Indigo, although unfortunately not in previous versions of Eclipse. There is some concern that large manufacturers, like Adobe and Microsoft, could charge an upgrade fee for the next version that includes full-screen support, but this is up the individual vendors to decide.

2. New Mail App

In my initial Mac OS X Lion review, I indicated that I liked the Mail application, but did not go into much detail. After two weeks of using it, I’ve come to the realization that I love the streamlined, full-screen interface. It makes reading mail much simpler and less cumbersome than most modern mail applications, such as Mozilla Thunderbird or Microsoft Outlook. Also, I really like the conversations interface, borrowed a bit from Google’s Gmail web interface, which shows related messages, including your replies, in a single vertical view. Overall, this makeover makes for a much more solid, user-friendly application.

3. New Multi-Touch Gestures

The new 3-finger gestures are quite fun to use, such as pinching to make the Launchpad appear, or sliding the current page back in Safari, as an alternative to the back button. While it is getting a little difficult to remember all the different gestures available, they are playful and add a new level to the Mac. I have noticed some novice users trip up on multi-touch gestures though. For example, a particular family member of mine accidentally zoomed out on her Desktop resulting in all of the desktop icons shrinking to an unusable size. I would recommend that Apple turns off many of the advanced multi-touch gestures and enables them gradually and with the user’s permission, so that less skilled users understand how they work better.

4. All My Files: The Onion Prophecy Comes True!

Over two years ago, The Onion released a video showing a mock MacBook Wheel laptop, in which the entire keyboard is replaced by a single button, in part to mock Apple’s reliance on single-button hardware. In the video [at 1:06], they show a user searching their computer with all of the files in a single folder. Apparently, someone at Apple was taking notes, because the new version OS X Lion comes with an “All My Files” option in the finder menu. If you are like me, and have thousands of documents, I have no idea when this feature would ever be useful. In fact, if you use iPhoto and iTunes to manage all of your photos and music, there is never a reason to include them in this window. Overall, this feature seems like a last minute addition by an unskilled developer that probably should have never made it to the final build. You can turn this feature off by either right-clicking on it and removing it from the Sidebar, or unchecking the option in Finder -> Preferences -> Sidebar. Since it found thousands of useless icons and web files, I turned this feature off after a week as I decided it was a complete waste of time for anyone with more than a few dozen content items on their computer.

5. The Leftovers: What’s still bad

After reflecting on the topic, I’ve come to realize Mission Control, while useful, is so much like Exposé, that Apple really shouldn’t be highlighting this as a brand new feature. Perhaps not enough people were using Exposé, but this feels like a completely recycled feature with nothing of value added.

As for Natural Scrolling, in which they reversed horizontal and vertical scroll directions in OS X Lion, one person suggested they were trying to make a consistent interface with the iPad. If Apple ever does release a touch-screen Mac, this would certainly be the ground work for it. I decided to re-enable the natural scrolling following launch day and ultimately, it makes no difference to me which method I use. I still contend changing a major component of a user interface without explicitly informing the user is a horrible idea, as it tends to confuse the less-informed user base.

Finally, if you are Rosetta user who depends on older versions of applications, you may want to postpone upgrading at this time. I still content Microsoft Office 2004, which no longer works in OS X Lion, is the best version of Office released for Mac in the last decade due to its exclusion of the annoying ribbon, and inclusion of scripting support removed in Microsoft Office 2008. Users of Adobe CS2 or earlier, or those Photoshop CS3/CS4 users that rely on Droplets for batch processing, should likewise wait, as these products no longer function in OS X Lion and Adobe products can be quite pricey to replace. Unfortunately, Adobe has announced that it will not be providing Droplet support for CS3/CS4 users.

Minor Installation Woes

Having experienced serious installations issues on release day with Snow Leopard, I am pleased to report the installation of OS X Lion amongst my family members went almost entirely without problems. One computer did have a minor issue in which it restarted in Lion Recovery mode following the first reboot part of the installation. I needed to select the built-in hard drive as the Start Up disk, reboot the computer, then restart the entire installation. This solution worked, and have not seen any other installation issues.

Conclusion

The performance issues that I reported in my first review of OS X Lion eventually subsided, although it took all day. Between Spotlight indexing the entire hard drive and Time Machine backing up all of the changes, my computer was so hot I couldn’t touch it for hours after installation. Since then, the performance has been about the same as in 10.6 Snow Leopard, the previous version of Mac OS X. At this point, I am changing my satisfaction with OS X Lion from 35% previously reported to 90%, with the bulk of it stemming from the new full-screen mode that makes an 11″ MacBook Air perform like a 13″ MacBook Air.

There are still some rough edges, but overall this update is a welcome change and, unless you are one of those unfortunate users dependent on a Rosetta application, it is no-brainer upgrade at a $30 per household and a nearly error-free installation.

downloading java 7 for the mac and a ubuntu linux vm

I’ve been thinking about setting up a Linux VM on my Mac for a little while now.  I already have a Chrome VM.   While I installed Java 7 on my Mac yesterday from Open JDK, I also wanted an “official” version.  In case I come across anything odd, I want a way to know if it is from the Mac version being not quite ready or “the way things work.”  Which gave me a reason/excuse to install the Linux VM.  This blog entry is about how to get started.

WARNING: Java 7 is not yet production ready.  See Java 7 Ships with Severe Bug.  (it has to do with loops not functioning properly and affects Lucene and likely other things.)

For the Mac

Download and install

  1. Download Java 7 dmg file
  2. Install it
  3. Optional go to Java in system preferences to choose Java 7 as default.  (I did not do this since it sounds experimental with known buts at this point.)
  4. Note the install location to reference is /Library/Java/JavaVirtualMachines/1.7.0.jdk/Contents/Home/bin.

Pointing to Java 7

Since Java 7 has reported stability problems, I didn’t want to set it in my PATH but only use it for selected command line invocations.  To facilitate, I set up the following in my .bash_profile:
alias javac7='/Library/Java/JavaVirtualMachines/1.7.0.jdk/Contents/Home/bin/javac'
alias java7='/Library/Java/JavaVirtualMachines/1.7.0.jdk/Contents/Home/bin/java'

To validate the aliases are working:

Jeanne-Boyarskys-MacBook-Pro:~ nyjeanne$ javac7 -version
javac 1.7.0-internal
Jeanne-Boyarskys-MacBook-Pro:~ nyjeanne$ java7 -version
openjdk version "1.7.0-internal"
OpenJDK Runtime Environment (build 1.7.0-internal-b00)
OpenJDK 64-Bit Server VM (build 21.0-b17, mixed mode)

Linux VM on VirtualBox

Download and install

  1. Download ubutntu iso file.   It took a number of hours to download the iso file.  (I let it run overnight.)  While the download was less than 100MB, I downloaded Lion the night before (over 3GB) so my ISP may be throttling my connection speed now.  That or a slow server.  Note that you don’t need to create a USB stick or CD.  Just the iso file is fine.
  2. Create a new VirtualBox VM and set CD drive to read from the downloaded iso file.  Even those these instructions are for Windows, they were easy to follow on a Mac.
  3. Try to downloadthe .tar.gz file for Java 7.  I got a page not found so I tried the .rpm file.  This gave me errors when I installed and tried to run it.
     javac -version gave:
    Error occurred during initialization of VM.  java/lang/NoClassDefFoundError: java/lang/Object
  4. Deleted the bad install.
  5. Tried again to download the .tar.gz file for Java 7.  This time the path was found.

Pointing to Java 7

Since my Linux machine is a VM specifically for trying Windows 7, I felt safe adding it to the beginning of my PATH in the .profile file.

A really simple Java program

A really simple program using a Java 7 feature to further test your setup.

<pre>import java.util.*;

public class JeanneTest {
  public static void main(String... args) {
    System.out.println("test");
    Set<String> test = new HashSet<>();
  }
}

Connecting to MS Access Files via JDBC in 64-bit Java

In 32-bit Java, the technique for connecting to a Microsoft Access file via JDBC connection is well-known and available as part of the Sun JDK. There are a number of errors, though, if you attempt to use a 64-bit version of Java that are not as well documented. This article points out some of those issues and a working strategy for how to successfully connect to a Microsoft Access file via JDBC in 64-bit Java.

1. Review of the 32-bit Connection Strategy

The well-known syntax for connecting to an Microsoft Access file via JDBC is as follows:

final String fileName = "c:/myDataBase.mdb";
Connection con = null;
try {
	Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");
	String url = "jdbc:odbc:Driver={Microsoft Access Driver (*.mdb)};DBQ="+fileName;
	con = DriverManager.getConnection(url,"","");
} catch (Exception e) {
	// Handle exceptions
	...
} finally {
	try { if(con!=null) {con.close();} } catch (Exception e) {}
}

If you are using the Sun JDK, then the driver will be available in the classpath automatically. Notice, I make sure to close my connection object in a finally block as all good JDBC developers know to do.

2. Errors in the 64-bit World

Attempting to run the proceeding code returns the following error when using a 64-bit JDK:

[Microsoft][ODBC Driver Manager] Data source name not found and no default driver specified

If you would prefer to stick with the 32-bit version of the driver, there are two options available:

  • Use the 64-bit Java installation but run java.exe with the “-D32” flag.
  • Use a 32-bit Java installation

Both of these solutions limit the amount of memory a Java application can use.

3. Adapting JDBC to 64-bit Java

If you would prefer to use the 64-bit Java, there is a solution, although for some users this may require removing Microsoft Office.

Step #1: Download the Microsoft Access Database Engine 2010 Redistributable, specifically the AccessDatabaseEngine_x64.exe file.

Step #2: Install the Microsoft Access Database Engine. If you are running a 32-bit version of Microsoft Office, you will likely get the following error when you try to install it:

You cannot install the 64-bit version of Office 2010 because you have 32-bit Office products installed.

At this point, you must decide whether or not to uninstall the 32-bit version of Microsoft Office. Newer versions of Office, such as 2010, often contain both 32-bit and 64-bit versions on the installation DVD, although the 32-bit version is used by default when installed via the AutoRun process. In this case, you would first uninstall the 32-bit version of Office. Restart the computer. Then, ignore the AutoRun on the DVD and manually open the setup executable in the x64 directory. After a 64-bit Office version is installed, continue with the Microsoft Access Database Engine installation.

Note: If you are installing a recent 64-bit version of Microsoft Office, you may be able to skip installing the Microsoft Access Database Engine, as it is often included in the Office installation.

If a 64-bit version of Office is not available, then you will unable to run the 32-bit version of Microsoft Office alongside the 64-bit Microsoft Access Database Engine, and must decide which is more important.

Step #3 Update the JDBC code to use the following revised connection string as follows:

final String fileName = "c:/myDataBase.mdb";
Connection con = null;
try {
	Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");
	String url = "jdbc:odbc:Driver={Microsoft Access Driver (*.mdb, *.accdb)};DBQ="+fileName;
	con = DriverManager.getConnection(url,"","");
} catch (Exception e) {
	// Handle exceptions
	...
} finally {
	try { if(con!=null) {con.close();} } catch (Exception e) {}
}

After making these changes, you should be able to connect to your Access database in 64-bit Java.