logjam_agent 0.29.6 → 0.32.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +49 -28
- data/Rakefile +5 -0
- data/lib/logjam_agent.rb +14 -4
- data/lib/logjam_agent/active_support/core_ext/array/extract.rb +21 -0
- data/lib/logjam_agent/active_support/parameter_filter.rb +128 -0
- data/lib/logjam_agent/buffered_logger.rb +17 -42
- data/lib/logjam_agent/middleware.rb +16 -4
- data/lib/logjam_agent/monkey_patches/ffi-rzmq-patch.rb +19 -0
- data/lib/logjam_agent/rack/logger.rb +19 -81
- data/lib/logjam_agent/rack/rails_support.rb +26 -0
- data/lib/logjam_agent/rack/sinatra_request.rb +32 -0
- data/lib/logjam_agent/railtie.rb +3 -0
- data/lib/logjam_agent/receiver.rb +22 -0
- data/lib/logjam_agent/sinatra.rb +116 -0
- data/lib/logjam_agent/syslog_like_formatter.rb +15 -7
- data/lib/logjam_agent/util.rb +6 -1
- data/lib/logjam_agent/version.rb +1 -1
- data/lib/logjam_agent/zmq_forwarder.rb +48 -30
- data/test/sinatra_app.rb +32 -0
- data/test/sinatra_classic_app.rb +31 -0
- data/test/sinatra_classic_test.rb +20 -0
- data/test/sinatra_test.rb +54 -0
- data/test/test_helper.rb +8 -3
- data/test/util_test.rb +5 -0
- metadata +70 -16
- data/.gitignore +0 -5
- data/Gemfile +0 -4
- data/logjam_agent.gemspec +0 -34
- data/script/console +0 -28
data/Gemfile
DELETED
data/logjam_agent.gemspec
DELETED
@@ -1,34 +0,0 @@
|
|
1
|
-
# -*- encoding: utf-8 -*-
|
2
|
-
$:.push File.expand_path("../lib", __FILE__)
|
3
|
-
require "logjam_agent/version"
|
4
|
-
|
5
|
-
Gem::Specification.new do |s|
|
6
|
-
s.name = "logjam_agent"
|
7
|
-
s.version = LogjamAgent::VERSION
|
8
|
-
s.authors = ["Stefan Kaes"]
|
9
|
-
s.email = ["stefan.kaes@xing.com"]
|
10
|
-
s.homepage = ""
|
11
|
-
s.summary = %q{Logjam client library to be used with logjam}
|
12
|
-
s.description = %q{Logjam logger and request information forwarding}
|
13
|
-
|
14
|
-
s.rubyforge_project = "logjam_agent"
|
15
|
-
|
16
|
-
s.files = `git ls-files`.split("\n")
|
17
|
-
s.test_files = `git ls-files -- {test,spec,features}/*`.split("\n")
|
18
|
-
s.executables = `git ls-files -- bin/*`.split("\n").map{ |f| File.basename(f) }
|
19
|
-
s.require_paths = ["lib"]
|
20
|
-
|
21
|
-
s.add_development_dependency "rake"
|
22
|
-
s.add_development_dependency "i18n"
|
23
|
-
s.add_development_dependency "snappy"
|
24
|
-
s.add_development_dependency "lz4-ruby"
|
25
|
-
s.add_development_dependency "oj"
|
26
|
-
s.add_development_dependency "byebug"
|
27
|
-
s.add_development_dependency "minitest"
|
28
|
-
s.add_development_dependency "mocha"
|
29
|
-
|
30
|
-
s.add_runtime_dependency "activesupport"
|
31
|
-
s.add_runtime_dependency "time_bandits", [">= 0.6.0"]
|
32
|
-
s.add_runtime_dependency "ffi-rzmq-core", [">= 1.0.5"]
|
33
|
-
s.add_runtime_dependency "ffi-rzmq", [">= 2.0.4"]
|
34
|
-
end
|
data/script/console
DELETED
@@ -1,28 +0,0 @@
|
|
1
|
-
#!/usr/bin/env ruby
|
2
|
-
require 'optparse'
|
3
|
-
|
4
|
-
options = { }
|
5
|
-
OptionParser.new do |opt|
|
6
|
-
opt.banner = "Usage: console [options]"
|
7
|
-
opt.on("--debugger", 'Enable ruby-debugging for the console.') { |v| options[:debugger] = v }
|
8
|
-
opt.parse!(ARGV)
|
9
|
-
end
|
10
|
-
|
11
|
-
lib_dir = File.expand_path("../../lib/", __FILE__)
|
12
|
-
libs = " -r irb/completion"
|
13
|
-
libs << " -I #{lib_dir}"
|
14
|
-
libs << " -r #{lib_dir}/logjam_agent.rb"
|
15
|
-
|
16
|
-
if options[:debugger]
|
17
|
-
begin
|
18
|
-
require 'byebug'
|
19
|
-
libs << " -r byebug"
|
20
|
-
puts "=> Debugger enabled"
|
21
|
-
rescue Exception
|
22
|
-
puts "You need to install ruby-debug to run the console in debugging mode. With gems, use 'gem install ruby-debug'"
|
23
|
-
exit
|
24
|
-
end
|
25
|
-
end
|
26
|
-
|
27
|
-
irb = RUBY_PLATFORM =~ /(:?mswin|mingw)/ ? 'irb.bat' : 'irb'
|
28
|
-
exec "#{irb} #{libs} --simple-prompt"
|