summaryrefslogtreecommitdiff
path: root/cpp/src/IceGrid/ServerI.cpp
diff options
context:
space:
mode:
authorJose <jose@zeroc.com>2012-08-14 00:05:17 +0200
committerJose <jose@zeroc.com>2012-08-14 00:05:17 +0200
commitb3a890faf5841289df3299bac6ada7120b324c16 (patch)
treeeacdb167a4d1e6310bfd49827f90fb2ddf2c144a /cpp/src/IceGrid/ServerI.cpp
parentmissing filter properties (diff)
downloadice-b3a890faf5841289df3299bac6ada7120b324c16.tar.bz2
ice-b3a890faf5841289df3299bac6ada7120b324c16.tar.xz
ice-b3a890faf5841289df3299bac6ada7120b324c16.zip
ICE-4809 - AMI metadata in Ice services internal definitions
Diffstat (limited to 'cpp/src/IceGrid/ServerI.cpp')
-rwxr-xr-xcpp/src/IceGrid/ServerI.cpp35
1 files changed, 8 insertions, 27 deletions
diff --git a/cpp/src/IceGrid/ServerI.cpp b/cpp/src/IceGrid/ServerI.cpp
index 1eb80d965f3..4db7ef92f78 100755
--- a/cpp/src/IceGrid/ServerI.cpp
+++ b/cpp/src/IceGrid/ServerI.cpp
@@ -248,31 +248,6 @@ private:
const TraceLevelsPtr _traceLevels;
};
-class WaitForApplicationUpdateCB : public AMI_NodeSession_waitForApplicationUpdate
-{
-public:
-
- WaitForApplicationUpdateCB(const ServerIPtr& server) : _server(server)
- {
- }
-
- virtual void
- ice_response()
- {
- _server->activate();
- }
-
- virtual void
- ice_exception(const Ice::Exception&)
- {
- _server->activate();
- }
-
-private:
-
- const ServerIPtr _server;
-};
-
struct EnvironmentEval : std::unary_function<string, string>
{
@@ -697,6 +672,12 @@ ServerI::~ServerI()
}
void
+ServerI::waitForApplicationUpdateCompleted(const Ice::AsyncResultPtr&)
+{
+ activate();
+}
+
+void
ServerI::start_async(const AMD_Server_startPtr& amdCB, const Ice::Current&)
{
start(Manual, amdCB);
@@ -1406,8 +1387,8 @@ ServerI::activate()
NodeSessionPrx session = _node->getMasterNodeSession();
if(session)
{
- AMI_NodeSession_waitForApplicationUpdatePtr cb = new WaitForApplicationUpdateCB(this);
- _node->getMasterNodeSession()->waitForApplicationUpdate_async(cb, desc->uuid, desc->revision);
+ _node->getMasterNodeSession()->begin_waitForApplicationUpdate(
+ desc->uuid, desc->revision, ::Ice::newCallback(this, &ServerI::waitForApplicationUpdateCompleted));
return;
}
}