hypermetrics

1.2.1 • Public • Published

Hypermetrics

Hypercore Prometheus metric collector.

Usage

const client = require('prom-client')
const hypermetrics = new Hypermetrics(client)

const core = new Hypercore(ram)
await core.ready()
hypermetrics.add(core, { name: 'name-of-the-core' })

server.get('/metrics', async function (req, res) {
    res.send(await hypermetrics.register.metrics())
})

server.listen({ port: 8080 })

Readme

Keywords

none

Package Sidebar

Install

npm i hypermetrics

Weekly Downloads

1

Version

1.2.1

License

Apache-2.0

Unpacked Size

22.3 kB

Total Files

6

Last publish

Collaborators

  • rafapaezbas