summaryrefslogtreecommitdiff
path: root/cpp
diff options
context:
space:
mode:
Diffstat (limited to 'cpp')
-rw-r--r--cpp/include/Ice/ObserverHelper.h14
-rw-r--r--cpp/include/Ice/Outgoing.h13
-rw-r--r--cpp/include/Ice/OutgoingAsync.h7
-rw-r--r--cpp/src/Ice/ConnectionI.cpp18
-rw-r--r--cpp/src/Ice/Incoming.cpp19
-rw-r--r--cpp/src/Ice/IncomingAsync.cpp1
-rw-r--r--cpp/src/Ice/InstrumentationI.cpp50
-rw-r--r--cpp/src/Ice/InstrumentationI.h13
-rw-r--r--cpp/src/Ice/Outgoing.cpp5
-rw-r--r--cpp/src/Ice/OutgoingAsync.cpp9
-rw-r--r--cpp/test/Ice/metrics/AllTests.cpp26
11 files changed, 134 insertions, 41 deletions
diff --git a/cpp/include/Ice/ObserverHelper.h b/cpp/include/Ice/ObserverHelper.h
index 9cfe030590a..164e6e95cd8 100644
--- a/cpp/include/Ice/ObserverHelper.h
+++ b/cpp/include/Ice/ObserverHelper.h
@@ -107,6 +107,14 @@ public:
_observer->userException();
}
}
+
+ void reply(Ice::Int size)
+ {
+ if(_observer)
+ {
+ _observer->reply(size);
+ }
+ }
};
class ICE_API InvocationObserver : public ObserverHelperT<Ice::Instrumentation::InvocationObserver>
@@ -130,12 +138,12 @@ public:
}
}
- ::Ice::Instrumentation::ObserverPtr
- getRemoteObserver(const Ice::ConnectionInfoPtr& con, const Ice::EndpointPtr& endpt)
+ ::Ice::Instrumentation::RemoteObserverPtr
+ getRemoteObserver(const Ice::ConnectionInfoPtr& con, const Ice::EndpointPtr& endpt, int requestId, int size)
{
if(_observer)
{
- return _observer->getRemoteObserver(con, endpt);
+ return _observer->getRemoteObserver(con, endpt, requestId, size);
}
return 0;
}
diff --git a/cpp/include/Ice/Outgoing.h b/cpp/include/Ice/Outgoing.h
index ca986d664cf..1909187e007 100644
--- a/cpp/include/Ice/Outgoing.h
+++ b/cpp/include/Ice/Outgoing.h
@@ -138,9 +138,10 @@ public:
void throwUserException();
- void attachRemoteObserver(const Ice::ConnectionInfoPtr& connection, const Ice::EndpointPtr& endpt)
+ void attachRemoteObserver(const Ice::ConnectionInfoPtr& c, const Ice::EndpointPtr& endpt,
+ Ice::Int requestId, Ice::Int size)
{
- _remoteObserver.attach(_observer.getRemoteObserver(connection, endpt));
+ _remoteObserver.attach(_observer.getRemoteObserver(c, endpt, requestId, size));
}
private:
@@ -152,7 +153,7 @@ private:
RequestHandler* _handler;
IceUtil::UniquePtr<Ice::LocalException> _exception;
InvocationObserver& _observer;
- ObserverHelperT<> _remoteObserver;
+ ObserverHelperT<Ice::Instrumentation::RemoteObserver> _remoteObserver;
enum
{
@@ -193,9 +194,9 @@ public:
BasicStream* os() { return &_os; }
- void attachRemoteObserver(const Ice::ConnectionInfoPtr& connection, const Ice::EndpointPtr& endpt)
+ void attachRemoteObserver(const Ice::ConnectionInfoPtr& connection, const Ice::EndpointPtr& endpt, Ice::Int sz)
{
- _remoteObserver.attach(_observer.getRemoteObserver(connection, endpt));
+ _remoteObserver.attach(_observer.getRemoteObserver(connection, endpt, 0, sz));
}
private:
@@ -209,7 +210,7 @@ private:
BasicStream _os;
InvocationObserver& _observer;
- ObserverHelperT<> _remoteObserver;
+ ObserverHelperT<Ice::Instrumentation::RemoteObserver> _remoteObserver;
};
}
diff --git a/cpp/include/Ice/OutgoingAsync.h b/cpp/include/Ice/OutgoingAsync.h
index f142c51df71..5a282be0b12 100644
--- a/cpp/include/Ice/OutgoingAsync.h
+++ b/cpp/include/Ice/OutgoingAsync.h
@@ -121,9 +121,10 @@ public:
virtual void __exception(const Exception&); // Required to be public for AsynchronousException
void __sent(); // Required to be public for AsynchronousSent
- virtual void __attachRemoteObserver(const Ice::ConnectionInfoPtr& connection, const Ice::EndpointPtr& endpt)
+ virtual void __attachRemoteObserver(const Ice::ConnectionInfoPtr& c, const Ice::EndpointPtr& endpt,
+ Ice::Int requestId, Ice::Int sz)
{
- _remoteObserver.attach(_observer.getRemoteObserver(connection, endpt));
+ _remoteObserver.attach(_observer.getRemoteObserver(c, endpt, requestId, sz));
}
IceInternal::InvocationObserver& __getObserver()
@@ -165,7 +166,7 @@ protected:
bool _sentSynchronously;
IceUtil::UniquePtr<Exception> _exception;
IceInternal::InvocationObserver _observer;
- IceInternal::ObserverHelperT<> _remoteObserver;
+ IceInternal::ObserverHelperT<Ice::Instrumentation::RemoteObserver> _remoteObserver;
};
}
diff --git a/cpp/src/Ice/ConnectionI.cpp b/cpp/src/Ice/ConnectionI.cpp
index 8a548df8a1d..d2ef8eadba9 100644
--- a/cpp/src/Ice/ConnectionI.cpp
+++ b/cpp/src/Ice/ConnectionI.cpp
@@ -559,8 +559,6 @@ Ice::ConnectionI::sendRequest(Outgoing* out, bool compress, bool response)
assert(_state > StateNotValidated);
assert(_state < StateClosing);
- out->attachRemoteObserver(initConnectionInfo(), _endpoint);
-
//
// Ensure the message isn't bigger than what we can send with the
// transport.
@@ -591,6 +589,8 @@ Ice::ConnectionI::sendRequest(Outgoing* out, bool compress, bool response)
#endif
}
+ out->attachRemoteObserver(initConnectionInfo(), _endpoint, requestId, os->b.size() - headerSize - 4);
+
//
// Send the message. If it can't be sent without blocking the message is added
// to _sendStreams and it will be sent by the selector thread.
@@ -638,8 +638,6 @@ Ice::ConnectionI::sendAsyncRequest(const OutgoingAsyncPtr& out, bool compress, b
assert(_state > StateNotValidated);
assert(_state < StateClosing);
- out->__attachRemoteObserver(initConnectionInfo(), _endpoint);
-
//
// Ensure the message isn't bigger than what we can send with the
// transport.
@@ -670,6 +668,8 @@ Ice::ConnectionI::sendAsyncRequest(const OutgoingAsyncPtr& out, bool compress, b
#endif
}
+ out->__attachRemoteObserver(initConnectionInfo(), _endpoint, requestId, os->b.size() - headerSize - 4);
+
AsyncStatus status = AsyncStatusQueued;
try
{
@@ -958,8 +958,6 @@ Ice::ConnectionI::flushBatchRequests(BatchOutgoing* out)
_exception->ice_throw();
}
- out->attachRemoteObserver(initConnectionInfo(), _endpoint);
-
if(_batchRequestNum == 0)
{
out->sent(false);
@@ -975,6 +973,9 @@ Ice::ConnectionI::flushBatchRequests(BatchOutgoing* out)
#else
copy(p, p + sizeof(Int), _batchStream.b.begin() + headerSize);
#endif
+
+ out->attachRemoteObserver(initConnectionInfo(), _endpoint, _batchStream.b.size() - headerSize - 4);
+
_batchStream.swap(*out->os());
//
@@ -1018,8 +1019,6 @@ Ice::ConnectionI::flushAsyncBatchRequests(const BatchOutgoingAsyncPtr& outAsync)
_exception->ice_throw();
}
- outAsync->__attachRemoteObserver(initConnectionInfo(), _endpoint);
-
if(_batchRequestNum == 0)
{
AsyncStatus status = AsyncStatusSent;
@@ -1039,6 +1038,9 @@ Ice::ConnectionI::flushAsyncBatchRequests(const BatchOutgoingAsyncPtr& outAsync)
#else
copy(p, p + sizeof(Int), _batchStream.b.begin() + headerSize);
#endif
+
+ outAsync->__attachRemoteObserver(initConnectionInfo(), _endpoint, 0, _batchStream.b.size() - headerSize - 4);
+
_batchStream.swap(*outAsync->__getOs());
//
diff --git a/cpp/src/Ice/Incoming.cpp b/cpp/src/Ice/Incoming.cpp
index 04dc96a838b..699ece0d3d5 100644
--- a/cpp/src/Ice/Incoming.cpp
+++ b/cpp/src/Ice/Incoming.cpp
@@ -230,6 +230,7 @@ IceInternal::IncomingBase::__servantLocatorFinished()
_os.startWriteEncaps(_current.encoding, DefaultFormat);
_os.write(ex);
_os.endWriteEncaps();
+ _observer.reply(_os.b.size() - headerSize - 4);
_connection->sendResponse(&_os, _compress);
}
else
@@ -322,6 +323,7 @@ IceInternal::IncomingBase::__handleException(const std::exception& exc)
_os.write(rfe->operation, false);
+ _observer.reply(_os.b.size() - headerSize - 4);
_connection->sendResponse(&_os, _compress);
}
else
@@ -389,6 +391,7 @@ IceInternal::IncomingBase::__handleException(const std::exception& exc)
_os.write(str.str(), false);
}
+ _observer.reply(_os.b.size() - headerSize - 4);
_connection->sendResponse(&_os, _compress);
}
else
@@ -415,6 +418,8 @@ IceInternal::IncomingBase::__handleException(const std::exception& exc)
ostringstream str;
str << "std::exception: " << exc.what();
_os.write(str.str(), false);
+
+ _observer.reply(_os.b.size() - headerSize - 4);
_connection->sendResponse(&_os, _compress);
}
else
@@ -448,6 +453,7 @@ IceInternal::IncomingBase::__handleException()
_os.write(replyUnknownException);
string reason = "unknown c++ exception";
_os.write(reason, false);
+ _observer.reply(_os.b.size() - headerSize - 4);
_connection->sendResponse(&_os, _compress);
}
else
@@ -542,6 +548,8 @@ IceInternal::Incoming::invoke(const ServantManagerPtr& servantManager, BasicStre
{
_is = stream;
+ BasicStream::Container::iterator start = _is->i;
+
//
// Read the current.
//
@@ -582,8 +590,13 @@ IceInternal::Incoming::invoke(const ServantManagerPtr& servantManager, BasicStre
const CommunicatorObserverPtr& obsv = _is->instance()->initializationData().observer;
if(obsv)
- {
- _observer.attach(obsv->getDispatchObserver(_current));
+ {
+ // Read the parameter encapsulation size.
+ Ice::Int sz;
+ _is->read(sz);
+ _is->i -= 4;
+
+ _observer.attach(obsv->getDispatchObserver(_current, _is->i - start + sz));
}
//
@@ -621,6 +634,7 @@ IceInternal::Incoming::invoke(const ServantManagerPtr& servantManager, BasicStre
_os.startWriteEncaps(encoding, DefaultFormat);
_os.write(ex);
_os.endWriteEncaps();
+ _observer.reply(_os.b.size() - headerSize - 4);
_connection->sendResponse(&_os, _compress);
}
else
@@ -711,6 +725,7 @@ IceInternal::Incoming::invoke(const ServantManagerPtr& servantManager, BasicStre
if(_response)
{
+ _observer.reply(_os.b.size() - headerSize - 4);
_connection->sendResponse(&_os, _compress);
}
else
diff --git a/cpp/src/Ice/IncomingAsync.cpp b/cpp/src/Ice/IncomingAsync.cpp
index e9f8c628e00..30fd7de967d 100644
--- a/cpp/src/Ice/IncomingAsync.cpp
+++ b/cpp/src/Ice/IncomingAsync.cpp
@@ -200,6 +200,7 @@ IceInternal::IncomingAsync::__response()
if(_response)
{
+ _observer.reply(_os.b.size() - headerSize - 4);
_connection->sendResponse(&_os, _compress);
}
else
diff --git a/cpp/src/Ice/InstrumentationI.cpp b/cpp/src/Ice/InstrumentationI.cpp
index 319d0a2842e..437e23ade9c 100644
--- a/cpp/src/Ice/InstrumentationI.cpp
+++ b/cpp/src/Ice/InstrumentationI.cpp
@@ -209,13 +209,14 @@ public:
add("identity", &DispatchHelper::getIdentity);
add("facet", &DispatchHelper::getCurrent, &Current::facet);
add("mode", &DispatchHelper::getMode);
+ add("requestId", &DispatchHelper::getCurrent, &Current::requestId);
setDefault(&DispatchHelper::resolve);
}
};
static Attributes attributes;
- DispatchHelper(const Current& current) : _current(current)
+ DispatchHelper(const Current& current, int size) : _current(current), _size(size)
{
}
@@ -224,6 +225,11 @@ public:
return attributes(this, attribute);
}
+ virtual void initMetrics(const DispatchMetricsPtr& v) const
+ {
+ v->size += _size;
+ }
+
string resolve(const string& attribute) const
{
if(attribute.compare(0, 8, "context.") == 0)
@@ -308,6 +314,7 @@ public:
private:
const Current& _current;
+ const int _size;
mutable string _id;
mutable EndpointInfoPtr _endpointInfo;
};
@@ -466,7 +473,7 @@ private:
InvocationHelper::Attributes InvocationHelper::attributes;
-class RemoteInvocationHelper : public MetricsHelperT<Metrics>
+class RemoteInvocationHelper : public MetricsHelperT<RemoteMetrics>
{
public:
@@ -478,13 +485,14 @@ public:
{
add("parent", &RemoteInvocationHelper::getParent);
add("id", &RemoteInvocationHelper::getId);
+ add("requestId", &RemoteInvocationHelper::_requestId);
addConnectionAttributes<RemoteInvocationHelper>(*this);
}
};
static Attributes attributes;
- RemoteInvocationHelper(const ConnectionInfoPtr& con, const EndpointPtr& endpt) :
- _connectionInfo(con), _endpoint(endpt)
+ RemoteInvocationHelper(const ConnectionInfoPtr& con, const EndpointPtr& endpt, int requestId, int size) :
+ _connectionInfo(con), _endpoint(endpt), _requestId(requestId), _size(size)
{
}
@@ -493,6 +501,11 @@ public:
return attributes(this, attribute);
}
+ virtual void initMetrics(const RemoteMetricsPtr& v) const
+ {
+ v->size += _size;
+ }
+
const string&
getId() const
{
@@ -546,6 +559,8 @@ private:
const ConnectionInfoPtr& _connectionInfo;
const EndpointPtr& _endpoint;
+ const int _requestId;
+ const int _size;
mutable string _id;
mutable EndpointInfoPtr _endpointInfo;
};
@@ -692,6 +707,18 @@ DispatchObserverI::userException()
}
void
+DispatchObserverI::reply(Int size)
+{
+ forEach(add(&DispatchMetrics::replySize, size));
+}
+
+void
+RemoteObserverI::reply(Int size)
+{
+ forEach(add(&RemoteMetrics::replySize, size));
+}
+
+void
InvocationObserverI::retried()
{
forEach(inc(&InvocationMetrics::retry));
@@ -703,12 +730,15 @@ InvocationObserverI::userException()
forEach(inc(&InvocationMetrics::userException));
}
-ObserverPtr
-InvocationObserverI::getRemoteObserver(const ConnectionInfoPtr& connection, const EndpointPtr& endpoint)
+RemoteObserverPtr
+InvocationObserverI::getRemoteObserver(const ConnectionInfoPtr& connection,
+ const EndpointPtr& endpoint,
+ int requestId,
+ int size)
{
try
{
- return getObserver<ObserverI>("Remote", RemoteInvocationHelper(connection, endpoint));
+ return getObserver<RemoteObserverI>("Remote", RemoteInvocationHelper(connection, endpoint, requestId, size));
}
catch(const exception&)
{
@@ -725,7 +755,7 @@ CommunicatorObserverI::CommunicatorObserverI(const IceInternal::MetricsAdminIPtr
_connects(metrics, "ConnectionEstablishment"),
_endpointLookups(metrics, "EndpointLookup")
{
- _invocations.registerSubMap<Metrics>("Remote", &InvocationMetrics::remotes);
+ _invocations.registerSubMap<RemoteMetrics>("Remote", &InvocationMetrics::remotes);
}
void
@@ -832,13 +862,13 @@ CommunicatorObserverI::getInvocationObserver(const ObjectPrx& proxy, const strin
}
DispatchObserverPtr
-CommunicatorObserverI::getDispatchObserver(const Current& current)
+CommunicatorObserverI::getDispatchObserver(const Current& current, int size)
{
if(_dispatch.isEnabled())
{
try
{
- return _dispatch.getObserver(DispatchHelper(current));
+ return _dispatch.getObserver(DispatchHelper(current, size));
}
catch(const exception& ex)
{
diff --git a/cpp/src/Ice/InstrumentationI.h b/cpp/src/Ice/InstrumentationI.h
index 035aed387cc..7ddbbeedb72 100644
--- a/cpp/src/Ice/InstrumentationI.h
+++ b/cpp/src/Ice/InstrumentationI.h
@@ -72,6 +72,14 @@ class DispatchObserverI : public Ice::Instrumentation::DispatchObserver,
public:
virtual void userException();
+
+ virtual void reply(Ice::Int);
+};
+
+class RemoteObserverI : public Ice::Instrumentation::RemoteObserver,
+ public IceMX::ObserverT<IceMX::RemoteMetrics>
+{
+ virtual void reply(Ice::Int);
};
class InvocationObserverI : public Ice::Instrumentation::InvocationObserver,
@@ -83,7 +91,8 @@ public:
virtual void userException();
- virtual Ice::Instrumentation::ObserverPtr getRemoteObserver(const Ice::ConnectionInfoPtr&, const Ice::EndpointPtr&);
+ virtual Ice::Instrumentation::RemoteObserverPtr getRemoteObserver(const Ice::ConnectionInfoPtr&,
+ const Ice::EndpointPtr&, Ice::Int, Ice::Int);
};
class ICE_API CommunicatorObserverI : public Ice::Instrumentation::CommunicatorObserver
@@ -113,7 +122,7 @@ public:
const std::string&,
const Ice::Context&);
- virtual Ice::Instrumentation::DispatchObserverPtr getDispatchObserver(const Ice::Current&);
+ virtual Ice::Instrumentation::DispatchObserverPtr getDispatchObserver(const Ice::Current&, Ice::Int);
const IceInternal::MetricsAdminIPtr& getMetricsAdmin() const;
diff --git a/cpp/src/Ice/Outgoing.cpp b/cpp/src/Ice/Outgoing.cpp
index 85e15a53509..118dc25612c 100644
--- a/cpp/src/Ice/Outgoing.cpp
+++ b/cpp/src/Ice/Outgoing.cpp
@@ -379,9 +379,14 @@ IceInternal::Outgoing::finished(BasicStream& is)
assert(_handler->getReference()->getMode() == Reference::ModeTwoway); // Can only be called for twoways.
assert(_state <= StateInProgress);
+ if(_remoteObserver)
+ {
+ _remoteObserver->reply(is.b.size() - headerSize - 4);
+ }
_remoteObserver.detach();
_is.swap(is);
+
Byte replyStatus;
_is.read(replyStatus);
diff --git a/cpp/src/Ice/OutgoingAsync.cpp b/cpp/src/Ice/OutgoingAsync.cpp
index eee5b3215c2..890e33a4cb9 100644
--- a/cpp/src/Ice/OutgoingAsync.cpp
+++ b/cpp/src/Ice/OutgoingAsync.cpp
@@ -617,6 +617,10 @@ IceInternal::OutgoingAsync::__finished(BasicStream& is)
{
IceUtil::Monitor<IceUtil::Mutex>::Lock sync(_monitor);
assert(!_exception.get() && !(_state & Done));
+ if(_remoteObserver)
+ {
+ _remoteObserver->reply(is.b.size() - headerSize - 4);
+ }
_remoteObserver.detach();
if(_timerTaskConnection)
@@ -1054,9 +1058,10 @@ IceInternal::CommunicatorBatchOutgoingAsync::flushConnection(const ConnectionIPt
_outAsync->check(false);
}
- virtual void __attachRemoteObserver(const Ice::ConnectionInfoPtr& connection, const Ice::EndpointPtr& endpt)
+ virtual void __attachRemoteObserver(const Ice::ConnectionInfoPtr& connection, const Ice::EndpointPtr& endpt,
+ Ice::Int requestId, Ice::Int sz)
{
- _remoteObserver.attach(_observer.getRemoteObserver(connection, endpt));
+ _remoteObserver.attach(_observer.getRemoteObserver(connection, endpt, requestId, sz));
}
private:
diff --git a/cpp/test/Ice/metrics/AllTests.cpp b/cpp/test/Ice/metrics/AllTests.cpp
index 877c930a791..3eff9f63e28 100644
--- a/cpp/test/Ice/metrics/AllTests.cpp
+++ b/cpp/test/Ice/metrics/AllTests.cpp
@@ -789,21 +789,26 @@ allTests(const Ice::CommunicatorPtr& communicator)
IceMX::DispatchMetricsPtr dm1 = IceMX::DispatchMetricsPtr::dynamicCast(map["op"]);
test(dm1->current <= 1 && dm1->total == 1 && dm1->failures == 0 && dm1->userException == 0);
+ test(dm1->size == 21 && dm1->replySize == 7);
dm1 = IceMX::DispatchMetricsPtr::dynamicCast(map["opWithUserException"]);
test(dm1->current <= 1 && dm1->total == 1 && dm1->failures == 0 && dm1->userException == 1);
+ test(dm1->size == 38 && dm1->replySize == 23);
dm1 = IceMX::DispatchMetricsPtr::dynamicCast(map["opWithLocalException"]);
test(dm1->current <= 1 && dm1->total == 1 && dm1->failures == 1 && dm1->userException == 0);
checkFailure(serverMetrics, "Dispatch", dm1->id, "Ice::SyscallException", 1);
+ test(dm1->size == 39 && dm1->replySize > 7); // Reply contains the exception stack depending on the OS.
dm1 = IceMX::DispatchMetricsPtr::dynamicCast(map["opWithRequestFailedException"]);
test(dm1->current <= 1 && dm1->total == 1 && dm1->failures == 1 && dm1->userException == 0);
checkFailure(serverMetrics, "Dispatch", dm1->id, "Ice::ObjectNotExistException", 1);
+ test(dm1->size == 47 && dm1->replySize == 40);
dm1 = IceMX::DispatchMetricsPtr::dynamicCast(map["opWithUnknownException"]);
test(dm1->current <= 1 && dm1->total == 1 && dm1->failures == 1 && dm1->userException == 0);
checkFailure(serverMetrics, "Dispatch", dm1->id, "unknown", 1);
+ test(dm1->size == 41 && dm1->replySize == 23);
InvokeOp op(metrics);
@@ -962,28 +967,39 @@ allTests(const Ice::CommunicatorPtr& communicator)
test(map.size() == 6);
IceMX::InvocationMetricsPtr im1;
+ IceMX::RemoteMetricsPtr rim1;
im1 = IceMX::InvocationMetricsPtr::dynamicCast(map["op"]);
test(im1->current <= 1 && im1->total == 3 && im1->failures == 0 && im1->retry == 0 && im1->remotes.size() == 1);
- test(im1->remotes[0]->current == 0 && im1->remotes[0]->total == 3 && im1->remotes[0]->failures == 0);
+ rim1 = IceMX::RemoteMetricsPtr::dynamicCast(im1->remotes[0]);
+ test(rim1->current == 0 && rim1->total == 3 && rim1->failures == 0);
+ test(rim1->size == 63 && rim1->replySize == 21);
im1 = IceMX::InvocationMetricsPtr::dynamicCast(map["opWithUserException"]);
test(im1->current <= 1 && im1->total == 3 && im1->failures == 0 && im1->retry == 0 && im1->remotes.size() == 1);
- test(im1->remotes[0]->current == 0 && im1->remotes[0]->total == 3 && im1->remotes[0]->failures == 0);
+ rim1 = IceMX::RemoteMetricsPtr::dynamicCast(im1->remotes[0]);
+ test(rim1->current == 0 && rim1->total == 3 && rim1->failures == 0);
+ test(rim1->size == 114 && rim1->replySize == 69);
test(im1->userException == 3);
im1 = IceMX::InvocationMetricsPtr::dynamicCast(map["opWithLocalException"]);
test(im1->current <= 1 && im1->total == 3 && im1->failures == 3 && im1->retry == 0 && im1->remotes.size() == 1);
- test(im1->remotes[0]->current == 0 && im1->remotes[0]->total == 3 && im1->remotes[0]->failures == 0);
+ rim1 = IceMX::RemoteMetricsPtr::dynamicCast(im1->remotes[0]);
+ test(rim1->current == 0 && rim1->total == 3 && rim1->failures == 0);
+ test(rim1->size == 117 && rim1->replySize > 7);
checkFailure(clientMetrics, "Invocation", im1->id, "Ice::UnknownLocalException", 3);
im1 = IceMX::InvocationMetricsPtr::dynamicCast(map["opWithRequestFailedException"]);
test(im1->current <= 1 && im1->total == 3 && im1->failures == 3 && im1->retry == 0 && im1->remotes.size() == 1);
- test(im1->remotes[0]->current == 0 && im1->remotes[0]->total == 3 && im1->remotes[0]->failures == 0);
+ rim1 = IceMX::RemoteMetricsPtr::dynamicCast(im1->remotes[0]);
+ test(rim1->current == 0 && rim1->total == 3 && rim1->failures == 0);
+ test(rim1->size == 141 && rim1->replySize == 120);
checkFailure(clientMetrics, "Invocation", im1->id, "Ice::ObjectNotExistException", 3);
im1 = IceMX::InvocationMetricsPtr::dynamicCast(map["opWithUnknownException"]);
test(im1->current <= 1 && im1->total == 3 && im1->failures == 3 && im1->retry == 0 && im1->remotes.size() == 1);
- test(im1->remotes[0]->current == 0 && im1->remotes[0]->total == 3 && im1->remotes[0]->failures == 0);
+ rim1 = IceMX::RemoteMetricsPtr::dynamicCast(im1->remotes[0]);
+ test(rim1->current == 0 && rim1->total == 3 && rim1->failures == 0);
+ test(rim1->size == 123 && rim1->replySize == 69);
checkFailure(clientMetrics, "Invocation", im1->id, "Ice::UnknownException", 3);
im1 = IceMX::InvocationMetricsPtr::dynamicCast(map["fail"]);