{"id":15941458,"url":"https://github.com/fernandomoraes/prometheus-nodejs-exporter","last_synced_at":"2025-10-19T03:31:20.871Z","repository":{"id":37705742,"uuid":"316013812","full_name":"fernandomoraes/prometheus-nodejs-exporter","owner":"fernandomoraes","description":"The simplest way to export your NodeJS Applications metrics to Prometheus","archived":false,"fork":false,"pushed_at":"2020-12-07T19:09:22.000Z","size":56,"stargazers_count":4,"open_issues_count":0,"forks_count":1,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-01-29T08:11:15.776Z","etag":null,"topics":["grafana","metrics","nodejs","prometheus","prometheus-exporter"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/fernandomoraes.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2020-11-25T17:47:09.000Z","updated_at":"2023-05-04T05:28:17.000Z","dependencies_parsed_at":"2022-09-15T22:40:42.137Z","dependency_job_id":null,"html_url":"https://github.com/fernandomoraes/prometheus-nodejs-exporter","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fernandomoraes%2Fprometheus-nodejs-exporter","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fernandomoraes%2Fprometheus-nodejs-exporter/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fernandomoraes%2Fprometheus-nodejs-exporter/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fernandomoraes%2Fprometheus-nodejs-exporter/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/fernandomoraes","download_url":"https://codeload.github.com/fernandomoraes/prometheus-nodejs-exporter/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":237062178,"owners_count":19249017,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["grafana","metrics","nodejs","prometheus","prometheus-exporter"],"created_at":"2024-10-07T07:04:27.823Z","updated_at":"2025-10-19T03:31:15.595Z","avatar_url":"https://github.com/fernandomoraes.png","language":"JavaScript","readme":"# prometheus-nodejs-exporter\n\nThe simplest way to export your NodeJS Applications metrics to Prometheus.\n\n## Instalation\n\n```\nyarn add @moraes/prometheus-nodejs-exporter\n\n//or with npm\nnpm install --save @moraes/prometheus-nodejs-exporter\n```\n\nYou can now load the agent module using the preload sintax, without need to change your production code:\n\n```\nnode -r node_modules/@moraes/prometheus-nodejs-exporter myServer.js\n```\n\nCongradulations, now you have all the metrics exported at:\n\n`http://localhost:{port}/metrics`\n\n## Metrics\n\nExample values:\n\n```\nnodejs_app_cpu_percent 0.008496580143248911\nnodejs_app_cpu_system 4474\nnodejs_app_cpu_user 29499\nnodejs_app_memory_percent 0.00238173648447801\nnodejs_app_memory_rss_allocated_byte 39546880\nnodejs_app_memory_total_byte 16604221440\nnodejs_app_memory_heap_percent 0.5280970213498623\nnodejs_app_memory_heap_used_byte 4711200\nnodejs_app_memory_heap_total_byte 8921088\nnodejs_app_memory_ext_usage_byte 1625018\nnodejs_app_event_loop_delay_ms 0\nnodejs_app_runtime_ms 6003\nnodejs_app_gc_total_ms{type=\"scavenge\"} 0\nnodejs_app_gc_total_ms{type=\"mark_sweep_compact\"} 0\nnodejs_app_gc_total_ms{type=\"incremental_marking\"} 0\nnodejs_app_gc_total_ms{type=\"process_weak_callbacks\"} 0\nnodejs_app_gc_total_ms{type=\"all\"} 0\n```\n\n## Configuration\n\nThe following variables can be used to customize de metrics exporter:\n\n-   PROMETHEUS_SCHEDULE_TIMER (default 2000 ms): Time used to read and update the metrics values\n-   PROMETHEUS_METRICS_PATH (default metrics): Path that will respond the metrics\n\n## Http server support\n\nThis library works with all http servers based on nodejs `http, https or http2` modules like `Express` and so on.\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffernandomoraes%2Fprometheus-nodejs-exporter","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ffernandomoraes%2Fprometheus-nodejs-exporter","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffernandomoraes%2Fprometheus-nodejs-exporter/lists"}