Refactor to trapperkeeper

This PR is a replacement for #773.  It is rebased onto the latest PuppetDB master branch, updated to use released versions of trapperkeeper and kitchensink, and addresses all of the comments that were made on that PR.