madvertise-logging 1.2.1 → 1.3.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,15 @@
1
1
  ---
2
- SHA1:
3
- metadata.gz: d638bc4aa14a6c9fdc883e1d15b545e5f464ba15
4
- data.tar.gz: 5819fcb1527c1bd70a5180e04e1ca0cf6b8d3d85
5
- SHA512:
6
- metadata.gz: 5ca330ec041ce2086413c0dcf77fd720ef419d4f35b79f12312665bd4c1b0db93b9ef8889a3b16ab8b7ab02849f0418ae449f4ebc6cf71a865865e2bded2a4eb
7
- data.tar.gz: d4c8bf5002ca8cd6dcfc45e2b2ed28de4e55346d59d8fc70746dfe9dbe55921a3ead71cc23877880a37a349c6a3e458e5382226051d836f6a3d0250753e8aeb5
2
+ !binary "U0hBMQ==":
3
+ metadata.gz: !binary |-
4
+ Y2QyZDg0NWU2N2IzMDdlNTU2ZjEyMzAxZjhkMTUyZWI4NzRiNmNjOA==
5
+ data.tar.gz: !binary |-
6
+ NzMzNjIyZmRlNDVhMjI3Y2FmOGJiYTE0MWJiYmQzNzk3ZWQzZWRjNA==
7
+ !binary "U0hBNTEy":
8
+ metadata.gz: !binary |-
9
+ OGQ4ZTJhNGU1NDk3ZmQxMzRkM2Y5ZWNiY2RiZDdkZGNmYzk3MTY4YmJiMjhj
10
+ ZThlYjEwZGEyMzUzMjliMDA4NDAwNDA1ZTQ1NTdhZDgzNGQ3MDg0M2FkZGY2
11
+ MGMyOWJlNDI0ZmNlZDdkMTk0ZWJkYjRjYjA4ZjI1ODc4NGUzNGE=
12
+ data.tar.gz: !binary |-
13
+ YTk5ODY3YTE1ZDJkMjVlOWM3MzA4MDBlMmMzMmMzMTYwOTY3YTZhNzc3YzJl
14
+ MzNmYWJmMjI4ZDI3MmNmMWZiMWQ2NGFjNjVhNzViYmY0Yzc2NDI0ODlmMjQ0
15
+ MGViMmJmOWUwMjI0MzY3MDE4NmM4YWRlOWFmOWUxNjgzOWZkYTM=
data/.rspec ADDED
@@ -0,0 +1,3 @@
1
+ --require spec_helper
2
+ --color
3
+ --format Fuubar
@@ -1,6 +1,6 @@
1
1
  language: ruby
2
2
  rvm:
3
- - 1.9.3
4
- - 1.9.2
3
+ - jruby-1.7.4
5
4
  - ruby-head
6
- - jruby-head
5
+ - 2.0.0
6
+ - 1.9.3
data/Gemfile CHANGED
@@ -5,6 +5,7 @@ gemspec
5
5
  gem 'syslogger', :require => false
6
6
 
7
7
  group :development, :test do
8
+ gem 'fuubar'
8
9
  gem 'rake'
9
10
  gem 'reek'
10
11
  gem 'rspec'
@@ -249,7 +249,7 @@ module Madvertise
249
249
 
250
250
  case @backend
251
251
  when :log4j
252
- create_log4j_backend
252
+ create_log4j_logger
253
253
  when :ruby
254
254
  create_ruby_logger(STDOUT)
255
255
  when :stdout
@@ -315,30 +315,21 @@ module Madvertise
315
315
  end
316
316
 
317
317
  def create_logger
318
- case RUBY_PLATFORM
319
- when 'java'
320
- create_log4j_logger
321
- else
322
- create_ruby_logger(@logfile)
323
- end
318
+ create_ruby_logger(@logfile)
324
319
  end
325
320
 
326
321
  def create_log4j_logger
327
- begin
328
- require 'log4j'
329
- require 'log4jruby'
330
- Log4jruby::Logger.get($0).tap do |logger|
331
- @backend = :log4j
332
- configure_log4j(logger)
333
- end
334
- rescue LoadError
335
- self.logger = :ruby
336
- error("Couldn't load log4jruby gem, falling back to pure ruby Logger")
322
+ Log4jruby::Logger.get($0).tap do |logger|
323
+ @backend = :log4j
324
+ configure_log4j(logger)
337
325
  end
338
326
  end
339
327
 
340
328
  def configure_log4j(logger)
341
- return unless @backend == :log4j
329
+ return unless RUBY_PLATFORM == 'java'
330
+
331
+ require 'log4j'
332
+ require 'log4jruby'
342
333
 
343
334
  @console = org.apache.log4j.ConsoleAppender.new
344
335
  @console.setLayout(org.apache.log4j.PatternLayout.new(Formatter.log4j_format))
@@ -2,7 +2,7 @@
2
2
 
3
3
  Gem::Specification.new do |spec|
4
4
  spec.name = "madvertise-logging"
5
- spec.version = "1.2.1"
5
+ spec.version = "1.3.0"
6
6
  spec.authors = ["madvertise Mobile Advertising GmbH"]
7
7
  spec.email = ["tech@madvertise.com"]
8
8
  spec.description = %q{Advanced logging classes with buffer backend, transactions, multi logger, etc}
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: madvertise-logging
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.2.1
4
+ version: 1.3.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - madvertise Mobile Advertising GmbH
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2013-08-01 00:00:00.000000000 Z
11
+ date: 2013-10-19 00:00:00.000000000 Z
12
12
  dependencies: []
13
13
  description: Advanced logging classes with buffer backend, transactions, multi logger,
14
14
  etc
@@ -19,6 +19,7 @@ extensions: []
19
19
  extra_rdoc_files: []
20
20
  files:
21
21
  - .gitignore
22
+ - .rspec
22
23
  - .travis.yml
23
24
  - .yardopts
24
25
  - Gemfile
@@ -36,7 +37,6 @@ files:
36
37
  - madvertise-logging.gemspec
37
38
  - spec/improved_logger_spec.rb
38
39
  - spec/multi_logger_spec.rb
39
- - spec/spec.opts
40
40
  - spec/spec_helper.rb
41
41
  - tasks/reek.rake
42
42
  - tasks/rspec.rake
@@ -50,17 +50,17 @@ require_paths:
50
50
  - lib
51
51
  required_ruby_version: !ruby/object:Gem::Requirement
52
52
  requirements:
53
- - - '>='
53
+ - - ! '>='
54
54
  - !ruby/object:Gem::Version
55
55
  version: '0'
56
56
  required_rubygems_version: !ruby/object:Gem::Requirement
57
57
  requirements:
58
- - - '>='
58
+ - - ! '>='
59
59
  - !ruby/object:Gem::Version
60
60
  version: '0'
61
61
  requirements: []
62
62
  rubyforge_project:
63
- rubygems_version: 2.0.5
63
+ rubygems_version: 2.0.6
64
64
  signing_key:
65
65
  specification_version: 4
66
66
  summary: Advanced logging classes with buffer backend, transactions, multi logger,
@@ -68,6 +68,5 @@ summary: Advanced logging classes with buffer backend, transactions, multi logge
68
68
  test_files:
69
69
  - spec/improved_logger_spec.rb
70
70
  - spec/multi_logger_spec.rb
71
- - spec/spec.opts
72
71
  - spec/spec_helper.rb
73
72
  has_rdoc:
@@ -1,2 +0,0 @@
1
- --colour
2
- --format documentation