(PUP-3512) Use new Profiler API

Change the `profile` function in PuppetDB to use the new Puppet
Profiler API in preparation for removing the old API from Puppet.
Modify all calls to the `profile` function in PuppetDB to pass in
a metric ID.
Merge pull request #1157 from fpringvaldsen/PUP-3512-new-profiler-api

(PUP-3512) Use new Profiler API