[asterisk-scf-commits] asterisk-scf/integration/servicediscovery.git branch "retry_deux" updated.

Commits to the Asterisk SCF project code repositories asterisk-scf-commits at lists.digium.com
Thu May 3 11:37:46 CDT 2012


branch "retry_deux" has been updated
       via  955ebd54eed532aecd7465a462319303487f796e (commit)
      from  66909960f4925507579eeae27a15daeb55368bb1 (commit)

Summary of changes:
 src/ServiceLocator.cpp |   15 +++++++++++----
 1 files changed, 11 insertions(+), 4 deletions(-)


- Log -----------------------------------------------------------------
commit 955ebd54eed532aecd7465a462319303487f796e
Author: Ken Hunt <ken.hunt at digium.com>
Date:   Thu May 3 11:37:44 2012 -0500

    Corrected verify logic.

diff --git a/src/ServiceLocator.cpp b/src/ServiceLocator.cpp
index 7115b6f..1f6ac35 100644
--- a/src/ServiceLocator.cpp
+++ b/src/ServiceLocator.cpp
@@ -147,12 +147,16 @@ public:
         catch (const std::exception& e)
         {
             data->setException(e);
+            throw e;
         }
         catch (...)
         {
             data->setException();
+            throw;
         }
 
+        data->setCompleted();
+
         return true;
     }
 
@@ -192,11 +196,15 @@ public:
         catch (const std::exception& e)
         {
             data->setException(e);
+            throw e;
         }
         catch (...)
         {
             data->setException();
+            throw;
         }
+
+         data->setCompleted();
     }
 
     void addListener(const OperationContextPtr& context, const ReplicaListenerPrx& listener, const Ice::Current&)
@@ -329,11 +337,12 @@ void ServiceLocatorApp::start(const string& appName, const Ice::CommunicatorPtr&
 {
     mCommunicator = communicator;
 
+    mBackplaneAdapterName = appName + ".BackplaneAdapter";
+    mServiceAdapterName = appName + ".Management.ServiceAdapter";
     verifyProperties();
 
     mIceStorm = new AsteriskSCF::CollocatedIceStorm::CollocatedIceStorm(appName, communicator->getProperties());
-
-    mBackplaneAdapterName = appName + ".BackplaneAdapter";
+    
     mLocalAdapter = communicator->createObjectAdapterWithEndpoints(mBackplaneAdapterName,
         communicator->getProperties()->getPropertyWithDefault(mBackplaneAdapterName + ".Endpoints", "tcp -p 4410"));
 
@@ -396,8 +405,6 @@ void ServiceLocatorApp::start(const string& appName, const Ice::CommunicatorPtr&
      * management may want to be protected so arbitrary people can't inject bad services
      * into the infrastructure while discovery as a read only function may be allowed to all.
      */
-
-    mServiceAdapterName = appName + ".Management.ServiceAdapter";
     mManagementAdapter = communicator->createObjectAdapterWithEndpoints(mServiceAdapterName,
         communicator->getProperties()->getPropertyWithDefault(mServiceAdapterName + ".Endpoints", "tcp -p 4412"));
 

-----------------------------------------------------------------------


-- 
asterisk-scf/integration/servicediscovery.git



More information about the asterisk-scf-commits mailing list