npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

@antoineschaller/kadira

v1.0.1

Published

Performance Monitoring for Meteor with meteor email support

Downloads

14

Readme

Kadira - Performance Monitoring for Meteor

This project is based on the Kadira without jQuery dependency.

If you are looking for the kadira server, take a look at meteor apm server.

Getting started

  1. Create an account in Meteor APM or Kadira
  2. From the UI, create an app. You'll get an AppId and an AppSecret.
  3. Run meteor add lmachens:kadira in your project
  4. Configure your Meteor app with the AppId and AppSecret by adding the following code snippet to a server/kadira.js file:
Meteor.startup(function() {
  Kadira.connect('<AppId>', '<AppSecret>');
});

Now you can deploy your application and it will send information to Kadira. Wait up to one minute and you'll see data appearing in the Kadira Dashboard.

Auto Connect

Your app can connect to Kadira using environment variables or using Meteor.settings.

Using Meteor.settings

Use the followng settings.json file with your app:

{
  ...
  "kadira": {
    "appId": "<appId>",
    "appSecret": "<appSecret>"
  }
  ...
}

The run your app with meteor --settings=settings.json.

Using Environment Variables

Export the following environment variables before running or deploying your app:

export KADIRA_APP_ID=<appId>
export KADIRA_APP_SECRET=<appSecret>

Error Tracking

Kadira comes with built in error tracking solution for Meteor apps. It has been enabled by default. For more information, please visit the meteor docs.

By default, Kadira tracks all the errors for you. But you may need to handle errors yourself. For those situations, you may need to report the error back to kadira as well. Here are the some of the options you can do.

Option 1 - Throw a new Error

Easiest option is try capture errors and handle them yourself. Then throw another error. Then kadira will capture that and you can see that error from in the UI.

try {
  // your code which may throw some errors
} catch(ex) {
  // handle your error and throw again
  throw ex;
}

Option 2 - Use Kadira.trackError

Other option is to use Kadira.trackError API. Which is available on both client and the server. See how it can used.

try {
  // your code 
} catch(ex) {
  var type = 'my-error-type';
  var message = ex.message;
  Kadira.trackError(type, message);
}

When you are tracking custom errors, do not use following types:

  • client
  • method
  • sub
  • server-crash
  • server-internal

We use above types to track errors automatically. If you also send errors with above types, things may not works as they used to.