start_her 0.0.4 → 0.0.5

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: a12e176cfeb39e6fb11f3a0f07650f6bf449a217
4
- data.tar.gz: 0e4bddf2e2bb7abc37199fccf663fe99f617aca1
3
+ metadata.gz: de6f836c41fbc39e99de1176a4348cc5667446a0
4
+ data.tar.gz: 2bcac23346d1e13473be191b82d7c6b01a668619
5
5
  SHA512:
6
- metadata.gz: 5d8e16a6a01f0d216a65949f01972bb8daa0a1862800e01c7beb384b84d994945ee28106a0a1ad7d26435100146e7f310a1230619586155054be4f0e467898dc
7
- data.tar.gz: 91898997d8c206598fa041e6218e74605a9b9ade3f22538aa34ff86157f6015b02dc3bc27d0a351941d7572122277bb727da96959c5ea374f5acbe0fb3c70a78
6
+ metadata.gz: 17eb4c074016764ef010e9481f12b1bd08912094531c9417233365d08922d3f9eca3fff2cf9ab5d0467225c24ed573900e4999da78af908f6f046580e26a272b
7
+ data.tar.gz: 9c96d69a18c3a7ce96be020f9a95c9d1979ff7572b6c47afda051782571a76c04bc4aab624816f36c13ee84db74e062eaadbbd5e07f21674b01fbb12505166fb
data/.gitignore CHANGED
@@ -17,3 +17,5 @@
17
17
  /public
18
18
  /storage
19
19
  /pkg
20
+
21
+ .ruby-version
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- start_her (0.0.3)
4
+ start_her (0.0.4)
5
5
  gemsupport (~> 0.4)
6
6
  logstash-logger (~> 0.15)
7
7
  msgpack (~> 0.7)
@@ -67,4 +67,4 @@ DEPENDENCIES
67
67
  start_her!
68
68
 
69
69
  BUNDLED WITH
70
- 1.10.6
70
+ 1.12.5
@@ -28,7 +28,7 @@ module StartHer
28
28
  end
29
29
  end
30
30
 
31
- # Safe loading for stuff that needs MailHer#config
31
+ # Safe loading for stuff that needs StartHer#config
32
32
  autoload :RedisClient, 'start_her/redis_client'
33
33
  autoload :Subscriber, 'start_her/subscriber'
34
34
  autoload :Publisher, 'start_her/publisher'
@@ -1,11 +1,10 @@
1
1
  module StartHer
2
2
  class Configuration
3
- attr_accessor :redis, :logstash_url, :backlog_ttl
3
+ attr_accessor :redis, :backlog_ttl
4
4
  attr_writer :logger
5
5
 
6
6
  def initialize
7
7
  @redis = {}
8
- @logstash_url = ''
9
8
  @backlog_ttl = 60 * 60 * 24 * 7 # 1.week
10
9
  end
11
10
 
@@ -9,24 +9,17 @@ module StartHer
9
9
  end
10
10
 
11
11
  def development
12
- LogStashLogger.new(type: :multi_delegator, outputs: [
13
- { type: :stdout },
14
- { type: :file, path: 'log/development.log', sync: true }
15
- ], formatter: ::Logger::Formatter)
12
+ LogStashLogger.new(type: :stdout, formatter: ::Logger::Formatter)
16
13
  end
17
14
 
18
15
  def production
19
- LogStashLogger.new(
20
- type: :redis, url: StartHer.config.logstash_url, sync: true).tap do |logger|
16
+ LogStashLogger.new(type: :stdout, formatter: :json).tap do |logger|
21
17
  logger.level = ::Logger::INFO
22
18
  end
23
19
  end
24
20
  class << self
25
21
  alias_method :staging, :production
26
- end
27
-
28
- def test
29
- LogStashLogger.new(type: :stdout, formatter: ::Logger::Formatter)
22
+ alias_method :test, :development
30
23
  end
31
24
  end
32
25
  end
@@ -1,3 +1,3 @@
1
1
  module StartHer
2
- VERSION = '0.0.4'
2
+ VERSION = '0.0.5'
3
3
  end
@@ -7,10 +7,6 @@ module StartHer
7
7
  expect(subject.redis).to eq({})
8
8
  end
9
9
 
10
- it 'contains default Logstash URL' do
11
- expect(subject.logstash_url).to eq('')
12
- end
13
-
14
10
  it 'contains default logger' do
15
11
  expect(subject.logger).to be_a(::LogStashLogger)
16
12
  end
@@ -33,7 +33,7 @@ module StartHer
33
33
  CustomHelpers.suppress(RuntimeError) do
34
34
  exponential_backoff.call(options)
35
35
  end
36
- expect((Time.now.utc - started_at).round(2)).to eq(options[:elapsed_time_secs])
36
+ expect((Time.now.utc - started_at).round(1)).to eq(options[:elapsed_time_secs])
37
37
  end
38
38
 
39
39
  it 'raises an error' do
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: start_her
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.4
4
+ version: 0.0.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - abourquin
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2016-01-11 00:00:00.000000000 Z
12
+ date: 2016-07-18 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: redis
@@ -186,9 +186,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
186
186
  version: '0'
187
187
  requirements: []
188
188
  rubyforge_project:
189
- rubygems_version: 2.4.7
189
+ rubygems_version: 2.4.5.1
190
190
  signing_key:
191
191
  specification_version: 4
192
192
  summary: StartHer
193
193
  test_files: []
194
- has_rdoc: