Seattle for Visitors
If someone comes to visit you from off world or even out of state, here are some places to go to make their stay more memorable.
- The Experience Music Project (EMP). I’ve heard good and not so good reviews about it. Nevertheless, I’d like to see the inside of it. (I wish I didn’t have to look at the outside of it;-)
- The Museum of Flight: I’ve only heard good things about this place.
- University of Washington: I love those gothic buildings around Red Square. The spring time cherry tree blossoms are definitely worth a walk through.
- Top of Queen Anne: A great views of Seattle.
- Alki Beach: A nice view of Seattle. But don’t go to Salty’s. It’s dreadful and expensive the last couple years:-(
- Seattle Art Museum
- Seattle Asian Art Museum
- Pacific Science Center
- Space Needle: You can visit the top for a quick view and/or have dinner there. The food is nothing to write home about and it’s pricey. But because the whole restaurant revolves 360 degrees every hour, it’s a great way to see Seattle in a relaxed way.
- Deception Pass: A ways north of Seattle, but quite spectacular.
- Chuckanut Drive: If you’re visitors are heading up to Vancouver BC, you might as well go up or come back on the scenic Chuckanut Drive. Also, if you like east coast quality bagels, stop in at the Bagelry in Bellingham, near where a north bound drive on Chuckanut will dump you.
- Olympia Pizza on 15th in Capital Hill: It’s my favorite pizza place for thicker crust pizza. BUT, make sure to order “lite” cheese on the pizza, or you may be overwhelmed by the monstrous amount of cheese they usually put on. If the weather is nice, you can eat outside in front of the restaurant and enjoy the laid back 15th Ave scene.
- Bruce Lee’s Grave: He and his son are buried in the graveyard at the top of Capital Hill. You can get to via 15th Ave. It’s near the Asian Art Museum. Not for everyone, but some people would enjoy visiting it. If you’re into famous graves, you could also visit Jimi Hendrix in Renton.
- Safeco Field: I’m not much into baseball, but a warm summer evening at this baseball park is very enjoyable. Buy the cheapest tickets you can. Then spend most of your time walking around the stadium and sit in any empty good seat you want. They kettle corn they sell outside the stadium is pretty darn good too.
What places do you like to take your out of town visitors to?
Add comment July 26, 2009
Java Wish List
Things I wish Java had:
- A way to get the currently running method name, i.e. Thread.getCurrentThread().getCurrentMethodName(). This would help in unit tests, where I often use the test method name as the basis for usernames, log traces, database values, and directory names etc. For example, when my test needs to login to some service, I’ll create a username like this “<testMethodName>-username”. There are ways to get the current method name, but they involve using unsupported Sun methods or extracting it from a stack trace, both of which are non portable.
- Hmmm…what else?
Add comment June 3, 2009
GroovyWS HTTP Proxy Configuration
Here’s the story of how I got Groovy 1.6.3 and GroovyWS 0.5.0 to call a SOAP service through an HTTP proxy.
As of 28-May-2009, the GroovyWS website said…
Using proxies
If you are using a proxy for accessing internet, you can use the following environment variables to get rid of it:
- proxyHost
- proxyPort
- proxy.user
- proxy.password
or directly use the following in your proxy.setproxypropertie([:])
I tried to make HTTP proxy configuration work by following their instructions. Unfortunately, the following three ways didn’t work
I used various property naming conventions I saw in the GroovyWS javadocs and other online examples.
//A
proxy.setProxyProperties( [ "proxyHost":"proxy.foo.org", proxyPort:"8080", "proxy.user":"myUsername", "proxy.password":"myPassword" ] )
//B
proxy.setProxyProperties( [ "http.proxyHost":"proxy.foo.org", "http.proxyPort":"8080", "http.proxy.user":"myUsername", "http.proxy.password":"myPassword" ] )
//C
proxy.setProxyProperties( [ proxyHost:"proxy.foo.org", proxyPort:"8080", "http.proxy.user":"myUsername", "proxy.password":"myPassword" ] )
However, these two ways did work
//D
System.setProperty(“http.proxyHost”, “proxy.foo.org”)
System.setProperty(“http.proxyPort”, “8080″)
System.setProperty(“http.proxy.user”, “myUsername”)
System.setProperty(“http.proxy.password”, “myPassword”)
//E
System.setProperty(“proxyHost”, “proxy.foo.org”)
System.setProperty(“proxyPort”, “8080″)
System.setProperty(“proxy.user”, “myUsername”)
System.setProperty(“proxy.password”, “myPassword”)
My conclusion is that either I called setProxyProperties() incorrectly or that it doesn’t work. Setting the system properties directly was the only way I got GroovyWS to work through an HTTP proxy.
Here is the final working script:
import groovyx.net.ws.WSClient System.setProperty("proxyHost", "proxy.foo.org") System.setProperty("proxyPort", "8080") System.setProperty("proxy.user", "myUsername") System.setProperty("proxy.password", "myPassword") WSClient proxy = new WSClient("http://www.w3schools.com/webservices/tempconvert.asmx?WSDL", this.class.classLoader) proxy.initialize() def result = proxy.CelsiusToFahrenheit(0) println "You are probably freezing at ${result} degrees Farhenheit"
NOTE: I used the GroovyWS uber jar: groovyws-standalone-0.5.0.jar. Because it was taking too long, I gave up on trying use the GroovyWS minimal jar and then figuring out which CXF dependencies were needed for a simple SOAP client.
Add comment May 28, 2009
Make Subversion Ignore Directories Completely
I want to exclude “log” and other transient directories from SVN. As far as I can tell, SVN’s global ignore example does not show how to exclude a directory itself. But there is a way.
To make SVN completely ignore a directory named “log” and all its contents, add log to the global-ignores line in the ~/.subversion/config file.
This is the only way I’ve found to make SVN 1.5.x & 1.6.x to not show the log directory when I run the svn status command.

Add comment April 20, 2009
Ted’s Steak Making Method
My friend Ted Neyer makes just about the best damn steak in Seattle. He makes steak better than El Gaucho, The Met, Ruth’s Chris Steakhouse, and Daniel’s Broiler. The only restaurant that makes steak better than Ted is Morton’s Steakhouse, and that is probably due to their superior meat.
The steaks Ted cooks to perfection are from Costco. They have really good prices compared to grocery stores. Also, they sell so much meat so fast, that you can be sure it’s fresh.
There is nothing fancy about how Ted cooks steak, except how it tastes. He uses a big cast iron frying pan on a gas stove top, but can do just as well on an electric stove top. The only fancy thing that Ted needs to cook steak is a powerful exhaust fan because, with exception of Filet Mignon, steak cooked at high temperatures puts out a lot of greasy smoke.
The Method
- Buy steaks from Costco: New York, Filet Mignon, or best of all Rib Eye. Don’t be shy, buy thick ones.
- Take the steak out of the fridge and let it sit until it reaches room temperature.
- Soak the steak in light olive oil, Johnny’s Seasoning, & ground pepper for about 20 minutes. (I used to not like pepper on steak, but Ted showed me the error of my ways)
- Heat up your cast iron frying pan until it just starts to smoke. In other words, it ought to be pretty dang hot.
- Cook the steak 4 minutes per side. The goal is to create a black crust that seals in the flavor, but leaves the center rare to medium rare.
- If you’re concerned that you didn’t cook it enough, you can put it in a 350º-375º oven. Use an electronic thermometer to watch the temperature. For rare-ish steak, keep it in until it reaches 115º. For medium rare to medium, let it reach 135°.
- After taking it out of the pan or oven, don’t eat it yet! Let it rest, under a foil tent, for about 5 minutes. It needs time for the juices to settle down and soak back in. If you don’t wait, when you cut into it the steak, the juice will flow out onto the plate, where it won’t be able to add flavor to the meat.
When all is said and done, but before the eating begins, you could end up with this.

filet mignon, ricotta, and asparagus
If steak ends up becoming a big part of your diet, then you may be interested in one of these.

Add comment March 31, 2009
HttpClient Proxy Configuration
I recently wrote a Java client to upload files over HTTP/S using Apache’s HttpClient. My client had to go through a password protected proxy. Googling found many examples of setting a proxy, but almost none showing how to set the proxy username and password. So without further ado, here’s how to do it:
HttpClient client = new HttpClient();
AuthScope proxyAuthScope =
new AuthScope( "proxy.mycompany.com",8080);
UsernamePasswordCredentials proxyCreds =
new UsernamePasswordCredentials( "myUsername","myPassword");
client.getState().setProxyCredentials(proxyAuthScope, proxyCreds);
client.getHostConfiguration().setProxy("proxy.mycompany.com",8080);
Add comment March 11, 2009
Amazing Ubuntu 8.10
For years and years and years I searched for a usable version of Linux. Until recently, the closest thing was SUSE 11. But things have changed recently, I tried Ubuntu again, and it’s frickin amazing. This blog entry catalogs my continuing amazements and a few frustrations:
Amazements
- Installing stuff is sooooo easy. I just type sudo apt-get install and it’s done!
- Ubuntu’s wireless connection manager sees all the wireless networks in my neighborhood. It even lets me easily connect to the one in my house! Red Hat and Mandriva didn’t do that.
- I wanted to print a document today. I marched up to my HP printer, plugged in the USB cable, and within two minutes Ubuntu said the printer was ready to use. Then I just printed my document. Imagine that. Not even Windows ever automagically recognized the exact printer model and got it all configured and ready for me to use.
- I used to always prefer the KDE desktop. But the Ubuntu folks have done such a fine job of picking good Gnome apps and making them play nice together, that I’m happy to use the Gnome desktop. KDE really shot themselves in the foot with the premature release of KDE verison 4. It was unstable and it lost hours of my work (even though my work was saved).
- The Rhythmbox music player works great. I right click on songs in the file browser and open and play them!
- The BitTorrent client Deluge works as good as uTorrent.
- The file compression utility built-in to the Nautilus file browser understands every compression format I know of, even my favorite 7zip.
- Ubuntu automatically mounts NTFS USB hard drives. I can even copy files to NTFS drives without corrupting the disk like SUSE did. SUSE also won’t automount an NTFS drive without manually editing the fstab file. What were they thinking?
- The screen graphics, font crispness, and refresh speed on Ubuntu is acceptable. Some how Red Hat fonts looked best on my Dell LCD and ThinkPad screens. Odd that a server oriented distribution would do that. SUSE’s fonts (for a long, long time) have look dreadful on LCD screens. For some odd reason, they go the extra mile to make text look very unpleasant on LCDs.
Frustrations
- Whenever I startup Ubuntu or resume from hibernation, I’m asked for the password to a keyring where it stored my wireless network password. Ubuntu didn’t ask me to save my wireless password to a keyring, it just did it. It really should’ve asked, so I could say NO. Windows is much nicer, it just lets me use my wireless connection. I don’t know why Ubuntu makes it so hard. I did some research and this problem has plagued Ubuntu for several releases. They claim to have fixed it, but clearly they didn’t.
- Because it’s the first Linux distribution that might actually free me from Microsoft, I want to give Ubuntu some money. I want them to be successful. But the only way I can see on their web site to give them money, is to pay $250 for a year’s worth of technical support. Well, I like Ubuntu, but not that much. I only want to give them $50. If it keeps improving, I’ll give them $50 next year too. But I see no way to do it on their web site. They’re throwing away money by not having a “Donate” button.
- VMWare and Ubuntu’s preferred virtualization application, KVM, barely coexist. My battery ran out while VMWare was running. When I restored power, VMWare could not run because KVM was auto-loaded when Ubuntu started. Somehow, during the crash, KVM retook control of the “…virtualization capabilities of my computer…”, which meant no other virtual machine app could run. This happened even after I had completely uninstalled all KVM packages. I think it’s fine for Ubuntu to choose a virtualization application and even compile it into the Linux kernel. I just wish they’d provide a straight forward way for a mere mortal to stop/remove it. I ended up reinstalling VMWare, which was able to flip some magic switch to prevent KVM from loading.

1 comment February 22, 2009
Movie Picks
Worth Seeing
- Gran Torino: Man-o-man, Clint Eastwood is a national treasure.
- Slumdog Millionaire: It’s currently riding a wave of Oscar hype. You might be disappointed if you expect too much. But with reasonable expectations, you’ll like it. You’ll also learn about real life in India, even if many Indians don’t want you to see it. It’s a flashback type of film, where the whole story isn’t clear until the end, which makes it more interesting to watch.
- Groundhog Day: My all-time favorite movie. Bill Murray and Andie MacDowell, at his best and her prettiest.
- Grosse Pointe Blank: Akroyd, Cusack, and Mini Driver. A very funny movie about assassins.
- The Increadibles: Best animated movie to date.
- The Bourne Identity: Best of the three Bourne movies.
- Out of Sight: Good chemistry between JLo and Clooney.
- Sin City: Astounding mixture of good actors (Mickey Rourke, Clive Owen, & Jessica Alba) and comic book graphics.
- The World’s Fastest Indian: Amazing and true story. Anthony Hopkin’s best film in 20 years.
- Kung Fu Hustle: Shattered my conceptions of Chinese cinema and sense of humor.
- The Life Aquatic with Steve Zissou: Bill Murray’s 2nd best movie. A must see for Murray fans.
- Sex, Lies, and Video Tape: Hard to describe. Evokes lots of different emotions. Each actor’s performance is superb.
- American Beauty: Both funny and sad. One of Kevin Spacey’s best movies (and he’s got a lot of them).
- Lord of War: Nicolas Cage in a funny movie with a message.
- You Kill Me: Ben Kingsley: the most versatile actor I know of.
- I Am Legend: Will Smith: likable, earnest, and he saves the world again!
Not Worth Seeing
- Max Payne: I wanted to like this. I’m a Mark Wahlberg fan. But he needs a new agent. He picks so many bad movies to be in, and this is another. One silly thing is that they kill off Olga Kurylenko’s (world’s sexiest women contender) character within minutes. This movie is supposed to have spiritual overtones, but Wahlberg doesn’t really have the depth to pull it off. Plus the computer graphics aren’t very polished. Too bad. I really like Wahlberg and wanted to enjoy this movie.
- The Wrestler: If you’re an artsy type, who enjoys movies just for the acting, you’ll like this film. But I watch movies for fun or to be uplifted in some way. This movie is just a downer. If you don’t see it, you won’t have missed anything.

Add comment February 22, 2009
Create an Executable Jar with Maven
There are several ways to make an executable jar with Maven. Two popular ways are to use the maven-jar-plugin or use the maven-assembly-plugin. Each has pro’s and con’s.
With the maven-jar-plugin, your executable jar won’t include it’s dependencies. But I want my executable jars to include everything needed to run. A benefit of the Jar plugin is that, the executable jar is your project’s main artifact and it has the name you expect. Either ${project.name} or ${project.build.finalName}.
Using the maven-assembly-plugin lets you include all dependencies in the executable jar. But the jar isn’t your project’s main articifact It also typically requires a separate assembly definition file. You can use a default descriptorRef “jar-with-dependencies” to avoid that, but then you’re stuck with a final jar name with “-jar-with-dependencies” appended to it. Another problem is that when the Assembly plugin adds dependencies, it includes all their dependencies too. This can quickly lead to a gigantic final jar.
I think I’ve found a simpler way to create an all-in-one executable jar. This method uses the maven-jar-plugin along with the maven-shade-plugin. The Shade plugin lets you add dependencies. Fortunately, by default, it only includes your project’s direct dependencies and no transitive dependencies. (If you need a few transitive dependencies, the Shade plugin lets you.) As a result, the executable jar is slim and trim. Another plus, the final executable jar has the name you want and is the project’s primary artifact.
Below is an example of the plugin definitions needed to create an all-in-one executable jar using Maven’s Jar and Shade plugins:
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-jar-plugin</artifactId>
<configuration>
<archive>
<manifest>
<mainClass>org.foo.MyMain</mainClass>
</manifest>
</archive>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-shade-plugin</artifactId>
<version>1.2</version>
<executions>
<execution>
<phase>package</phase>
<goals>
<goal>shade</goal>
</goals>
<configuration>
<artifactSet>
<!-- Use this to in/exclude only specific dependencies -->
<includes>
<include>commons-codec:commons-codec</include>
</includes>
</artifactSet>
<transformers>
<transformer implementation="org.apache.maven.plugins.shade.resource.ComponentsXmlResourceTransformer" />
</transformers>
</configuration>
</execution>
</executions>
</plugin>

1 comment February 18, 2009
NetBeans 6.5 Better Than 6.0?
With the recent release of NetBeans 6.5, I’m giving it another try. In the past NetBeans (NB) has never failed to disappoint. Those NetBeaners have been better at hype than delivering a usable IDE. But, maybe things are different this time around. So far, here’s what I’ve found:
Pro’s
- As advertised, NB opens and runs Maven and Grails projects right out of the box. Gotta like that.
- It works well on Ubuntu 8.10 (as in, no errors yet), while my Intellij IDEA 7.0.5 has problems (can’t remember which JDK it’s supposed to be using).
- A recent PHP IDE review was rather complimentary toward NB (especially version 7 Milestone 1) as being one of the best PHP editors. Good for me since I gave up trying to find a reasonably priced Java Web Host and will be using PHP and/or Rails for server side stuff on personal web projects.
- Groovy code completion worked great. NB correctly inferred variable types and showed me only the relevant methods. IDEA’s JetGroovy plugin can’t figure out variables declared with “def” and shows you absurdly long lists of every possible method, seemingly from many Class types. Good code completion really helps me learn a new language.
Con’s
- Is it really necessary to force people into a 249 MB download to try Netbeans various languages and features (hint: no)? [Sun, you just look desperate when you force people to download your GlassFish server (not one but two different versions). Tomcat is really all what most people want for JEE development. Not many people need a full blown EJB container, so offer a JEE download that doesn't include GlassFish darnit.]
- NB uses quite a bit more memory than IDEA. I’m guessing on average, about twice as much. Good thing memory is cheap.
I am hoping NB continues to work well. I’d love to break my addiction to the usable but stagnant Intellij IDEA.

Add comment February 17, 2009