From 5560ebe54df426008552ab385f28d093d24359d1 Mon Sep 17 00:00:00 2001 From: Michael Gmelin Date: Sun, 10 Jul 2016 12:47:32 +0000 Subject: Fix icegridadmin's handling of properties on shared communicators See also: https://forums.zeroc.com/discussion/46405/how-to-access-service-properties-using-icegridadmin-on-the-command-line-on-a-shared-communicator Approved by: mentors (implicit) --- devel/ice/Makefile | 1 + devel/ice/files/patch-cpp-src-IceGrid-Parser.cpp | 27 ++++++++++++++++++++++++ 2 files changed, 28 insertions(+) create mode 100644 devel/ice/files/patch-cpp-src-IceGrid-Parser.cpp (limited to 'devel') diff --git a/devel/ice/Makefile b/devel/ice/Makefile index 15bf3223e63b..cf2767522399 100644 --- a/devel/ice/Makefile +++ b/devel/ice/Makefile @@ -3,6 +3,7 @@ PORTNAME= Ice PORTVERSION= 3.6.2 +PORTREVISION= 1 DISTVERSIONPREFIX= v CATEGORIES= devel diff --git a/devel/ice/files/patch-cpp-src-IceGrid-Parser.cpp b/devel/ice/files/patch-cpp-src-IceGrid-Parser.cpp new file mode 100644 index 000000000000..39d41e788afe --- /dev/null +++ b/devel/ice/files/patch-cpp-src-IceGrid-Parser.cpp @@ -0,0 +1,27 @@ +--- cpp/src/IceGrid/Parser.cpp.orig 2016-05-16 22:49:28.132976967 +0200 ++++ cpp/src/IceGrid/Parser.cpp 2016-05-16 23:15:17.589867966 +0200 +@@ -1912,10 +1912,24 @@ + return; + } + ++ + Ice::ObjectPrx admin = _admin->getServerAdmin(server); + Ice::PropertiesAdminPrx propAdmin = + Ice::PropertiesAdminPrx::uncheckedCast(admin, "IceBox.Service." + service + ".Properties"); + ++ try ++ { ++ propAdmin->ice_ping(); ++ } ++ catch(const Ice::ObjectNotExistException&) ++ { ++ Ice::PropertiesAdminPrx serverPropAdmin = Ice::PropertiesAdminPrx::uncheckedCast(admin, "Properties"); ++ if (atoi(serverPropAdmin->getProperty("IceBox.UseSharedCommunicator." + service).c_str())) ++ { ++ propAdmin = Ice::PropertiesAdminPrx::uncheckedCast(admin, "IceBox.SharedCommunicator.Properties"); ++ } ++ } ++ + if(single) + { + string val = propAdmin->getProperty(property); -- cgit v1.2.3