Since I am constantly forgetting to do this before compilation, I thought I would post about it in case it benefits others.
$ gem install rake
ERROR: Loading command: install (LoadError)
cannot load such file — zlib
Installing rvm and ruby requires various per-requisites, namely development libraries ruby builds against during compilation. The RVM site leads you towards installation via RVM package, which introduces a whole other set of sources. A better solution is installing the appropriate native packages beforehand.
See also:
After several hours troubleshooting my production Rails environment, I finally found out why images were not being served properly after an upgrade to 3.1: no XSendfile module. Rails 3.1/Sprockets apparently relies heavily on Apache’s XSendfile to serve assets, and without the module installed and configured, images will silently fail and browsers will display a missing image.
To enable under Ubuntu:
More details here.
I regularly contribute to StackOverflow, a free, community powered Q&A site, about once a week. Whenever I have a challenging IT question in a particular domain, I find StackOverflow or one of it’s fellow sites in the StackExchange network, to be the fastest, cheapest, easiest route to getting feedback or suggestions. The unique mix of reputation and rewards for answering questions seem to have engendered a community that is actively interested in posing technical questions, and answering them well.
And so I am excited to learn StackExchange is planning on expanding to a site that focuses on Healthcare IT related questions as well. I think this would be a great edition to the HIT community, and provide a reputable source for HIT related Q&A beyond what can currently be offered by the hodge-podge of forums and groups that exist today. The site is still in the planning and proposal state, everyone is welcome to check it out, and contribute.
Why does my application work in the local development environment, but not in production?

Heroku is an awesome service. It provides a stable platform and tools for quickly deploying applications to the cloud, and allows users to enjoy all the scaling benefits cloud infrastructure can provide. One gotcha I have experienced, however, is Heroku’s reliance on the Postgres database, instead of MySQL.
While researching Heroku I noticed this, but naively assumed that I could use MySQL for local development, and that any differences between these two databases would be relatively obvious, and that I could compensate on the backend. ”Surely” I remember thinking, “almost all of my database queries will be performed in Active Record, and so I’ll be protected from DB differences anyway.” Unfortunately, I was wrong.
Some portions of my application code required implementing a slightly tricky join with the aggregate function ‘avg’. The results of this ended up going into a vector.
Unfortunately, Active Record returns strings instead of floats or integers for aggregate functions in Postgres. This is obviously leads to problems if your app is expecting something it can calculate with, and in my case leading to a silent conversion to 0.0. The end result was an application that performed differently on production at Heroku than locally in my MySQL development environment, and several hours spent moving to Postgres locally.
Lesson learned. Postgres all the way.
Update: It turns out converting to Postgres and removing DatabaseCleaner calls from my spec_helper reduced spec time from 78.2 seconds to 38.75 seconds. 50% faster specs eases the pain.
While looking for a good way to visualize ActiveRecord models, I stumbled upon Rails ERD. I followed the painless install process which is essentially involves adding a one-liner in bundler and installing Graphviz via the DMG, and fired off the associated Rails ERD rake task. 5 seconds later I had a readable, dynamically generated PDF of the database schema for my project. Hats off to Rolf Timmermans for this useful utility.
Last year I enrolled in a new graduate program being offered by the Fuqua School of Business at Duke University.
The Master of Management in Clinical Informatics (MMCi) degree is a “one-year Management in Clinical Informatics program is the only interdisciplinary management program of its kind in the United States—leveraging Duke’s world-renowned track record in medicine, business, and health informatics. Through access to the finest faculty and resources across health care, IT, and management education, students will acquire the knowledge and skills to merge technology and patient care and help improve human health.”
I am incredibly proud of my involvement with this exciting new program, and I recently shared the story of how I came to choose MMCi over other graduate school options. I hope that this post will be part of a larger series of articles for Healthcare IT Today, if you have any questions or comments about the series please feel free to contact me via the feedback link to the right.
Late last year drop.io was purchased by Facebook. I had been using drop.io to provide a public “drop box” (not related to the other drop box service) where folks could upload files, as well as a (rarely used) chat area that lived at the bottom of the main page at justintylerwiley.com.
These canned services were really just the tip of the drop.io API stack iceberg, which was Google Wave-like in scope and technical complexity. Drop.io had some really talented and creative developers working for them and came up with a number of innovative features that as far as I know were never really fully utilized in the web community. They were one of the first to pioneer Javascript based XMPP transfer functionality, and I remember when Katie and I first ran across them in 2009 we were pretty convinced that we were seeing Web 3.0.
Dropbox and chat services have been discontinued, and I’m not sure what Facebook has in store for the team, but I hope it’s as original and interesting as drop.io.