[hydra-commits] hydra/servicediscovery.git branch "master" updated.

Commits to the Hydra project code repositories hydra-commits at lists.digium.com
Mon Aug 2 13:25:05 CDT 2010


branch "master" has been updated
       via  bf0d9d84ec852304cf65493760303bdb0883a723 (commit)
       via  df08c5c126bbb6fa0cd371b2c81cf894eb75f21b (commit)
      from  9c79125b7fccf4db64b4c49b20a9cdaa3b8e6f09 (commit)

Summary of changes:
 slice/service_locator.ice   |    2 +-
 test/TestServiceLocator.cpp |   11 ++++++++---
 2 files changed, 9 insertions(+), 4 deletions(-)


- Log -----------------------------------------------------------------
commit bf0d9d84ec852304cf65493760303bdb0883a723
Author: Joshua Colp <jcolp at digium.com>
Date:   Mon Aug 2 15:25:21 2010 -0300

    We need to preserve sliced data as it flows through us.

diff --git a/slice/service_locator.ice b/slice/service_locator.ice
index 132403f..5b97a58 100644
--- a/slice/service_locator.ice
+++ b/slice/service_locator.ice
@@ -33,7 +33,7 @@ module V1
 	/**
 	 * Generic service locator parameters class that more specific parameter classes can extend.
 	 */
-	class ServiceLocatorParams
+	["preserved"] class ServiceLocatorParams
 	{
 		/**
 		 * Basic category for the service, such as bridge or channel service.

commit df08c5c126bbb6fa0cd371b2c81cf894eb75f21b
Author: Joshua Colp <jcolp at digium.com>
Date:   Mon Aug 2 10:52:18 2010 -0300

    Go a step further and actually call into the found services.

diff --git a/test/TestServiceLocator.cpp b/test/TestServiceLocator.cpp
index db6adec..a520371 100644
--- a/test/TestServiceLocator.cpp
+++ b/test/TestServiceLocator.cpp
@@ -311,8 +311,10 @@ BOOST_AUTO_TEST_CASE(UseServiceFoundWithoutCompareService)
 	bool usable = false;
 
 	try {
-		/* We can do a comparison of the proxy against local to confirm it's proper so we don't have to call back into ourselves */
-		if (Testbed.found_compare == Testbed.compare) {
+		ServiceLocatorParamsPtr params = new ServiceLocatorParams;
+		params->category = "bob";
+
+		if ((Testbed.found_compare == Testbed.compare) && (Testbed.found_compare->isSupported(params) == true)) {
 			usable = true;
 		}
 	} catch (const Ice::Exception &e) {
@@ -407,7 +409,10 @@ BOOST_AUTO_TEST_CASE(UseServiceFoundWithCompareService)
 	bool usable = false;
 
 	try {
-		if (Testbed.found_compare == Testbed.compare) {
+		ServiceLocatorParamsPtr params = new ServiceLocatorParams;
+		params->category = "bob";
+
+		if ((Testbed.found_compare == Testbed.compare) && (Testbed.found_compare->isSupported(params) == true)) {
 			usable = true;
 		}
 	} catch (const Ice::Exception &e) {

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


-- 
hydra/servicediscovery.git




More information about the asterisk-scf-commits mailing list