diff options
author | Benoit Foucher <benoit@zeroc.com> | 2005-09-15 12:32:45 +0000 |
---|---|---|
committer | Benoit Foucher <benoit@zeroc.com> | 2005-09-15 12:32:45 +0000 |
commit | 0df21eda351a4e9ea3d7647bf1a91d8bee903b61 (patch) | |
tree | 4f6ad583db87fe40bc0de570a4cfb4d575e615ca /cpp/src/IceGrid/NodeSessionI.cpp | |
parent | Fix (diff) | |
download | ice-0df21eda351a4e9ea3d7647bf1a91d8bee903b61.tar.bz2 ice-0df21eda351a4e9ea3d7647bf1a91d8bee903b61.tar.xz ice-0df21eda351a4e9ea3d7647bf1a91d8bee903b61.zip |
Better tracing
Diffstat (limited to 'cpp/src/IceGrid/NodeSessionI.cpp')
-rw-r--r-- | cpp/src/IceGrid/NodeSessionI.cpp | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/cpp/src/IceGrid/NodeSessionI.cpp b/cpp/src/IceGrid/NodeSessionI.cpp index 1cfe92db208..74c3f7ec485 100644 --- a/cpp/src/IceGrid/NodeSessionI.cpp +++ b/cpp/src/IceGrid/NodeSessionI.cpp @@ -8,6 +8,7 @@ // ********************************************************************** #include <Ice/Ice.h> + #include <IceGrid/NodeSessionI.h> #include <IceGrid/Database.h> @@ -16,6 +17,7 @@ using namespace IceGrid; NodeSessionI::NodeSessionI(const DatabasePtr& database, const string& name, const NodePrx& node) : _database(database), + _traceLevels(database->getTraceLevels()), _name(name), _node(node), _startTime(IceUtil::Time::now()), @@ -44,8 +46,16 @@ NodeSessionI::keepAlive(const LoadInfo& load, const Ice::Current& current) throw Ice::ObjectNotExistException(__FILE__, __LINE__); } + if(_traceLevels->node > 2) + { + Ice::Trace out(_traceLevels->logger, _traceLevels->nodeCat); + out << "node `" << _name << "' keep alive "; + out << "(load = " << _load.load1 << ", " << _load.load5 << ", " << _load.load15 << ")"; + } + _timestamp = IceUtil::Time::now(); _load = load; + } Ice::StringSeq |