Permalink
Browse files

small fix to thread pool

  • Loading branch information...
movitto committed Oct 13, 2012
1 parent fbc6a6a commit 1ccfdb2cffdbcb812e9c018fb3b9420b573a0eb1
Showing with 2 additions and 1 deletion.
  1. +2 −1 lib/rjr/thread_pool2.rb
View
@@ -55,7 +55,7 @@ def exec
@timestamp = Time.now
}
- @handler.call @params
+ @handler.call *@params
# synchronized so as to ensure that a timeout check does not
# occur until before (in which case thread is killed during
@@ -108,6 +108,7 @@ def launch_worker
# TODO cleaner / more immediate way to pop item off running_queue
#RJR::Logger.debug "finished thread pool job #{work}"
rescue Exception => e
+ # FIXME also send to rjr logger at a critical level
puts "Thread raised Fatal Exception #{e}"
puts "\n#{e.backtrace.join("\n")}"
end

0 comments on commit 1ccfdb2

Please sign in to comment.