added exception passing from dbmath through math back to the client
authorerickson <erickson@9efc2488-bf62-4759-914b-345cdb29e865>
Tue, 8 Feb 2005 15:31:11 +0000 (15:31 +0000)
committererickson <erickson@9efc2488-bf62-4759-914b-345cdb29e865>
Tue, 8 Feb 2005 15:31:11 +0000 (15:31 +0000)
git-svn-id: svn://svn.open-ils.org/OpenSRF/trunk@30 9efc2488-bf62-4759-914b-345cdb29e865

src/perlmods/OpenSRF/Application/Demo/Math.pm

index a9208af..0faba6b 100644 (file)
@@ -63,7 +63,11 @@ sub send_request {
                else{ $log->debug( "Math received empty value", ERROR ); }
                $req->finish;
                $session->finish;
-               throw OpenSRF::EX::ERROR ("Did not receive expected data from MathDB");
+               if( $resp ) {
+                       throw OpenSRF::EX::ERROR ("Did not receive expected data from MathDB\n" . $resp);
+               } else {
+                       throw OpenSRF::EX::ERROR ("Received no data from MathDB");
+               }
 
        }
 }