diff options
author | Michi Henning <michi@zeroc.com> | 2008-10-17 17:04:16 +1000 |
---|---|---|
committer | Michi Henning <michi@zeroc.com> | 2008-10-17 17:04:16 +1000 |
commit | 4259685e44589a6efbb45f43f054b406dc8cf89c (patch) | |
tree | d3e26a8201d782e4cd4f617c090cafe9e609d943 /cpp/src/IceGrid/LocatorI.cpp | |
parent | Changed swish-e perl scripts to tolerate -IceTouch suffix and to avoid (diff) | |
parent | Squashed commit of the following: (diff) | |
download | ice-4259685e44589a6efbb45f43f054b406dc8cf89c.tar.bz2 ice-4259685e44589a6efbb45f43f054b406dc8cf89c.tar.xz ice-4259685e44589a6efbb45f43f054b406dc8cf89c.zip |
Merge branch 'R3_3_branch'
Diffstat (limited to 'cpp/src/IceGrid/LocatorI.cpp')
-rw-r--r-- | cpp/src/IceGrid/LocatorI.cpp | 20 |
1 files changed, 15 insertions, 5 deletions
diff --git a/cpp/src/IceGrid/LocatorI.cpp b/cpp/src/IceGrid/LocatorI.cpp index 554a170c22d..3fbe3a146f1 100644 --- a/cpp/src/IceGrid/LocatorI.cpp +++ b/cpp/src/IceGrid/LocatorI.cpp @@ -236,12 +236,15 @@ LocatorI::Request::activate(const string& id) // NOTE: we use a timeout large enough to ensure that the activate() call won't // timeout if the server hangs in deactivation and/or activation. // - for(LocatorAdapterInfoSeq::const_iterator p = _adapters.begin(); p != _adapters.end(); ++p) { - if(p->id == id) + Lock sync(*this); + for(LocatorAdapterInfoSeq::const_iterator p = _adapters.begin(); p != _adapters.end(); ++p) { - _locator->activate(*p, this); - _activating.insert(id); + if(p->id == id) + { + _locator->activate(*p, this); + _activating.insert(id); + } } } @@ -684,7 +687,14 @@ LocatorI::removePendingResolve(const string& adapterId, int roundRobinCount) // if(roundRobinCount > 0) { - _database->getAdapter(adapterId)->increaseRoundRobinCount(roundRobinCount); + try + { + _database->getAdapter(adapterId)->increaseRoundRobinCount(roundRobinCount); + } + catch(const Ice::Exception&) + { + // Ignore. + } } map<string, deque<Ice::AMD_Locator_findAdapterByIdPtr> >::iterator p = _resolves.find(adapterId); |