asynchronous 1.0.3 → 1.0.4
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +8 -8
- data/VERSION +1 -1
- data/lib/asynchronous/parallelism.rb +8 -8
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,15 +1,15 @@
|
|
1
1
|
---
|
2
2
|
!binary "U0hBMQ==":
|
3
3
|
metadata.gz: !binary |-
|
4
|
-
|
4
|
+
OTU5ZGY2NjQ1ZjAwMDBkNDhmN2JhMjkwZjdjNjk4M2RiMWQxYTRmOQ==
|
5
5
|
data.tar.gz: !binary |-
|
6
|
-
|
6
|
+
MDY5MjRjMjhjMzc2YmUxZWUzODFiMWY4NWNkYWFiM2RmZDdmNjg5MQ==
|
7
7
|
SHA512:
|
8
8
|
metadata.gz: !binary |-
|
9
|
-
|
10
|
-
|
11
|
-
|
9
|
+
Mjg5MzZiN2I3NDM4Yzc2MmYwYzMyNzk3OGUxOWU3NjIwZTdiNjg2NDM0NGQx
|
10
|
+
NGQ2MGE4NmFiYTgxNDM1OWVmMmQ5YjMwZjI5ODcxZTM2MTk0NWE5OTdiOWI1
|
11
|
+
NTY2N2FhODI4N2JkOTljNDU1OTE5NGY0YTM4NWY3MTliNzIyNWQ=
|
12
12
|
data.tar.gz: !binary |-
|
13
|
-
|
14
|
-
|
15
|
-
|
13
|
+
ZjViMzZjODEwNTI2MzIxZjNlYjE0MDZkMTg0MzNiNzY1MTQ3MDYyNmI1MzJh
|
14
|
+
ZTE3ODQxMWFjNjhlYmE3MWNjMDgwMmQ2NmQyOWNhNGJjOWVlOTY0ZTZhYjI4
|
15
|
+
N2YzOTZiYzEzOWJhNTMyZDFlNmRiMDE3Y2JmYTkxZjU4ZmExZDM=
|
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
1.0.
|
1
|
+
1.0.4
|
@@ -17,7 +17,7 @@ module Asynchronous
|
|
17
17
|
@@motherpid ||= $$
|
18
18
|
@@agent ||= nil
|
19
19
|
@@zombie ||= true
|
20
|
-
|
20
|
+
::Kernel.require 'yaml'
|
21
21
|
|
22
22
|
end
|
23
23
|
|
@@ -55,11 +55,14 @@ module Asynchronous
|
|
55
55
|
# return the value
|
56
56
|
begin
|
57
57
|
|
58
|
+
#::Kernel.puts callable.class
|
59
|
+
|
58
60
|
return_value= callable.call
|
59
61
|
|
60
62
|
@rd.close
|
61
|
-
|
62
|
-
#@wr.write return_value
|
63
|
+
|
64
|
+
#@wr.write ::Marshal.dump(return_value)
|
65
|
+
@wr.write return_value.to_yaml
|
63
66
|
|
64
67
|
@wr.close
|
65
68
|
|
@@ -94,7 +97,6 @@ module Asynchronous
|
|
94
97
|
|
95
98
|
if @value.nil?
|
96
99
|
|
97
|
-
|
98
100
|
#while alive?(@pid)
|
99
101
|
# ::Kernel.puts alive? @pid
|
100
102
|
# ::Kernel.sleep 1
|
@@ -105,10 +107,8 @@ module Asynchronous
|
|
105
107
|
return_value= @rd.read
|
106
108
|
@rd.close
|
107
109
|
|
108
|
-
|
109
|
-
|
110
|
-
return_value= ::Marshal.load(return_value)
|
111
|
-
#return_value= ::YAML.load(return_value)
|
110
|
+
#return_value= ::Marshal.load(return_value)
|
111
|
+
return_value= ::YAML.load(return_value)
|
112
112
|
|
113
113
|
@@pids.delete(@pid)
|
114
114
|
@value= return_value
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: asynchronous
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.
|
4
|
+
version: 1.0.4
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Adam Luzsi
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2014-
|
11
|
+
date: 2014-02-05 00:00:00.000000000 Z
|
12
12
|
dependencies: []
|
13
13
|
description: ! 'DSL for for dead simple to use asynchronous patterns in both VM managed
|
14
14
|
and OS managed way (Concurrency and Parallelism) '
|