qpid-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From tr...@apache.org
Subject svn commit: r834498 - /qpid/trunk/qpid/cpp/bindings/qmf/ruby/qmf.rb
Date Tue, 10 Nov 2009 15:25:30 GMT
Author: tross
Date: Tue Nov 10 15:25:30 2009
New Revision: 834498

URL: http://svn.apache.org/viewvc?rev=834498&view=rev
Log:
Added limited backtracing for exceptions raised in console callbacks.

Modified:
    qpid/trunk/qpid/cpp/bindings/qmf/ruby/qmf.rb

Modified: qpid/trunk/qpid/cpp/bindings/qmf/ruby/qmf.rb
URL: http://svn.apache.org/viewvc/qpid/trunk/qpid/cpp/bindings/qmf/ruby/qmf.rb?rev=834498&r1=834497&r2=834498&view=diff
==============================================================================
--- qpid/trunk/qpid/cpp/bindings/qmf/ruby/qmf.rb (original)
+++ qpid/trunk/qpid/cpp/bindings/qmf/ruby/qmf.rb Tue Nov 10 15:25:30 2009
@@ -865,6 +865,7 @@
       @sync_count = nil
       @sync_result = nil
       @select = []
+      @bt_count = 0
       @cb_cond = new_cond
       @cb_thread = Thread.new do
         run_cb_thread
@@ -1061,8 +1062,12 @@
             @handler.agent_heartbeat(AgentProxy.new(@event.agent, nil), @event.timestamp)
if @handler
           when Qmfengine::ConsoleEvent::METHOD_RESPONSE
           end
-        rescue
-          puts "Exception caught in callback thread: #{$!}"
+        rescue Exception => ex
+          puts "Exception caught in callback: #{ex}"
+          if @bt_count < 2
+            puts ex.backtrace
+            @bt_count += 1
+          end
         end
         @impl.popEvent
         valid = @impl.getEvent(@event)



---------------------------------------------------------------------
Apache Qpid - AMQP Messaging Implementation
Project:      http://qpid.apache.org
Use/Interact: mailto:commits-subscribe@qpid.apache.org


Mime
View raw message