Skip to content

scott-steadman/rails_monitoring_engine

Repository files navigation

Rails Monitoring Engine

This engine provides NewRelic-like functionality to rails apps.

I wanted to be able to monitor my rails applicaiton performance without having to pay someone or sending telemetry data outside my network.

Usage

How to use my plugin.

Installation

Add this line to your application's Gemfile:

gem 'rails_monitoring_engine'

And then execute:

$ bundle install

Configuration

Add the following code:

# config/initializers/rails_monitoring_engine.rb

  RailsMonitoringEngine.enable!

Development

To set up the development environment run the following:

$ bundle install --path vendor/bundle --clean
rails db:create db:migrate

Adding a Model

To add a model run the following:

rails g model <model name>

Edit/test your migration then annotate it via the following command:

rails app:rails_monitoring_engine::annotate_models

Testing

I'm aiming for 100% test coverage so I feel more confident when making changes.

Coverage

To generate a coverage report execute the following:

rails app:simplecov

To see the coverage detail report start the server and go to: http://localhost:3000/coverage/

Performance

To run a performance test using the Apache Benchmarking Tool start the server in one shell via

cd test/dummy
rails server

Then, in another shell, execute the following:

rails app:test:performance

Contributing

Contribution directions go here.

License

The gem is available as open source under the terms of the MIT License.

About

A Rails performance monitoring engine (like NewRelic)

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published