concurrent-ruby 1.0.0.pre5 → 1.0.0
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.
- checksums.yaml +4 -4
- data/CHANGELOG.md +4 -15
- data/lib/concurrent/atom.rb +1 -1
- data/lib/concurrent/atomics.rb +2 -1
- data/lib/concurrent/exchanger.rb +2 -2
- data/lib/concurrent/lazy_register.rb +1 -1
- data/lib/concurrent/synchronization/object.rb +4 -4
- data/lib/concurrent/version.rb +2 -2
- metadata +4 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 2d453d5a3a329cb31a092efc32c4525fcdfa89eb
|
4
|
+
data.tar.gz: 7cc6fd6b7d77c27182ab24a41e0df972b188f6a4
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 846bf05bc551466a21bc36bfc4334d572e7f5eac66ccf2a3fdab0c0c33a81b8b76bb37a6037056a975f985ca4cc8367dcd2f7132a7ff2ea7b6ad225f61e8bbf5
|
7
|
+
data.tar.gz: f7141b245f69ce70bdcdb7f9370b9a349c668a1bef6c64ed67be987a48d49c2d991bdf2917dff9c57c8f74b656ea98b147a029cdc0012823132c812b6b2d9afe
|
data/CHANGELOG.md
CHANGED
@@ -1,7 +1,8 @@
|
|
1
|
-
|
2
|
-
|
3
|
-
## Current Release v1.0.0.pre5 (04 November 2015)
|
1
|
+
## Current Release v1.0.0 (13 November 2015)
|
4
2
|
|
3
|
+
* Rename `attr_volatile_with_cas` to `attr_atomic`
|
4
|
+
* Add `clear_each` to `LockFreeStack`
|
5
|
+
* Update `AtomicReference` documentation
|
5
6
|
* Further updates and improvements to the synchronization layer.
|
6
7
|
* Performance and memory usage performance with `Actor` logging.
|
7
8
|
* Fixed `ThreadPoolExecutor` task count methods.
|
@@ -9,9 +10,6 @@
|
|
9
10
|
* Fixed bug in `LockFreeLinkedSet`.
|
10
11
|
* Fixed bug in which `Agent#await` triggered a validation failure.
|
11
12
|
* Further `Channel` updates.
|
12
|
-
|
13
|
-
### Release v1.0.0.pre4 (08 October 2015)
|
14
|
-
|
15
13
|
* Adopted a project Code of Conduct
|
16
14
|
* Cleared interpreter warnings
|
17
15
|
* Fixed bug in `ThreadPoolExecutor` task count methods
|
@@ -19,18 +17,12 @@
|
|
19
17
|
* Improved Java extension loading
|
20
18
|
* Handle Exception children in Edge::Future
|
21
19
|
* Continued improvements to channel
|
22
|
-
|
23
|
-
### Release v1.0.0.pre3 (29 September 2015)
|
24
|
-
|
25
20
|
* Removed interpreter warnings.
|
26
21
|
* Shared constants now in `lib/concurrent/constants.rb`
|
27
22
|
* Refactored many tests.
|
28
23
|
* Improved synchronization layer/memory model documentation.
|
29
24
|
* Bug fix in Edge `Future#flat`
|
30
25
|
* Brand new `Channel` implementation in Edge gem.
|
31
|
-
|
32
|
-
### Release v1.0.0.pre2 (19 September 2015)
|
33
|
-
|
34
26
|
* Simplification of `RubySingleThreadExecutor`
|
35
27
|
* `Async` improvements
|
36
28
|
- Each object uses its own `SingleThreadExecutor` instead of the global thread pool.
|
@@ -42,9 +34,6 @@
|
|
42
34
|
- Added a `#reset` method
|
43
35
|
* Brand new `Agent` API and implementation. Now functionally equivalent to Clojure.
|
44
36
|
* Continued improvements to the synchronization layer
|
45
|
-
|
46
|
-
### Release v1.0.0.pre1 (19 August 2015)
|
47
|
-
|
48
37
|
* Merged in the `thread_safe` gem
|
49
38
|
- `Concurrent::Array`
|
50
39
|
- `Concurrent::Hash`
|
data/lib/concurrent/atom.rb
CHANGED
data/lib/concurrent/atomics.rb
CHANGED
data/lib/concurrent/exchanger.rb
CHANGED
@@ -143,7 +143,7 @@ module Concurrent
|
|
143
143
|
safe_initialization!
|
144
144
|
|
145
145
|
class Node < Concurrent::Synchronization::Object
|
146
|
-
|
146
|
+
attr_atomic :value
|
147
147
|
safe_initialization!
|
148
148
|
|
149
149
|
def initialize(item)
|
@@ -170,7 +170,7 @@ module Concurrent
|
|
170
170
|
|
171
171
|
private
|
172
172
|
|
173
|
-
|
173
|
+
attr_atomic(:slot)
|
174
174
|
|
175
175
|
# @!macro exchanger_method_do_exchange
|
176
176
|
#
|
@@ -18,7 +18,7 @@ module Concurrent
|
|
18
18
|
# Abstract object providing final, volatile, ans CAS extensions to build other concurrent abstractions.
|
19
19
|
# - final instance variables see {Object.safe_initialization!}
|
20
20
|
# - volatile instance variables see {Object.attr_volatile}
|
21
|
-
# - volatile instance variables see {Object.
|
21
|
+
# - volatile instance variables see {Object.attr_atomic}
|
22
22
|
class Object < ObjectImplementation
|
23
23
|
|
24
24
|
# @!method self.attr_volatile(*names)
|
@@ -87,14 +87,14 @@ module Concurrent
|
|
87
87
|
# `compare_and_set_value(expected, value) #=> true || false`, `update_value(&block)`.
|
88
88
|
# @param [Array<Symbol>] names of the instance variables to be volatile with CAS.
|
89
89
|
# @return [Array<Symbol>] names of defined method names.
|
90
|
-
def self.
|
90
|
+
def self.attr_atomic(*names)
|
91
91
|
@volatile_cas_fields ||= []
|
92
92
|
@volatile_cas_fields += names
|
93
93
|
safe_initialization!
|
94
94
|
define_initialize_volatile_with_cas
|
95
95
|
|
96
96
|
names.each do |name|
|
97
|
-
ivar = :"@
|
97
|
+
ivar = :"@Atomic#{name.to_s.gsub(/(?:^|_)(.)/) { $1.upcase }}"
|
98
98
|
class_eval <<-RUBY, __FILE__, __LINE__ + 1
|
99
99
|
def #{name}
|
100
100
|
#{ivar}.get
|
@@ -131,7 +131,7 @@ module Concurrent
|
|
131
131
|
private
|
132
132
|
|
133
133
|
def self.define_initialize_volatile_with_cas
|
134
|
-
assignments = @volatile_cas_fields.map { |name| "@
|
134
|
+
assignments = @volatile_cas_fields.map { |name| "@Atomic#{name.to_s.gsub(/(?:^|_)(.)/) { $1.upcase }} = AtomicReference.new(nil)" }.join("\n")
|
135
135
|
class_eval <<-RUBY
|
136
136
|
def initialize_volatile_with_cas
|
137
137
|
super
|
data/lib/concurrent/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: concurrent-ruby
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.0
|
4
|
+
version: 1.0.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Jerry D'Antonio
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2015-11-
|
12
|
+
date: 2015-11-13 00:00:00.000000000 Z
|
13
13
|
dependencies: []
|
14
14
|
description: |
|
15
15
|
Modern concurrency tools including agents, futures, promises, thread pools, actors, supervisors, and more.
|
@@ -162,9 +162,9 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
162
162
|
version: 1.9.3
|
163
163
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
164
164
|
requirements:
|
165
|
-
- - "
|
165
|
+
- - ">="
|
166
166
|
- !ruby/object:Gem::Version
|
167
|
-
version:
|
167
|
+
version: '0'
|
168
168
|
requirements: []
|
169
169
|
rubyforge_project:
|
170
170
|
rubygems_version: 2.4.8
|