diff options
author | Benoit Foucher <benoit@zeroc.com> | 2010-02-19 18:45:14 +0100 |
---|---|---|
committer | Benoit Foucher <benoit@zeroc.com> | 2010-02-19 18:45:14 +0100 |
commit | ea9a8bcfc079175205766491ab217e65536a656f (patch) | |
tree | 8dd6cd069f9966bd59d72587052a42195d45cf63 /cpp/src/IceGrid/AdminSessionI.cpp | |
parent | added txt to ICE_LICENSE (diff) | |
download | ice-ea9a8bcfc079175205766491ab217e65536a656f.tar.bz2 ice-ea9a8bcfc079175205766491ab217e65536a656f.tar.xz ice-ea9a8bcfc079175205766491ab217e65536a656f.zip |
Fixed bug 4677 - IceGrid update hang
Diffstat (limited to 'cpp/src/IceGrid/AdminSessionI.cpp')
-rw-r--r-- | cpp/src/IceGrid/AdminSessionI.cpp | 27 |
1 files changed, 24 insertions, 3 deletions
diff --git a/cpp/src/IceGrid/AdminSessionI.cpp b/cpp/src/IceGrid/AdminSessionI.cpp index fb2392946d0..0a5b293c475 100644 --- a/cpp/src/IceGrid/AdminSessionI.cpp +++ b/cpp/src/IceGrid/AdminSessionI.cpp @@ -231,19 +231,40 @@ AdminSessionI::getReplicaName(const Ice::Current& current) const FileIteratorPrx AdminSessionI::openServerLog(const string& id, const string& path, int nLines, const Ice::Current& current) { - return addFileIterator(_database->getServer(id)->getProxy(), "#" + path, nLines, current); + try + { + return addFileIterator(_database->getServer(id)->getProxy(false, 5), "#" + path, nLines, current); + } + catch(const SynchronizationException&) + { + throw DeploymentException("server is being updated"); + } } FileIteratorPrx AdminSessionI::openServerStdOut(const string& id, int nLines, const Ice::Current& current) { - return addFileIterator(_database->getServer(id)->getProxy(), "stdout", nLines, current); + try + { + return addFileIterator(_database->getServer(id)->getProxy(false, 5), "stdout", nLines, current); + } + catch(const SynchronizationException&) + { + throw DeploymentException("server is being updated"); + } } FileIteratorPrx AdminSessionI::openServerStdErr(const string& id, int nLines, const Ice::Current& current) { - return addFileIterator(_database->getServer(id)->getProxy(), "stderr", nLines, current); + try + { + return addFileIterator(_database->getServer(id)->getProxy(false, 5), "stderr", nLines, current); + } + catch(const SynchronizationException&) + { + throw DeploymentException("server is being updated"); + } } FileIteratorPrx |