Let’s see how to use SPM for Node.js with the Meteor framework.
Step 1: Create SPM App of type „Node.js“
Step 2: Install npm packages
# install SPM agent with meteor npm integration meteor npm i spm-agent-nodejs --save
Step 3: Configure SPM for Node.js agent
# preload spm-agent-nodejs module by setting NODE_OPTIONS environment variable export NODE_OPTIONS="-r spm-agent-nodejs“ # configure SPM agent for the SPM app by setting SPM_TOKEN environment variable export SPM_TOKEN=YOUR_SPM_TOKEN
If your monitoring app is in the EU datacenter, you’ll can point the Agent to the EU endpoints through environment variables as well:
export SPM_RECEIVER_URL=https://spm-receiver.eu.sematext.com/receiver/v1 export EVENTS_RECEIVER_URL=https://event-receiver.eu.sematext.com
Also, if you’re on Windows, you won’t be using
export. These variables go to Control Panel → System → Advanced System Settings → Environment Variables.
Step 4: Run your Meteor app
# run the meteor app as usual .. meteor run
Step 5: Check results in SPM
After a minute or so you should see the performance metrics such as EventLoop Latencies, Memory Usage, Garbage Collection details, and HTTP statistics of your Meteor app in SPM.
Meteor metrics in SPM for Node.js
Once you have all your Node.js metrics you can start to define alert rules and configure ChatOps integrations to be alerted about anomalies in your Meteor app.
Need a Meteor monitoring solution? Try SPM for Node.js!
Get key Node.js metrics in your Meteor app, transaction tracing, and more.
The Meteor framework typically uses MongoDB as the database, while caching and SSL termination is often off-loaded to Nginx. If you use Meteor, MongoDB, and Nginx in your stack you may want to have MongoDB monitoring and Nginx monitoring together with Meteor monitoring to cover monitoring for your whole application stack.