plezi 0.14.3 → 0.14.4

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: 6ddd8b8186ab951cdd13190a403826c0cbe91981
4
- data.tar.gz: 5dcfc9e0bacc74de928eabe54a03916eec97743c
3
+ metadata.gz: 42876c61ff855afd7f6385ec7e6d28c3eb5f245c
4
+ data.tar.gz: 433b879ffe3e66d914926c08146218478e8a25bb
5
5
  SHA512:
6
- metadata.gz: 4d68a58f2895b7dcdb345adf54d5c0e721706ec02fe8cd4b516bfcdf48ca2c7214a96a2c1ca0cd0f4697d86c1b082ba83fa4dceabd0df1221ce3547cdf470f2b
7
- data.tar.gz: 67d8deb352baea686243f1a3ef56873afce60596127f59332da185a2db998a59d0172dd5bdedfdedbbbf6705f5c4c2014229b20854110a2d6309732573439712
6
+ metadata.gz: 7ae7db10a005e2751b253f404c5d1e45bc6971c869a33047ab95a7980e45a9ad721f45c3c0ee168cb698e029d05448d1e8d3aed3c40a2f9bc5e8ba1ab77f0903
7
+ data.tar.gz: 9e9e96ed337490cb82a8ffb1416fc88ef5e210a65c43b49335d3d9898e50291564b6b99342214f5f0c1e18a1ea1329ec58c4b2b1aa78d94116aea926b61fab9d
data/CHANGELOG.md CHANGED
@@ -2,6 +2,12 @@
2
2
 
3
3
  ***
4
4
 
5
+ Change log v.0.14.4
6
+
7
+ **Fix**: fixed an issue were scaling using `fork` or server workers would break the automatic scaling feature. The issue was caused by the pub/Sub channel ID of the new processes being identical to the origin process. Credit to Vladimir Dementyev (@palkan) for exposing this issue. This did not seem to effect applications that scaled up with independent processes / machines, such as applications that scaled up using "dynos" on Heroku.
8
+
9
+ ***
10
+
5
11
  Change log v.0.14.3
6
12
 
7
13
  **Dependencies**: added the missing `bundler` and `rack >= 2.0.0` dependencies. Since the bundler gem is often installed by default, it took me a while to realize it was missing from the dependency list. Rack was also easy to miss (being as common).
@@ -12,10 +12,10 @@ module Plezi
12
12
  end
13
13
  @plezi_initialize = nil
14
14
  def self.plezi_initialize
15
- ::Plezi::Base::MessageDispatch._init
16
15
  if @plezi_initialize.nil?
17
16
  @plezi_initialize = true
18
17
  @plezi_autostart = true if @plezi_autostart.nil?
18
+ puts "WARNNING: auto-scaling with redis is set using ENV['PL_REDIS_URL'.freeze]\r\n but the Redis gem isn't included! - SCALING IS IGNORED!" if ENV['PL_REDIS_URL'.freeze] && !defined?(::Redis)
19
19
  at_exit do
20
20
  next if @plezi_autostart == false
21
21
  ::Iodine::Rack.app = ::Plezi.app
@@ -28,3 +28,4 @@ end
28
28
 
29
29
  ::Iodine.threads ||= 16
30
30
  ::Iodine.processes ||= 1 unless ENV['PL_REDIS_URL'.freeze]
31
+ ::Iodine.run { ::Plezi::Base::MessageDispatch._init }
data/lib/plezi/version.rb CHANGED
@@ -1,3 +1,3 @@
1
1
  module Plezi
2
- VERSION = '0.14.3'.freeze
2
+ VERSION = '0.14.4'.freeze
3
3
  end
@@ -12,7 +12,13 @@ module Plezi
12
12
 
13
13
  module_function
14
14
 
15
+ @ppid = ::Process.pid
16
+
15
17
  def pid
18
+ if(@ppid != ::Process.pid)
19
+ @pid = nil
20
+ @ppid = ::Process.pid
21
+ end
16
22
  @pid ||= SecureRandom.urlsafe_base64.tap { |str| @prefix_len = str.length }
17
23
  end
18
24
 
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: plezi
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.14.3
4
+ version: 0.14.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Boaz Segev
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2016-12-31 00:00:00.000000000 Z
11
+ date: 2017-02-13 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: iodine
@@ -164,7 +164,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
164
164
  version: '0'
165
165
  requirements: []
166
166
  rubyforge_project:
167
- rubygems_version: 2.5.2
167
+ rubygems_version: 2.6.8
168
168
  signing_key:
169
169
  specification_version: 4
170
170
  summary: The Plezi.io Ruby Framework for real time web applications.