0.0
No commit activity in last 3 years
No release in over 3 years
Rack middleware and application to enable NewRelic agent.
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies

Development

~> 1.14
>= 0
~> 0.6.3
~> 10.0
~> 3.0

Runtime

 Project Readme

Partiarelic

Build Status

Adds endpoint to enable New Relic manually.

Installation

Add this line to your application's Gemfile:

gem 'partiarelic'

And then execute:

$ bundle

Or install it yourself as:

$ gem install partiarelic

Usage

typical Rails app

# Gemfile
gem 'partiarelic', require: 'partiarelic/rails'

then your Rails application will handle /_newrelic/manual_start.

rack application

# Gemfile
gem 'partiarelic'

# config.ru (middleware)
use Partiarelic::Middleware, path: '/_newrelic/manual_start'

# config.ru (mount)
map '/_newrelic/manual_start' do
  run Partiarelic::App.new(path: '/_newrelic/manual_start')
end

gRPC application

# Gemfile
gem 'partiarelic', require 'partiarelic/grpc'

# server
s = GRPC::RpcServer.new
s.add_http2_port(host, :this_port_is_insecure)
s.handle(Partiarelic::GrpcApp)
s.run_till_terminated

# client
require 'partiarelic/grpc/partiarelic_services_pb.rb'
stub = Partiarelic::V1::App::Stub.new(host, :this_channel_is_insecure)
stub.manual_start(Partiarelic::V1::ManualStartRequest.new)

Development

Test

$ rake spec

Contributing

Bug reports and pull requests are welcome on GitHub at https://github.com/wata-gh/partiarelic.

License

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