Better error handling and logging

Signed-off-by: James Myers <jmyers@pivotallabs.com>