OS X Ruby Troubleshooting: “command not found: dot”
If you’re trying to run rdoc but are getting errors like..
Generating HTML…
Diagrams: ./opt/local/lib/ruby/vendor_ruby/1.8/rubygems/custom_require.rb:27: command not found: dot -Tismap dot/f_0.dot
./opt/local/lib/ruby/vendor_ruby/1.8/rubygems/custom_require.rb:27: command not found: dot -Tismap dot/f_1.dot
..the package you need to install is called graphviz. You can install it using Darwin Ports on OS X like so..
sudo port install graphviz
Tags: graphviz, osx, ruby, troubleshooting
Parallels Desktop Coherence Mode Rocks: OS X/Windows XP Screenshot
I tried Parallels Desktop’s Coherence mode today, and was so blown away I had to blog about it immediately.

The above image has not been doctored. It’s my normal OS X desktop with Windows XP running in coherence mode. When activated, the window around the XP virtualization session vanishes, the XP taskbar integrates into your OS X desktop, and XP application windows are free to float around. With Parallels Tools installed each XP application has a dock item which can be Command-Tabbed to. If you look closely you can see I’m running IE 6 next to Safari, both natively, without the visual distraction of the virtualization window. This is a huge usability landmark. Thank you Parallels!
Try it yourself by selecting the View -> Coherence menu option when running Parallels Desktop.
(Question: Does VMWare currently have a feature like this?)
Tags: development, opinion, osx, parallels, virtualization, windows
SRP Time-of-Use Plan Hourly Price Change Reminder
To those on SRP’s time-of-use plan, reprogram your thermostats! On May 1st we’ll be entering into the expensive months.
- 1pm - 8pm weekdays are “on-peak”: 17.83¢/kWh.
- All other hours and holidays are “off-peak”: 4.88¢/kWh.
From here. If you live in a hot area and do not have a programmable thermostat, you absolutely must get one. If you live in Phoenix you’ll more than recoup the cost in a single summer.
Tags: energy, environment, news, reminder
J2ME Acronym Cheat Sheet
Sometimes I think we’ll eventually run out of TLAs (three letter acronyms) in the Java space. Here’s a quick reference for the forgetful..
- ABB (Audio Building Block)
- API (Application Programming Interface)
- BCC (Bluetooth Control Center)
- BPWD (W3C Mobile Web Best Practices Working Group)
- CBS (Cell Broadcast Service)
- CDC (Connect Device Configuration)
- CLDC (Connected, Limited Device Configuration)
- CSS (Cascading Style Shee)
- CSS-MP (Cascading Style Sheet - Mobile Profile)
- DDC (Default Delivery Context)
- GCF (Generic Connection Framework)
- J2ME/JME (Java Micro Edition)
- JTWI (Java Technology for the Wireless Industry)
- JMF (Java Media Framework)
- JSR (Java Specification Request)
- JVM (Java Virtual Machine)
- MMAPI (Mobile Media API)
- OBEX (Object Exchange Protocol)
- OMA (Open Mobile Alliance)
- PAN (Personal Area Network)
- PDA (Personal Digital Assistant)
- PDAP (PDA Profile)
- PIM (Personal Information Management)
- MIDP (Mobile Information Device Profile)
- MMS (Multimedia Message Service)
- SMS (Short Message Service)
- SDD (Service Discovery Database)
- UAP (User Agent Profile)
- WAP (Wireless Application Protocol)
- WCSS (Wireless Cascading Style Sheet)
- WMA (Wireless Messaging API)
- WML (Wireless Markup Languge)
- WTK (The Sun Java Wireless Toolkit/J2ME Wireless Toolkit)
- XHTML-MP (XHTML Mobile Profile)
5 Roadblocks To Enterprise Rails Acceptance
I love Rails for its pragmatic design and agile culture: two qualities not usually associated with the large, enterprisey systems of Fortune 500 companies. In my last formal position I was part of a small internal movement to drive the Rails train upward through the IT ranks, but the effort was met with limited success. The unfortunately reality is that Rails currently lacks several key qualities to which enterprise project leaders have become accustomed. Here are five reasons of varying significance to start us off.
Insane Query Support
Most documentation you read about ActiveRecord will take you through tidy, minimalistic examples which are squeaky clean and really fast. Complex queries, however, will be easier to do using Model.find_by_sql, which accepts a raw SQL query. Ordinary dynamic finds with deep loading behavior may require you to hard-code names in the query to avoid issues with the generated SQL. ActiveRecord is way easier to use, but far from Hibernate. I’d say that over 95% of the queries issued by a larger application are of trivial or medium complexity, but a lot of time and your best developers go into that last 5%, and this is where the heavier OR/M frameworks start looking better than ActiveRecord.
Distributed Transactions
The rise in SOA interest over the last couple years has led to more applications using multiple data sources. While it is possible to nest transactions, “Rails doesn’t support distributed two-phase commits (which is the jargon term for the protocol that lets databases synchronize with each other).” (From Agile Development with Rails, 2nd Edition.) In many situations, simply nesting transactions will suffice; however, many situations should really have the safely and reliability of two-phase semantics, and this factor alone could be a deal breaker.
Data Integrity
Database Designers (DBDs) like FOREIGN KEY constraints, CHECKs, high levels of normalization, and are the natural enemy of null fields. In other words, DBDs don’t like Rails. While I’m certainly no Pedantic Data Nazi (PDN?), there should at least be a basic set of built-in mechanisms for generating such simple self-defenses against naughty applications. Frankly I’m surprised that the community isn’t pushing harder for solid constraint support within migrations.
IDEs
This isn’t technically an issue with Rails itself, but a roadblock to its adoption nonetheless. Most Rails developers (including myself) appear to be using TextMate. A smaller population use RDT, Emacs, or numerous other packages. But there isn’t yet an application which comes close to the basic core feature of the popular Java and .Net IDEs. The currently broken breakpointer is another swift kick in the pants. What I can do with Eclipse on a remote application server isn’t in the same universe of functionality as the Rails breakpointer, even when it worked.
Top-Down Push
For whatever reason, CTOs and CIOs haven’t yet become seriously interested in Rails, and without this air of implicit exploratory approval, managers seem reluctant to give in to antsy developers. I would love to see Rails become a flagship of agile enterprise projects, but that’s not going to happen until management sees the real ROI of a project done by experienced Rails developers.
None of these things are insurmountable, but there are many more challenges to overcome if Rails will ever sit on the same application servers as Java and .Net. What challenges have you faced with Rails at your organization?
Tags: enterprise, methodology, opinion, ralis, review, ruby



