Metrics http json handler redo

@syamp

redid metrics httpjsonhandler. Allows filtering of metrics written