right_support 2.6.15 → 2.6.16
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -99,6 +99,7 @@ module RightSupport::Net::LB
|
|
99
99
|
# health. For any new endpoint, set its health to INITIAL_N_LEVEL.
|
100
100
|
|
101
101
|
def update!(new_endpoints)
|
102
|
+
new_endpoints = new_endpoints.dup # duplicate the array, so we don't modify the passed one.
|
102
103
|
@endpoints.each { |k,v| new_endpoints.include?(k) ? new_endpoints.delete(k) : @endpoints.delete(k) }
|
103
104
|
new_endpoints.each { |ep| @endpoints[ep] = {:n_level => INITIAL_N_LEVEL, :timestamp => 0} }
|
104
105
|
end
|
@@ -147,7 +148,7 @@ module RightSupport::Net::LB
|
|
147
148
|
end
|
148
149
|
|
149
150
|
def next
|
150
|
-
# Returns the array of hashes which consists of yellow and green endpoints with the
|
151
|
+
# Returns the array of hashes which consists of yellow and green endpoints with the
|
151
152
|
# following structure: [ [EP1, {:n_level => ..., :timestamp => ... }], [EP2, ... ] ]
|
152
153
|
endpoints = @stack.sweep_and_return_yellow_and_green
|
153
154
|
return nil if endpoints.empty?
|
@@ -31,6 +31,8 @@ module RightSupport::Rack
|
|
31
31
|
# this middleware will set it before calling the next middleware. Therefore,
|
32
32
|
# RequestLogger can be used standalone to fulfill all logging needs, or combined
|
33
33
|
# with Rack::Logger or another middleware that provides logging services.
|
34
|
+
#
|
35
|
+
# @deprecated this class will be removed in RightSupport 3.0, please do not use it
|
34
36
|
class LogSetter
|
35
37
|
# Initialize an instance of the middleware. For backward compatibility, the order of the
|
36
38
|
# logger and level parameters can be switched.
|
@@ -43,6 +45,7 @@ module RightSupport::Rack
|
|
43
45
|
def initialize(app, options={})
|
44
46
|
@app = app
|
45
47
|
@logger = options[:logger]
|
48
|
+
warn "#{self.class.name} is deprecated and will be removed in 3.0, please refrain from using it"
|
46
49
|
end
|
47
50
|
|
48
51
|
# Add a logger to the Rack environment and call the next middleware.
|
data/right_support.gemspec
CHANGED
@@ -7,8 +7,8 @@ spec = Gem::Specification.new do |s|
|
|
7
7
|
s.required_ruby_version = Gem::Requirement.new(">= 1.8.7")
|
8
8
|
|
9
9
|
s.name = 'right_support'
|
10
|
-
s.version = '2.6.
|
11
|
-
s.date = '2013-01-
|
10
|
+
s.version = '2.6.16'
|
11
|
+
s.date = '2013-01-28'
|
12
12
|
|
13
13
|
s.authors = ['Tony Spataro', 'Sergey Sergyenko', 'Ryan Williamson', 'Lee Kirchhoff', 'Sergey Enin', 'Alexey Karpik', 'Scott Messier']
|
14
14
|
s.email = 'support@rightscale.com'
|
metadata
CHANGED
@@ -1,13 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: right_support
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
hash:
|
4
|
+
hash: 55
|
5
5
|
prerelease: false
|
6
6
|
segments:
|
7
7
|
- 2
|
8
8
|
- 6
|
9
|
-
-
|
10
|
-
version: 2.6.
|
9
|
+
- 16
|
10
|
+
version: 2.6.16
|
11
11
|
platform: ruby
|
12
12
|
authors:
|
13
13
|
- Tony Spataro
|
@@ -21,7 +21,7 @@ autorequire:
|
|
21
21
|
bindir: bin
|
22
22
|
cert_chain: []
|
23
23
|
|
24
|
-
date: 2013-01-
|
24
|
+
date: 2013-01-28 00:00:00 -08:00
|
25
25
|
default_executable:
|
26
26
|
dependencies: []
|
27
27
|
|