mnemosyne-ruby 0.1.0 → 0.2.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 5d1ae774cf6ab9a36c5d387675d49fc1f646dc03
4
- data.tar.gz: 9a2e7ad49b27c1866dfd0517820849bb728744d9
3
+ metadata.gz: 577b1ff892814a13933e71023e510dbe5cc51b6c
4
+ data.tar.gz: dddfd0f83e7fc0bd58600a9f3acdc46462d8922c
5
5
  SHA512:
6
- metadata.gz: 2e0a25632d5e1447fdc7af933b02e5b459ebad667b442eb7ae8799ad4556bb42317a525d215ac383f2e24fd7bd028b69651c4f4ee1b2644e54bc7c83d9654159
7
- data.tar.gz: 3bd51d5807b2b29dafe064976b0c3faa10649881056535ebe5720f7e4db9b16091006bea2984291fe32c0c15805dc55d3a4039f47e93f1b357d4f90eb23d1304
6
+ metadata.gz: eaa317aac84fbb7358d7dd8b67047bf2128bc27d6d222243557d96878c84da071192a1ac7b2a974799b18f39741404e4fc81e6930bb0ecd08e21e254dcd7c5b7
7
+ data.tar.gz: 6f2373a6981ec4547ef3153202cfd4833df22f37cae9abdc04c54c9e7676d02583bf2b3afefa2fa67105837aefd8e41e9a2f44532aa10c9dcf941fb99b741493
data/.rubocop.yml CHANGED
@@ -25,7 +25,7 @@ Style/SignalException:
25
25
  EnforcedStyle: only_raise
26
26
 
27
27
  Style/CaseIndentation:
28
- IndentWhenRelativeTo: end
28
+ EnforcedStyle: end
29
29
  SupportedStyles:
30
30
  - case
31
31
  - end
data/.travis.yml CHANGED
@@ -1,6 +1,17 @@
1
1
  language: ruby
2
+ cache: bundler
2
3
  rvm:
4
+ - '2.4.0'
3
5
  - '2.3.3'
4
6
  - '2.2.6'
7
+ - '2.1.10'
8
+ before_script:
9
+ - export JRUBY_OPTS="--2.0"
5
10
  before_install:
11
+ - gem update --system
6
12
  - gem install bundler
13
+ script:
14
+ - bundle exec rake rubocop
15
+ - bundle exec rake spec
16
+ matrix:
17
+ fast_finish: true
data/CHANGELOG.md ADDED
@@ -0,0 +1,10 @@
1
+ # Changelog
2
+
3
+ ## 0.2.0
4
+
5
+ * Rename gem to mnemosyne-ruby due to name conflict
6
+ * Add platform identifier
7
+
8
+ ## 0.1.0
9
+
10
+ * Initial test release
data/README.md CHANGED
@@ -4,18 +4,22 @@ The ruby client plugin for the Mnemosyne monitoring system. It extracts full app
4
4
 
5
5
  Currently supported probes:
6
6
 
7
- * ActionController: Process Action, Renderers
8
- * ActiveRecord: SQL query
7
+ * Acfs: Remote calls including tracing middleware
8
+ * ActionController: Processing actions and rendering
9
+ * ActiveView: Template and Partial rendering
10
+ * ActiveRecord: SQL query time
11
+ * Grape: Endpoint run, filter and render times
12
+ * Mnemosyne: Custom traces
9
13
  * Responders: render time
10
- * Custom instrumentation
11
-
14
+ * Restify: Remote calls including tracing middleware
15
+ * Rack: Middleware for request tracing
12
16
 
13
17
  ## Installation
14
18
 
15
19
  Add this line to your application's Gemfile:
16
20
 
17
21
  ```ruby
18
- gem 'mnemosyne'
22
+ gem 'mnemosyne-ruby', '0.2.0'
19
23
  ```
20
24
 
21
25
  And then execute:
data/Rakefile CHANGED
@@ -1,7 +1,12 @@
1
1
  # frozen_string_literal: true
2
2
  require 'bundler/gem_tasks'
3
3
  require 'rspec/core/rake_task'
4
+ require 'rubocop/rake_task'
4
5
 
5
6
  RSpec::Core::RakeTask.new(:spec)
6
7
 
7
- task default: :spec
8
+ RuboCop::RakeTask.new(:rubocop) do |task|
9
+ task.fail_on_error = false
10
+ end
11
+
12
+ task default: [:rubocop, :spec]
@@ -0,0 +1 @@
1
+ require 'mnemosyne'
@@ -7,6 +7,7 @@ module Mnemosyne
7
7
  class Config
8
8
  attr_reader :application
9
9
  attr_reader :hostname
10
+ attr_reader :platform
10
11
  attr_reader :amqp
11
12
  attr_reader :exchange
12
13
  attr_reader :logger
@@ -14,6 +15,7 @@ module Mnemosyne
14
15
 
15
16
  # rubocop:disable Metrics/AbcSize
16
17
  def initialize(config)
18
+ @platform = config.fetch('platform', 'default').freeze
17
19
  @application = config.fetch('application').freeze
18
20
  @enabled = config.fetch('enabled', true)
19
21
  @hostname = config.fetch('hostname') { default_hostname }.freeze
@@ -49,7 +49,8 @@ module Mnemosyne
49
49
  def submit(trace)
50
50
  blob = {
51
51
  hostname: @config.hostname,
52
- application: @config.application
52
+ platform: @config.platform,
53
+ application: @config.application,
53
54
  }
54
55
 
55
56
  # TODO: nest
@@ -8,7 +8,7 @@ module Mnemosyne
8
8
 
9
9
  config['application'] ||= app.class.name.underscore.titleize
10
10
 
11
- # config['logger'] = Rails.logger
11
+ config['logger'] ||= Rails.logger
12
12
  config['enabled'] ||= config.key?('server')
13
13
 
14
14
  config = ::Mnemosyne::Config.new(config)
@@ -3,7 +3,7 @@
3
3
  module Mnemosyne
4
4
  module VERSION
5
5
  MAJOR = 0
6
- MINOR = 1
6
+ MINOR = 2
7
7
  PATCH = 0
8
8
  STAGE = nil
9
9
 
@@ -26,4 +26,5 @@ Gem::Specification.new do |spec|
26
26
  spec.add_development_dependency 'rake', '~> 10.0'
27
27
  spec.add_development_dependency 'rspec', '~> 3.0'
28
28
  spec.add_development_dependency 'timecop', '~> 0.8.0'
29
+ spec.add_development_dependency 'rubocop', '~> 0.47.1'
29
30
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: mnemosyne-ruby
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
4
+ version: 0.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Jan Graichen
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-01-17 00:00:00.000000000 Z
11
+ date: 2017-03-21 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bunny
@@ -94,6 +94,20 @@ dependencies:
94
94
  - - "~>"
95
95
  - !ruby/object:Gem::Version
96
96
  version: 0.8.0
97
+ - !ruby/object:Gem::Dependency
98
+ name: rubocop
99
+ requirement: !ruby/object:Gem::Requirement
100
+ requirements:
101
+ - - "~>"
102
+ - !ruby/object:Gem::Version
103
+ version: 0.47.1
104
+ type: :development
105
+ prerelease: false
106
+ version_requirements: !ruby/object:Gem::Requirement
107
+ requirements:
108
+ - - "~>"
109
+ - !ruby/object:Gem::Version
110
+ version: 0.47.1
97
111
  description:
98
112
  email:
99
113
  - jgraichen@altimos.de
@@ -105,10 +119,12 @@ files:
105
119
  - ".rspec"
106
120
  - ".rubocop.yml"
107
121
  - ".travis.yml"
122
+ - CHANGELOG.md
108
123
  - Gemfile
109
124
  - LICENSE
110
125
  - README.md
111
126
  - Rakefile
127
+ - lib/mnemosyne-ruby.rb
112
128
  - lib/mnemosyne.rb
113
129
  - lib/mnemosyne/client.rb
114
130
  - lib/mnemosyne/clock.rb
@@ -165,4 +181,3 @@ signing_key:
165
181
  specification_version: 4
166
182
  summary: Ruby/Rails client for Mnemosynce
167
183
  test_files: []
168
- has_rdoc: