Server health

Like an activity monitor for your servers. @blipit/node 0.2 and later send each server's vital signs every 30 seconds, and the Server health page shows them live, one row per server, with charts for the last hour, 24 hours or 7 days.

1Turn it on

Nothing to add: it starts with Blipit.init. Give each app a serverName so its servers are grouped under one name.

js
Blipit.init({
  key: process.env.BLIPIT_SECRET_KEY,
  serverName: "api",
});

2What each server sends

  • CPU used by the process, where 100% is one full core.
  • Memory used by the process, and how full the machine's memory is.
  • JavaScript heap used and total.
  • Event-loop delay at the 99th percentile: how long requests wait while the server is busy.
  • Open handles, such as sockets and timers.
  • Database connections from pg pools: in use, idle and waiting. Waiting means requests are queuing for a connection.

3Read the page

Live means the server is sending data; Not reporting means it went quiet. Pick a server to see its charts. The page refreshes every 30 seconds while it is open.

4Get alerted

Under Alerts, in Dependency and server alerts, set your own limit for each alert or switch it off.

  • High CPU: a server's CPU stays above your limit.
  • Memory almost full: a server's memory use stays above your limit.
  • Slow responses: a server's event loop is blocked longer than your limit, so requests wait.
  • Stopped reporting: every server of a service stops sending data, for example after a crash.

5Other stacks

Send OpenTelemetry metrics as OTLP JSON to https://in.blipit.io/v1/metrics with the X-Blipit-Key header. Blipit reads process.cpu.utilization, process.memory.usage, system.memory.utilization, system.cpu.load_average.1m, db.client.connections.usage and the Node.js event-loop metrics; service.instance.id names the server.

sh
OTEL_EXPORTER_OTLP_METRICS_ENDPOINT=https://in.blipit.io/v1/metrics
OTEL_EXPORTER_OTLP_METRICS_PROTOCOL=http/json
OTEL_EXPORTER_OTLP_HEADERS=X-Blipit-Key=blipit_sk_your_secret_key

6Serverless functions

Apps on Vercel, AWS Lambda, Netlify or Azure Functions run as many short-lived instances that pause between requests. Server health groups them into one row per platform, such as Vercel functions, with the number of instances seen and their memory, instead of listing each instance as a server. CPU and Not reporting are left out because a paused instance reports neither in a useful way, and serverless instances never raise high CPU, slow response or stopped reporting alerts.

Good to know

  • metrics: false turns it off; metricsIntervalMs changes the 30-second interval, down to 10 seconds.
  • Kept as long as spans: 7 days on Free and Solo, 14 days on Team and Scale. Server data does not count toward any allowance.
  • The memory percentage uses the machine's total memory. In a container with a lower memory limit than its host, watch Memory used instead.

Stuck? Email support@blipit.io. Keys and the project id for each project are under API keys in app.blipit.io.