Friday, May 15, 2009

Steer for the deep waters only

A cool quote by Walt Whitman that I think about sometimes when I am learning new things and trying to adapt them for use...

"Sail Forth- Steer for the deep waters only. Reckless O soul, exploring. I with thee and thou with me. For we are bound where mariner has not yet dared go. And we will risk the ship, ourselves, and all."

This quote and other writings by Walt Whitman were used in Ralph Vaughn Williams' first symphony - A Sea Symphony, which is also really cool.

Wednesday, May 13, 2009

IRC - Internet Relay Chat

For those who don't know what irc is - it's basically a chat service where you can ask and answer questions and discuss technologies. There are several development oriented channels out there. On irc.freenode.net (more info), there are channels like #jquery, #hudson, #spring, #hibernate, #jsf, #oracle, #jython, #intellij, #eclipse, and many many others. Organizations like mozilla (irc.mozilla.org) have their own irc server. Sometimes you have to hunt down where a channel might live. For example the #maven channel is found on irc.codehaus.org (more info). Often, developers of that particular technology lurk in the channels as well.

For those used to a chatroom where people constantly monitor the goings on, IRC is a bit different. True there are often several people in a channel at a time. However, they often stay logged in at work and possibly while they are away from their computer. Therefore, depending on the channel, you might need to wait 10 or 20 minutes for a response to a general question. If you know who you would like to ask, then use their username in your question or comment. That usually triggers a notification in their IRC client and they are more apt to answer if they are around.

More information about irc and different clients can be found here:
http://en.wikipedia.org/wiki/Internet_Relay_Chat
http://freenode.net/faq.shtml#whatwhy - why freenode exists

Clients:

Tuesday, May 12, 2009

Site-specific browsers (SSB)

Site-specific browsers are kind of a hobby topic for me because of their utility. I often find that there are things like GMail, Jira, and others that seem to fit a mold where they are kind of a world of their own, a self-contained web application. If I use something like that with any degree of frequency, I consider making it into a site-specific browser instance.

Some of the basic niceties that I've found for my use include:
  • - Ability to choose an icon for the SSB
  • - Modify the URL that is being used upon creation of the SSB
  • - Show/don't show navigation controls
  • - Hotkey support
  • - Show/don't show the status bar

A few of the SSBs that I've tried on various platforms include:

Fluid

By far, fluid (mac only) is the best that I've seen for my needs. It is essentially a layer on top of the webkit browser on the mac. It has all of the basics and much, much more. It is the most configurable, almost to a fault interface-wise. It can integrate with Growl on the mac, which allows for desktop notification. It has greasekit support. That opens up tons of possibilities. That is part of the plugin support. It also has a few themes for the UI itself. One of the nicest features is to allow for regular expressions of which sites it allows within the SSB. Along with that you can default to another browser for external linking. This makes Google Reader or other web based RSS aggregator quite useful in fluid. You can configure it to open rss feed links in the external browser in the background, so you can scan all of the new items and then go to, say, Firefox (with adblock plus) to actually read the stories. Besides all that, it allows for tabbed browsing with the SSB if you wish. My rating for fluid is awesome, based on a scale from 0 to awesome.

Chrome

Chrome is okay. It is essentially a beta SSB in my mind. It seems that currently, they're just throwing out the notion of using GMail, Google apps, etc. as their own app within Chrome on the desktop. However, it's still pretty clunky. There is no support for browser controls. There is no support for modifying the URL. There is almost no configuration of any kind. It makes it simple in a good and bad way. The only thing you *can* configure is where a shortcut can be placed. I think with the competition and the resources they're putting into it, it will improve. Google I/O is coming up and I'm thinking that they'll announce a pretty great roadmap for the browser. Cross-platform support and plugins seem to be foremost on their minds right now though, so SSB functionality/configurability might take a little while, depending on their strategy for Chrome. You never know with Google.

Prism

Mozilla started Prism, then it got to version 0.9.x in the Summer of 2008, then it fell off the face of the Earth. There was no real development again until they released version 1.0 beta recently with an updated site. Since I am currently using windows and linux, the latest prism update is my option of choice. Prism is kind of the middle ground between chrome and fluid. It allows for some configurability and with the Firefox plugin, it allows you to create a shortcut or prism application right from Firefox. Addons seem to be coming as there is a configuration option for them in each prism instance. The inclusion of addons would definitely set it apart. However currently, the list of available addons (and themes) for prism is empty. I do like the fact that it tries to integrate well with the platform too. You can have it minimize to the system tray on windows, leaving your task bar real estate for other things. One other new feature that I like is the auto-update functionality. Fluid has to update each instance individually, but it looks like prism allows for updating across all instances.

Bubbles

Bubbles is another contender that is based on the IE engine and is therefore limited to Windows. I don't personally like windows very much but I've found value in creating a "bubble" for Outlook Web Access. Its main goal, it seems, is to create a variety of pre-built bubbles for things like GMail so that people can just use them. It does a decent job and might be like a fluid for windows. However, I don't like the IE engine and I don't like windows. Besides that it has a central interface for your bubbles, which I don't particularly like. Updating is always a hassle with SSBs so I can see where a centrally managed set of SSBs is nice.

Others

Safari 4.0 on Snow Leopard (Mac OS 10.6) supposedly will have SSB support, like is sort of does on the iPhone. It will be interesting to see how Apple approaches it. Generally I like many of their defaults, but I'm usually underwhelmed by what they provide with configurability with Safari. Come on Apple, let's see some plugin support.

I briefly also tried Mango SSB, but at that point I was kind of sick of trying new SSB engines...

Anyway, it seems like an interesting space that will see quite a bit of development over the next 6-12 months. I'm hoping that this blog entry will be quite ancient in SSB progress by then.

Tuesday, May 5, 2009

Virtual Box

I am currently trying out Virtual Box. It's an OSS virtualization product managed by Sun.

I come from having used a mac these last few years and had gotten used to the warring between Parallels Desktop and VMWare Fusion. Both of those progressed nicely over time and remind me why competition is so great for the consumer.

Virtual Box takes a different approach with its open-source codebase, with the option to utilize some proprietary extensions in the closed-source version.

My plan is to use it as a container for a winxp machine for testing and windows-necessary stuff like MS Office. Currently the host for that vm is winxp too, but when the vm is ready, I'm planning to move to Ubuntu (jaunty jackalope) as the host.

So far, Virtual Box has satisfied my needs. It has a seamless mode to sort of have the programs running in vm look like they are just programs running in the host. It's not as elegantly done as the other two I've used in the past, but it's functional. For example alt-tab, when in seamless mode, only switches between the vm's applications. The Virtual Box Guest Additions provide the mouse pass-through mode so you can more easily switch between host and vm. And from what it looks like networking and audio also appear to work (in winxp and ubuntu at least).

Things I wish it had were drag-and-drop file support and a better seamless mode. One other thing I found out from the IRC channel is that in order to move a vm from one platform to another, you need to make sure you export and import the vm. I was used to just copying the vm file in vmware fusion at least, but that's not a frequent operation. Features/enhancements like those may come in the future though and it's hard to argue with the price.

One thing that is quite nice about virtual box though is the community. If I have a question, I search online or I can check out the IRC channel (#virtualbox on irc.freenode.net). I had some questions earlier and they were quite friendly and responsive (on the IRC channel).

All-in-all, I am quite impressed with it thus far.

Friday, May 1, 2009

JPA composite key craziness (vs. SQL Alchemy)

I know that a framework generally isn't designed to handle edge use cases gracefully. The old saying goes that you make the common case fast and the rare case possible. That often turns out to be the case for frameworks as well.

I was trying to map a composite key that made up an Oracle view - two foreign keys. The JPA is sadly very complicated with its mapping of composite keys (hibernate doc link). I heard stories around the office like, "I think XXX tried to do one of those, but then he backed out those changes." and "I did one of those once (shudder)."

In response to my ranting, a python guru friend of mine who works on both python code and java code regularly, told me that SQL Alchemy has had support for composite keys since version 0.1. He said it's pretty simple... Too bad. Too bad the JPA standard isn't better. However, maybe now that Oracle is buying Sun, the JPA will get a shot in the arm.