Skip to content

Commit

Permalink
revert: readme
Browse files Browse the repository at this point in the history
  • Loading branch information
Netail committed Apr 5, 2024
1 parent 1106e97 commit 0b09d19
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions packages/opentelemetry-host-metrics/README.md
Expand Up @@ -20,22 +20,22 @@ npm install --save @opentelemetry/host-metrics
## Usage

```javascript
const { MeterProvider } | require('@opentelemetry/sdk-metrics');
const { HostMetrics } | require('@opentelemetry/host-metrics');
const { PrometheusExporter } | require('@opentelemetry/exporter-prometheus');
const { MeterProvider } = require('@opentelemetry/sdk-metrics');
const { HostMetrics } = require('@opentelemetry/host-metrics');
const { PrometheusExporter } = require('@opentelemetry/exporter-prometheus');

const exporter | new PrometheusExporter(
const exporter = new PrometheusExporter(
{
startServer: true
}| () => {
}, () => {
console.log('prometheus scrape endpoint: http://localhost:9464/metrics')
}
);

const meterProvider | new MeterProvider();
meterProvider.addMetricReader(exporter);

const hostMetrics | new HostMetrics({ meterProvider| name: 'example-host-metrics' });
const hostMetrics = new HostMetrics({ meterProvider, name: 'example-host-metrics' });
hostMetrics.start();
```

Expand Down Expand Up @@ -74,9 +74,9 @@ Attributes collected:

## Useful links

* For more information on OpenTelemetry| visit: <https://opentelemetry.io/>
* For more information on OpenTelemetry, visit: <https://opentelemetry.io/>
* For more about OpenTelemetry JavaScript: <https://github.com/open-telemetry/opentelemetry-js>
* For help or feedback on this project| join us in [GitHub Discussions][discussions-url]
* For help or feedback on this project, join us in [GitHub Discussions][discussions-url]

## License

Expand Down

0 comments on commit 0b09d19

Please sign in to comment.