All Projects β†’ Meteor-Community-Packages β†’ meteor-elastic-apm

Meteor-Community-Packages / meteor-elastic-apm

Licence: MIT license
Meteor Elastic APM integration

Programming Languages

javascript
184084 projects - #8 most used programming language

Projects that are alternatives of or similar to meteor-elastic-apm

Openki
We moved to GitLab πŸ’” Openki is a tool to build up and organize local communities – Open education for real.
Stars: ✭ 137 (+144.64%)
Mutual labels:  meteor
Accounts Ui
Accounts UI for React in Meteor 1.3+
Stars: ✭ 197 (+251.79%)
Mutual labels:  meteor
Ews Javascript Api
EWS API for TypeScript/JavaScript - ported from OfficeDev/ews-managed-api - node, cordova, meteor, Ionic, Electron, Outlook Add-Ins
Stars: ✭ 241 (+330.36%)
Mutual labels:  meteor
Meteor Partitioner
Transparently divide a single meteor app into several different instances shared between different groups of users.
Stars: ✭ 153 (+173.21%)
Mutual labels:  meteor
Meteor Client Bundler
https://blog.meteor.com/leverage-the-power-of-meteor-with-any-client-side-framework-bfb909141008
Stars: ✭ 187 (+233.93%)
Mutual labels:  meteor
Analytics
UNMAINTAINED! - Complete Google Analytics, Mixpanel, KISSmetrics (and more) integration for Meteor
Stars: ✭ 211 (+276.79%)
Mutual labels:  meteor
Meteor Service Worker
An universal service worker for meteor apps
Stars: ✭ 132 (+135.71%)
Mutual labels:  meteor
elastic-stack-testing
Elastic Stack Testing Framework (ESTF) πŸ€–
Stars: ✭ 47 (-16.07%)
Mutual labels:  apm
Stevejobs
A simple jobs queue that just works (for Meteor.js)
Stars: ✭ 195 (+248.21%)
Mutual labels:  meteor
React Landing Page Template
A simple react one page landing page templates for startups/companies
Stars: ✭ 224 (+300%)
Mutual labels:  meteor
Scotty
Meteor React Redux boilerplate with Server-Side Rendering
Stars: ✭ 159 (+183.93%)
Mutual labels:  meteor
Awesome Opensource Apps
πŸ β„ΉοΈ Curated list of awesome open source crafted web & mobile applications - Learn, Fork, Contribute & Most Importantly Enjoy!
Stars: ✭ 2,199 (+3826.79%)
Mutual labels:  meteor
Angular Meteor
Angular and Meteor - The perfect stack
Stars: ✭ 2,385 (+4158.93%)
Mutual labels:  meteor
Meteor Apollo Accounts
Meteor accounts in GraphQL
Stars: ✭ 145 (+158.93%)
Mutual labels:  meteor
Acgn Stock
PTT ACGNθ‚‘η₯¨δΊ€ζ˜“εΈ‚ε ΄
Stars: ✭ 252 (+350%)
Mutual labels:  meteor
Mantra Cli
Command line interface for building Meteor apps with Mantra
Stars: ✭ 138 (+146.43%)
Mutual labels:  meteor
Meteor Google Maps
πŸ—Ί Meteor package for the Google Maps Javascript API v3
Stars: ✭ 198 (+253.57%)
Mutual labels:  meteor
Timbr V1
A web service that turns an arbitrary web page into structural JSON data and easy-to-use APIs with just a few clicks
Stars: ✭ 50 (-10.71%)
Mutual labels:  meteor
tester-jest
Tester Jest is a tester provider for the Atom Tester.
Stars: ✭ 21 (-62.5%)
Mutual labels:  apm
Simple React Form
The simplest way to handle forms in React
Stars: ✭ 224 (+300%)
Mutual labels:  meteor

meteor-elastic-apm

Build Status codecov

Performance Monitoring for Meteor based on Elastic APM

Meteor Elastic APM screenshot

Getting started

  1. Install and configure elasticsearch - https://www.elastic.co/downloads/elasticsearch
  2. Install and configure Kibana - https://www.elastic.co/downloads/kibana
  3. Install and configure elastic APM server - https://www.elastic.co/downloads/apm

Then in your Meteor project

meteor add kschingiz:meteor-elastic-apm

Maybe you will need to also install

meteor add http mongo-livequery

Then somewhere in your server code, Elastic documentation says that Agent.start should be executed before anything else, and should be at the very top of your code

import Agent from 'meteor/kschingiz:meteor-elastic-apm';

const options = {
  serviceName: 'meteor-demo-app'
};
Agent.start(options);

Complete list of Agent options

In addition, this plugin supports the following Agent options:

  • active - Boolean value which determins if monitoring is active. Default: true
  • disableMeteorInstrumentations - An array of meteor related instrumentations which should not be recorded. Default: []. Possible values: ['methods', 'session', 'subscription', 'async', 'db, 'metrics']

What it monitors

  1. Meteor methods: method params, result, exceptions, stack trace
    • Ignores methods starting with _FilesCollectionWrite_. (See: #30)
  2. Meteor pub/sub: tracks publications response time, params, exceptions, result
  3. Meteor collection methods(find, insert, etc...): params, result, execution time
  4. MongoDB cursor method(fetch, map, etc...): params, result, execution time
  5. Trace async execution
  6. All Incoming and outgoing HTTP requests, useful if you have REST API
  7. Exception handling

Metrics

From version 2.2.0 the package collects and sends meteor specific metrics to the apm-server. You can learn how it works and how to use it in Metrics docs

Performance

If you discover significant performance implications, you can disable any of the metrics by adding the configuration disableMeteorInstrumentations and specifying in an array which of the metrics you want to disable: ['methods', 'session', 'subscription', 'async', 'db, 'metrics'].

Please also have a look at the documentation of the underlying library apm-agent-nodejs

Screenshots

https://github.com/kschingiz/meteor-elastic-apm/blob/master/assets/

Kibana APM with Meteor with MUP

Meteor Up is a production quality Meteor app deployment tool. We expect you already has up and running Meteor app on server deployed with MUP.

  1. mup ssh
  2. wget https://raw.githubusercontent.com/elastic/apm-server/master/apm-server.yml && cp apm-server.yml /etc/apm-server/apm-server.yml
  3. Now you need to edit /etc/apm-server/apm-server.yml, at least you need to add you elastic search url under output.elasticsearch. When you finish just close this terminal
  4. Now we need to update mup.js file to: a) Install apm-server in app container b) Pass apm-server config file into our app container c) Start it everytime after deploy
{
  app: {
    ...
    volumes: {
      '/etc/apm-server/apm-server.yml': '/etc/apm-server/apm-server.yml'
    },
    docker: {
        ...
        buildInstructions: [
        // https://www.elastic.co/guide/en/apm/server/current/setup-repositories.html
        'RUN apt-get install wget -y',
        'RUN wget -qO - https://artifacts.elastic.co/GPG-KEY-elasticsearch | apt-key add -',
        'RUN apt-get install apt-transport-https',
        'RUN echo "deb https://artifacts.elastic.co/packages/6.x/apt stable main" | tee -a /etc/apt/sources.list.d/elastic-6.x.list',
        'RUN apt-get update && apt-get install apm-server -y',
        'RUN update-rc.d apm-server defaults 95 10'
        ]
    }
    ...
  },
  ...
  hooks: {
    // Run apm-server
    'post.deploy'(api) {
      return api.runSSHCommand(
        api.getConfig().servers.one,
        'docker exec development service apm-server start'
      );
    }
  },
}

demo app

https://github.com/kschingiz/demo-meteor-elastic-apm

API

Agent is based on elastic/apm-agent-nodejs and fully supports all of it's features https://github.com/elastic/apm-agent-nodejs

Contributions

All contributions are welcome, Let's make the better APM together!

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].