Need to add a logger here, and probably sprinkle logging statements throughout.  I may be wrong on the last bit :)