summaryrefslogtreecommitdiff
path: root/cpp/src/Glacier2/Blobject.cpp
diff options
context:
space:
mode:
authorBenoit Foucher <benoit@zeroc.com>2012-10-12 11:34:53 +0200
committerBenoit Foucher <benoit@zeroc.com>2012-10-12 11:34:53 +0200
commit23c1e3b603a9d902593ffe9f99562fcda3af1589 (patch)
tree60ea7cdc0da5a9676ca12350ac82b069cc86eb5e /cpp/src/Glacier2/Blobject.cpp
parent.NET demo project updates (diff)
downloadice-23c1e3b603a9d902593ffe9f99562fcda3af1589.tar.bz2
ice-23c1e3b603a9d902593ffe9f99562fcda3af1589.tar.xz
ice-23c1e3b603a9d902593ffe9f99562fcda3af1589.zip
Added support for Glacier2 MX and fixed ICE-4880
Diffstat (limited to 'cpp/src/Glacier2/Blobject.cpp')
-rwxr-xr-xcpp/src/Glacier2/Blobject.cpp37
1 files changed, 22 insertions, 15 deletions
diff --git a/cpp/src/Glacier2/Blobject.cpp b/cpp/src/Glacier2/Blobject.cpp
index c64e3def10e..3c7098e3968 100755
--- a/cpp/src/Glacier2/Blobject.cpp
+++ b/cpp/src/Glacier2/Blobject.cpp
@@ -9,10 +9,12 @@
#include <Glacier2/Blobject.h>
#include <Glacier2/SessionRouterI.h>
+#include <Glacier2/Instrumentation.h>
using namespace std;
using namespace Ice;
using namespace Glacier2;
+using namespace Glacier2::Instrumentation;
namespace
{
@@ -68,27 +70,36 @@ Glacier2::Blobject::destroy()
}
void
+Glacier2::Blobject::updateObserver(const Glacier2::Instrumentation::SessionObserverPtr& observer)
+{
+ if(_requestQueue)
+ {
+ _requestQueue->updateObserver(observer);
+ }
+}
+
+void
Glacier2::Blobject::invokeResponse(bool ok, const pair<const Byte*, const Byte*>& outParams,
- const InvokeCookiePtr& cookie)
+ const AMD_Object_ice_invokePtr& amdCB)
{
- cookie->cb()->ice_response(ok, outParams);
+ amdCB->ice_response(ok, outParams);
}
void
-Glacier2::Blobject::invokeSent(bool sent, const InvokeCookiePtr& cookie)
+Glacier2::Blobject::invokeSent(bool sent, const AMD_Object_ice_invokePtr& amdCB)
{
if(sent)
{
#if (defined(_MSC_VER) && (_MSC_VER >= 1600))
- cookie->cb()->ice_response(true, pair<const Byte*, const Byte*>(nullptr, nullptr));
+ amdCB->ice_response(true, pair<const Byte*, const Byte*>(nullptr, nullptr));
#else
- cookie->cb()->ice_response(true, pair<const Byte*, const Byte*>(0, 0));
+ amdCB->ice_response(true, pair<const Byte*, const Byte*>(0, 0));
#endif
}
}
void
-Glacier2::Blobject::invokeException(const Exception& ex, const InvokeCookiePtr& cookie)
+Glacier2::Blobject::invokeException(const Exception& ex, const AMD_Object_ice_invokePtr& amdCB)
{
//
// If the connection has been lost, destroy the session.
@@ -108,7 +119,7 @@ Glacier2::Blobject::invokeException(const Exception& ex, const InvokeCookiePtr&
}
}
}
- cookie->cb()->ice_exception(ex);
+ amdCB->ice_exception(ex);
}
void
@@ -346,26 +357,22 @@ Glacier2::Blobject::invoke(ObjectPrx& proxy, const AMD_Object_ice_invokePtr& amd
{
Context ctx = current.ctx;
ctx.insert(_context.begin(), _context.end());
- proxy->begin_ice_invoke(current.operation, current.mode, inParams, ctx, amiCB,
- new InvokeCookie(amdCB));
+ proxy->begin_ice_invoke(current.operation, current.mode, inParams, ctx, amiCB, amdCB);
}
else
{
- proxy->begin_ice_invoke(current.operation, current.mode, inParams, current.ctx, amiCB,
- new InvokeCookie(amdCB));
+ proxy->begin_ice_invoke(current.operation, current.mode, inParams, current.ctx, amiCB, amdCB);
}
}
else
{
if(_context.size() > 0)
{
- proxy->begin_ice_invoke(current.operation, current.mode, inParams, _context, amiCB,
- new InvokeCookie(amdCB));
+ proxy->begin_ice_invoke(current.operation, current.mode, inParams, _context, amiCB, amdCB);
}
else
{
- proxy->begin_ice_invoke(current.operation, current.mode, inParams, amiCB,
- new InvokeCookie(amdCB));
+ proxy->begin_ice_invoke(current.operation, current.mode, inParams, amiCB, amdCB);
}
}
}