weel 1.99.7 → 1.99.8
Sign up to get free protection for your applications and to get access to all the features.
- data/lib/weel.rb +10 -12
- data/test/TestHandlerWrapper.rb +1 -1
- data/weel.gemspec +1 -1
- metadata +2 -2
data/lib/weel.rb
CHANGED
@@ -241,8 +241,8 @@ class WEEL
|
|
241
241
|
!@q.empty?
|
242
242
|
end
|
243
243
|
end
|
244
|
-
def continue
|
245
|
-
@q.push
|
244
|
+
def continue(what=nil)
|
245
|
+
@q.push what
|
246
246
|
end
|
247
247
|
def clear
|
248
248
|
@q.clear
|
@@ -621,15 +621,13 @@ class WEEL
|
|
621
621
|
|
622
622
|
passthrough = @__weel_search_positions[position] ? @__weel_search_positions[position].passthrough : nil
|
623
623
|
begin
|
624
|
-
# with loop if
|
625
|
-
|
626
|
-
|
627
|
-
|
628
|
-
|
629
|
-
|
630
|
-
|
631
|
-
again = true
|
632
|
-
end
|
624
|
+
# with loop if catching Signal::Again
|
625
|
+
# handshake call and wait until it finished
|
626
|
+
|
627
|
+
handlerwrapper.activity_handle passthrough, params
|
628
|
+
waitingresult = nil
|
629
|
+
waitingresult = Thread.current[:continue].wait unless Thread.current[:nolongernecessary] || self.__weel_state == :stopping || self.__weel_state == :stopped
|
630
|
+
raise waitingresult if !waitingresult.nil? && waitingresult.is_a?(Signal::Again)
|
633
631
|
|
634
632
|
if Thread.current[:nolongernecessary]
|
635
633
|
handlerwrapper.activity_no_longer_necessary
|
@@ -661,7 +659,7 @@ class WEEL
|
|
661
659
|
(mr.changed_endpoints.any? ? mr.changed_endpoints.uniq : nil)
|
662
660
|
)
|
663
661
|
end
|
664
|
-
end while wp.passthrough.nil? &&
|
662
|
+
end while wp.passthrough.nil? && waitingresult == Signal::Again
|
665
663
|
if wp.passthrough.nil?
|
666
664
|
handlerwrapper.inform_activity_done
|
667
665
|
wp.detail = :after
|
data/test/TestHandlerWrapper.rb
CHANGED
@@ -19,7 +19,7 @@ class TestHandlerWrapper < WEEL::HandlerWrapperBase
|
|
19
19
|
if @__myhandler_endpoint == 'again'
|
20
20
|
@__myhandler_returnValue = parameters.has_key?(:result) ? parameters[:result] : 'Handler_Dummy_Result'
|
21
21
|
if parameters[:call].call
|
22
|
-
|
22
|
+
@__myhandler_continue.continue WEEL::Signal::Again
|
23
23
|
else
|
24
24
|
@__myhandler_continue.continue
|
25
25
|
end
|
data/weel.gemspec
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: weel
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.99.
|
4
|
+
version: 1.99.8
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -10,7 +10,7 @@ authors:
|
|
10
10
|
autorequire:
|
11
11
|
bindir: bin
|
12
12
|
cert_chain: []
|
13
|
-
date: 2014-04-
|
13
|
+
date: 2014-04-03 00:00:00.000000000 Z
|
14
14
|
dependencies: []
|
15
15
|
description: see http://cpee.org
|
16
16
|
email: juergen.mangler@gmail.com
|