summaryrefslogtreecommitdiff
path: root/cpp/src
diff options
context:
space:
mode:
authorDwayne Boone <dwayne@zeroc.com>2009-02-19 14:49:13 -0330
committerDwayne Boone <dwayne@zeroc.com>2009-02-19 14:49:13 -0330
commit57d89ba2b0b0f51ffb2123f595f8e727d246cc50 (patch)
treeaebc52c6485bf7ab9597462d48a6da2ff21a9acc /cpp/src
parentBug 3053/3616 - .NET and pdbs (diff)
downloadice-57d89ba2b0b0f51ffb2123f595f8e727d246cc50.tar.bz2
ice-57d89ba2b0b0f51ffb2123f595f8e727d246cc50.tar.xz
ice-57d89ba2b0b0f51ffb2123f595f8e727d246cc50.zip
Bug 3410 - remove deprecation of Ice.MonitorConnections
Diffstat (limited to 'cpp/src')
-rw-r--r--cpp/src/Ice/ConnectionI.cpp4
-rw-r--r--cpp/src/Ice/ConnectionI.h2
-rw-r--r--cpp/src/Ice/ConnectionMonitor.cpp3
-rw-r--r--cpp/src/Ice/Instance.cpp2
-rw-r--r--cpp/src/Ice/PropertyNames.cpp4
-rw-r--r--cpp/src/Ice/PropertyNames.h2
6 files changed, 9 insertions, 8 deletions
diff --git a/cpp/src/Ice/ConnectionI.cpp b/cpp/src/Ice/ConnectionI.cpp
index 1e3e2cb76ab..a549a74ebf2 100644
--- a/cpp/src/Ice/ConnectionI.cpp
+++ b/cpp/src/Ice/ConnectionI.cpp
@@ -421,7 +421,7 @@ Ice::ConnectionI::waitUntilFinished()
}
void
-Ice::ConnectionI::monitor()
+Ice::ConnectionI::monitor(const IceUtil::Time& now)
{
IceUtil::Monitor<IceUtil::Mutex>::TryLock sync(*this);
if(!sync.acquired())
@@ -445,7 +445,7 @@ Ice::ConnectionI::monitor()
return;
}
- if(IceUtil::Time::now(IceUtil::Time::Monotonic) >= _acmAbsoluteTimeout)
+ if(now >= _acmAbsoluteTimeout)
{
setState(StateClosing, ConnectionTimeoutException(__FILE__, __LINE__));
}
diff --git a/cpp/src/Ice/ConnectionI.h b/cpp/src/Ice/ConnectionI.h
index 642a41f981c..04fe3f100df 100644
--- a/cpp/src/Ice/ConnectionI.h
+++ b/cpp/src/Ice/ConnectionI.h
@@ -81,7 +81,7 @@ public:
void waitUntilHolding() const;
void waitUntilFinished(); // Not const, as this might close the connection upon timeout.
- void monitor();
+ void monitor(const IceUtil::Time&);
bool sendRequest(IceInternal::Outgoing*, bool, bool);
bool sendAsyncRequest(const IceInternal::OutgoingAsyncPtr&, bool, bool);
diff --git a/cpp/src/Ice/ConnectionMonitor.cpp b/cpp/src/Ice/ConnectionMonitor.cpp
index 9fde65606d9..6933ab3d401 100644
--- a/cpp/src/Ice/ConnectionMonitor.cpp
+++ b/cpp/src/Ice/ConnectionMonitor.cpp
@@ -88,11 +88,12 @@ IceInternal::ConnectionMonitor::runTimerTask()
// Monitor connections outside the thread synchronization, so
// that connections can be added or removed during monitoring.
//
+ IceUtil::Time now = IceUtil::Time::now(IceUtil::Time::Monotonic);
for(set<ConnectionIPtr>::const_iterator p = connections.begin(); p != connections.end(); ++p)
{
try
{
- (*p)->monitor();
+ (*p)->monitor(now);
}
catch(const Exception& ex)
{
diff --git a/cpp/src/Ice/Instance.cpp b/cpp/src/Ice/Instance.cpp
index 34133c7d42d..8c1f054805a 100644
--- a/cpp/src/Ice/Instance.cpp
+++ b/cpp/src/Ice/Instance.cpp
@@ -1165,7 +1165,7 @@ IceInternal::Instance::finishSetup(int& argc, char* argv[])
}
if(interval > 0)
{
- interval = min(300, max(1, (int)interval / 10));
+ interval = min(300, max(5, (int)interval / 10));
}
interval = _initData.properties->getPropertyAsIntWithDefault("Ice.MonitorConnections", interval);
if(interval > 0)
diff --git a/cpp/src/Ice/PropertyNames.cpp b/cpp/src/Ice/PropertyNames.cpp
index 9d78a8694b1..52f1bf80901 100644
--- a/cpp/src/Ice/PropertyNames.cpp
+++ b/cpp/src/Ice/PropertyNames.cpp
@@ -8,7 +8,7 @@
// **********************************************************************
//
-// Generated by makeprops.py from file ../config/PropertyNames.xml, Wed Feb 4 15:39:07 2009
+// Generated by makeprops.py from file ../config/PropertyNames.xml, Thu Feb 19 14:25:55 2009
// IMPORTANT: Do not edit this file -- any edits made here will be lost!
@@ -73,7 +73,7 @@ const IceInternal::Property IcePropsData[] =
IceInternal::Property("Ice.ImplicitContext", false, 0),
IceInternal::Property("Ice.InitPlugins", false, 0),
IceInternal::Property("Ice.MessageSizeMax", false, 0),
- IceInternal::Property("Ice.MonitorConnections", true, 0),
+ IceInternal::Property("Ice.MonitorConnections", false, 0),
IceInternal::Property("Ice.Nohup", false, 0),
IceInternal::Property("Ice.NullHandleAbort", false, 0),
IceInternal::Property("Ice.Override.Compress", false, 0),
diff --git a/cpp/src/Ice/PropertyNames.h b/cpp/src/Ice/PropertyNames.h
index 7a60a865038..d31c8c387c8 100644
--- a/cpp/src/Ice/PropertyNames.h
+++ b/cpp/src/Ice/PropertyNames.h
@@ -8,7 +8,7 @@
// **********************************************************************
//
-// Generated by makeprops.py from file ../config/PropertyNames.xml, Wed Feb 4 15:39:07 2009
+// Generated by makeprops.py from file ../config/PropertyNames.xml, Thu Feb 19 14:25:55 2009
// IMPORTANT: Do not edit this file -- any edits made here will be lost!