summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBenoit Foucher <benoit@zeroc.com>2017-04-27 13:05:25 +0200
committerBenoit Foucher <benoit@zeroc.com>2017-04-27 13:05:25 +0200
commitc5ee6fd5310199110dae6b2d01decbd20174d8db (patch)
treedaf558482821eb3a1ffd496b06ba8bcc2edce841
parentExtra whitespace (diff)
downloadice-c5ee6fd5310199110dae6b2d01decbd20174d8db.tar.bz2
ice-c5ee6fd5310199110dae6b2d01decbd20174d8db.tar.xz
ice-c5ee6fd5310199110dae6b2d01decbd20174d8db.zip
Fixed ICE-6680 - WS transports are now provided by a separate IceWS plugin
-rw-r--r--CHANGELOG-3.7.md16
-rw-r--r--cpp/include/Ice/RegisterPlugins.h2
-rw-r--r--cpp/src/Ice/EndpointFactory.cpp151
-rw-r--r--cpp/src/Ice/EndpointFactory.h67
-rw-r--r--cpp/src/Ice/EndpointFactoryManager.cpp17
-rw-r--r--cpp/src/Ice/EndpointFactoryManager.h1
-rw-r--r--cpp/src/Ice/Instance.cpp16
-rwxr-xr-xcpp/src/Ice/Network.cpp6
-rw-r--r--cpp/src/Ice/ProtocolInstance.cpp7
-rw-r--r--cpp/src/Ice/ProtocolInstance.h2
-rw-r--r--cpp/src/Ice/RegisterPluginsInit.cpp10
-rw-r--r--cpp/src/Ice/TcpEndpointI.cpp2
-rw-r--r--cpp/src/Ice/TcpEndpointI.h2
-rw-r--r--cpp/src/Ice/UdpEndpointI.cpp22
-rw-r--r--cpp/src/Ice/UdpEndpointI.h2
-rw-r--r--cpp/src/Ice/WSEndpoint.cpp130
-rw-r--r--cpp/src/Ice/WSEndpoint.h19
-rw-r--r--cpp/src/Ice/ios/StreamEndpointI.cpp2
-rw-r--r--cpp/src/Ice/ios/StreamEndpointI.h3
-rw-r--r--cpp/src/IceBT/EndpointI.cpp3
-rw-r--r--cpp/src/IceBT/EndpointI.h3
-rw-r--r--cpp/src/IceBT/PluginI.cpp15
-rw-r--r--cpp/src/IceDiscovery/PluginI.cpp7
-rw-r--r--cpp/src/IceIAP/EndpointI.h3
-rw-r--r--cpp/src/IceIAP/EndpointI.mm16
-rw-r--r--cpp/src/IceLocatorDiscovery/PluginI.cpp7
-rw-r--r--cpp/src/IceSSL/EndpointI.cpp43
-rw-r--r--cpp/src/IceSSL/EndpointI.h24
-rwxr-xr-xcpp/src/IceSSL/PluginI.cpp27
-rw-r--r--cpp/test/Ice/acm/Client.cpp1
-rw-r--r--cpp/test/Ice/acm/Server.cpp1
-rw-r--r--cpp/test/Ice/adapterDeactivation/Client.cpp1
-rw-r--r--cpp/test/Ice/adapterDeactivation/Collocated.cpp1
-rw-r--r--cpp/test/Ice/adapterDeactivation/Server.cpp2
-rw-r--r--cpp/test/Ice/admin/Client.cpp1
-rw-r--r--cpp/test/Ice/admin/Server.cpp1
-rw-r--r--cpp/test/Ice/ami/Client.cpp1
-rw-r--r--cpp/test/Ice/ami/Collocated.cpp1
-rw-r--r--cpp/test/Ice/ami/Server.cpp1
-rw-r--r--cpp/test/Ice/background/Client.cpp1
-rw-r--r--cpp/test/Ice/background/EndpointFactory.cpp2
-rw-r--r--cpp/test/Ice/background/EndpointFactory.h3
-rw-r--r--cpp/test/Ice/background/PluginI.cpp8
-rw-r--r--cpp/test/Ice/background/Server.cpp1
-rw-r--r--cpp/test/Ice/binding/Client.cpp2
-rw-r--r--cpp/test/Ice/binding/Server.cpp2
-rw-r--r--cpp/test/Ice/checksum/Client.cpp1
-rw-r--r--cpp/test/Ice/checksum/Server.cpp1
-rw-r--r--cpp/test/Ice/custom/Client.cpp1
-rw-r--r--cpp/test/Ice/custom/Collocated.cpp1
-rw-r--r--cpp/test/Ice/custom/Server.cpp1
-rw-r--r--cpp/test/Ice/custom/ServerAMD.cpp1
-rw-r--r--cpp/test/Ice/defaultServant/Client.cpp1
-rw-r--r--cpp/test/Ice/dispatcher/Client.cpp1
-rw-r--r--cpp/test/Ice/dispatcher/Collocated.cpp1
-rw-r--r--cpp/test/Ice/dispatcher/Server.cpp1
-rw-r--r--cpp/test/Ice/enums/Client.cpp1
-rw-r--r--cpp/test/Ice/enums/Server.cpp1
-rw-r--r--cpp/test/Ice/exceptions/Client.cpp1
-rw-r--r--cpp/test/Ice/exceptions/Collocated.cpp1
-rw-r--r--cpp/test/Ice/exceptions/Server.cpp2
-rw-r--r--cpp/test/Ice/exceptions/ServerAMD.cpp2
-rw-r--r--cpp/test/Ice/facets/Client.cpp1
-rw-r--r--cpp/test/Ice/facets/Collocated.cpp1
-rw-r--r--cpp/test/Ice/facets/Server.cpp1
-rw-r--r--cpp/test/Ice/faultTolerance/Client.cpp1
-rw-r--r--cpp/test/Ice/faultTolerance/Server.cpp2
-rw-r--r--cpp/test/Ice/gc/Client.cpp1
-rw-r--r--cpp/test/Ice/hash/Client.cpp1
-rw-r--r--cpp/test/Ice/hold/Client.cpp1
-rw-r--r--cpp/test/Ice/hold/Server.cpp2
-rw-r--r--cpp/test/Ice/impl/Server.cpp2
-rw-r--r--cpp/test/Ice/impl/ServerAMD.cpp2
-rw-r--r--cpp/test/Ice/info/Client.cpp2
-rw-r--r--cpp/test/Ice/info/Server.cpp2
-rw-r--r--cpp/test/Ice/inheritance/Client.cpp1
-rw-r--r--cpp/test/Ice/inheritance/Collocated.cpp1
-rw-r--r--cpp/test/Ice/inheritance/Server.cpp1
-rw-r--r--cpp/test/Ice/interceptor/Client.cpp1
-rw-r--r--cpp/test/Ice/invoke/Client.cpp1
-rw-r--r--cpp/test/Ice/invoke/Server.cpp2
-rw-r--r--cpp/test/Ice/location/Client.cpp1
-rw-r--r--cpp/test/Ice/location/Server.cpp2
-rw-r--r--cpp/test/Ice/logger/Client1.cpp1
-rw-r--r--cpp/test/Ice/logger/Client2.cpp1
-rw-r--r--cpp/test/Ice/logger/Client3.cpp1
-rw-r--r--cpp/test/Ice/logger/Client4.cpp1
-rw-r--r--cpp/test/Ice/logger/Client5.cpp1
-rw-r--r--cpp/test/Ice/metrics/Client.cpp1
-rw-r--r--cpp/test/Ice/metrics/Collocated.cpp1
-rw-r--r--cpp/test/Ice/metrics/Server.cpp1
-rw-r--r--cpp/test/Ice/metrics/ServerAMD.cpp1
-rw-r--r--cpp/test/Ice/networkProxy/Client.cpp1
-rw-r--r--cpp/test/Ice/networkProxy/Server.cpp2
-rw-r--r--cpp/test/Ice/objects/Client.cpp1
-rw-r--r--cpp/test/Ice/objects/Collocated.cpp1
-rw-r--r--cpp/test/Ice/objects/Server.cpp1
-rw-r--r--cpp/test/Ice/operations/Client.cpp1
-rw-r--r--cpp/test/Ice/operations/Collocated.cpp1
-rw-r--r--cpp/test/Ice/operations/Server.cpp2
-rw-r--r--cpp/test/Ice/operations/ServerAMD.cpp2
-rw-r--r--cpp/test/Ice/optional/Client.cpp1
-rw-r--r--cpp/test/Ice/optional/Server.cpp1
-rw-r--r--cpp/test/Ice/optional/ServerAMD.cpp1
-rw-r--r--cpp/test/Ice/properties/Client.cpp1
-rw-r--r--cpp/test/Ice/proxy/Client.cpp1
-rw-r--r--cpp/test/Ice/proxy/Collocated.cpp1
-rw-r--r--cpp/test/Ice/proxy/Server.cpp1
-rw-r--r--cpp/test/Ice/proxy/ServerAMD.cpp1
-rw-r--r--cpp/test/Ice/retry/Client.cpp1
-rw-r--r--cpp/test/Ice/retry/Collocated.cpp1
-rw-r--r--cpp/test/Ice/retry/Server.cpp2
-rw-r--r--cpp/test/Ice/servantLocator/Client.cpp1
-rw-r--r--cpp/test/Ice/servantLocator/Collocated.cpp1
-rw-r--r--cpp/test/Ice/servantLocator/Server.cpp2
-rw-r--r--cpp/test/Ice/servantLocator/ServerAMD.cpp2
-rw-r--r--cpp/test/Ice/services/Client.cpp1
-rw-r--r--cpp/test/Ice/slicing/exceptions/Client.cpp1
-rw-r--r--cpp/test/Ice/slicing/exceptions/Server.cpp1
-rw-r--r--cpp/test/Ice/slicing/exceptions/ServerAMD.cpp1
-rw-r--r--cpp/test/Ice/slicing/objects/Client.cpp1
-rw-r--r--cpp/test/Ice/slicing/objects/Server.cpp1
-rw-r--r--cpp/test/Ice/slicing/objects/ServerAMD.cpp1
-rw-r--r--cpp/test/Ice/stream/Client.cpp1
-rw-r--r--cpp/test/Ice/stringConverter/Client.cpp1
-rw-r--r--cpp/test/Ice/stringConverter/Server.cpp2
-rw-r--r--cpp/test/Ice/threadPoolPriority/Client.cpp1
-rw-r--r--cpp/test/Ice/threadPoolPriority/Server.cpp1
-rw-r--r--cpp/test/Ice/threadPoolPriority/ServerCustomThreadPool.cpp1
-rw-r--r--cpp/test/Ice/timeout/Client.cpp1
-rw-r--r--cpp/test/Ice/timeout/Server.cpp2
-rw-r--r--cpp/test/Ice/udp/Client.cpp2
-rw-r--r--cpp/test/Ice/udp/Server.cpp2
-rw-r--r--cpp/test/IceDiscovery/simple/Client.cpp1
-rw-r--r--cpp/test/IceDiscovery/simple/Server.cpp1
-rw-r--r--cpp/test/IceGrid/simple/Client.cpp1
-rw-r--r--cpp/test/IceGrid/simple/Server.cpp1
-rw-r--r--cpp/test/IceSSL/configuration/Client.cpp4
-rw-r--r--cpp/test/IceSSL/configuration/Server.cpp1
-rw-r--r--csharp/src/Ice/EndpointFactory.cs77
-rw-r--r--csharp/src/Ice/EndpointFactoryManager.cs25
-rw-r--r--csharp/src/Ice/Instance.cs23
-rw-r--r--csharp/src/Ice/ProtocolInstance.cs5
-rw-r--r--csharp/src/Ice/TcpEndpointI.cs6
-rw-r--r--csharp/src/Ice/UdpEndpointI.cs6
-rw-r--r--csharp/src/Ice/WSEndpoint.cs37
-rw-r--r--csharp/src/IceSSL/EndpointI.cs39
-rw-r--r--csharp/src/IceSSL/PluginI.cs8
-rw-r--r--csharp/test/Ice/background/EndpointFactory.cs6
-rw-r--r--java-compat/src/Ice/src/main/java/IceInternal/EndpointFactory.java3
-rw-r--r--java-compat/src/Ice/src/main/java/IceInternal/EndpointFactoryManager.java28
-rw-r--r--java-compat/src/Ice/src/main/java/IceInternal/EndpointFactoryWithUnderlying.java92
-rw-r--r--java-compat/src/Ice/src/main/java/IceInternal/Instance.java22
-rw-r--r--java-compat/src/Ice/src/main/java/IceInternal/ProtocolInstance.java5
-rw-r--r--java-compat/src/Ice/src/main/java/IceInternal/TcpEndpointFactory.java8
-rw-r--r--java-compat/src/Ice/src/main/java/IceInternal/UdpEndpointFactory.java8
-rw-r--r--java-compat/src/Ice/src/main/java/IceInternal/UnderlyingEndpointFactory.java90
-rw-r--r--java-compat/src/Ice/src/main/java/IceInternal/WSEndpointFactory.java41
-rw-r--r--java-compat/src/Ice/src/main/java/IceSSL/EndpointFactoryI.java42
-rw-r--r--java-compat/src/Ice/src/main/java/IceSSL/PluginI.java18
-rw-r--r--java-compat/src/IceBT/src/main/java/IceBT/EndpointFactoryI.java8
-rw-r--r--java-compat/src/IceBT/src/main/java/IceBT/PluginI.java16
-rw-r--r--java-compat/test/src/main/java/test/Ice/background/EndpointFactory.java8
-rw-r--r--java/src/Ice/src/main/java/com/zeroc/IceInternal/EndpointFactory.java7
-rw-r--r--java/src/Ice/src/main/java/com/zeroc/IceInternal/EndpointFactoryManager.java28
-rw-r--r--java/src/Ice/src/main/java/com/zeroc/IceInternal/EndpointFactoryWithUnderlying.java92
-rw-r--r--java/src/Ice/src/main/java/com/zeroc/IceInternal/Instance.java34
-rw-r--r--java/src/Ice/src/main/java/com/zeroc/IceInternal/ProtocolInstance.java5
-rw-r--r--java/src/Ice/src/main/java/com/zeroc/IceInternal/TcpEndpointFactory.java2
-rw-r--r--java/src/Ice/src/main/java/com/zeroc/IceInternal/UdpEndpointFactory.java2
-rw-r--r--java/src/Ice/src/main/java/com/zeroc/IceInternal/UnderlyingEndpointFactory.java90
-rw-r--r--java/src/Ice/src/main/java/com/zeroc/IceInternal/WSEndpointFactory.java41
-rw-r--r--java/src/IceBT/src/main/java/com/zeroc/IceBT/EndpointFactoryI.java4
-rw-r--r--java/src/IceBT/src/main/java/com/zeroc/IceBT/PluginI.java23
-rw-r--r--java/src/IceSSL/src/main/java/com/zeroc/IceSSL/EndpointFactoryI.java45
-rw-r--r--java/src/IceSSL/src/main/java/com/zeroc/IceSSL/PluginI.java23
-rw-r--r--java/test/src/main/java/test/Ice/background/EndpointFactory.java3
-rw-r--r--js/src/Ice/EndpointFactoryManager.js28
-rw-r--r--objective-c/include/objc/Ice/Initialize.h2
-rw-r--r--objective-c/test/Ice/acm/Client.m1
-rw-r--r--objective-c/test/Ice/acm/Server.m1
-rw-r--r--objective-c/test/Ice/adapterDeactivation/Client.m1
-rw-r--r--objective-c/test/Ice/adapterDeactivation/Collocated.m1
-rw-r--r--objective-c/test/Ice/adapterDeactivation/Server.m2
-rw-r--r--objective-c/test/Ice/admin/Client.m1
-rw-r--r--objective-c/test/Ice/admin/Server.m1
-rw-r--r--objective-c/test/Ice/ami/Client.m1
-rw-r--r--objective-c/test/Ice/ami/Collocated.m2
-rw-r--r--objective-c/test/Ice/ami/Server.m2
-rw-r--r--objective-c/test/Ice/binding/Client.m1
-rw-r--r--objective-c/test/Ice/binding/Server.m2
-rw-r--r--objective-c/test/Ice/defaultServant/Client.m1
-rw-r--r--objective-c/test/Ice/defaultValue/Client.m1
-rw-r--r--objective-c/test/Ice/dispatcher/Client.m1
-rw-r--r--objective-c/test/Ice/dispatcher/Collocated.m1
-rw-r--r--objective-c/test/Ice/dispatcher/Server.m2
-rw-r--r--objective-c/test/Ice/enums/Client.m1
-rw-r--r--objective-c/test/Ice/enums/Server.m2
-rw-r--r--objective-c/test/Ice/exceptions/Client.m1
-rw-r--r--objective-c/test/Ice/exceptions/Collocated.m1
-rw-r--r--objective-c/test/Ice/exceptions/Server.m2
-rw-r--r--objective-c/test/Ice/facets/Client.m1
-rw-r--r--objective-c/test/Ice/facets/Collocated.m1
-rw-r--r--objective-c/test/Ice/facets/Server.m1
-rw-r--r--objective-c/test/Ice/faultTolerance/Client.m1
-rw-r--r--objective-c/test/Ice/faultTolerance/Server.m2
-rw-r--r--objective-c/test/Ice/hash/Client.m2
-rw-r--r--objective-c/test/Ice/hold/Client.m1
-rw-r--r--objective-c/test/Ice/hold/Server.m2
-rw-r--r--objective-c/test/Ice/info/Client.m2
-rw-r--r--objective-c/test/Ice/info/Server.m2
-rw-r--r--objective-c/test/Ice/inheritance/Client.m1
-rw-r--r--objective-c/test/Ice/inheritance/Collocated.m1
-rw-r--r--objective-c/test/Ice/inheritance/Server.m1
-rw-r--r--objective-c/test/Ice/interceptor/Client.m1
-rw-r--r--objective-c/test/Ice/invoke/Client.m1
-rw-r--r--objective-c/test/Ice/invoke/Server.m2
-rw-r--r--objective-c/test/Ice/location/Client.m1
-rw-r--r--objective-c/test/Ice/location/Server.m2
-rw-r--r--objective-c/test/Ice/metrics/Client.m1
-rw-r--r--objective-c/test/Ice/metrics/Server.m1
-rw-r--r--objective-c/test/Ice/objects/Client.m1
-rw-r--r--objective-c/test/Ice/objects/Collocated.m1
-rw-r--r--objective-c/test/Ice/objects/Server.m1
-rw-r--r--objective-c/test/Ice/operations/Client.m1
-rw-r--r--objective-c/test/Ice/operations/Collocated.m1
-rw-r--r--objective-c/test/Ice/operations/Server.m2
-rw-r--r--objective-c/test/Ice/optional/Client.m1
-rw-r--r--objective-c/test/Ice/optional/Server.m1
-rw-r--r--objective-c/test/Ice/proxy/Client.m1
-rw-r--r--objective-c/test/Ice/proxy/Collocated.m1
-rw-r--r--objective-c/test/Ice/proxy/Server.m2
-rw-r--r--objective-c/test/Ice/retry/Client.m1
-rw-r--r--objective-c/test/Ice/retry/Collocated.m1
-rw-r--r--objective-c/test/Ice/retry/Server.m2
-rw-r--r--objective-c/test/Ice/servantLocator/Client.m1
-rw-r--r--objective-c/test/Ice/servantLocator/Collocated.m1
-rw-r--r--objective-c/test/Ice/servantLocator/Server.m2
-rw-r--r--objective-c/test/Ice/services/Client.m1
-rw-r--r--objective-c/test/Ice/slicing/exceptions/Client.m1
-rw-r--r--objective-c/test/Ice/slicing/exceptions/Server.m1
-rw-r--r--objective-c/test/Ice/slicing/objects/Client.m1
-rw-r--r--objective-c/test/Ice/slicing/objects/Server.m1
-rw-r--r--objective-c/test/Ice/stream/Client.m1
-rw-r--r--objective-c/test/Ice/timeout/Client.m1
-rw-r--r--objective-c/test/Ice/timeout/Server.m2
-rw-r--r--objective-c/test/Slice/escape/Client.m1
247 files changed, 1377 insertions, 531 deletions
diff --git a/CHANGELOG-3.7.md b/CHANGELOG-3.7.md
index bfd4de61616..15db623cc08 100644
--- a/CHANGELOG-3.7.md
+++ b/CHANGELOG-3.7.md
@@ -279,6 +279,14 @@ These are the changes since the Ice 3.6 release or snapshot described in
## C++ Changes
+- The UDP and WS transports are no longer enabled by default with static builds
+ of the Ice library. You will need to explicitly register them with the
+ Ice::registerIceUDP() or Ice::registerIceWS() function if you want to use
+ these transports with your statically linked application.
+
+ NOTE: this affects UWP and iOS applications which are linked statically with
+ Ice libraries.
+
- Added a new C++11 mapping that takes advantage of C++11 language features. This
new mapping is very different from the Slice-to-C++ mapping provided in prior
releases. The old mapping, now known as the C++98 mapping, is still supported so
@@ -441,6 +449,14 @@ These are the changes since the Ice 3.6 release or snapshot described in
## Objective-C Changes
+- The UDP and WS transports are no longer enabled by default with static builds
+ of the IceObjC library. You will need to explicitly register them with the
+ ICEregisterIceUDP() or ICEregisterIceWS() function if you want to use these
+ transports with your statically linked application.
+
+ NOTE: this affects iOS applications which are linked statically with Ice
+ libraries.
+
- Fixed a bug where optional object dictionary parameters would
trigger an assert on marshaling.
diff --git a/cpp/include/Ice/RegisterPlugins.h b/cpp/include/Ice/RegisterPlugins.h
index 28d4e6fce1a..1a50b70d05d 100644
--- a/cpp/include/Ice/RegisterPlugins.h
+++ b/cpp/include/Ice/RegisterPlugins.h
@@ -36,6 +36,8 @@ namespace Ice
#ifndef ICE_API_EXPORTS
ICE_PLUGIN_REGISTER_DECLSPEC_IMPORT void registerIceStringConverter(bool = true);
+ICE_PLUGIN_REGISTER_DECLSPEC_IMPORT void registerIceUDP(bool = true);
+ICE_PLUGIN_REGISTER_DECLSPEC_IMPORT void registerIceWS(bool = true);
#endif
#ifndef ICESSL_API_EXPORTS
diff --git a/cpp/src/Ice/EndpointFactory.cpp b/cpp/src/Ice/EndpointFactory.cpp
index 1ccd152bac5..e7a79313404 100644
--- a/cpp/src/Ice/EndpointFactory.cpp
+++ b/cpp/src/Ice/EndpointFactory.cpp
@@ -10,6 +10,7 @@
#include <Ice/EndpointFactory.h>
#include <Ice/Instance.h>
#include <Ice/EndpointFactoryManager.h>
+#include <Ice/ProtocolInstance.h>
using namespace std;
using namespace Ice;
@@ -25,6 +26,12 @@ IceInternal::EndpointFactory::~EndpointFactory()
{
}
+void
+IceInternal::EndpointFactory::initialize()
+{
+ // Nothing to do, can be overriden by specialization to finish initialization.
+}
+
IceInternal::EndpointFactoryPlugin::EndpointFactoryPlugin(const CommunicatorPtr& communicator,
const EndpointFactoryPtr& factory)
{
@@ -41,3 +48,147 @@ void
IceInternal::EndpointFactoryPlugin::destroy()
{
}
+
+IceInternal::EndpointFactoryWithUnderlying::EndpointFactoryWithUnderlying(const ProtocolInstancePtr& instance,
+ Short type) :
+ _instance(instance), _type(type)
+{
+}
+
+void
+IceInternal::EndpointFactoryWithUnderlying::initialize()
+{
+ //
+ // Get the endpoint factory for the underlying type and clone it with
+ // our protocol instance.
+ //
+ EndpointFactoryPtr factory = _instance->getEndpointFactory(_type);
+ if(factory)
+ {
+ _underlying = factory->clone(_instance);
+ _underlying->initialize();
+ }
+}
+
+Short
+IceInternal::EndpointFactoryWithUnderlying::type() const
+{
+ return _instance->type();
+}
+
+string
+IceInternal::EndpointFactoryWithUnderlying::protocol() const
+{
+ return _instance->protocol();
+}
+
+EndpointIPtr
+IceInternal::EndpointFactoryWithUnderlying::create(vector<string>& args, bool oaEndpoint) const
+{
+ if(!_underlying)
+ {
+ return 0; // Can't create an endpoint without underlying factory.
+ }
+ return createWithUnderlying(_underlying->create(args, oaEndpoint), args, oaEndpoint);
+}
+
+EndpointIPtr
+IceInternal::EndpointFactoryWithUnderlying::read(InputStream* s) const
+{
+ if(!_underlying)
+ {
+ return 0; // Can't create an endpoint without underlying factory.
+ }
+ return readWithUnderlying(_underlying->read(s), s);
+}
+
+void
+IceInternal::EndpointFactoryWithUnderlying::destroy()
+{
+ if(_underlying)
+ {
+ _underlying->destroy();
+ }
+ _instance = 0;
+}
+
+EndpointFactoryPtr
+IceInternal::EndpointFactoryWithUnderlying::clone(const ProtocolInstancePtr& instance) const
+{
+ return cloneWithUnderlying(instance, _type);
+}
+
+IceInternal::UnderlyingEndpointFactory::UnderlyingEndpointFactory(const ProtocolInstancePtr& instance,
+ Short type,
+ Short underlying) :
+ _instance(instance), _type(type), _underlying(underlying)
+{
+}
+
+void
+IceInternal::UnderlyingEndpointFactory::initialize()
+{
+ //
+ // Get the endpoint factory of the given endpoint type. If it's a factory that
+ // delegates to an underlying endpoint, clone it and instruct it to delegate to
+ // our underlying factory.
+ //
+ EndpointFactoryPtr factory = _instance->getEndpointFactory(_type);
+ if(factory)
+ {
+ EndpointFactoryWithUnderlying* f = dynamic_cast<EndpointFactoryWithUnderlying*>(factory.get());
+ if(f)
+ {
+ _factory = f->cloneWithUnderlying(_instance, _underlying);
+ _factory->initialize();
+ }
+ }
+}
+
+Short
+IceInternal::UnderlyingEndpointFactory::type() const
+{
+ return _instance->type();
+}
+
+string
+IceInternal::UnderlyingEndpointFactory::protocol() const
+{
+ return _instance->protocol();
+}
+
+EndpointIPtr
+IceInternal::UnderlyingEndpointFactory::create(vector<string>& args, bool oaEndpoint) const
+{
+ if(!_factory)
+ {
+ return 0;
+ }
+ return _factory->create(args, oaEndpoint);
+}
+
+EndpointIPtr
+IceInternal::UnderlyingEndpointFactory::read(InputStream* s) const
+{
+ if(!_factory)
+ {
+ return 0;
+ }
+ return _factory->read(s);
+}
+
+void
+IceInternal::UnderlyingEndpointFactory::destroy()
+{
+ if(_factory)
+ {
+ _factory->destroy();
+ }
+ _instance = 0;
+}
+
+EndpointFactoryPtr
+IceInternal::UnderlyingEndpointFactory::clone(const ProtocolInstancePtr& instance) const
+{
+ return new UnderlyingEndpointFactory(instance, _type, _underlying);
+}
diff --git a/cpp/src/Ice/EndpointFactory.h b/cpp/src/Ice/EndpointFactory.h
index 1a206b52d6b..b775cd1c91a 100644
--- a/cpp/src/Ice/EndpointFactory.h
+++ b/cpp/src/Ice/EndpointFactory.h
@@ -33,19 +33,80 @@ public:
virtual ~EndpointFactory();
- virtual ::Ice::Short type() const = 0;
- virtual ::std::string protocol() const = 0;
+ virtual void initialize();
+ virtual Ice::Short type() const = 0;
+ virtual std::string protocol() const = 0;
virtual EndpointIPtr create(std::vector<std::string>&, bool) const = 0;
virtual EndpointIPtr read(Ice::InputStream*) const = 0;
virtual void destroy() = 0;
- virtual EndpointFactoryPtr clone(const ProtocolInstancePtr&, const EndpointFactoryPtr&) const = 0;
+ virtual EndpointFactoryPtr clone(const ProtocolInstancePtr&) const = 0;
protected:
EndpointFactory();
};
+//
+// The endpoint factory with underlying create endpoints that delegate to an underlying
+// endpoint (e.g.: the SSL/WS endpoints are endpoints with underlying endpoints).
+//
+class ICE_API EndpointFactoryWithUnderlying : public EndpointFactory
+{
+public:
+
+ EndpointFactoryWithUnderlying(const ProtocolInstancePtr&, Ice::Short);
+
+ virtual void initialize();
+ virtual Ice::Short type() const;
+ virtual std::string protocol() const;
+ virtual EndpointIPtr create(std::vector<std::string>&, bool) const;
+ virtual EndpointIPtr read(Ice::InputStream*) const;
+ virtual void destroy();
+
+ virtual EndpointFactoryPtr clone(const ProtocolInstancePtr&) const;
+
+ virtual EndpointFactoryPtr cloneWithUnderlying(const ProtocolInstancePtr&, Ice::Short) const = 0;
+
+protected:
+
+ virtual EndpointIPtr createWithUnderlying(const EndpointIPtr&, std::vector<std::string>&, bool) const = 0;
+ virtual EndpointIPtr readWithUnderlying(const EndpointIPtr&, Ice::InputStream*) const = 0;
+
+ ProtocolInstancePtr _instance;
+ const Ice::Short _type;
+ EndpointFactoryPtr _underlying;
+};
+
+//
+// The underlying endpoint factory creates endpoints with a factory of the given
+// type. If this factory is of the EndpointFactoryWithUnderlying type, it will
+// delegate to the given underlying factory (this is used by IceIAP/IceBT plugins
+// for the BTS/iAPS endpoint factories).
+//
+class ICE_API UnderlyingEndpointFactory : public EndpointFactory
+{
+public:
+
+ UnderlyingEndpointFactory(const ProtocolInstancePtr&, Ice::Short, Ice::Short);
+
+ virtual void initialize();
+ virtual Ice::Short type() const;
+ virtual std::string protocol() const;
+ virtual EndpointIPtr create(std::vector<std::string>&, bool) const;
+ virtual EndpointIPtr read(Ice::InputStream*) const;
+ virtual void destroy();
+
+ virtual EndpointFactoryPtr clone(const ProtocolInstancePtr&) const;
+
+private:
+
+ ProtocolInstancePtr _instance;
+ const Ice::Short _type;
+ const Ice::Short _underlying;
+ EndpointFactoryPtr _factory;
+};
+
class ICE_API EndpointFactoryPlugin : public Ice::Plugin
{
public:
diff --git a/cpp/src/Ice/EndpointFactoryManager.cpp b/cpp/src/Ice/EndpointFactoryManager.cpp
index 8fa1e614769..a2105da4274 100644
--- a/cpp/src/Ice/EndpointFactoryManager.cpp
+++ b/cpp/src/Ice/EndpointFactoryManager.cpp
@@ -30,6 +30,15 @@ IceInternal::EndpointFactoryManager::EndpointFactoryManager(const InstancePtr& i
}
void
+IceInternal::EndpointFactoryManager::initialize() const
+{
+ for(vector<EndpointFactoryPtr>::size_type i = 0; i < _factories.size(); i++)
+ {
+ _factories[i]->initialize();
+ }
+}
+
+void
IceInternal::EndpointFactoryManager::add(const EndpointFactoryPtr& factory)
{
IceUtil::Mutex::Lock sync(*this); // TODO: Necessary?
@@ -188,7 +197,13 @@ IceInternal::EndpointFactoryManager::read(InputStream* s) const
{
e = factory->read(s);
}
- else
+ //
+ // If the factory failed to read the endpoint, return an opaque endpoint. This can
+ // occur if for example the factory delegates to another factory and this factory
+ // isn't available. In this case, the factory needs to make sure the stream position
+ // is preserved for reading the opaque endpoint.
+ //
+ if(!e)
{
e = ICE_MAKE_SHARED(OpaqueEndpointI, type, s);
}
diff --git a/cpp/src/Ice/EndpointFactoryManager.h b/cpp/src/Ice/EndpointFactoryManager.h
index afa99c77232..bdeb9a4e45e 100644
--- a/cpp/src/Ice/EndpointFactoryManager.h
+++ b/cpp/src/Ice/EndpointFactoryManager.h
@@ -31,6 +31,7 @@ class EndpointFactoryManager : public ::IceUtil::Shared, public ::IceUtil::Mutex
{
public:
+ void initialize() const;
void add(const EndpointFactoryPtr&);
EndpointFactoryPtr get(::Ice::Short) const;
EndpointIPtr create(const std::string&, bool) const;
diff --git a/cpp/src/Ice/Instance.cpp b/cpp/src/Ice/Instance.cpp
index e94781b3cf1..490327881d2 100644
--- a/cpp/src/Ice/Instance.cpp
+++ b/cpp/src/Ice/Instance.cpp
@@ -1351,20 +1351,10 @@ IceInternal::Instance::finishSetup(int& argc, const char* argv[], const Ice::Com
pluginManagerImpl->loadPlugins(argc, argv);
//
- // Add WS and WSS endpoint factories if TCP/SSL factories are installed.
+ // Initialize the endpoint factories once all the plugins are loaded. This gives
+ // the opportunity for the endpoint factories to find underyling factories.
//
- EndpointFactoryPtr tcpFactory = _endpointFactoryManager->get(TCPEndpointType);
- if(tcpFactory)
- {
- ProtocolInstancePtr instance = new ProtocolInstance(communicator, WSEndpointType, "ws", false);
- _endpointFactoryManager->add(new WSEndpointFactory(instance, tcpFactory->clone(instance, 0)));
- }
- EndpointFactoryPtr sslFactory = _endpointFactoryManager->get(SSLEndpointType);
- if(sslFactory)
- {
- ProtocolInstancePtr instance = new ProtocolInstance(communicator, WSSEndpointType, "wss", true);
- _endpointFactoryManager->add(new WSEndpointFactory(instance, sslFactory->clone(instance, 0)));
- }
+ _endpointFactoryManager->initialize();
//
// Reset _stringConverter and _wstringConverter, in case a plugin changed them
diff --git a/cpp/src/Ice/Network.cpp b/cpp/src/Ice/Network.cpp
index a78556b151d..c761d65dfe0 100755
--- a/cpp/src/Ice/Network.cpp
+++ b/cpp/src/Ice/Network.cpp
@@ -855,7 +855,7 @@ IceInternal::NativeInfo::queueAction(SocketOperation op, IAsyncAction^ action, b
[=] (IAsyncAction^ info, Windows::Foundation::AsyncStatus status)
{
//
- // COMPILERFIX with VC141 using operator!= and operator== inside
+ // COMPILERFIX with VC141 using operator!= and operator== inside
// a lambda callback triggers a compiler bug, we move the code to
// a seperate private method to workaround the issue.
//
@@ -896,11 +896,11 @@ IceInternal::NativeInfo::queueOperation(SocketOperation op, IAsyncOperation<unsi
[=] (IAsyncOperation<unsigned int>^ operation, Windows::Foundation::AsyncStatus status)
{
//
- // COMPILERFIX with VC141 using operator!= and operator== inside
+ // COMPILERFIX with VC141 using operator!= and operator== inside
// a lambda callback triggers a compiler bug, we move the code to
// a seperate private method to workaround the issue.
//
- this->queueOperationCompleted(op, info, operation, status);
+ this->queueOperationCompleted(op, info, operation, status);
});
}
operation->Completed = info->completedHandler;
diff --git a/cpp/src/Ice/ProtocolInstance.cpp b/cpp/src/Ice/ProtocolInstance.cpp
index c9950f65a64..43ed6b27bcc 100644
--- a/cpp/src/Ice/ProtocolInstance.cpp
+++ b/cpp/src/Ice/ProtocolInstance.cpp
@@ -13,6 +13,7 @@
#include <Ice/IPEndpointI.h>
#include <Ice/DefaultsAndOverrides.h>
#include <Ice/TraceLevels.h>
+#include <Ice/EndpointFactoryManager.h>
using namespace std;
using namespace Ice;
@@ -55,6 +56,12 @@ IceInternal::ProtocolInstance::logger() const
return _instance->initializationData().logger;
}
+EndpointFactoryPtr
+IceInternal::ProtocolInstance::getEndpointFactory(Ice::Short type) const
+{
+ return _instance->endpointFactoryManager()->get(type);
+}
+
BufSizeWarnInfo
IceInternal::ProtocolInstance::getBufSizeWarn(Short type)
{
diff --git a/cpp/src/Ice/ProtocolInstance.h b/cpp/src/Ice/ProtocolInstance.h
index 3f3805eb917..ba791c1928d 100644
--- a/cpp/src/Ice/ProtocolInstance.h
+++ b/cpp/src/Ice/ProtocolInstance.h
@@ -15,6 +15,7 @@
#include <Ice/PropertiesF.h>
#include <Ice/LoggerF.h>
#include <Ice/EndpointIF.h>
+#include <Ice/EndpointFactory.h>
#include <Ice/ConnectorF.h>
#include <Ice/IPEndpointIF.h>
#include <Ice/NetworkF.h>
@@ -63,6 +64,7 @@ public:
return _secure;
}
+ IceInternal::EndpointFactoryPtr getEndpointFactory(Ice::Short) const;
BufSizeWarnInfo getBufSizeWarn(Ice::Short type);
void setSndBufSizeWarn(Ice::Short type, int size);
void setRcvBufSizeWarn(Ice::Short type, int size);
diff --git a/cpp/src/Ice/RegisterPluginsInit.cpp b/cpp/src/Ice/RegisterPluginsInit.cpp
index f0fac12f972..47c7a00c81c 100644
--- a/cpp/src/Ice/RegisterPluginsInit.cpp
+++ b/cpp/src/Ice/RegisterPluginsInit.cpp
@@ -16,11 +16,19 @@ extern "C"
Ice::Plugin* createIceUDP(const Ice::CommunicatorPtr&, const std::string&, const Ice::StringSeq&);
Ice::Plugin* createIceTCP(const Ice::CommunicatorPtr&, const std::string&, const Ice::StringSeq&);
+Ice::Plugin* createIceWS(const Ice::CommunicatorPtr&, const std::string&, const Ice::StringSeq&);
};
IceInternal::RegisterPluginsInit::RegisterPluginsInit()
{
- Ice::registerPluginFactory("IceUDP", createIceUDP, true);
Ice::registerPluginFactory("IceTCP", createIceTCP, true);
+
+ //
+ // Only include the UDP and WS transport plugins with non-static builds or Gem/PyPI builds.
+ //
+#if !defined(ICE_STATIC_LIBS) || defined(ICE_GEM) || defined(ICE_PYPI)
+ Ice::registerPluginFactory("IceUDP", createIceUDP, true);
+ Ice::registerPluginFactory("IceWS", createIceWS, true);
+#endif
}
diff --git a/cpp/src/Ice/TcpEndpointI.cpp b/cpp/src/Ice/TcpEndpointI.cpp
index c1b87d1b931..57a44ac4b20 100644
--- a/cpp/src/Ice/TcpEndpointI.cpp
+++ b/cpp/src/Ice/TcpEndpointI.cpp
@@ -382,7 +382,7 @@ IceInternal::TcpEndpointFactory::destroy()
}
EndpointFactoryPtr
-IceInternal::TcpEndpointFactory::clone(const ProtocolInstancePtr& instance, const EndpointFactoryPtr&) const
+IceInternal::TcpEndpointFactory::clone(const ProtocolInstancePtr& instance) const
{
return new TcpEndpointFactory(instance);
}
diff --git a/cpp/src/Ice/TcpEndpointI.h b/cpp/src/Ice/TcpEndpointI.h
index 6c027e27392..93bc40e25e0 100644
--- a/cpp/src/Ice/TcpEndpointI.h
+++ b/cpp/src/Ice/TcpEndpointI.h
@@ -83,7 +83,7 @@ public:
virtual EndpointIPtr read(Ice::InputStream*) const;
virtual void destroy();
- virtual EndpointFactoryPtr clone(const ProtocolInstancePtr&, const EndpointFactoryPtr&) const;
+ virtual EndpointFactoryPtr clone(const ProtocolInstancePtr&) const;
private:
diff --git a/cpp/src/Ice/UdpEndpointI.cpp b/cpp/src/Ice/UdpEndpointI.cpp
index 9016a2ae2f7..11f7d565008 100644
--- a/cpp/src/Ice/UdpEndpointI.cpp
+++ b/cpp/src/Ice/UdpEndpointI.cpp
@@ -38,6 +38,26 @@ createIceUDP(const CommunicatorPtr& c, const string&, const StringSeq&)
}
+namespace Ice
+{
+
+ICE_API void
+registerIceUDP(bool loadOnInitialize)
+{
+ Ice::registerPluginFactory("IceUDP", createIceUDP, loadOnInitialize);
+}
+
+}
+
+//
+// Objective-C function to allow Objective-C programs to register plugin.
+//
+extern "C" ICE_API void
+ICEregisterIceUDP(bool loadOnInitialize)
+{
+ Ice::registerIceUDP(loadOnInitialize);
+}
+
IceInternal::UdpEndpointI::UdpEndpointI(const ProtocolInstancePtr& instance, const string& host, Int port,
const Address& sourceAddr, const string& mcastInterface, Int mttl, bool conn,
const string& conId, bool co) :
@@ -492,7 +512,7 @@ IceInternal::UdpEndpointFactory::destroy()
}
EndpointFactoryPtr
-IceInternal::UdpEndpointFactory::clone(const ProtocolInstancePtr& instance, const EndpointFactoryPtr&) const
+IceInternal::UdpEndpointFactory::clone(const ProtocolInstancePtr& instance) const
{
return new UdpEndpointFactory(instance);
}
diff --git a/cpp/src/Ice/UdpEndpointI.h b/cpp/src/Ice/UdpEndpointI.h
index 19400fb031a..f95af7ef8b3 100644
--- a/cpp/src/Ice/UdpEndpointI.h
+++ b/cpp/src/Ice/UdpEndpointI.h
@@ -88,7 +88,7 @@ public:
virtual EndpointIPtr read(Ice::InputStream*) const;
virtual void destroy();
- virtual EndpointFactoryPtr clone(const ProtocolInstancePtr&, const EndpointFactoryPtr&) const;
+ virtual EndpointFactoryPtr clone(const ProtocolInstancePtr&) const;
private:
diff --git a/cpp/src/Ice/WSEndpoint.cpp b/cpp/src/Ice/WSEndpoint.cpp
index 6296400a16d..386125545d4 100644
--- a/cpp/src/Ice/WSEndpoint.cpp
+++ b/cpp/src/Ice/WSEndpoint.cpp
@@ -25,12 +25,21 @@ using namespace IceInternal;
namespace
{
-Ice::IPEndpointInfoPtr
-getIPEndpointInfo(const Ice::EndpointInfoPtr& info)
+class WSEndpointFactoryPlugin : public Plugin
{
- for(Ice::EndpointInfoPtr p = info; p; p = p->underlying)
+public:
+
+ WSEndpointFactoryPlugin(const CommunicatorPtr&);
+ virtual void initialize();
+ virtual void destroy();
+};
+
+IPEndpointInfoPtr
+getIPEndpointInfo(const EndpointInfoPtr& info)
+{
+ for(EndpointInfoPtr p = info; p; p = p->underlying)
{
- Ice::IPEndpointInfoPtr ipInfo = ICE_DYNAMIC_CAST(Ice::IPEndpointInfo, p);
+ IPEndpointInfoPtr ipInfo = ICE_DYNAMIC_CAST(IPEndpointInfo, p);
if(ipInfo)
{
return ipInfo;
@@ -41,10 +50,60 @@ getIPEndpointInfo(const Ice::EndpointInfoPtr& info)
}
+extern "C"
+{
+
+Plugin*
+createIceWS(const CommunicatorPtr& c, const string&, const StringSeq&)
+{
+ return new WSEndpointFactoryPlugin(c);
+}
+
+}
+
+namespace Ice
+{
+
+ICE_API void
+registerIceWS(bool loadOnInitialize)
+{
+ registerPluginFactory("IceWS", createIceWS, loadOnInitialize);
+}
+
+}
+
+//
+// Objective-C function to allow Objective-C programs to register plugin.
+//
+extern "C" ICE_API void
+ICEregisterIceWS(bool loadOnInitialize)
+{
+ Ice::registerIceWS(loadOnInitialize);
+}
+
#ifndef ICE_CPP11_MAPPING
IceUtil::Shared* IceInternal::upCast(WSEndpoint* p) { return p; }
#endif
+WSEndpointFactoryPlugin::WSEndpointFactoryPlugin(const CommunicatorPtr& communicator)
+{
+ assert(communicator);
+
+ const EndpointFactoryManagerPtr efm = getInstance(communicator)->endpointFactoryManager();
+ efm->add(new WSEndpointFactory(new ProtocolInstance(communicator, WSEndpointType, "ws", false), TCPEndpointType));
+ efm->add(new WSEndpointFactory(new ProtocolInstance(communicator, WSSEndpointType, "wss", true), SSLEndpointType));
+}
+
+void
+WSEndpointFactoryPlugin::initialize()
+{
+}
+
+void
+WSEndpointFactoryPlugin::destroy()
+{
+}
+
IceInternal::WSEndpoint::WSEndpoint(const ProtocolInstancePtr& instance, const EndpointIPtr& del, const string& res) :
_instance(instance), _delegate(del), _resource(res)
{
@@ -67,10 +126,10 @@ IceInternal::WSEndpoint::WSEndpoint(const ProtocolInstancePtr& instance, const E
s->read(const_cast<string&>(_resource), false);
}
-Ice::EndpointInfoPtr
+EndpointInfoPtr
IceInternal::WSEndpoint::getInfo() const
{
- WSEndpointInfoPtr info = ICE_MAKE_SHARED(InfoI<Ice::WSEndpointInfo>, ICE_SHARED_FROM_CONST_THIS(WSEndpoint));
+ WSEndpointInfoPtr info = ICE_MAKE_SHARED(InfoI<WSEndpointInfo>, ICE_SHARED_FROM_CONST_THIS(WSEndpoint));
info->underlying = _delegate->getInfo();
info->compress = info->underlying->compress;
info->timeout = info->underlying->timeout;
@@ -78,7 +137,7 @@ IceInternal::WSEndpoint::getInfo() const
return info;
}
-Ice::Short
+Short
IceInternal::WSEndpoint::type() const
{
return _delegate->type();
@@ -173,7 +232,7 @@ IceInternal::WSEndpoint::transceiver() const
}
void
-IceInternal::WSEndpoint::connectors_async(Ice::EndpointSelectionType selType,
+IceInternal::WSEndpoint::connectors_async(EndpointSelectionType selType,
const EndpointI_connectorsPtr& callback) const
{
class CallbackI : public EndpointI_connectors
@@ -196,7 +255,7 @@ IceInternal::WSEndpoint::connectors_async(Ice::EndpointSelectionType selType,
_callback->connectors(connectors);
}
- virtual void exception(const Ice::LocalException& ex)
+ virtual void exception(const LocalException& ex)
{
_callback->exception(ex);
}
@@ -293,7 +352,7 @@ IceInternal::WSEndpoint::equivalent(const EndpointIPtr& endpoint) const
return _delegate->equivalent(wsEndpointI->_delegate);
}
-Ice::Int
+Int
IceInternal::WSEndpoint::hash() const
{
int h = _delegate->hash();
@@ -336,7 +395,7 @@ bool
#ifdef ICE_CPP11_MAPPING
IceInternal::WSEndpoint::operator==(const Endpoint& r) const
#else
-IceInternal::WSEndpoint::operator==(const Ice::LocalObject& r) const
+IceInternal::WSEndpoint::operator==(const LocalObject& r) const
#endif
{
const WSEndpoint* p = dynamic_cast<const WSEndpoint*>(&r);
@@ -350,7 +409,7 @@ IceInternal::WSEndpoint::operator==(const Ice::LocalObject& r) const
return true;
}
- if(!Ice::targetEqualTo(_delegate, p->_delegate))
+ if(!targetEqualTo(_delegate, p->_delegate))
{
return false;
}
@@ -367,7 +426,7 @@ bool
#ifdef ICE_CPP11_MAPPING
IceInternal::WSEndpoint::operator<(const Endpoint& r) const
#else
-IceInternal::WSEndpoint::operator<(const Ice::LocalObject& r) const
+IceInternal::WSEndpoint::operator<(const LocalObject& r) const
#endif
{
const WSEndpoint* p = dynamic_cast<const WSEndpoint*>(&r);
@@ -386,11 +445,11 @@ IceInternal::WSEndpoint::operator<(const Ice::LocalObject& r) const
return false;
}
- if(Ice::targetLess(_delegate, p->_delegate))
+ if(targetLess(_delegate, p->_delegate))
{
return true;
}
- else if (Ice::targetLess(p->_delegate, _delegate))
+ else if (targetLess(p->_delegate, _delegate))
{
return false;
}
@@ -431,48 +490,25 @@ IceInternal::WSEndpoint::checkOption(const string& option, const string& argumen
}
}
-IceInternal::WSEndpointFactory::WSEndpointFactory(const ProtocolInstancePtr& instance, const EndpointFactoryPtr& del) :
- _instance(instance), _delegate(del)
+IceInternal::WSEndpointFactory::WSEndpointFactory(const ProtocolInstancePtr& instance, Short type) :
+ EndpointFactoryWithUnderlying(instance, type)
{
}
-IceInternal::WSEndpointFactory::~WSEndpointFactory()
-{
-}
-
-Short
-IceInternal::WSEndpointFactory::type() const
-{
- return _instance->type();
-}
-
-string
-IceInternal::WSEndpointFactory::protocol() const
+EndpointFactoryPtr
+IceInternal::WSEndpointFactory::cloneWithUnderlying(const ProtocolInstancePtr& instance, Short underlying) const
{
- return _instance->protocol();
+ return new WSEndpointFactory(instance, underlying);
}
EndpointIPtr
-IceInternal::WSEndpointFactory::create(vector<string>& args, bool oaEndpoint) const
+IceInternal::WSEndpointFactory::createWithUnderlying(const EndpointIPtr& underlying, vector<string>& args, bool) const
{
- return ICE_MAKE_SHARED(WSEndpoint, _instance, _delegate->create(args, oaEndpoint), args);
+ return ICE_MAKE_SHARED(WSEndpoint, _instance, underlying, args);
}
EndpointIPtr
-IceInternal::WSEndpointFactory::read(InputStream* s) const
-{
- return ICE_MAKE_SHARED(WSEndpoint, _instance, _delegate->read(s), s);
-}
-
-void
-IceInternal::WSEndpointFactory::destroy()
-{
- _delegate->destroy();
- _instance = 0;
-}
-
-EndpointFactoryPtr
-IceInternal::WSEndpointFactory::clone(const ProtocolInstancePtr& instance, const EndpointFactoryPtr& delegate) const
+IceInternal::WSEndpointFactory::readWithUnderlying(const EndpointIPtr& underlying, InputStream* s) const
{
- return new WSEndpointFactory(instance, delegate);
+ return ICE_MAKE_SHARED(WSEndpoint, _instance, underlying, s);
}
diff --git a/cpp/src/Ice/WSEndpoint.h b/cpp/src/Ice/WSEndpoint.h
index fe38fe331cf..8cb1b39b235 100644
--- a/cpp/src/Ice/WSEndpoint.h
+++ b/cpp/src/Ice/WSEndpoint.h
@@ -79,25 +79,18 @@ private:
const std::string _resource;
};
-class ICE_API WSEndpointFactory : public EndpointFactory
+class ICE_API WSEndpointFactory : public EndpointFactoryWithUnderlying
{
public:
- WSEndpointFactory(const ProtocolInstancePtr&, const EndpointFactoryPtr&);
- virtual ~WSEndpointFactory();
+ WSEndpointFactory(const ProtocolInstancePtr&, Ice::Short);
- virtual Ice::Short type() const;
- virtual std::string protocol() const;
- virtual EndpointIPtr create(std::vector<std::string>&, bool) const;
- virtual EndpointIPtr read(Ice::InputStream*) const;
- virtual void destroy();
-
- virtual EndpointFactoryPtr clone(const ProtocolInstancePtr&, const EndpointFactoryPtr&) const;
+ virtual EndpointFactoryPtr cloneWithUnderlying(const ProtocolInstancePtr&, Ice::Short) const;
-private:
+protected:
- ProtocolInstancePtr _instance;
- const EndpointFactoryPtr _delegate;
+ virtual EndpointIPtr createWithUnderlying(const EndpointIPtr&, std::vector<std::string>&, bool) const;
+ virtual EndpointIPtr readWithUnderlying(const EndpointIPtr&, Ice::InputStream*) const;
};
}
diff --git a/cpp/src/Ice/ios/StreamEndpointI.cpp b/cpp/src/Ice/ios/StreamEndpointI.cpp
index d2290c88dfc..7c2ad1a4738 100644
--- a/cpp/src/Ice/ios/StreamEndpointI.cpp
+++ b/cpp/src/Ice/ios/StreamEndpointI.cpp
@@ -480,7 +480,7 @@ IceObjC::StreamEndpointFactory::destroy()
}
EndpointFactoryPtr
-IceObjC::StreamEndpointFactory::clone(const ProtocolInstancePtr& instance, const EndpointFactoryPtr&) const
+IceObjC::StreamEndpointFactory::clone(const ProtocolInstancePtr& instance) const
{
return new StreamEndpointFactory(_instance->clone(instance));
}
diff --git a/cpp/src/Ice/ios/StreamEndpointI.h b/cpp/src/Ice/ios/StreamEndpointI.h
index 0a05061d5ea..cd117edb06e 100644
--- a/cpp/src/Ice/ios/StreamEndpointI.h
+++ b/cpp/src/Ice/ios/StreamEndpointI.h
@@ -144,8 +144,7 @@ public:
virtual IceInternal::EndpointIPtr read(Ice::InputStream*) const;
virtual void destroy();
- virtual IceInternal::EndpointFactoryPtr clone(const IceInternal::ProtocolInstancePtr&,
- const IceInternal::EndpointFactoryPtr&) const;
+ virtual IceInternal::EndpointFactoryPtr clone(const IceInternal::ProtocolInstancePtr&) const;
private:
diff --git a/cpp/src/IceBT/EndpointI.cpp b/cpp/src/IceBT/EndpointI.cpp
index a081b36747f..40726c63b82 100644
--- a/cpp/src/IceBT/EndpointI.cpp
+++ b/cpp/src/IceBT/EndpointI.cpp
@@ -684,8 +684,7 @@ IceBT::EndpointFactoryI::destroy()
}
IceInternal::EndpointFactoryPtr
-IceBT::EndpointFactoryI::clone(const IceInternal::ProtocolInstancePtr& instance,
- const IceInternal::EndpointFactoryPtr&) const
+IceBT::EndpointFactoryI::clone(const IceInternal::ProtocolInstancePtr& instance) const
{
return new EndpointFactoryI(new Instance(_instance->engine(), instance->type(), instance->protocol()));
}
diff --git a/cpp/src/IceBT/EndpointI.h b/cpp/src/IceBT/EndpointI.h
index 8e322574a1f..3d3e58db9cf 100644
--- a/cpp/src/IceBT/EndpointI.h
+++ b/cpp/src/IceBT/EndpointI.h
@@ -113,8 +113,7 @@ public:
virtual IceInternal::EndpointIPtr read(Ice::InputStream*) const;
virtual void destroy();
- virtual IceInternal::EndpointFactoryPtr clone(const IceInternal::ProtocolInstancePtr&,
- const IceInternal::EndpointFactoryPtr&) const;
+ virtual IceInternal::EndpointFactoryPtr clone(const IceInternal::ProtocolInstancePtr&) const;
private:
diff --git a/cpp/src/IceBT/PluginI.cpp b/cpp/src/IceBT/PluginI.cpp
index 1703c7732b5..55728c448fc 100644
--- a/cpp/src/IceBT/PluginI.cpp
+++ b/cpp/src/IceBT/PluginI.cpp
@@ -59,21 +59,18 @@ registerIceBT(bool loadOnInitialize)
IceBT::PluginI::PluginI(const Ice::CommunicatorPtr& com) :
_engine(new Engine(com))
{
- IceInternal::ProtocolPluginFacadePtr pluginFacade = IceInternal::getProtocolPluginFacade(com);
+ IceInternal::ProtocolPluginFacadePtr f = IceInternal::getProtocolPluginFacade(com);
//
// Register the endpoint factory. We have to do this now, rather
// than in initialize, because the communicator may need to
// interpret proxies before the plug-in is fully initialized.
//
- pluginFacade->addEndpointFactory(new EndpointFactoryI(new Instance(_engine, BTEndpointType, "bt")));
-
- IceInternal::EndpointFactoryPtr sslFactory = pluginFacade->getEndpointFactory(SSLEndpointType);
- if(sslFactory)
- {
- InstancePtr instance = new Instance(_engine, BTSEndpointType, "bts");
- pluginFacade->addEndpointFactory(sslFactory->clone(instance, new EndpointFactoryI(instance)));
- }
+ InstancePtr bt = new Instance(_engine, BTEndpointType, "bt");
+ f->addEndpointFactory(new EndpointFactoryI(bt));
+
+ InstancePtr bts = new Instance(_engine, BTSEndpointType, "bts");
+ f->addEndpointFactory(new IceInternal::UnderlyingEndpointFactory(bts, SSLEndpointType, BTEndpointType));
}
void
diff --git a/cpp/src/IceDiscovery/PluginI.cpp b/cpp/src/IceDiscovery/PluginI.cpp
index 1a76f34ff06..1489f725184 100644
--- a/cpp/src/IceDiscovery/PluginI.cpp
+++ b/cpp/src/IceDiscovery/PluginI.cpp
@@ -42,6 +42,13 @@ ICE_DISCOVERY_API void
registerIceDiscovery(bool loadOnInitialize)
{
Ice::registerPluginFactory("IceDiscovery", createIceDiscovery, loadOnInitialize);
+
+#ifdef ICE_STATIC_LIBS
+ //
+ // Also register the UDP plugin with static builds to ensure the UDP transport is loaded.
+ //
+ registerIceUDP(true);
+#endif
}
}
diff --git a/cpp/src/IceIAP/EndpointI.h b/cpp/src/IceIAP/EndpointI.h
index 8e71869eb70..ce1157c7e7a 100644
--- a/cpp/src/IceIAP/EndpointI.h
+++ b/cpp/src/IceIAP/EndpointI.h
@@ -100,8 +100,7 @@ public:
virtual IceInternal::EndpointIPtr read(Ice::InputStream*) const;
virtual void destroy();
- virtual IceInternal::EndpointFactoryPtr clone(const IceInternal::ProtocolInstancePtr&,
- const IceInternal::EndpointFactoryPtr&) const;
+ virtual IceInternal::EndpointFactoryPtr clone(const IceInternal::ProtocolInstancePtr&) const;
private:
diff --git a/cpp/src/IceIAP/EndpointI.mm b/cpp/src/IceIAP/EndpointI.mm
index 1914e3e79ba..9d160964d87 100644
--- a/cpp/src/IceIAP/EndpointI.mm
+++ b/cpp/src/IceIAP/EndpointI.mm
@@ -42,19 +42,15 @@ public:
iAPEndpointFactoryPlugin(const Ice::CommunicatorPtr& com)
{
- ProtocolPluginFacadePtr pluginFacade = getProtocolPluginFacade(com);
+ ProtocolPluginFacadePtr f = getProtocolPluginFacade(com);
// iAP transport
- ProtocolInstancePtr instance = new ProtocolInstance(com, iAPEndpointType, "iap", false);
- pluginFacade->addEndpointFactory(new IceObjC::iAPEndpointFactory(instance));
+ ProtocolInstancePtr iap = new ProtocolInstance(com, iAPEndpointType, "iap", false);
+ f->addEndpointFactory(new IceObjC::iAPEndpointFactory(iap));
// SSL based on iAP transport
- EndpointFactoryPtr ssl = pluginFacade->getEndpointFactory(SSLEndpointType);
- if(ssl)
- {
- ProtocolInstancePtr sslinstance = new ProtocolInstance(com, iAPSEndpointType, "iaps", true);
- pluginFacade->addEndpointFactory(ssl->clone(sslinstance, new IceObjC::iAPEndpointFactory(sslinstance)));
- }
+ ProtocolInstancePtr iaps = new ProtocolInstance(com, iAPSEndpointType, "iaps", true);
+ f->addEndpointFactory(new UnderlyingEndpointFactory(iaps, SSLEndpointType, iAPEndpointType));
}
virtual void initialize() {}
@@ -708,7 +704,7 @@ IceObjC::iAPEndpointFactory::destroy()
}
EndpointFactoryPtr
-IceObjC::iAPEndpointFactory::clone(const ProtocolInstancePtr& instance, const IceInternal::EndpointFactoryPtr&) const
+IceObjC::iAPEndpointFactory::clone(const ProtocolInstancePtr& instance) const
{
return new iAPEndpointFactory(instance);
}
diff --git a/cpp/src/IceLocatorDiscovery/PluginI.cpp b/cpp/src/IceLocatorDiscovery/PluginI.cpp
index 7a32c20a844..ee01719fd72 100644
--- a/cpp/src/IceLocatorDiscovery/PluginI.cpp
+++ b/cpp/src/IceLocatorDiscovery/PluginI.cpp
@@ -247,6 +247,13 @@ ICE_LOCATOR_DISCOVERY_API void
registerIceLocatorDiscovery(bool loadOnInitialize)
{
Ice::registerPluginFactory("IceLocatorDiscovery", createIceLocatorDiscovery, loadOnInitialize);
+
+#ifdef ICE_STATIC_LIBS
+ //
+ // Also register the UDP plugin with static builds to ensure the UDP transport is loaded.
+ //
+ registerIceUDP(true);
+#endif
}
}
diff --git a/cpp/src/IceSSL/EndpointI.cpp b/cpp/src/IceSSL/EndpointI.cpp
index 69705dcbcd8..099818f8fbc 100644
--- a/cpp/src/IceSSL/EndpointI.cpp
+++ b/cpp/src/IceSSL/EndpointI.cpp
@@ -347,51 +347,32 @@ IceSSL::EndpointI::checkOption(const string& option, const string& argument, con
return false;
}
-IceSSL::EndpointFactoryI::EndpointFactoryI(const InstancePtr& instance,
- const IceInternal::EndpointFactoryPtr& delegate) :
- _instance(instance), _delegate(delegate)
+IceSSL::EndpointFactoryI::EndpointFactoryI(const InstancePtr& instance, Short type) :
+ IceInternal::EndpointFactoryWithUnderlying(instance, type), _instance(instance.get())
{
}
-IceSSL::EndpointFactoryI::~EndpointFactoryI()
-{
-}
-
-Short
-IceSSL::EndpointFactoryI::type() const
+void
+IceSSL::EndpointFactoryI::destroy()
{
- return _instance->type();
+ _instance = 0;
}
-string
-IceSSL::EndpointFactoryI::protocol() const
+IceInternal::EndpointFactoryPtr
+IceSSL::EndpointFactoryI::cloneWithUnderlying(const IceInternal::ProtocolInstancePtr& instance, Short underlying) const
{
- return _instance->protocol();
+ return new EndpointFactoryI(new Instance(_instance->engine(), instance->type(), instance->protocol()), underlying);
}
IceInternal::EndpointIPtr
-IceSSL::EndpointFactoryI::create(vector<string>& args, bool oaEndpoint) const
+IceSSL::EndpointFactoryI::createWithUnderlying(const IceInternal::EndpointIPtr& underlying, vector<string>&, bool) const
{
- return ICE_MAKE_SHARED(EndpointI, _instance, _delegate->create(args, oaEndpoint));
+ return ICE_MAKE_SHARED(EndpointI, _instance, underlying);
}
IceInternal::EndpointIPtr
-IceSSL::EndpointFactoryI::read(Ice::InputStream* s) const
+IceSSL::EndpointFactoryI::readWithUnderlying(const IceInternal::EndpointIPtr& underlying, Ice::InputStream* s) const
{
- return ICE_MAKE_SHARED(EndpointI, _instance, _delegate->read(s));
+ return ICE_MAKE_SHARED(EndpointI, _instance, underlying);
}
-void
-IceSSL::EndpointFactoryI::destroy()
-{
- _delegate->destroy();
- _instance = 0;
-}
-
-IceInternal::EndpointFactoryPtr
-IceSSL::EndpointFactoryI::clone(const IceInternal::ProtocolInstancePtr& inst,
- const IceInternal::EndpointFactoryPtr& delegate) const
-{
- InstancePtr instance = new Instance(_instance->engine(), inst->type(), inst->protocol());
- return new EndpointFactoryI(instance, delegate ? delegate : _delegate->clone(instance, 0));
-}
diff --git a/cpp/src/IceSSL/EndpointI.h b/cpp/src/IceSSL/EndpointI.h
index d27a7182a4a..584ec149848 100644
--- a/cpp/src/IceSSL/EndpointI.h
+++ b/cpp/src/IceSSL/EndpointI.h
@@ -15,6 +15,7 @@
#include <Ice/EndpointFactory.h>
#include <IceSSL/InstanceF.h>
#include <IceSSL/EndpointInfo.h>
+#include <IceSSL/SSLEngineF.h>
#include <Ice/Network.h>
namespace IceSSL
@@ -76,28 +77,27 @@ private:
const IceInternal::EndpointIPtr _delegate;
};
-class EndpointFactoryI : public IceInternal::EndpointFactory
+class EndpointFactoryI : public IceInternal::EndpointFactoryWithUnderlying
{
public:
- virtual ~EndpointFactoryI();
+ EndpointFactoryI(const InstancePtr&, Ice::Short);
- virtual Ice::Short type() const;
- virtual std::string protocol() const;
- virtual IceInternal::EndpointIPtr create(std::vector<std::string>&, bool) const;
- virtual IceInternal::EndpointIPtr read(Ice::InputStream*) const;
virtual void destroy();
- virtual IceInternal::EndpointFactoryPtr clone(const IceInternal::ProtocolInstancePtr&,
- const IceInternal::EndpointFactoryPtr&) const;
+ virtual IceInternal::EndpointFactoryPtr
+ cloneWithUnderlying(const IceInternal::ProtocolInstancePtr&, Ice::Short) const;
-private:
+protected:
- EndpointFactoryI(const InstancePtr&, const IceInternal::EndpointFactoryPtr&);
- friend class PluginI;
+ virtual IceInternal::EndpointIPtr
+ createWithUnderlying(const IceInternal::EndpointIPtr&, std::vector<std::string>&, bool) const;
+ virtual IceInternal::EndpointIPtr
+ readWithUnderlying(const IceInternal::EndpointIPtr&, Ice::InputStream*) const;
+
+private:
InstancePtr _instance;
- const IceInternal::EndpointFactoryPtr _delegate;
};
}
diff --git a/cpp/src/IceSSL/PluginI.cpp b/cpp/src/IceSSL/PluginI.cpp
index cb0f20f5f6f..c12b3f9098e 100755
--- a/cpp/src/IceSSL/PluginI.cpp
+++ b/cpp/src/IceSSL/PluginI.cpp
@@ -49,31 +49,8 @@ PluginI::PluginI(const Ice::CommunicatorPtr& com, const SSLEnginePtr& engine) :
// than in initialize, because the communicator may need to
// interpret proxies before the plug-in is fully initialized.
//
- IceInternal::ProtocolPluginFacadePtr pluginFacade = IceInternal::getProtocolPluginFacade(com);
-
- // SSL based on TCP
- IceInternal::EndpointFactoryPtr tcp = pluginFacade->getEndpointFactory(TCPEndpointType);
- if(tcp)
- {
- InstancePtr instance = new Instance(_engine, SSLEndpointType, "ssl");
- pluginFacade->addEndpointFactory(new EndpointFactoryI(instance, tcp->clone(instance, 0)));
- }
-
- // SSL based on Bluetooth
- IceInternal::EndpointFactoryPtr bluetooth = pluginFacade->getEndpointFactory(BTEndpointType);
- if(bluetooth)
- {
- InstancePtr instance = new Instance(_engine, BTSEndpointType, "bts");
- pluginFacade->addEndpointFactory(new EndpointFactoryI(instance, bluetooth->clone(instance, 0)));
- }
-
- // SSL based on iAP
- IceInternal::EndpointFactoryPtr iap = pluginFacade->getEndpointFactory(iAPEndpointType);
- if(iap)
- {
- InstancePtr instance = new Instance(_engine, iAPSEndpointType, "iaps");
- pluginFacade->addEndpointFactory(new EndpointFactoryI(instance, iap->clone(instance, 0)));
- }
+ InstancePtr instance = new Instance(_engine, SSLEndpointType, "ssl"); // SSL based on TCP
+ IceInternal::getProtocolPluginFacade(com)->addEndpointFactory(new EndpointFactoryI(instance, TCPEndpointType));
}
void
diff --git a/cpp/test/Ice/acm/Client.cpp b/cpp/test/Ice/acm/Client.cpp
index da61340c1a4..e2a42513662 100644
--- a/cpp/test/Ice/acm/Client.cpp
+++ b/cpp/test/Ice/acm/Client.cpp
@@ -27,6 +27,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
# if defined(__linux)
Ice::registerIceBT(false);
# endif
diff --git a/cpp/test/Ice/acm/Server.cpp b/cpp/test/Ice/acm/Server.cpp
index 1e1ab2ef7c6..b17f955984a 100644
--- a/cpp/test/Ice/acm/Server.cpp
+++ b/cpp/test/Ice/acm/Server.cpp
@@ -39,6 +39,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
#endif
try
{
diff --git a/cpp/test/Ice/adapterDeactivation/Client.cpp b/cpp/test/Ice/adapterDeactivation/Client.cpp
index eb9044aa404..3d9e2c5ee16 100644
--- a/cpp/test/Ice/adapterDeactivation/Client.cpp
+++ b/cpp/test/Ice/adapterDeactivation/Client.cpp
@@ -32,6 +32,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
#endif
try
diff --git a/cpp/test/Ice/adapterDeactivation/Collocated.cpp b/cpp/test/Ice/adapterDeactivation/Collocated.cpp
index 10c4fc3893f..2a1b4c83576 100644
--- a/cpp/test/Ice/adapterDeactivation/Collocated.cpp
+++ b/cpp/test/Ice/adapterDeactivation/Collocated.cpp
@@ -44,6 +44,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
#endif
try
diff --git a/cpp/test/Ice/adapterDeactivation/Server.cpp b/cpp/test/Ice/adapterDeactivation/Server.cpp
index dc2a51ede3e..32d3393aa21 100644
--- a/cpp/test/Ice/adapterDeactivation/Server.cpp
+++ b/cpp/test/Ice/adapterDeactivation/Server.cpp
@@ -34,6 +34,8 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
+ Ice::registerIceUDP(true);
#endif
try
diff --git a/cpp/test/Ice/admin/Client.cpp b/cpp/test/Ice/admin/Client.cpp
index 413989a104e..15e778d42b4 100644
--- a/cpp/test/Ice/admin/Client.cpp
+++ b/cpp/test/Ice/admin/Client.cpp
@@ -28,6 +28,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
#endif
try
diff --git a/cpp/test/Ice/admin/Server.cpp b/cpp/test/Ice/admin/Server.cpp
index c6da44bdfb9..4f40a3350de 100644
--- a/cpp/test/Ice/admin/Server.cpp
+++ b/cpp/test/Ice/admin/Server.cpp
@@ -33,6 +33,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
#endif
try
diff --git a/cpp/test/Ice/ami/Client.cpp b/cpp/test/Ice/ami/Client.cpp
index 17210914722..d918a3aa88e 100644
--- a/cpp/test/Ice/ami/Client.cpp
+++ b/cpp/test/Ice/ami/Client.cpp
@@ -28,6 +28,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
# if defined(__linux)
Ice::registerIceBT(false);
# endif
diff --git a/cpp/test/Ice/ami/Collocated.cpp b/cpp/test/Ice/ami/Collocated.cpp
index 06aa5bcf897..a21d5a2f324 100644
--- a/cpp/test/Ice/ami/Collocated.cpp
+++ b/cpp/test/Ice/ami/Collocated.cpp
@@ -44,6 +44,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
#endif
try
diff --git a/cpp/test/Ice/ami/Server.cpp b/cpp/test/Ice/ami/Server.cpp
index aa72f3babdc..e153cd12b5e 100644
--- a/cpp/test/Ice/ami/Server.cpp
+++ b/cpp/test/Ice/ami/Server.cpp
@@ -44,6 +44,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
#endif
try
diff --git a/cpp/test/Ice/background/Client.cpp b/cpp/test/Ice/background/Client.cpp
index 304595228f8..4daa3fe7572 100644
--- a/cpp/test/Ice/background/Client.cpp
+++ b/cpp/test/Ice/background/Client.cpp
@@ -40,6 +40,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
Ice::registerPluginFactory("Test", createTestTransport, false);
#endif
diff --git a/cpp/test/Ice/background/EndpointFactory.cpp b/cpp/test/Ice/background/EndpointFactory.cpp
index 533aef616c8..6d6f56615cc 100644
--- a/cpp/test/Ice/background/EndpointFactory.cpp
+++ b/cpp/test/Ice/background/EndpointFactory.cpp
@@ -60,7 +60,7 @@ EndpointFactory::destroy()
}
IceInternal::EndpointFactoryPtr
-EndpointFactory::clone(const IceInternal::ProtocolInstancePtr&, const IceInternal::EndpointFactoryPtr&) const
+EndpointFactory::clone(const IceInternal::ProtocolInstancePtr&) const
{
return const_cast<EndpointFactory*>(this);
}
diff --git a/cpp/test/Ice/background/EndpointFactory.h b/cpp/test/Ice/background/EndpointFactory.h
index c5a375e88e0..e7d29569790 100644
--- a/cpp/test/Ice/background/EndpointFactory.h
+++ b/cpp/test/Ice/background/EndpointFactory.h
@@ -24,8 +24,7 @@ public:
virtual IceInternal::EndpointIPtr read(Ice::InputStream*) const;
virtual void destroy();
- virtual IceInternal::EndpointFactoryPtr clone(const IceInternal::ProtocolInstancePtr&,
- const IceInternal::EndpointFactoryPtr&) const;
+ virtual IceInternal::EndpointFactoryPtr clone(const IceInternal::ProtocolInstancePtr&) const;
protected:
diff --git a/cpp/test/Ice/background/PluginI.cpp b/cpp/test/Ice/background/PluginI.cpp
index 5b4cffd557c..6e41947132e 100644
--- a/cpp/test/Ice/background/PluginI.cpp
+++ b/cpp/test/Ice/background/PluginI.cpp
@@ -25,10 +25,10 @@ class TestPluginI : public PluginI
public:
TestPluginI(const Ice::CommunicatorPtr&);
-
+
virtual void initialize();
virtual void destroy();
-
+
virtual ConfigurationPtr getConfiguration();
private:
@@ -52,12 +52,12 @@ createTestTransport(const Ice::CommunicatorPtr& communicator, const string&, con
}
-TestPluginI::TestPluginI(const Ice::CommunicatorPtr& communicator) :
+TestPluginI::TestPluginI(const Ice::CommunicatorPtr& communicator) :
_communicator(communicator),
_configuration(new Configuration())
{
}
-
+
void
TestPluginI::initialize()
{
diff --git a/cpp/test/Ice/background/Server.cpp b/cpp/test/Ice/background/Server.cpp
index 97f8cdec5c7..1811e94a7ae 100644
--- a/cpp/test/Ice/background/Server.cpp
+++ b/cpp/test/Ice/background/Server.cpp
@@ -161,6 +161,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
Ice::registerPluginFactory("Test", createTestTransport, false);
#endif
diff --git a/cpp/test/Ice/binding/Client.cpp b/cpp/test/Ice/binding/Client.cpp
index 89654fe604f..ce2dbe2af22 100644
--- a/cpp/test/Ice/binding/Client.cpp
+++ b/cpp/test/Ice/binding/Client.cpp
@@ -28,6 +28,8 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
+ Ice::registerIceUDP(true);
# if defined(__linux)
Ice::registerIceBT(false);
# endif
diff --git a/cpp/test/Ice/binding/Server.cpp b/cpp/test/Ice/binding/Server.cpp
index 75edfceca24..11314a3f517 100644
--- a/cpp/test/Ice/binding/Server.cpp
+++ b/cpp/test/Ice/binding/Server.cpp
@@ -81,6 +81,8 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
+ Ice::registerIceUDP(true);
#endif
try
{
diff --git a/cpp/test/Ice/checksum/Client.cpp b/cpp/test/Ice/checksum/Client.cpp
index 59e98144d54..310a608c32a 100644
--- a/cpp/test/Ice/checksum/Client.cpp
+++ b/cpp/test/Ice/checksum/Client.cpp
@@ -29,6 +29,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
#endif
try
{
diff --git a/cpp/test/Ice/checksum/Server.cpp b/cpp/test/Ice/checksum/Server.cpp
index 8755cfad619..a97f968ae16 100644
--- a/cpp/test/Ice/checksum/Server.cpp
+++ b/cpp/test/Ice/checksum/Server.cpp
@@ -32,6 +32,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
#endif
try
{
diff --git a/cpp/test/Ice/custom/Client.cpp b/cpp/test/Ice/custom/Client.cpp
index 6f0dcc28692..8f295becce9 100644
--- a/cpp/test/Ice/custom/Client.cpp
+++ b/cpp/test/Ice/custom/Client.cpp
@@ -31,6 +31,7 @@ main(int argc, char** argv)
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
#endif
int status;
Ice::CommunicatorPtr communicator;
diff --git a/cpp/test/Ice/custom/Collocated.cpp b/cpp/test/Ice/custom/Collocated.cpp
index e103ff19a5d..0c1f15bc911 100644
--- a/cpp/test/Ice/custom/Collocated.cpp
+++ b/cpp/test/Ice/custom/Collocated.cpp
@@ -37,6 +37,7 @@ main(int argc, char** argv)
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
#endif
int status;
Ice::CommunicatorPtr communicator;
diff --git a/cpp/test/Ice/custom/Server.cpp b/cpp/test/Ice/custom/Server.cpp
index f9dee7d284b..1b3f7402fd8 100644
--- a/cpp/test/Ice/custom/Server.cpp
+++ b/cpp/test/Ice/custom/Server.cpp
@@ -38,6 +38,7 @@ main(int argc, char** argv)
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
#endif
int status;
Ice::CommunicatorPtr communicator;
diff --git a/cpp/test/Ice/custom/ServerAMD.cpp b/cpp/test/Ice/custom/ServerAMD.cpp
index 1c3b3acc40f..0674a73474e 100644
--- a/cpp/test/Ice/custom/ServerAMD.cpp
+++ b/cpp/test/Ice/custom/ServerAMD.cpp
@@ -38,6 +38,7 @@ main(int argc, char** argv)
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
#endif
int status;
Ice::CommunicatorPtr communicator;
diff --git a/cpp/test/Ice/defaultServant/Client.cpp b/cpp/test/Ice/defaultServant/Client.cpp
index 71e377a2d8c..030bd9f3eac 100644
--- a/cpp/test/Ice/defaultServant/Client.cpp
+++ b/cpp/test/Ice/defaultServant/Client.cpp
@@ -29,6 +29,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
#endif
try
{
diff --git a/cpp/test/Ice/dispatcher/Client.cpp b/cpp/test/Ice/dispatcher/Client.cpp
index 41e57e874dc..e7f7660661f 100644
--- a/cpp/test/Ice/dispatcher/Client.cpp
+++ b/cpp/test/Ice/dispatcher/Client.cpp
@@ -29,6 +29,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
#endif
int status;
try
diff --git a/cpp/test/Ice/dispatcher/Collocated.cpp b/cpp/test/Ice/dispatcher/Collocated.cpp
index c24f647be48..1cf5a07842b 100644
--- a/cpp/test/Ice/dispatcher/Collocated.cpp
+++ b/cpp/test/Ice/dispatcher/Collocated.cpp
@@ -44,6 +44,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
#endif
int status;
try
diff --git a/cpp/test/Ice/dispatcher/Server.cpp b/cpp/test/Ice/dispatcher/Server.cpp
index c231b212599..83efbff0d4d 100644
--- a/cpp/test/Ice/dispatcher/Server.cpp
+++ b/cpp/test/Ice/dispatcher/Server.cpp
@@ -45,6 +45,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
#endif
int status;
try
diff --git a/cpp/test/Ice/enums/Client.cpp b/cpp/test/Ice/enums/Client.cpp
index f2522289709..ea8c679c0c3 100644
--- a/cpp/test/Ice/enums/Client.cpp
+++ b/cpp/test/Ice/enums/Client.cpp
@@ -30,6 +30,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
# if defined(__linux)
Ice::registerIceBT(false);
# endif
diff --git a/cpp/test/Ice/enums/Server.cpp b/cpp/test/Ice/enums/Server.cpp
index cedf846b391..5ff07f82a49 100644
--- a/cpp/test/Ice/enums/Server.cpp
+++ b/cpp/test/Ice/enums/Server.cpp
@@ -34,6 +34,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
#endif
try
diff --git a/cpp/test/Ice/exceptions/Client.cpp b/cpp/test/Ice/exceptions/Client.cpp
index a4bc2be2efd..f0b8e2ac3f6 100644
--- a/cpp/test/Ice/exceptions/Client.cpp
+++ b/cpp/test/Ice/exceptions/Client.cpp
@@ -30,6 +30,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
# if defined(__linux)
Ice::registerIceBT(false);
# endif
diff --git a/cpp/test/Ice/exceptions/Collocated.cpp b/cpp/test/Ice/exceptions/Collocated.cpp
index 2c1fdbb519e..29f0a27e97f 100644
--- a/cpp/test/Ice/exceptions/Collocated.cpp
+++ b/cpp/test/Ice/exceptions/Collocated.cpp
@@ -35,6 +35,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
#endif
try
diff --git a/cpp/test/Ice/exceptions/Server.cpp b/cpp/test/Ice/exceptions/Server.cpp
index 2f5d9320931..b91c49d88d5 100644
--- a/cpp/test/Ice/exceptions/Server.cpp
+++ b/cpp/test/Ice/exceptions/Server.cpp
@@ -43,6 +43,8 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
+ Ice::registerIceUDP(true);
#endif
try
diff --git a/cpp/test/Ice/exceptions/ServerAMD.cpp b/cpp/test/Ice/exceptions/ServerAMD.cpp
index 5d3bcd80c60..4867fc1a6e9 100644
--- a/cpp/test/Ice/exceptions/ServerAMD.cpp
+++ b/cpp/test/Ice/exceptions/ServerAMD.cpp
@@ -43,6 +43,8 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
+ Ice::registerIceUDP(true);
#endif
try
diff --git a/cpp/test/Ice/facets/Client.cpp b/cpp/test/Ice/facets/Client.cpp
index 89d96801260..e0eb81dc61e 100644
--- a/cpp/test/Ice/facets/Client.cpp
+++ b/cpp/test/Ice/facets/Client.cpp
@@ -30,6 +30,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
# if defined(__linux)
Ice::registerIceBT(false);
# endif
diff --git a/cpp/test/Ice/facets/Collocated.cpp b/cpp/test/Ice/facets/Collocated.cpp
index bc1adf94cde..f2b066b9b62 100644
--- a/cpp/test/Ice/facets/Collocated.cpp
+++ b/cpp/test/Ice/facets/Collocated.cpp
@@ -40,6 +40,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
#endif
try
diff --git a/cpp/test/Ice/facets/Server.cpp b/cpp/test/Ice/facets/Server.cpp
index 6d174b28c52..8203115f117 100644
--- a/cpp/test/Ice/facets/Server.cpp
+++ b/cpp/test/Ice/facets/Server.cpp
@@ -39,6 +39,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
#endif
try
diff --git a/cpp/test/Ice/faultTolerance/Client.cpp b/cpp/test/Ice/faultTolerance/Client.cpp
index b91d6ce2c64..65c92960e9b 100644
--- a/cpp/test/Ice/faultTolerance/Client.cpp
+++ b/cpp/test/Ice/faultTolerance/Client.cpp
@@ -61,6 +61,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
#endif
try
diff --git a/cpp/test/Ice/faultTolerance/Server.cpp b/cpp/test/Ice/faultTolerance/Server.cpp
index dd473f41141..dd82d9deeb7 100644
--- a/cpp/test/Ice/faultTolerance/Server.cpp
+++ b/cpp/test/Ice/faultTolerance/Server.cpp
@@ -65,6 +65,8 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
+ Ice::registerIceUDP(true);
#endif
try
diff --git a/cpp/test/Ice/gc/Client.cpp b/cpp/test/Ice/gc/Client.cpp
index ff09ff5e1fe..a2238ad0f28 100644
--- a/cpp/test/Ice/gc/Client.cpp
+++ b/cpp/test/Ice/gc/Client.cpp
@@ -537,6 +537,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
#endif
MyApplication app;
return app.main(argc, argv);
diff --git a/cpp/test/Ice/hash/Client.cpp b/cpp/test/Ice/hash/Client.cpp
index 6f6203dbdff..4167fe400ff 100644
--- a/cpp/test/Ice/hash/Client.cpp
+++ b/cpp/test/Ice/hash/Client.cpp
@@ -24,6 +24,7 @@ DEFINE_TEST("client")
int main(int argc, char** argv)
{
#ifdef ICE_STATIC_LIBS
+ Ice::registerIceUDP(true);
Ice::registerIceSSL(false);
#endif
cout << "testing proxy hash algorithm collisions... " << flush;
diff --git a/cpp/test/Ice/hold/Client.cpp b/cpp/test/Ice/hold/Client.cpp
index 2fbb146ec3e..a9f227144ef 100644
--- a/cpp/test/Ice/hold/Client.cpp
+++ b/cpp/test/Ice/hold/Client.cpp
@@ -29,6 +29,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
# if defined(__linux)
Ice::registerIceBT(false);
# endif
diff --git a/cpp/test/Ice/hold/Server.cpp b/cpp/test/Ice/hold/Server.cpp
index b64acaa0b28..67d03dc1890 100644
--- a/cpp/test/Ice/hold/Server.cpp
+++ b/cpp/test/Ice/hold/Server.cpp
@@ -53,6 +53,8 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
+ Ice::registerIceUDP(true);
#endif
try
{
diff --git a/cpp/test/Ice/impl/Server.cpp b/cpp/test/Ice/impl/Server.cpp
index 1cfc5f4d4fa..d10beeb0c75 100644
--- a/cpp/test/Ice/impl/Server.cpp
+++ b/cpp/test/Ice/impl/Server.cpp
@@ -34,6 +34,8 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
+ Ice::registerIceUDP(true);
#endif
try
diff --git a/cpp/test/Ice/impl/ServerAMD.cpp b/cpp/test/Ice/impl/ServerAMD.cpp
index c9e1518cb6c..f76947be7de 100644
--- a/cpp/test/Ice/impl/ServerAMD.cpp
+++ b/cpp/test/Ice/impl/ServerAMD.cpp
@@ -34,6 +34,8 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
+ Ice::registerIceUDP(true);
#endif
try
diff --git a/cpp/test/Ice/info/Client.cpp b/cpp/test/Ice/info/Client.cpp
index 840b96d0def..d7aafce2256 100644
--- a/cpp/test/Ice/info/Client.cpp
+++ b/cpp/test/Ice/info/Client.cpp
@@ -28,6 +28,8 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
+ Ice::registerIceUDP(true);
#endif
try
diff --git a/cpp/test/Ice/info/Server.cpp b/cpp/test/Ice/info/Server.cpp
index 38f9b5f3a6e..80772d12461 100644
--- a/cpp/test/Ice/info/Server.cpp
+++ b/cpp/test/Ice/info/Server.cpp
@@ -33,6 +33,8 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
+ Ice::registerIceUDP(true);
#endif
try
diff --git a/cpp/test/Ice/inheritance/Client.cpp b/cpp/test/Ice/inheritance/Client.cpp
index b91b542333f..f0b767295d7 100644
--- a/cpp/test/Ice/inheritance/Client.cpp
+++ b/cpp/test/Ice/inheritance/Client.cpp
@@ -30,6 +30,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
# if defined(__linux)
Ice::registerIceBT(false);
# endif
diff --git a/cpp/test/Ice/inheritance/Collocated.cpp b/cpp/test/Ice/inheritance/Collocated.cpp
index 13d8d7076c1..38e7c0e4644 100644
--- a/cpp/test/Ice/inheritance/Collocated.cpp
+++ b/cpp/test/Ice/inheritance/Collocated.cpp
@@ -35,6 +35,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
#endif
try
diff --git a/cpp/test/Ice/inheritance/Server.cpp b/cpp/test/Ice/inheritance/Server.cpp
index b8baedf80ec..d26b3edff8c 100644
--- a/cpp/test/Ice/inheritance/Server.cpp
+++ b/cpp/test/Ice/inheritance/Server.cpp
@@ -33,6 +33,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
#endif
try
diff --git a/cpp/test/Ice/interceptor/Client.cpp b/cpp/test/Ice/interceptor/Client.cpp
index bb1fe439030..cf2497ae791 100644
--- a/cpp/test/Ice/interceptor/Client.cpp
+++ b/cpp/test/Ice/interceptor/Client.cpp
@@ -94,6 +94,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
#endif
#ifndef _WIN32
diff --git a/cpp/test/Ice/invoke/Client.cpp b/cpp/test/Ice/invoke/Client.cpp
index 644ff8d17f8..2a443e6c260 100644
--- a/cpp/test/Ice/invoke/Client.cpp
+++ b/cpp/test/Ice/invoke/Client.cpp
@@ -33,6 +33,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
#endif
int status;
diff --git a/cpp/test/Ice/invoke/Server.cpp b/cpp/test/Ice/invoke/Server.cpp
index 8ede7fc952c..de3904b9fa0 100644
--- a/cpp/test/Ice/invoke/Server.cpp
+++ b/cpp/test/Ice/invoke/Server.cpp
@@ -116,6 +116,8 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
+ Ice::registerIceUDP(true);
#endif
int status;
diff --git a/cpp/test/Ice/location/Client.cpp b/cpp/test/Ice/location/Client.cpp
index ea763b0e6ba..b70b8565e68 100644
--- a/cpp/test/Ice/location/Client.cpp
+++ b/cpp/test/Ice/location/Client.cpp
@@ -28,6 +28,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
#endif
try
{
diff --git a/cpp/test/Ice/location/Server.cpp b/cpp/test/Ice/location/Server.cpp
index 113963498b7..ac3958edcfc 100644
--- a/cpp/test/Ice/location/Server.cpp
+++ b/cpp/test/Ice/location/Server.cpp
@@ -59,6 +59,8 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
+ Ice::registerIceUDP(true);
#endif
try
{
diff --git a/cpp/test/Ice/logger/Client1.cpp b/cpp/test/Ice/logger/Client1.cpp
index 80a25af446b..af91a5e864a 100644
--- a/cpp/test/Ice/logger/Client1.cpp
+++ b/cpp/test/Ice/logger/Client1.cpp
@@ -34,6 +34,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
#endif
cout << "testing logger encoding with Ice.LogFile... " << flush;
diff --git a/cpp/test/Ice/logger/Client2.cpp b/cpp/test/Ice/logger/Client2.cpp
index 6072f6b2032..311df0e169b 100644
--- a/cpp/test/Ice/logger/Client2.cpp
+++ b/cpp/test/Ice/logger/Client2.cpp
@@ -34,6 +34,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
#endif
#ifdef _WIN32
diff --git a/cpp/test/Ice/logger/Client3.cpp b/cpp/test/Ice/logger/Client3.cpp
index d78bf03787b..1e0301b41c8 100644
--- a/cpp/test/Ice/logger/Client3.cpp
+++ b/cpp/test/Ice/logger/Client3.cpp
@@ -33,6 +33,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
#endif
#ifdef _WIN32
diff --git a/cpp/test/Ice/logger/Client4.cpp b/cpp/test/Ice/logger/Client4.cpp
index f290a9d9cae..cfb9f365beb 100644
--- a/cpp/test/Ice/logger/Client4.cpp
+++ b/cpp/test/Ice/logger/Client4.cpp
@@ -33,6 +33,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
#endif
#ifdef _WIN32
diff --git a/cpp/test/Ice/logger/Client5.cpp b/cpp/test/Ice/logger/Client5.cpp
index 0039d04f440..fa178f83e87 100644
--- a/cpp/test/Ice/logger/Client5.cpp
+++ b/cpp/test/Ice/logger/Client5.cpp
@@ -52,6 +52,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
#endif
//
diff --git a/cpp/test/Ice/metrics/Client.cpp b/cpp/test/Ice/metrics/Client.cpp
index 60aa32443b2..77b498ed021 100644
--- a/cpp/test/Ice/metrics/Client.cpp
+++ b/cpp/test/Ice/metrics/Client.cpp
@@ -31,6 +31,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
#endif
try
{
diff --git a/cpp/test/Ice/metrics/Collocated.cpp b/cpp/test/Ice/metrics/Collocated.cpp
index b585cacac81..45ecb026590 100644
--- a/cpp/test/Ice/metrics/Collocated.cpp
+++ b/cpp/test/Ice/metrics/Collocated.cpp
@@ -41,6 +41,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
#endif
try
{
diff --git a/cpp/test/Ice/metrics/Server.cpp b/cpp/test/Ice/metrics/Server.cpp
index 244aa323373..fc6a73aab82 100644
--- a/cpp/test/Ice/metrics/Server.cpp
+++ b/cpp/test/Ice/metrics/Server.cpp
@@ -39,6 +39,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
#endif
try
{
diff --git a/cpp/test/Ice/metrics/ServerAMD.cpp b/cpp/test/Ice/metrics/ServerAMD.cpp
index 28311907478..032ea4157f3 100644
--- a/cpp/test/Ice/metrics/ServerAMD.cpp
+++ b/cpp/test/Ice/metrics/ServerAMD.cpp
@@ -39,6 +39,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
#endif
try
{
diff --git a/cpp/test/Ice/networkProxy/Client.cpp b/cpp/test/Ice/networkProxy/Client.cpp
index 97a854d2206..f84333e6437 100644
--- a/cpp/test/Ice/networkProxy/Client.cpp
+++ b/cpp/test/Ice/networkProxy/Client.cpp
@@ -28,6 +28,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
#endif
try
diff --git a/cpp/test/Ice/networkProxy/Server.cpp b/cpp/test/Ice/networkProxy/Server.cpp
index 5e11804309b..c3e54278479 100644
--- a/cpp/test/Ice/networkProxy/Server.cpp
+++ b/cpp/test/Ice/networkProxy/Server.cpp
@@ -49,6 +49,8 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
+ Ice::registerIceUDP(true);
#endif
try
diff --git a/cpp/test/Ice/objects/Client.cpp b/cpp/test/Ice/objects/Client.cpp
index 2a95bd4d2a6..dbd9b96d9cb 100644
--- a/cpp/test/Ice/objects/Client.cpp
+++ b/cpp/test/Ice/objects/Client.cpp
@@ -154,6 +154,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
# if defined(__linux)
Ice::registerIceBT(false);
# endif
diff --git a/cpp/test/Ice/objects/Collocated.cpp b/cpp/test/Ice/objects/Collocated.cpp
index f1bebd7822e..272642b4f0e 100644
--- a/cpp/test/Ice/objects/Collocated.cpp
+++ b/cpp/test/Ice/objects/Collocated.cpp
@@ -149,6 +149,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
#endif
try
diff --git a/cpp/test/Ice/objects/Server.cpp b/cpp/test/Ice/objects/Server.cpp
index a501281b29b..30a0d0e983a 100644
--- a/cpp/test/Ice/objects/Server.cpp
+++ b/cpp/test/Ice/objects/Server.cpp
@@ -83,6 +83,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
#endif
try
diff --git a/cpp/test/Ice/operations/Client.cpp b/cpp/test/Ice/operations/Client.cpp
index 39be98045c0..42400fba036 100644
--- a/cpp/test/Ice/operations/Client.cpp
+++ b/cpp/test/Ice/operations/Client.cpp
@@ -44,6 +44,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
# if defined(__linux)
Ice::registerIceBT(false);
# endif
diff --git a/cpp/test/Ice/operations/Collocated.cpp b/cpp/test/Ice/operations/Collocated.cpp
index 8d644244088..551d903bd57 100644
--- a/cpp/test/Ice/operations/Collocated.cpp
+++ b/cpp/test/Ice/operations/Collocated.cpp
@@ -37,6 +37,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
#endif
try
diff --git a/cpp/test/Ice/operations/Server.cpp b/cpp/test/Ice/operations/Server.cpp
index d65d9a15ce9..5a2eb27c72f 100644
--- a/cpp/test/Ice/operations/Server.cpp
+++ b/cpp/test/Ice/operations/Server.cpp
@@ -33,6 +33,8 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
+ Ice::registerIceUDP(true);
#endif
try
diff --git a/cpp/test/Ice/operations/ServerAMD.cpp b/cpp/test/Ice/operations/ServerAMD.cpp
index a1152339aca..1c59c905669 100644
--- a/cpp/test/Ice/operations/ServerAMD.cpp
+++ b/cpp/test/Ice/operations/ServerAMD.cpp
@@ -33,6 +33,8 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
+ Ice::registerIceUDP(true);
#endif
try
diff --git a/cpp/test/Ice/optional/Client.cpp b/cpp/test/Ice/optional/Client.cpp
index fa787ddb285..26c9caf3f92 100644
--- a/cpp/test/Ice/optional/Client.cpp
+++ b/cpp/test/Ice/optional/Client.cpp
@@ -30,6 +30,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
# if defined(__linux)
Ice::registerIceBT(false);
# endif
diff --git a/cpp/test/Ice/optional/Server.cpp b/cpp/test/Ice/optional/Server.cpp
index fe4b61813bf..c6d5af8cd9e 100644
--- a/cpp/test/Ice/optional/Server.cpp
+++ b/cpp/test/Ice/optional/Server.cpp
@@ -33,6 +33,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
#endif
int status;
diff --git a/cpp/test/Ice/optional/ServerAMD.cpp b/cpp/test/Ice/optional/ServerAMD.cpp
index 29bd777c0eb..5514ccb61b7 100644
--- a/cpp/test/Ice/optional/ServerAMD.cpp
+++ b/cpp/test/Ice/optional/ServerAMD.cpp
@@ -32,6 +32,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
#endif
int status;
diff --git a/cpp/test/Ice/properties/Client.cpp b/cpp/test/Ice/properties/Client.cpp
index 3b8f6c5d844..191e312ee6d 100644
--- a/cpp/test/Ice/properties/Client.cpp
+++ b/cpp/test/Ice/properties/Client.cpp
@@ -41,6 +41,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
#endif
ifstream in("./config/configPath");
diff --git a/cpp/test/Ice/proxy/Client.cpp b/cpp/test/Ice/proxy/Client.cpp
index 9d58f1c3279..612b12c56ca 100644
--- a/cpp/test/Ice/proxy/Client.cpp
+++ b/cpp/test/Ice/proxy/Client.cpp
@@ -31,6 +31,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
# if defined(__linux)
Ice::registerIceBT(false);
# endif
diff --git a/cpp/test/Ice/proxy/Collocated.cpp b/cpp/test/Ice/proxy/Collocated.cpp
index bba4295d3cb..d21086c95df 100644
--- a/cpp/test/Ice/proxy/Collocated.cpp
+++ b/cpp/test/Ice/proxy/Collocated.cpp
@@ -34,6 +34,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
#endif
try
diff --git a/cpp/test/Ice/proxy/Server.cpp b/cpp/test/Ice/proxy/Server.cpp
index bbf40844c93..5d474b53e8e 100644
--- a/cpp/test/Ice/proxy/Server.cpp
+++ b/cpp/test/Ice/proxy/Server.cpp
@@ -32,6 +32,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
#endif
try
diff --git a/cpp/test/Ice/proxy/ServerAMD.cpp b/cpp/test/Ice/proxy/ServerAMD.cpp
index 78cff3f0e18..0785dd1e652 100644
--- a/cpp/test/Ice/proxy/ServerAMD.cpp
+++ b/cpp/test/Ice/proxy/ServerAMD.cpp
@@ -32,6 +32,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
#endif
try
diff --git a/cpp/test/Ice/retry/Client.cpp b/cpp/test/Ice/retry/Client.cpp
index 858b343bd0b..b8dba358c3d 100644
--- a/cpp/test/Ice/retry/Client.cpp
+++ b/cpp/test/Ice/retry/Client.cpp
@@ -31,6 +31,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
#endif
try
{
diff --git a/cpp/test/Ice/retry/Collocated.cpp b/cpp/test/Ice/retry/Collocated.cpp
index c601ae0d7ac..2ace05b3da4 100644
--- a/cpp/test/Ice/retry/Collocated.cpp
+++ b/cpp/test/Ice/retry/Collocated.cpp
@@ -43,6 +43,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
#endif
try
{
diff --git a/cpp/test/Ice/retry/Server.cpp b/cpp/test/Ice/retry/Server.cpp
index 313756bf338..e3f98923f21 100644
--- a/cpp/test/Ice/retry/Server.cpp
+++ b/cpp/test/Ice/retry/Server.cpp
@@ -32,6 +32,8 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
+ Ice::registerIceUDP(true);
#endif
int status = EXIT_FAILURE;
try
diff --git a/cpp/test/Ice/servantLocator/Client.cpp b/cpp/test/Ice/servantLocator/Client.cpp
index 7a124be08ba..7fc67891adc 100644
--- a/cpp/test/Ice/servantLocator/Client.cpp
+++ b/cpp/test/Ice/servantLocator/Client.cpp
@@ -30,6 +30,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
# if defined(__linux)
Ice::registerIceBT(false);
# endif
diff --git a/cpp/test/Ice/servantLocator/Collocated.cpp b/cpp/test/Ice/servantLocator/Collocated.cpp
index 1b2057cebf3..7def79a66ba 100644
--- a/cpp/test/Ice/servantLocator/Collocated.cpp
+++ b/cpp/test/Ice/servantLocator/Collocated.cpp
@@ -110,6 +110,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
#endif
try
{
diff --git a/cpp/test/Ice/servantLocator/Server.cpp b/cpp/test/Ice/servantLocator/Server.cpp
index 113159d83fb..f9f61f45011 100644
--- a/cpp/test/Ice/servantLocator/Server.cpp
+++ b/cpp/test/Ice/servantLocator/Server.cpp
@@ -110,6 +110,8 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
+ Ice::registerIceUDP(true);
#endif
try
{
diff --git a/cpp/test/Ice/servantLocator/ServerAMD.cpp b/cpp/test/Ice/servantLocator/ServerAMD.cpp
index 5e1730395d5..32b827f3c4a 100644
--- a/cpp/test/Ice/servantLocator/ServerAMD.cpp
+++ b/cpp/test/Ice/servantLocator/ServerAMD.cpp
@@ -109,6 +109,8 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
+ Ice::registerIceUDP(true);
#endif
try
{
diff --git a/cpp/test/Ice/services/Client.cpp b/cpp/test/Ice/services/Client.cpp
index c65f2082994..41d7ac6038c 100644
--- a/cpp/test/Ice/services/Client.cpp
+++ b/cpp/test/Ice/services/Client.cpp
@@ -29,6 +29,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
#endif
try
diff --git a/cpp/test/Ice/slicing/exceptions/Client.cpp b/cpp/test/Ice/slicing/exceptions/Client.cpp
index c83c4f179d3..f9c54def90a 100644
--- a/cpp/test/Ice/slicing/exceptions/Client.cpp
+++ b/cpp/test/Ice/slicing/exceptions/Client.cpp
@@ -30,6 +30,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
# if defined(__linux)
Ice::registerIceBT(false);
# endif
diff --git a/cpp/test/Ice/slicing/exceptions/Server.cpp b/cpp/test/Ice/slicing/exceptions/Server.cpp
index 27e18bbccd0..0d7d0dee6ab 100644
--- a/cpp/test/Ice/slicing/exceptions/Server.cpp
+++ b/cpp/test/Ice/slicing/exceptions/Server.cpp
@@ -34,6 +34,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
#endif
try
{
diff --git a/cpp/test/Ice/slicing/exceptions/ServerAMD.cpp b/cpp/test/Ice/slicing/exceptions/ServerAMD.cpp
index 671a165298f..663ad27abd6 100644
--- a/cpp/test/Ice/slicing/exceptions/ServerAMD.cpp
+++ b/cpp/test/Ice/slicing/exceptions/ServerAMD.cpp
@@ -34,6 +34,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
#endif
try
{
diff --git a/cpp/test/Ice/slicing/objects/Client.cpp b/cpp/test/Ice/slicing/objects/Client.cpp
index 010bc283d07..b7c6cd053e5 100644
--- a/cpp/test/Ice/slicing/objects/Client.cpp
+++ b/cpp/test/Ice/slicing/objects/Client.cpp
@@ -30,6 +30,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
# if defined(__linux)
Ice::registerIceBT(false);
# endif
diff --git a/cpp/test/Ice/slicing/objects/Server.cpp b/cpp/test/Ice/slicing/objects/Server.cpp
index bfda78a59e1..d5f04076f98 100644
--- a/cpp/test/Ice/slicing/objects/Server.cpp
+++ b/cpp/test/Ice/slicing/objects/Server.cpp
@@ -35,6 +35,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
#endif
try
diff --git a/cpp/test/Ice/slicing/objects/ServerAMD.cpp b/cpp/test/Ice/slicing/objects/ServerAMD.cpp
index 9d466606cd4..c78e3e4fe4f 100644
--- a/cpp/test/Ice/slicing/objects/ServerAMD.cpp
+++ b/cpp/test/Ice/slicing/objects/ServerAMD.cpp
@@ -35,6 +35,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
#endif
try
diff --git a/cpp/test/Ice/stream/Client.cpp b/cpp/test/Ice/stream/Client.cpp
index 0f3e74f3e99..7a7654af2d2 100644
--- a/cpp/test/Ice/stream/Client.cpp
+++ b/cpp/test/Ice/stream/Client.cpp
@@ -1333,6 +1333,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
#endif
int status;
diff --git a/cpp/test/Ice/stringConverter/Client.cpp b/cpp/test/Ice/stringConverter/Client.cpp
index 248669edaf1..b0315f80854 100644
--- a/cpp/test/Ice/stringConverter/Client.cpp
+++ b/cpp/test/Ice/stringConverter/Client.cpp
@@ -26,6 +26,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
Ice::registerIceStringConverter(false);
#endif
diff --git a/cpp/test/Ice/stringConverter/Server.cpp b/cpp/test/Ice/stringConverter/Server.cpp
index 59681ba73bb..9565ec4d6fc 100644
--- a/cpp/test/Ice/stringConverter/Server.cpp
+++ b/cpp/test/Ice/stringConverter/Server.cpp
@@ -58,6 +58,8 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
+ Ice::registerIceUDP(true);
#endif
int status;
diff --git a/cpp/test/Ice/threadPoolPriority/Client.cpp b/cpp/test/Ice/threadPoolPriority/Client.cpp
index 26d2734a716..dadb73fe23c 100644
--- a/cpp/test/Ice/threadPoolPriority/Client.cpp
+++ b/cpp/test/Ice/threadPoolPriority/Client.cpp
@@ -29,6 +29,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
#endif
int status;
diff --git a/cpp/test/Ice/threadPoolPriority/Server.cpp b/cpp/test/Ice/threadPoolPriority/Server.cpp
index 1f6efb8a1aa..7d959092541 100644
--- a/cpp/test/Ice/threadPoolPriority/Server.cpp
+++ b/cpp/test/Ice/threadPoolPriority/Server.cpp
@@ -60,6 +60,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
#endif
int status;
diff --git a/cpp/test/Ice/threadPoolPriority/ServerCustomThreadPool.cpp b/cpp/test/Ice/threadPoolPriority/ServerCustomThreadPool.cpp
index d23f6e5a2da..18995e991a5 100644
--- a/cpp/test/Ice/threadPoolPriority/ServerCustomThreadPool.cpp
+++ b/cpp/test/Ice/threadPoolPriority/ServerCustomThreadPool.cpp
@@ -64,6 +64,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
#endif
int status;
diff --git a/cpp/test/Ice/timeout/Client.cpp b/cpp/test/Ice/timeout/Client.cpp
index fa04fa82273..848f87d1e80 100644
--- a/cpp/test/Ice/timeout/Client.cpp
+++ b/cpp/test/Ice/timeout/Client.cpp
@@ -30,6 +30,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
#endif
try
diff --git a/cpp/test/Ice/timeout/Server.cpp b/cpp/test/Ice/timeout/Server.cpp
index 0ba881f58de..f870738ad6e 100644
--- a/cpp/test/Ice/timeout/Server.cpp
+++ b/cpp/test/Ice/timeout/Server.cpp
@@ -34,6 +34,8 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
+ Ice::registerIceUDP(true);
#endif
try
diff --git a/cpp/test/Ice/udp/Client.cpp b/cpp/test/Ice/udp/Client.cpp
index c45a2678814..342b3ad5af6 100644
--- a/cpp/test/Ice/udp/Client.cpp
+++ b/cpp/test/Ice/udp/Client.cpp
@@ -37,6 +37,8 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
+ Ice::registerIceUDP(true);
#endif
try
diff --git a/cpp/test/Ice/udp/Server.cpp b/cpp/test/Ice/udp/Server.cpp
index 824fc9c1daa..7cbc9ed1e99 100644
--- a/cpp/test/Ice/udp/Server.cpp
+++ b/cpp/test/Ice/udp/Server.cpp
@@ -66,6 +66,8 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
+ Ice::registerIceUDP(true);
#endif
try
diff --git a/cpp/test/IceDiscovery/simple/Client.cpp b/cpp/test/IceDiscovery/simple/Client.cpp
index e31835348fa..bd03470f4d7 100644
--- a/cpp/test/IceDiscovery/simple/Client.cpp
+++ b/cpp/test/IceDiscovery/simple/Client.cpp
@@ -31,6 +31,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL();
+ Ice::registerIceWS();
#endif
//
// Explicitly register the IceDiscovery plugin to test registerIceDiscovery.
diff --git a/cpp/test/IceDiscovery/simple/Server.cpp b/cpp/test/IceDiscovery/simple/Server.cpp
index bda0aa5476f..8b58a1f65e4 100644
--- a/cpp/test/IceDiscovery/simple/Server.cpp
+++ b/cpp/test/IceDiscovery/simple/Server.cpp
@@ -52,6 +52,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL();
+ Ice::registerIceWS();
Ice::registerIceDiscovery();
#endif
diff --git a/cpp/test/IceGrid/simple/Client.cpp b/cpp/test/IceGrid/simple/Client.cpp
index 3b31fe83612..866ea63d943 100644
--- a/cpp/test/IceGrid/simple/Client.cpp
+++ b/cpp/test/IceGrid/simple/Client.cpp
@@ -48,6 +48,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
Ice::registerIceLocatorDiscovery(false);
#endif
int status;
diff --git a/cpp/test/IceGrid/simple/Server.cpp b/cpp/test/IceGrid/simple/Server.cpp
index 2eeeac34ef6..57f57c582f9 100644
--- a/cpp/test/IceGrid/simple/Server.cpp
+++ b/cpp/test/IceGrid/simple/Server.cpp
@@ -50,6 +50,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
#endif
Server app;
int rc = app.main(argc, argv);
diff --git a/cpp/test/IceSSL/configuration/Client.cpp b/cpp/test/IceSSL/configuration/Client.cpp
index 1e416a55e57..f90c13ae59a 100644
--- a/cpp/test/IceSSL/configuration/Client.cpp
+++ b/cpp/test/IceSSL/configuration/Client.cpp
@@ -73,6 +73,10 @@ main(int argc, char* argv[])
Ice::registerIceSSL();
#endif
+#ifdef ICE_STATIC_LIBS
+ Ice::registerIceWS(true);
+#endif
+
int status;
Ice::CommunicatorPtr communicator;
diff --git a/cpp/test/IceSSL/configuration/Server.cpp b/cpp/test/IceSSL/configuration/Server.cpp
index b8308cd89ba..5d9d1eb76cb 100644
--- a/cpp/test/IceSSL/configuration/Server.cpp
+++ b/cpp/test/IceSSL/configuration/Server.cpp
@@ -49,6 +49,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL(false);
+ Ice::registerIceWS(true);
#endif
int status;
diff --git a/csharp/src/Ice/EndpointFactory.cs b/csharp/src/Ice/EndpointFactory.cs
index 3bc4e979ea4..225cf374a15 100644
--- a/csharp/src/Ice/EndpointFactory.cs
+++ b/csharp/src/Ice/EndpointFactory.cs
@@ -13,13 +13,88 @@ namespace IceInternal
public interface EndpointFactory
{
+ void initialize();
short type();
string protocol();
EndpointI create(List<string> args, bool oaEndpoint);
EndpointI read(Ice.InputStream s);
void destroy();
- EndpointFactory clone(ProtocolInstance instance, EndpointFactory del);
+ EndpointFactory clone(ProtocolInstance instance);
}
+ abstract public class EndpointFactoryWithUnderlying : EndpointFactory
+ {
+ public EndpointFactoryWithUnderlying(ProtocolInstance instance, short type)
+ {
+ instance_ = instance;
+ _type = type;
+ }
+
+ public void initialize()
+ {
+ //
+ // Get the endpoint factory for the underlying type and clone it with
+ // our protocol instance.
+ //
+ EndpointFactory factory = instance_.getEndpointFactory(_type);
+ if(factory != null)
+ {
+ _underlying = factory.clone(instance_);
+ _underlying.initialize();
+ }
+ }
+
+ public short type()
+ {
+ return instance_.type();
+ }
+
+ public string protocol()
+ {
+ return instance_.protocol();
+ }
+
+ public EndpointI create(List<string> args, bool oaEndpoint)
+ {
+ if(_underlying == null)
+ {
+ return null; // Can't create an endpoint without underlying factory.
+ }
+ return createWithUnderlying(_underlying.create(args, oaEndpoint), args, oaEndpoint);
+ }
+
+ public EndpointI read(Ice.InputStream s)
+ {
+ if(_underlying == null)
+ {
+ return null; // Can't create an endpoint without underlying factory.
+ }
+ return readWithUnderlying(_underlying.read(s), s);
+ }
+
+ public void destroy()
+ {
+ if(_underlying != null)
+ {
+ _underlying.destroy();
+ }
+ instance_ = null;
+ }
+
+ public EndpointFactory clone(ProtocolInstance instance)
+ {
+ return cloneWithUnderlying(instance, _type);
+ }
+
+ abstract public EndpointFactory cloneWithUnderlying(ProtocolInstance instance, short type);
+
+ abstract protected EndpointI createWithUnderlying(EndpointI underlying, List<string> args, bool oaEndpoint);
+ abstract protected EndpointI readWithUnderlying(EndpointI underlying, Ice.InputStream s);
+
+ protected ProtocolInstance instance_;
+
+ private readonly short _type;
+ private EndpointFactory _underlying;
+ }
}
diff --git a/csharp/src/Ice/EndpointFactoryManager.cs b/csharp/src/Ice/EndpointFactoryManager.cs
index 7dc55c990b5..73c31e557aa 100644
--- a/csharp/src/Ice/EndpointFactoryManager.cs
+++ b/csharp/src/Ice/EndpointFactoryManager.cs
@@ -20,13 +20,20 @@ namespace IceInternal
_factories = new List<EndpointFactory>();
}
+ public void initialize()
+ {
+ foreach(EndpointFactory f in _factories)
+ {
+ f.initialize();
+ }
+ }
+
public void add(EndpointFactory factory)
{
lock(this)
{
- for(int i = 0; i < _factories.Count; i++)
+ foreach(EndpointFactory f in _factories)
{
- EndpointFactory f = _factories[i];
if(f.type() == factory.type())
{
Debug.Assert(false);
@@ -40,9 +47,8 @@ namespace IceInternal
{
lock(this)
{
- for(int i = 0; i < _factories.Count; i++)
+ foreach(EndpointFactory f in _factories)
{
- EndpointFactory f = _factories[i];
if(f.type() == type)
{
return f;
@@ -173,7 +179,13 @@ namespace IceInternal
{
e = factory.read(s);
}
- else
+ //
+ // If the factory failed to read the endpoint, return an opaque endpoint. This can
+ // occur if for example the factory delegates to another factory and this factory
+ // isn't available. In this case, the factory needs to make sure the stream position
+ // is preserved for reading the opaque endpoint.
+ //
+ if(e == null)
{
e = new OpaqueEndpointI(type, s);
}
@@ -186,9 +198,8 @@ namespace IceInternal
internal void destroy()
{
- for(int i = 0; i < _factories.Count; i++)
+ foreach(EndpointFactory f in _factories)
{
- EndpointFactory f = (EndpointFactory)_factories[i];
f.destroy();
}
_factories.Clear();
diff --git a/csharp/src/Ice/Instance.cs b/csharp/src/Ice/Instance.cs
index 423b24b96d2..63d3b232a70 100644
--- a/csharp/src/Ice/Instance.cs
+++ b/csharp/src/Ice/Instance.cs
@@ -937,6 +937,13 @@ namespace IceInternal
ProtocolInstance udpInstance = new ProtocolInstance(this, Ice.UDPEndpointType.value, "udp", false);
_endpointFactoryManager.add(new UdpEndpointFactory(udpInstance));
+
+ ProtocolInstance wsInstance = new ProtocolInstance(this, Ice.WSEndpointType.value, "ws", false);
+ _endpointFactoryManager.add(new WSEndpointFactory(wsInstance, Ice.TCPEndpointType.value));
+
+ ProtocolInstance wssInstance = new ProtocolInstance(this, Ice.WSSEndpointType.value, "wss", true);
+ _endpointFactoryManager.add(new WSEndpointFactory(wssInstance, Ice.SSLEndpointType.value));
+
_pluginManager = new Ice.PluginManagerI(communicator);
if(_initData.valueFactoryManager == null)
@@ -983,20 +990,10 @@ namespace IceInternal
pluginManagerImpl.loadPlugins(ref args);
//
- // Add WS and WSS endpoint factories if TCP/SSL factories are installed.
+ // Initialize the endpoint factories once all the plugins are loaded. This gives
+ // the opportunity for the endpoint factories to find underyling factories.
//
- EndpointFactory tcpFactory = _endpointFactoryManager.get(Ice.TCPEndpointType.value);
- if(tcpFactory != null)
- {
- ProtocolInstance instance = new ProtocolInstance(this, Ice.WSEndpointType.value, "ws", false);
- _endpointFactoryManager.add(new WSEndpointFactory(instance, tcpFactory.clone(instance, null)));
- }
- EndpointFactory sslFactory = _endpointFactoryManager.get(Ice.SSLEndpointType.value);
- if(sslFactory != null)
- {
- ProtocolInstance instance = new ProtocolInstance(this, Ice.WSSEndpointType.value, "wss", true);
- _endpointFactoryManager.add(new WSEndpointFactory(instance, sslFactory.clone(instance, null)));
- }
+ _endpointFactoryManager.initialize();
//
// Create Admin facets, if enabled.
diff --git a/csharp/src/Ice/ProtocolInstance.cs b/csharp/src/Ice/ProtocolInstance.cs
index 6cd500e44f1..83b843eefbc 100644
--- a/csharp/src/Ice/ProtocolInstance.cs
+++ b/csharp/src/Ice/ProtocolInstance.cs
@@ -52,6 +52,11 @@ namespace IceInternal
return logger_;
}
+ public EndpointFactory getEndpointFactory(short type)
+ {
+ return instance_.endpointFactoryManager().get(type);
+ }
+
public string protocol()
{
return protocol_;
diff --git a/csharp/src/Ice/TcpEndpointI.cs b/csharp/src/Ice/TcpEndpointI.cs
index 0f0e7d628ac..9d6f7c6b6af 100644
--- a/csharp/src/Ice/TcpEndpointI.cs
+++ b/csharp/src/Ice/TcpEndpointI.cs
@@ -299,6 +299,10 @@ namespace IceInternal
_instance = instance;
}
+ public void initialize()
+ {
+ }
+
public short type()
{
return _instance.type();
@@ -326,7 +330,7 @@ namespace IceInternal
_instance = null;
}
- public EndpointFactory clone(ProtocolInstance instance, EndpointFactory del)
+ public EndpointFactory clone(ProtocolInstance instance)
{
return new TcpEndpointFactory(instance);
}
diff --git a/csharp/src/Ice/UdpEndpointI.cs b/csharp/src/Ice/UdpEndpointI.cs
index 45a9adcf6e6..45dd6199f14 100644
--- a/csharp/src/Ice/UdpEndpointI.cs
+++ b/csharp/src/Ice/UdpEndpointI.cs
@@ -436,6 +436,10 @@ namespace IceInternal
_instance = instance;
}
+ public void initialize()
+ {
+ }
+
public short type()
{
return _instance.type();
@@ -463,7 +467,7 @@ namespace IceInternal
_instance = null;
}
- public EndpointFactory clone(ProtocolInstance instance, EndpointFactory del)
+ public EndpointFactory clone(ProtocolInstance instance)
{
return new UdpEndpointFactory(instance);
}
diff --git a/csharp/src/Ice/WSEndpoint.cs b/csharp/src/Ice/WSEndpoint.cs
index 2749388f585..ef6df9486e8 100644
--- a/csharp/src/Ice/WSEndpoint.cs
+++ b/csharp/src/Ice/WSEndpoint.cs
@@ -342,46 +342,25 @@ namespace IceInternal
private string _resource;
}
- public class WSEndpointFactory : EndpointFactory
+ public class WSEndpointFactory : EndpointFactoryWithUnderlying
{
- public WSEndpointFactory(ProtocolInstance instance, EndpointFactory del)
+ public WSEndpointFactory(ProtocolInstance instance, short type) : base(instance, type)
{
- _instance = instance;
- _delegate = del;
}
- public short type()
+ override public EndpointFactory cloneWithUnderlying(ProtocolInstance instance, short underlying)
{
- return _instance.type();
+ return new WSEndpointFactory(instance, underlying);
}
- public string protocol()
+ override protected EndpointI createWithUnderlying(EndpointI underlying, List<string> args, bool oaEndpoint)
{
- return _instance.protocol();
+ return new WSEndpoint(instance_, underlying, args);
}
- public EndpointI create(List<string> args, bool oaEndpoint)
+ override protected EndpointI readWithUnderlying(EndpointI underlying, Ice.InputStream s)
{
- return new WSEndpoint(_instance, _delegate.create(args, oaEndpoint), args);
+ return new WSEndpoint(instance_, underlying, s);
}
-
- public EndpointI read(Ice.InputStream s)
- {
- return new WSEndpoint(_instance, _delegate.read(s), s);
- }
-
- public void destroy()
- {
- _delegate.destroy();
- _instance = null;
- }
-
- public EndpointFactory clone(ProtocolInstance instance, EndpointFactory del)
- {
- return new WSEndpointFactory(instance, del);
- }
-
- private ProtocolInstance _instance;
- private EndpointFactory _delegate;
}
}
diff --git a/csharp/src/IceSSL/EndpointI.cs b/csharp/src/IceSSL/EndpointI.cs
index 13028f96428..3ed47be71e0 100644
--- a/csharp/src/IceSSL/EndpointI.cs
+++ b/csharp/src/IceSSL/EndpointI.cs
@@ -267,48 +267,31 @@ namespace IceSSL
private IceInternal.EndpointI _delegate;
}
- internal sealed class EndpointFactoryI : IceInternal.EndpointFactory
+ internal sealed class EndpointFactoryI : IceInternal.EndpointFactoryWithUnderlying
{
- internal EndpointFactoryI(Instance instance, IceInternal.EndpointFactory del)
+ public EndpointFactoryI(Instance instance, short type) : base(instance, type)
{
_instance = instance;
- _delegate = del;
- }
-
- public short type()
- {
- return _delegate.type();
- }
-
- public string protocol()
- {
- return _delegate.protocol();
- }
-
- public IceInternal.EndpointI create(List<string> args, bool oaEndpoint)
- {
- return new EndpointI(_instance, _delegate.create(args, oaEndpoint));
}
- public IceInternal.EndpointI read(Ice.InputStream s)
+ override public IceInternal.EndpointFactory
+ cloneWithUnderlying(IceInternal.ProtocolInstance inst, short underlying)
{
- return new EndpointI(_instance, _delegate.read(s));
+ return new EndpointFactoryI(new Instance(_instance.engine(), inst.type(), inst.protocol()), underlying);
}
- public void destroy()
+ override protected IceInternal.EndpointI
+ createWithUnderlying(IceInternal.EndpointI underlying, List<string> args, bool oaEndpoint)
{
- _delegate.destroy();
- _instance = null;
+ return new EndpointI(_instance, underlying);
}
- public IceInternal.EndpointFactory clone(IceInternal.ProtocolInstance inst,
- IceInternal.EndpointFactory del)
+ override protected IceInternal.EndpointI
+ readWithUnderlying(IceInternal.EndpointI underlying, Ice.InputStream s)
{
- Instance instance = new Instance(_instance.engine(), inst.type(), inst.protocol());
- return new EndpointFactoryI(instance, del != null ? del : _delegate.clone(instance, null));
+ return new EndpointI(_instance, underlying);
}
private Instance _instance;
- private IceInternal.EndpointFactory _delegate;
}
}
diff --git a/csharp/src/IceSSL/PluginI.cs b/csharp/src/IceSSL/PluginI.cs
index f4d205e4c83..fba2919ae38 100644
--- a/csharp/src/IceSSL/PluginI.cs
+++ b/csharp/src/IceSSL/PluginI.cs
@@ -43,12 +43,8 @@ namespace IceSSL
//
// SSL based on TCP
//
- IceInternal.EndpointFactory tcp = facade.getEndpointFactory(Ice.TCPEndpointType.value);
- if(tcp != null)
- {
- Instance instance = new Instance(_engine, Ice.SSLEndpointType.value, "ssl");
- facade.addEndpointFactory(new EndpointFactoryI(instance, tcp.clone(instance, null)));
- }
+ Instance instance = new Instance(_engine, Ice.SSLEndpointType.value, "ssl");
+ facade.addEndpointFactory(new EndpointFactoryI(instance, Ice.TCPEndpointType.value));
}
public override void initialize()
diff --git a/csharp/test/Ice/background/EndpointFactory.cs b/csharp/test/Ice/background/EndpointFactory.cs
index 9cbcd9def84..dd85387e7d0 100644
--- a/csharp/test/Ice/background/EndpointFactory.cs
+++ b/csharp/test/Ice/background/EndpointFactory.cs
@@ -17,6 +17,10 @@ internal class EndpointFactory : IceInternal.EndpointFactory
_factory = factory;
}
+ public void initialize()
+ {
+ }
+
public short type()
{
return (short)(EndpointI.TYPE_BASE + _factory.type());
@@ -47,7 +51,7 @@ internal class EndpointFactory : IceInternal.EndpointFactory
{
}
- public IceInternal.EndpointFactory clone(IceInternal.ProtocolInstance instance, IceInternal.EndpointFactory del)
+ public IceInternal.EndpointFactory clone(IceInternal.ProtocolInstance instance)
{
return this;
}
diff --git a/java-compat/src/Ice/src/main/java/IceInternal/EndpointFactory.java b/java-compat/src/Ice/src/main/java/IceInternal/EndpointFactory.java
index 02bb8b44a2f..480052c3ad2 100644
--- a/java-compat/src/Ice/src/main/java/IceInternal/EndpointFactory.java
+++ b/java-compat/src/Ice/src/main/java/IceInternal/EndpointFactory.java
@@ -11,11 +11,12 @@ package IceInternal;
public interface EndpointFactory
{
+ void initialize();
short type();
String protocol();
EndpointI create(java.util.ArrayList<String> args, boolean oaEndpoint);
EndpointI read(Ice.InputStream s);
void destroy();
- EndpointFactory clone(ProtocolInstance instance, EndpointFactory delegate);
+ EndpointFactory clone(ProtocolInstance instance);
}
diff --git a/java-compat/src/Ice/src/main/java/IceInternal/EndpointFactoryManager.java b/java-compat/src/Ice/src/main/java/IceInternal/EndpointFactoryManager.java
index b7b38abf5bb..be7bff93731 100644
--- a/java-compat/src/Ice/src/main/java/IceInternal/EndpointFactoryManager.java
+++ b/java-compat/src/Ice/src/main/java/IceInternal/EndpointFactoryManager.java
@@ -16,11 +16,18 @@ public final class EndpointFactoryManager
_instance = instance;
}
+ public void initialize()
+ {
+ for(EndpointFactory f : _factories)
+ {
+ f.initialize();
+ }
+ }
+
public synchronized void add(EndpointFactory factory)
{
- for(int i = 0; i < _factories.size(); i++)
+ for(EndpointFactory f : _factories)
{
- EndpointFactory f = _factories.get(i);
if(f.type() == factory.type())
{
assert(false);
@@ -31,9 +38,8 @@ public final class EndpointFactoryManager
public synchronized EndpointFactory get(short type)
{
- for(int i = 0; i < _factories.size(); i++)
+ for(EndpointFactory f : _factories)
{
- EndpointFactory f = _factories.get(i);
if(f.type() == type)
{
return f;
@@ -70,9 +76,8 @@ public final class EndpointFactoryManager
EndpointFactory factory = null;
- for(int i = 0; i < _factories.size(); i++)
+ for(EndpointFactory f : _factories)
{
- EndpointFactory f = _factories.get(i);
if(f.protocol().equals(protocol))
{
factory = f;
@@ -158,7 +163,13 @@ public final class EndpointFactoryManager
{
e = factory.read(s);
}
- else
+ //
+ // If the factory failed to read the endpoint, return an opaque endpoint. This can
+ // occur if for example the factory delegates to another factory and this factory
+ // isn't available. In this case, the factory needs to make sure the stream position
+ // is preserved for reading the opaque endpoint.
+ //
+ if(e == null)
{
e = new OpaqueEndpointI(type, s);
}
@@ -170,9 +181,8 @@ public final class EndpointFactoryManager
void destroy()
{
- for(int i = 0; i < _factories.size(); i++)
+ for(EndpointFactory f : _factories)
{
- EndpointFactory f = _factories.get(i);
f.destroy();
}
_factories.clear();
diff --git a/java-compat/src/Ice/src/main/java/IceInternal/EndpointFactoryWithUnderlying.java b/java-compat/src/Ice/src/main/java/IceInternal/EndpointFactoryWithUnderlying.java
new file mode 100644
index 00000000000..25c938e4b67
--- /dev/null
+++ b/java-compat/src/Ice/src/main/java/IceInternal/EndpointFactoryWithUnderlying.java
@@ -0,0 +1,92 @@
+// **********************************************************************
+//
+// Copyright (c) 2003-2017 ZeroC, Inc. All rights reserved.
+//
+// This copy of Ice is licensed to you under the terms described in the
+// ICE_LICENSE file included in this distribution.
+//
+// **********************************************************************
+
+package IceInternal;
+
+//
+// The endpoint factory with underlying create endpoints that delegate to an underlying
+// endpoint (e.g.: the SSL/WS endpoints are endpoints with underlying endpoints).
+//
+abstract public class EndpointFactoryWithUnderlying implements EndpointFactory
+{
+ public EndpointFactoryWithUnderlying(ProtocolInstance instance, short type)
+ {
+ _instance = instance;
+ _type = type;
+ }
+
+ public void initialize()
+ {
+ //
+ // Get the endpoint factory for the underlying type and clone it with
+ // our protocol instance.
+ //
+ EndpointFactory factory = _instance.getEndpointFactory(_type);
+ if(factory != null)
+ {
+ _underlying = factory.clone(_instance);
+ _underlying.initialize();
+ }
+ }
+
+ public short type()
+ {
+ return _instance.type();
+ }
+
+ public String protocol()
+ {
+ return _instance.protocol();
+ }
+
+ public EndpointI create(java.util.ArrayList<String> args, boolean oaEndpoint)
+ {
+ if(_underlying == null)
+ {
+ return null; // Can't create an endpoint without underlying factory.
+ }
+ return createWithUnderlying(_underlying.create(args, oaEndpoint), args, oaEndpoint);
+ }
+
+ public EndpointI read(Ice.InputStream s)
+ {
+ if(_underlying == null)
+ {
+ return null; // Can't create an endpoint without underlying factory.
+ }
+ return readWithUnderlying(_underlying.read(s), s);
+ }
+
+ public void destroy()
+ {
+ if(_underlying != null)
+ {
+ _underlying.destroy();
+ }
+ _instance = null;
+ }
+
+ public EndpointFactory clone(ProtocolInstance instance)
+ {
+ return cloneWithUnderlying(instance, _type);
+ }
+
+ abstract public EndpointFactory cloneWithUnderlying(ProtocolInstance instance, short type);
+
+ abstract protected EndpointI createWithUnderlying(EndpointI underlying,
+ java.util.ArrayList<String> args,
+ boolean oaEndpoint);
+
+ abstract protected EndpointI readWithUnderlying(EndpointI underlying, Ice.InputStream s);
+
+ protected ProtocolInstance _instance;
+
+ private final short _type;
+ private EndpointFactory _underlying;
+} \ No newline at end of file
diff --git a/java-compat/src/Ice/src/main/java/IceInternal/Instance.java b/java-compat/src/Ice/src/main/java/IceInternal/Instance.java
index cc774088796..b77c2cb527d 100644
--- a/java-compat/src/Ice/src/main/java/IceInternal/Instance.java
+++ b/java-compat/src/Ice/src/main/java/IceInternal/Instance.java
@@ -1086,6 +1086,12 @@ public final class Instance implements Ice.ClassResolver
ProtocolInstance udpProtocolInstance = new ProtocolInstance(this, Ice.UDPEndpointType.value, "udp", false);
_endpointFactoryManager.add(new UdpEndpointFactory(udpProtocolInstance));
+ ProtocolInstance wsProtocolInstance = new ProtocolInstance(this, Ice.WSEndpointType.value, "ws", false);
+ _endpointFactoryManager.add(new WSEndpointFactory(wsProtocolInstance, Ice.TCPEndpointType.value));
+
+ ProtocolInstance wssProtocolInstance = new ProtocolInstance(this, Ice.WSSEndpointType.value, "wss", true);
+ _endpointFactoryManager.add(new WSEndpointFactory(wssProtocolInstance, Ice.SSLEndpointType.value));
+
_pluginManager = new Ice.PluginManagerI(communicator, this);
if(_initData.valueFactoryManager == null)
@@ -1169,20 +1175,10 @@ public final class Instance implements Ice.ClassResolver
pluginManagerImpl.loadPlugins(args);
//
- // Add WS and WSS endpoint factories if TCP/SSL factories are installed.
+ // Initialize the endpoint factories once all the plugins are loaded. This gives
+ // the opportunity for the endpoint factories to find underyling factories.
//
- final EndpointFactory tcpFactory = _endpointFactoryManager.get(Ice.TCPEndpointType.value);
- if(tcpFactory != null)
- {
- final ProtocolInstance instance = new ProtocolInstance(this, Ice.WSEndpointType.value, "ws", false);
- _endpointFactoryManager.add(new WSEndpointFactory(instance, tcpFactory.clone(instance, null)));
- }
- final EndpointFactory sslFactory = _endpointFactoryManager.get(Ice.SSLEndpointType.value);
- if(sslFactory != null)
- {
- final ProtocolInstance instance = new ProtocolInstance(this, Ice.WSSEndpointType.value, "wss", true);
- _endpointFactoryManager.add(new WSEndpointFactory(instance, sslFactory.clone(instance, null)));
- }
+ _endpointFactoryManager.initialize();
//
// Create Admin facets, if enabled.
diff --git a/java-compat/src/Ice/src/main/java/IceInternal/ProtocolInstance.java b/java-compat/src/Ice/src/main/java/IceInternal/ProtocolInstance.java
index b564ec9875b..a6a3ca4bb3f 100644
--- a/java-compat/src/Ice/src/main/java/IceInternal/ProtocolInstance.java
+++ b/java-compat/src/Ice/src/main/java/IceInternal/ProtocolInstance.java
@@ -38,6 +38,11 @@ public class ProtocolInstance
return _logger;
}
+ public EndpointFactory getEndpointFactory(short type)
+ {
+ return _instance.endpointFactoryManager().get(type);
+ }
+
public String protocol()
{
return _protocol;
diff --git a/java-compat/src/Ice/src/main/java/IceInternal/TcpEndpointFactory.java b/java-compat/src/Ice/src/main/java/IceInternal/TcpEndpointFactory.java
index 349abfa5419..f4264eba043 100644
--- a/java-compat/src/Ice/src/main/java/IceInternal/TcpEndpointFactory.java
+++ b/java-compat/src/Ice/src/main/java/IceInternal/TcpEndpointFactory.java
@@ -17,6 +17,12 @@ final class TcpEndpointFactory implements EndpointFactory
}
@Override
+ public void initialize()
+ {
+ // Nothing to do.
+ }
+
+ @Override
public short type()
{
return _instance.type();
@@ -49,7 +55,7 @@ final class TcpEndpointFactory implements EndpointFactory
}
@Override
- public EndpointFactory clone(ProtocolInstance instance, EndpointFactory delegate)
+ public EndpointFactory clone(ProtocolInstance instance)
{
return new TcpEndpointFactory(instance);
}
diff --git a/java-compat/src/Ice/src/main/java/IceInternal/UdpEndpointFactory.java b/java-compat/src/Ice/src/main/java/IceInternal/UdpEndpointFactory.java
index 571a4d76088..f604d725281 100644
--- a/java-compat/src/Ice/src/main/java/IceInternal/UdpEndpointFactory.java
+++ b/java-compat/src/Ice/src/main/java/IceInternal/UdpEndpointFactory.java
@@ -17,6 +17,12 @@ final class UdpEndpointFactory implements EndpointFactory
}
@Override
+ public void initialize()
+ {
+ // Nothing to do.
+ }
+
+ @Override
public short type()
{
return _instance.type();
@@ -49,7 +55,7 @@ final class UdpEndpointFactory implements EndpointFactory
}
@Override
- public EndpointFactory clone(ProtocolInstance instance, EndpointFactory delegate)
+ public EndpointFactory clone(ProtocolInstance instance)
{
return new UdpEndpointFactory(instance);
}
diff --git a/java-compat/src/Ice/src/main/java/IceInternal/UnderlyingEndpointFactory.java b/java-compat/src/Ice/src/main/java/IceInternal/UnderlyingEndpointFactory.java
new file mode 100644
index 00000000000..1581f98983c
--- /dev/null
+++ b/java-compat/src/Ice/src/main/java/IceInternal/UnderlyingEndpointFactory.java
@@ -0,0 +1,90 @@
+// **********************************************************************
+//
+// Copyright (c) 2003-2017 ZeroC, Inc. All rights reserved.
+//
+// This copy of Ice is licensed to you under the terms described in the
+// ICE_LICENSE file included in this distribution.
+//
+// **********************************************************************
+
+package IceInternal;
+
+//
+// The underlying endpoint factory creates endpoints with a factory of the given
+// type. If this factory is of the EndpointFactoryWithUnderlying type, it will
+// delegate to the given underlying factory (this is used by IceIAP/IceBT plugins
+// for the BTS/iAPS endpoint factories).
+//
+public class UnderlyingEndpointFactory implements EndpointFactory
+{
+ public UnderlyingEndpointFactory(ProtocolInstance instance, short type, short underlying)
+ {
+ _instance = instance;
+ _type = type;
+ _underlying = underlying;
+ }
+
+ public void initialize()
+ {
+ //
+ // Get the endpoint factory of the given endpoint type. If it's a factory that
+ // delegates to an underlying endpoint, clone it and instruct it to delegate to
+ // our underlying factory.
+ //
+ EndpointFactory factory = _instance.getEndpointFactory(_type);
+ if(factory != null && factory instanceof EndpointFactoryWithUnderlying)
+ {
+ EndpointFactoryWithUnderlying f = (EndpointFactoryWithUnderlying)factory;
+ _factory = f.cloneWithUnderlying(_instance, _underlying);
+ _factory.initialize();
+ }
+ }
+
+ public short type()
+ {
+ return _instance.type();
+ }
+
+ public String protocol()
+ {
+ return _instance.protocol();
+ }
+
+ public EndpointI create(java.util.ArrayList<String> args, boolean oaEndpoint)
+ {
+ if(_factory == null)
+ {
+ return null;
+ }
+ return _factory.create(args, oaEndpoint);
+ }
+
+ public EndpointI read(Ice.InputStream s)
+ {
+ if(_factory == null)
+ {
+ return null;
+ }
+ return _factory.read(s);
+ }
+
+ public void destroy()
+ {
+ if(_factory != null)
+ {
+ _factory.destroy();
+ }
+ _instance = null;
+ }
+
+ public EndpointFactory clone(ProtocolInstance instance)
+ {
+ return new UnderlyingEndpointFactory(instance, _type, _underlying);
+ }
+
+ protected ProtocolInstance _instance;
+
+ private final short _type;
+ private final short _underlying;
+ private EndpointFactory _factory;
+} \ No newline at end of file
diff --git a/java-compat/src/Ice/src/main/java/IceInternal/WSEndpointFactory.java b/java-compat/src/Ice/src/main/java/IceInternal/WSEndpointFactory.java
index 66c8aa8ce7a..45d6f72f07b 100644
--- a/java-compat/src/Ice/src/main/java/IceInternal/WSEndpointFactory.java
+++ b/java-compat/src/Ice/src/main/java/IceInternal/WSEndpointFactory.java
@@ -9,51 +9,28 @@
package IceInternal;
-final public class WSEndpointFactory implements EndpointFactory
+final public class WSEndpointFactory extends EndpointFactoryWithUnderlying
{
- public WSEndpointFactory(ProtocolInstance instance, EndpointFactory delegate)
+ public WSEndpointFactory(ProtocolInstance instance, short type)
{
- _instance = instance;
- _delegate = delegate;
+ super(instance, type);
}
@Override
- public short type()
+ public EndpointFactory cloneWithUnderlying(ProtocolInstance instance, short underlying)
{
- return _instance.type();
+ return new WSEndpointFactory(instance, underlying);
}
@Override
- public String protocol()
+ public EndpointI createWithUnderlying(EndpointI underlying, java.util.ArrayList<String> args, boolean oaEndpoint)
{
- return _instance.protocol();
+ return new WSEndpoint(_instance, underlying, args);
}
@Override
- public EndpointI create(java.util.ArrayList<String> args, boolean oaEndpoint)
+ public EndpointI readWithUnderlying(EndpointI underlying, Ice.InputStream s)
{
- return new WSEndpoint(_instance, _delegate.create(args, oaEndpoint), args);
+ return new WSEndpoint(_instance, underlying, s);
}
-
- @Override
- public EndpointI read(Ice.InputStream s)
- {
- return new WSEndpoint(_instance, _delegate.read(s), s);
- }
-
- @Override
- public void destroy()
- {
- _delegate.destroy();
- _instance = null;
- }
-
- @Override
- public EndpointFactory clone(ProtocolInstance instance, EndpointFactory delegate)
- {
- return new WSEndpointFactory(instance, delegate);
- }
-
- private ProtocolInstance _instance;
- private EndpointFactory _delegate;
}
diff --git a/java-compat/src/Ice/src/main/java/IceSSL/EndpointFactoryI.java b/java-compat/src/Ice/src/main/java/IceSSL/EndpointFactoryI.java
index e7ce776b605..eef066e4340 100644
--- a/java-compat/src/Ice/src/main/java/IceSSL/EndpointFactoryI.java
+++ b/java-compat/src/Ice/src/main/java/IceSSL/EndpointFactoryI.java
@@ -9,52 +9,34 @@
package IceSSL;
-final class EndpointFactoryI implements IceInternal.EndpointFactory
+final class EndpointFactoryI extends IceInternal.EndpointFactoryWithUnderlying
{
- EndpointFactoryI(Instance instance, IceInternal.EndpointFactory delegate)
+ EndpointFactoryI(Instance instance, short type)
{
+ super(instance, type);
_instance = instance;
- _delegate = delegate;
}
@Override
- public short type()
+ public IceInternal.EndpointFactory cloneWithUnderlying(IceInternal.ProtocolInstance instance,
+ short underlying)
{
- return _instance.type();
+ return new EndpointFactoryI(new Instance(_instance.engine(), instance.type(), instance.protocol()), underlying);
}
@Override
- public String protocol()
+ public IceInternal.EndpointI createWithUnderlying(IceInternal.EndpointI underlying,
+ java.util.ArrayList<String> args,
+ boolean oaEndpoint)
{
- return _instance.protocol();
+ return new EndpointI(_instance, underlying);
}
@Override
- public IceInternal.EndpointI create(java.util.ArrayList<String> args, boolean oaEndpoint)
+ public IceInternal.EndpointI readWithUnderlying(IceInternal.EndpointI underlying, Ice.InputStream s)
{
- return new EndpointI(_instance, _delegate.create(args, oaEndpoint));
- }
-
- @Override
- public IceInternal.EndpointI read(Ice.InputStream s)
- {
- return new EndpointI(_instance, _delegate.read(s));
- }
-
- @Override
- public void destroy()
- {
- _delegate.destroy();
- _instance = null;
- }
-
- @Override
- public IceInternal.EndpointFactory clone(IceInternal.ProtocolInstance inst, IceInternal.EndpointFactory delegate)
- {
- Instance instance = new Instance(_instance.engine(), inst.type(), inst.protocol());
- return new EndpointFactoryI(instance, delegate != null ? delegate : _delegate.clone(instance, null));
+ return new EndpointI(_instance, underlying);
}
private Instance _instance;
- private IceInternal.EndpointFactory _delegate;
}
diff --git a/java-compat/src/Ice/src/main/java/IceSSL/PluginI.java b/java-compat/src/Ice/src/main/java/IceSSL/PluginI.java
index 3e35fb7235e..22e3b1fc83c 100644
--- a/java-compat/src/Ice/src/main/java/IceSSL/PluginI.java
+++ b/java-compat/src/Ice/src/main/java/IceSSL/PluginI.java
@@ -21,22 +21,8 @@ class PluginI implements Plugin
// in initialize, because the communicator may need to interpret
// proxies before the plug-in is fully initialized.
//
-
- // SSL based on TCP
- IceInternal.EndpointFactory tcp = facade.getEndpointFactory(Ice.TCPEndpointType.value);
- if(tcp != null)
- {
- Instance instance = new Instance(_engine, Ice.SSLEndpointType.value, "ssl");
- facade.addEndpointFactory(new EndpointFactoryI(instance, tcp.clone(instance, null)));
- }
-
- // SSL based on Bluetooth
- IceInternal.EndpointFactory bluetooth = facade.getEndpointFactory(Ice.BTEndpointType.value);
- if(bluetooth != null)
- {
- Instance instance = new Instance(_engine, Ice.BTSEndpointType.value, "bts");
- facade.addEndpointFactory(new EndpointFactoryI(instance, bluetooth.clone(instance, null)));
- }
+ Instance instance = new Instance(_engine, Ice.SSLEndpointType.value, "ssl");
+ facade.addEndpointFactory(new EndpointFactoryI(instance, Ice.TCPEndpointType.value));
}
@Override
diff --git a/java-compat/src/IceBT/src/main/java/IceBT/EndpointFactoryI.java b/java-compat/src/IceBT/src/main/java/IceBT/EndpointFactoryI.java
index 5c71a954f2e..247aa6806f2 100644
--- a/java-compat/src/IceBT/src/main/java/IceBT/EndpointFactoryI.java
+++ b/java-compat/src/IceBT/src/main/java/IceBT/EndpointFactoryI.java
@@ -17,6 +17,12 @@ final class EndpointFactoryI implements IceInternal.EndpointFactory
}
@Override
+ public void initialize()
+ {
+ // Nothing to do.
+ }
+
+ @Override
public short type()
{
return _instance.type();
@@ -50,7 +56,7 @@ final class EndpointFactoryI implements IceInternal.EndpointFactory
}
@Override
- public IceInternal.EndpointFactory clone(IceInternal.ProtocolInstance inst, IceInternal.EndpointFactory del)
+ public IceInternal.EndpointFactory clone(IceInternal.ProtocolInstance inst)
{
return new EndpointFactoryI(new Instance(_instance.communicator(), inst.type(), inst.protocol()));
}
diff --git a/java-compat/src/IceBT/src/main/java/IceBT/PluginI.java b/java-compat/src/IceBT/src/main/java/IceBT/PluginI.java
index 3880e3522ad..3c035a135d1 100644
--- a/java-compat/src/IceBT/src/main/java/IceBT/PluginI.java
+++ b/java-compat/src/IceBT/src/main/java/IceBT/PluginI.java
@@ -9,26 +9,24 @@
package IceBT;
+import IceInternal.UnderlyingEndpointFactory;
+
class PluginI implements Ice.Plugin
{
public PluginI(Ice.Communicator communicator)
{
- final IceInternal.ProtocolPluginFacade facade = IceInternal.Util.getProtocolPluginFacade(communicator);
+ final IceInternal.ProtocolPluginFacade f = IceInternal.Util.getProtocolPluginFacade(communicator);
//
// Register the endpoint factory. We have to do this now, rather than
// in initialize, because the communicator may need to interpret
// proxies before the plug-in is fully initialized.
//
- EndpointFactoryI factory = new EndpointFactoryI(new Instance(communicator, Ice.BTEndpointType.value, "bt"));
- facade.addEndpointFactory(factory);
+ Instance bt = new Instance(communicator, Ice.BTEndpointType.value, "bt");
+ f.addEndpointFactory(new EndpointFactoryI(bt));
- IceInternal.EndpointFactory sslFactory = facade.getEndpointFactory(Ice.SSLEndpointType.value);
- if(sslFactory != null)
- {
- Instance instance = new Instance(communicator, Ice.BTSEndpointType.value, "bts");
- facade.addEndpointFactory(sslFactory.clone(instance, new EndpointFactoryI(instance)));
- }
+ Instance bts = new Instance(communicator, Ice.BTSEndpointType.value, "bts");
+ f.addEndpointFactory(new UnderlyingEndpointFactory(bts, Ice.SSLEndpointType.value, Ice.BTEndpointType.value));
}
@Override
diff --git a/java-compat/test/src/main/java/test/Ice/background/EndpointFactory.java b/java-compat/test/src/main/java/test/Ice/background/EndpointFactory.java
index 821b15b9b3e..e6faec8827b 100644
--- a/java-compat/test/src/main/java/test/Ice/background/EndpointFactory.java
+++ b/java-compat/test/src/main/java/test/Ice/background/EndpointFactory.java
@@ -17,6 +17,12 @@ final class EndpointFactory implements IceInternal.EndpointFactory
}
@Override
+ public void
+ initialize()
+ {
+ }
+
+ @Override
public short
type()
{
@@ -58,7 +64,7 @@ final class EndpointFactory implements IceInternal.EndpointFactory
@Override
public IceInternal.EndpointFactory
- clone(IceInternal.ProtocolInstance instance, IceInternal.EndpointFactory del)
+ clone(IceInternal.ProtocolInstance instance)
{
return this;
}
diff --git a/java/src/Ice/src/main/java/com/zeroc/IceInternal/EndpointFactory.java b/java/src/Ice/src/main/java/com/zeroc/IceInternal/EndpointFactory.java
index 985875e7be6..b4de848e3f9 100644
--- a/java/src/Ice/src/main/java/com/zeroc/IceInternal/EndpointFactory.java
+++ b/java/src/Ice/src/main/java/com/zeroc/IceInternal/EndpointFactory.java
@@ -11,11 +11,16 @@ package com.zeroc.IceInternal;
public interface EndpointFactory
{
+ default void initialize()
+ {
+ // Nothing to do, can be overriden by specialization to finish initialization.
+ }
+
short type();
String protocol();
EndpointI create(java.util.ArrayList<String> args, boolean oaEndpoint);
EndpointI read(com.zeroc.Ice.InputStream s);
void destroy();
- EndpointFactory clone(ProtocolInstance instance, EndpointFactory delegate);
+ EndpointFactory clone(ProtocolInstance instance);
}
diff --git a/java/src/Ice/src/main/java/com/zeroc/IceInternal/EndpointFactoryManager.java b/java/src/Ice/src/main/java/com/zeroc/IceInternal/EndpointFactoryManager.java
index e3646c311db..5ecf681e547 100644
--- a/java/src/Ice/src/main/java/com/zeroc/IceInternal/EndpointFactoryManager.java
+++ b/java/src/Ice/src/main/java/com/zeroc/IceInternal/EndpointFactoryManager.java
@@ -16,11 +16,18 @@ public final class EndpointFactoryManager
_instance = instance;
}
+ public void initialize()
+ {
+ for(EndpointFactory f : _factories)
+ {
+ f.initialize();
+ }
+ }
+
public synchronized void add(EndpointFactory factory)
{
- for(int i = 0; i < _factories.size(); i++)
+ for(EndpointFactory f : _factories)
{
- EndpointFactory f = _factories.get(i);
if(f.type() == factory.type())
{
assert(false);
@@ -31,9 +38,8 @@ public final class EndpointFactoryManager
public synchronized EndpointFactory get(short type)
{
- for(int i = 0; i < _factories.size(); i++)
+ for(EndpointFactory f : _factories)
{
- EndpointFactory f = _factories.get(i);
if(f.type() == type)
{
return f;
@@ -70,9 +76,8 @@ public final class EndpointFactoryManager
EndpointFactory factory = null;
- for(int i = 0; i < _factories.size(); i++)
+ for(EndpointFactory f : _factories)
{
- EndpointFactory f = _factories.get(i);
if(f.protocol().equals(protocol))
{
factory = f;
@@ -159,7 +164,13 @@ public final class EndpointFactoryManager
{
e = factory.read(s);
}
- else
+ //
+ // If the factory failed to read the endpoint, return an opaque endpoint. This can
+ // occur if for example the factory delegates to another factory and this factory
+ // isn't available. In this case, the factory needs to make sure the stream position
+ // is preserved for reading the opaque endpoint.
+ //
+ if(e == null)
{
e = new OpaqueEndpointI(type, s);
}
@@ -171,9 +182,8 @@ public final class EndpointFactoryManager
void destroy()
{
- for(int i = 0; i < _factories.size(); i++)
+ for(EndpointFactory f : _factories)
{
- EndpointFactory f = _factories.get(i);
f.destroy();
}
_factories.clear();
diff --git a/java/src/Ice/src/main/java/com/zeroc/IceInternal/EndpointFactoryWithUnderlying.java b/java/src/Ice/src/main/java/com/zeroc/IceInternal/EndpointFactoryWithUnderlying.java
new file mode 100644
index 00000000000..747c38d7f37
--- /dev/null
+++ b/java/src/Ice/src/main/java/com/zeroc/IceInternal/EndpointFactoryWithUnderlying.java
@@ -0,0 +1,92 @@
+// **********************************************************************
+//
+// Copyright (c) 2003-2017 ZeroC, Inc. All rights reserved.
+//
+// This copy of Ice is licensed to you under the terms described in the
+// ICE_LICENSE file included in this distribution.
+//
+// **********************************************************************
+
+package com.zeroc.IceInternal;
+
+//
+// The endpoint factory with underlying create endpoints that delegate to an underlying
+// endpoint (e.g.: the SSL/WS endpoints are endpoints with underlying endpoints).
+//
+abstract public class EndpointFactoryWithUnderlying implements EndpointFactory
+{
+ public EndpointFactoryWithUnderlying(ProtocolInstance instance, short type)
+ {
+ _instance = instance;
+ _type = type;
+ }
+
+ public void initialize()
+ {
+ //
+ // Get the endpoint factory for the underlying type and clone it with
+ // our protocol instance.
+ //
+ EndpointFactory factory = _instance.getEndpointFactory(_type);
+ if(factory != null)
+ {
+ _underlying = factory.clone(_instance);
+ _underlying.initialize();
+ }
+ }
+
+ public short type()
+ {
+ return _instance.type();
+ }
+
+ public String protocol()
+ {
+ return _instance.protocol();
+ }
+
+ public EndpointI create(java.util.ArrayList<String> args, boolean oaEndpoint)
+ {
+ if(_underlying == null)
+ {
+ return null; // Can't create an endpoint without underlying factory.
+ }
+ return createWithUnderlying(_underlying.create(args, oaEndpoint), args, oaEndpoint);
+ }
+
+ public EndpointI read(com.zeroc.Ice.InputStream s)
+ {
+ if(_underlying == null)
+ {
+ return null; // Can't create an endpoint without underlying factory.
+ }
+ return readWithUnderlying(_underlying.read(s), s);
+ }
+
+ public void destroy()
+ {
+ if(_underlying != null)
+ {
+ _underlying.destroy();
+ }
+ _instance = null;
+ }
+
+ public EndpointFactory clone(ProtocolInstance instance)
+ {
+ return cloneWithUnderlying(instance, _type);
+ }
+
+ abstract public EndpointFactory cloneWithUnderlying(ProtocolInstance instance, short type);
+
+ abstract protected EndpointI createWithUnderlying(EndpointI underlying,
+ java.util.ArrayList<String> args,
+ boolean oaEndpoint);
+
+ abstract protected EndpointI readWithUnderlying(EndpointI underlying, com.zeroc.Ice.InputStream s);
+
+ protected ProtocolInstance _instance;
+
+ private final short _type;
+ private EndpointFactory _underlying;
+} \ No newline at end of file
diff --git a/java/src/Ice/src/main/java/com/zeroc/IceInternal/Instance.java b/java/src/Ice/src/main/java/com/zeroc/IceInternal/Instance.java
index 75965e551b8..56f062d292a 100644
--- a/java/src/Ice/src/main/java/com/zeroc/IceInternal/Instance.java
+++ b/java/src/Ice/src/main/java/com/zeroc/IceInternal/Instance.java
@@ -1101,13 +1101,17 @@ public final class Instance implements java.util.function.Function<String, Class
_endpointFactoryManager = new EndpointFactoryManager(this);
- ProtocolInstance tcpProtocolInstance =
- new ProtocolInstance(this, com.zeroc.Ice.TCPEndpointType.value, "tcp", false);
- _endpointFactoryManager.add(new TcpEndpointFactory(tcpProtocolInstance));
+ ProtocolInstance tcpProtocol = new ProtocolInstance(this, com.zeroc.Ice.TCPEndpointType.value, "tcp", false);
+ _endpointFactoryManager.add(new TcpEndpointFactory(tcpProtocol));
- ProtocolInstance udpProtocolInstance =
- new ProtocolInstance(this, com.zeroc.Ice.UDPEndpointType.value, "udp", false);
- _endpointFactoryManager.add(new UdpEndpointFactory(udpProtocolInstance));
+ ProtocolInstance udpProtocol = new ProtocolInstance(this, com.zeroc.Ice.UDPEndpointType.value, "udp", false);
+ _endpointFactoryManager.add(new UdpEndpointFactory(udpProtocol));
+
+ ProtocolInstance wsProtocol = new ProtocolInstance(this, com.zeroc.Ice.WSEndpointType.value, "ws", false);
+ _endpointFactoryManager.add(new WSEndpointFactory(wsProtocol, com.zeroc.Ice.TCPEndpointType.value));
+
+ ProtocolInstance wssProtocol = new ProtocolInstance(this, com.zeroc.Ice.WSSEndpointType.value, "wss", true);
+ _endpointFactoryManager.add(new WSEndpointFactory(wssProtocol, com.zeroc.Ice.SSLEndpointType.value));
_pluginManager = new com.zeroc.Ice.PluginManagerI(communicator, this);
@@ -1191,22 +1195,10 @@ public final class Instance implements java.util.function.Function<String, Class
args = pluginManagerImpl.loadPlugins(args);
//
- // Add WS and WSS endpoint factories if TCP/SSL factories are installed.
+ // Initialize the endpoint factories once all the plugins are loaded. This gives
+ // the opportunity for the endpoint factories to find underyling factories.
//
- final EndpointFactory tcpFactory = _endpointFactoryManager.get(com.zeroc.Ice.TCPEndpointType.value);
- if(tcpFactory != null)
- {
- final ProtocolInstance instance =
- new ProtocolInstance(this, com.zeroc.Ice.WSEndpointType.value, "ws", false);
- _endpointFactoryManager.add(new WSEndpointFactory(instance, tcpFactory.clone(instance, null)));
- }
- final EndpointFactory sslFactory = _endpointFactoryManager.get(com.zeroc.Ice.SSLEndpointType.value);
- if(sslFactory != null)
- {
- final ProtocolInstance instance =
- new ProtocolInstance(this, com.zeroc.Ice.WSSEndpointType.value, "wss", true);
- _endpointFactoryManager.add(new WSEndpointFactory(instance, sslFactory.clone(instance, null)));
- }
+ _endpointFactoryManager.initialize();
//
// Create Admin facets, if enabled.
diff --git a/java/src/Ice/src/main/java/com/zeroc/IceInternal/ProtocolInstance.java b/java/src/Ice/src/main/java/com/zeroc/IceInternal/ProtocolInstance.java
index 7ec1c3022f5..d3c13d9ee35 100644
--- a/java/src/Ice/src/main/java/com/zeroc/IceInternal/ProtocolInstance.java
+++ b/java/src/Ice/src/main/java/com/zeroc/IceInternal/ProtocolInstance.java
@@ -38,6 +38,11 @@ public class ProtocolInstance
return _logger;
}
+ public EndpointFactory getEndpointFactory(short type)
+ {
+ return _instance.endpointFactoryManager().get(type);
+ }
+
public String protocol()
{
return _protocol;
diff --git a/java/src/Ice/src/main/java/com/zeroc/IceInternal/TcpEndpointFactory.java b/java/src/Ice/src/main/java/com/zeroc/IceInternal/TcpEndpointFactory.java
index 1fa2907d43e..d4aa6740083 100644
--- a/java/src/Ice/src/main/java/com/zeroc/IceInternal/TcpEndpointFactory.java
+++ b/java/src/Ice/src/main/java/com/zeroc/IceInternal/TcpEndpointFactory.java
@@ -49,7 +49,7 @@ final class TcpEndpointFactory implements EndpointFactory
}
@Override
- public EndpointFactory clone(ProtocolInstance instance, EndpointFactory delegate)
+ public EndpointFactory clone(ProtocolInstance instance)
{
return new TcpEndpointFactory(instance);
}
diff --git a/java/src/Ice/src/main/java/com/zeroc/IceInternal/UdpEndpointFactory.java b/java/src/Ice/src/main/java/com/zeroc/IceInternal/UdpEndpointFactory.java
index e7b458e25a9..64cc4fb4a3f 100644
--- a/java/src/Ice/src/main/java/com/zeroc/IceInternal/UdpEndpointFactory.java
+++ b/java/src/Ice/src/main/java/com/zeroc/IceInternal/UdpEndpointFactory.java
@@ -49,7 +49,7 @@ final class UdpEndpointFactory implements EndpointFactory
}
@Override
- public EndpointFactory clone(ProtocolInstance instance, EndpointFactory delegate)
+ public EndpointFactory clone(ProtocolInstance instance)
{
return new UdpEndpointFactory(instance);
}
diff --git a/java/src/Ice/src/main/java/com/zeroc/IceInternal/UnderlyingEndpointFactory.java b/java/src/Ice/src/main/java/com/zeroc/IceInternal/UnderlyingEndpointFactory.java
new file mode 100644
index 00000000000..6ed97724ddb
--- /dev/null
+++ b/java/src/Ice/src/main/java/com/zeroc/IceInternal/UnderlyingEndpointFactory.java
@@ -0,0 +1,90 @@
+// **********************************************************************
+//
+// Copyright (c) 2003-2017 ZeroC, Inc. All rights reserved.
+//
+// This copy of Ice is licensed to you under the terms described in the
+// ICE_LICENSE file included in this distribution.
+//
+// **********************************************************************
+
+package com.zeroc.IceInternal;
+
+//
+// The underlying endpoint factory creates endpoints with a factory of the given
+// type. If this factory is of the EndpointFactoryWithUnderlying type, it will
+// delegate to the given underlying factory (this is used by IceIAP/IceBT plugins
+// for the BTS/iAPS endpoint factories).
+//
+public class UnderlyingEndpointFactory implements EndpointFactory
+{
+ public UnderlyingEndpointFactory(ProtocolInstance instance, short type, short underlying)
+ {
+ _instance = instance;
+ _type = type;
+ _underlying = underlying;
+ }
+
+ public void initialize()
+ {
+ //
+ // Get the endpoint factory of the given endpoint type. If it's a factory that
+ // delegates to an underlying endpoint, clone it and instruct it to delegate to
+ // our underlying factory.
+ //
+ EndpointFactory factory = _instance.getEndpointFactory(_type);
+ if(factory != null && factory instanceof EndpointFactoryWithUnderlying)
+ {
+ EndpointFactoryWithUnderlying f = (EndpointFactoryWithUnderlying)factory;
+ _factory = f.cloneWithUnderlying(_instance, _underlying);
+ _factory.initialize();
+ }
+ }
+
+ public short type()
+ {
+ return _instance.type();
+ }
+
+ public String protocol()
+ {
+ return _instance.protocol();
+ }
+
+ public EndpointI create(java.util.ArrayList<String> args, boolean oaEndpoint)
+ {
+ if(_factory == null)
+ {
+ return null;
+ }
+ return _factory.create(args, oaEndpoint);
+ }
+
+ public EndpointI read(com.zeroc.Ice.InputStream s)
+ {
+ if(_factory == null)
+ {
+ return null;
+ }
+ return _factory.read(s);
+ }
+
+ public void destroy()
+ {
+ if(_factory != null)
+ {
+ _factory.destroy();
+ }
+ _instance = null;
+ }
+
+ public EndpointFactory clone(ProtocolInstance instance)
+ {
+ return new UnderlyingEndpointFactory(instance, _type, _underlying);
+ }
+
+ protected ProtocolInstance _instance;
+
+ private final short _type;
+ private final short _underlying;
+ private EndpointFactory _factory;
+} \ No newline at end of file
diff --git a/java/src/Ice/src/main/java/com/zeroc/IceInternal/WSEndpointFactory.java b/java/src/Ice/src/main/java/com/zeroc/IceInternal/WSEndpointFactory.java
index a21a7c3129d..23e0cbf2305 100644
--- a/java/src/Ice/src/main/java/com/zeroc/IceInternal/WSEndpointFactory.java
+++ b/java/src/Ice/src/main/java/com/zeroc/IceInternal/WSEndpointFactory.java
@@ -9,51 +9,28 @@
package com.zeroc.IceInternal;
-final public class WSEndpointFactory implements EndpointFactory
+final public class WSEndpointFactory extends EndpointFactoryWithUnderlying
{
- public WSEndpointFactory(ProtocolInstance instance, EndpointFactory delegate)
+ public WSEndpointFactory(ProtocolInstance instance, short type)
{
- _instance = instance;
- _delegate = delegate;
+ super(instance, type);
}
@Override
- public short type()
+ public EndpointFactory cloneWithUnderlying(ProtocolInstance instance, short underlying)
{
- return _instance.type();
+ return new WSEndpointFactory(instance, underlying);
}
@Override
- public String protocol()
+ public EndpointI createWithUnderlying(EndpointI underlying, java.util.ArrayList<String> args, boolean oaEndpoint)
{
- return _instance.protocol();
+ return new WSEndpoint(_instance, underlying, args);
}
@Override
- public EndpointI create(java.util.ArrayList<String> args, boolean oaEndpoint)
+ public EndpointI readWithUnderlying(EndpointI underlying, com.zeroc.Ice.InputStream s)
{
- return new WSEndpoint(_instance, _delegate.create(args, oaEndpoint), args);
+ return new WSEndpoint(_instance, underlying, s);
}
-
- @Override
- public EndpointI read(com.zeroc.Ice.InputStream s)
- {
- return new WSEndpoint(_instance, _delegate.read(s), s);
- }
-
- @Override
- public void destroy()
- {
- _delegate.destroy();
- _instance = null;
- }
-
- @Override
- public EndpointFactory clone(ProtocolInstance instance, EndpointFactory delegate)
- {
- return new WSEndpointFactory(instance, delegate);
- }
-
- private ProtocolInstance _instance;
- private EndpointFactory _delegate;
}
diff --git a/java/src/IceBT/src/main/java/com/zeroc/IceBT/EndpointFactoryI.java b/java/src/IceBT/src/main/java/com/zeroc/IceBT/EndpointFactoryI.java
index 66c2b391438..af2be3673cb 100644
--- a/java/src/IceBT/src/main/java/com/zeroc/IceBT/EndpointFactoryI.java
+++ b/java/src/IceBT/src/main/java/com/zeroc/IceBT/EndpointFactoryI.java
@@ -53,9 +53,9 @@ final class EndpointFactoryI implements EndpointFactory
}
@Override
- public EndpointFactory clone(ProtocolInstance inst, EndpointFactory del)
+ public EndpointFactory clone(ProtocolInstance instance)
{
- return new EndpointFactoryI(new Instance(_instance.communicator(), inst.type(), inst.protocol()));
+ return new EndpointFactoryI(new Instance(_instance.communicator(), instance.type(), instance.protocol()));
}
private Instance _instance;
diff --git a/java/src/IceBT/src/main/java/com/zeroc/IceBT/PluginI.java b/java/src/IceBT/src/main/java/com/zeroc/IceBT/PluginI.java
index 2da1c7920a7..e030dc92b21 100644
--- a/java/src/IceBT/src/main/java/com/zeroc/IceBT/PluginI.java
+++ b/java/src/IceBT/src/main/java/com/zeroc/IceBT/PluginI.java
@@ -9,29 +9,28 @@
package com.zeroc.IceBT;
+import com.zeroc.IceInternal.ProtocolPluginFacade;
+import com.zeroc.Ice.BTEndpointType;
+import com.zeroc.Ice.BTSEndpointType;
+import com.zeroc.Ice.SSLEndpointType;
+import com.zeroc.IceInternal.UnderlyingEndpointFactory;
+
class PluginI implements com.zeroc.Ice.Plugin
{
public PluginI(com.zeroc.Ice.Communicator communicator)
{
- final com.zeroc.IceInternal.ProtocolPluginFacade facade =
- com.zeroc.IceInternal.Util.getProtocolPluginFacade(communicator);
+ final ProtocolPluginFacade f = com.zeroc.IceInternal.Util.getProtocolPluginFacade(communicator);
//
// Register the endpoint factory. We have to do this now, rather than
// in initialize, because the communicator may need to interpret
// proxies before the plug-in is fully initialized.
//
- EndpointFactoryI factory =
- new EndpointFactoryI(new Instance(communicator, com.zeroc.Ice.BTEndpointType.value, "bt"));
- facade.addEndpointFactory(factory);
+ Instance bt = new Instance(communicator, BTEndpointType.value, "bt");
+ f.addEndpointFactory(new EndpointFactoryI(bt));
- com.zeroc.IceInternal.EndpointFactory sslFactory =
- facade.getEndpointFactory(com.zeroc.Ice.SSLEndpointType.value);
- if(sslFactory != null)
- {
- Instance instance = new Instance(communicator, com.zeroc.Ice.BTSEndpointType.value, "bts");
- facade.addEndpointFactory(sslFactory.clone(instance, new EndpointFactoryI(instance)));
- }
+ Instance bts = new Instance(communicator, BTSEndpointType.value, "bts");
+ f.addEndpointFactory(new UnderlyingEndpointFactory(bts, SSLEndpointType.value, BTSEndpointType.value));
}
@Override
diff --git a/java/src/IceSSL/src/main/java/com/zeroc/IceSSL/EndpointFactoryI.java b/java/src/IceSSL/src/main/java/com/zeroc/IceSSL/EndpointFactoryI.java
index 0b4df6a95af..1c3fac9d452 100644
--- a/java/src/IceSSL/src/main/java/com/zeroc/IceSSL/EndpointFactoryI.java
+++ b/java/src/IceSSL/src/main/java/com/zeroc/IceSSL/EndpointFactoryI.java
@@ -9,54 +9,35 @@
package com.zeroc.IceSSL;
-import com.zeroc.IceInternal.EndpointFactory;
-
-final class EndpointFactoryI implements EndpointFactory
+final class EndpointFactoryI extends com.zeroc.IceInternal.EndpointFactoryWithUnderlying
{
- EndpointFactoryI(Instance instance, EndpointFactory delegate)
+ EndpointFactoryI(Instance instance, short type)
{
+ super(instance, type);
_instance = instance;
- _delegate = delegate;
- }
-
- @Override
- public short type()
- {
- return _instance.type();
- }
-
- @Override
- public String protocol()
- {
- return _instance.protocol();
- }
-
- @Override
- public com.zeroc.IceInternal.EndpointI create(java.util.ArrayList<String> args, boolean oaEndpoint)
- {
- return new EndpointI(_instance, _delegate.create(args, oaEndpoint));
}
@Override
- public com.zeroc.IceInternal.EndpointI read(com.zeroc.Ice.InputStream s)
+ public com.zeroc.IceInternal.EndpointFactory cloneWithUnderlying(com.zeroc.IceInternal.ProtocolInstance instance,
+ short underlying)
{
- return new EndpointI(_instance, _delegate.read(s));
+ return new EndpointFactoryI(new Instance(_instance.engine(), instance.type(), instance.protocol()), underlying);
}
@Override
- public void destroy()
+ public com.zeroc.IceInternal.EndpointI createWithUnderlying(com.zeroc.IceInternal.EndpointI underlying,
+ java.util.ArrayList<String> args,
+ boolean oaEndpoint)
{
- _delegate.destroy();
- _instance = null;
+ return new EndpointI(_instance, underlying);
}
@Override
- public EndpointFactory clone(com.zeroc.IceInternal.ProtocolInstance inst, EndpointFactory delegate)
+ public com.zeroc.IceInternal.EndpointI readWithUnderlying(com.zeroc.IceInternal.EndpointI underlying,
+ com.zeroc.Ice.InputStream s)
{
- Instance instance = new Instance(_instance.engine(), inst.type(), inst.protocol());
- return new EndpointFactoryI(instance, delegate != null ? delegate : _delegate.clone(instance, null));
+ return new EndpointI(_instance, underlying);
}
private Instance _instance;
- private com.zeroc.IceInternal.EndpointFactory _delegate;
}
diff --git a/java/src/IceSSL/src/main/java/com/zeroc/IceSSL/PluginI.java b/java/src/IceSSL/src/main/java/com/zeroc/IceSSL/PluginI.java
index be7fceb88bc..d028e2fc919 100644
--- a/java/src/IceSSL/src/main/java/com/zeroc/IceSSL/PluginI.java
+++ b/java/src/IceSSL/src/main/java/com/zeroc/IceSSL/PluginI.java
@@ -9,12 +9,13 @@
package com.zeroc.IceSSL;
+import com.zeroc.IceInternal.ProtocolPluginFacade;
+
class PluginI implements Plugin
{
public PluginI(com.zeroc.Ice.Communicator communicator)
{
- final com.zeroc.IceInternal.ProtocolPluginFacade facade =
- com.zeroc.IceInternal.Util.getProtocolPluginFacade(communicator);
+ final ProtocolPluginFacade facade = com.zeroc.IceInternal.Util.getProtocolPluginFacade(communicator);
_engine = new SSLEngine(facade);
//
@@ -22,22 +23,8 @@ class PluginI implements Plugin
// in initialize, because the communicator may need to interpret
// proxies before the plug-in is fully initialized.
//
-
- // SSL based on TCP
- com.zeroc.IceInternal.EndpointFactory tcp = facade.getEndpointFactory(com.zeroc.Ice.TCPEndpointType.value);
- if(tcp != null)
- {
- Instance instance = new Instance(_engine, com.zeroc.Ice.SSLEndpointType.value, "ssl");
- facade.addEndpointFactory(new EndpointFactoryI(instance, tcp.clone(instance, null)));
- }
-
- // SSL based on Bluetooth
- com.zeroc.IceInternal.EndpointFactory bluetooth = facade.getEndpointFactory(com.zeroc.Ice.BTEndpointType.value);
- if(bluetooth != null)
- {
- Instance instance = new Instance(_engine, com.zeroc.Ice.BTSEndpointType.value, "bts");
- facade.addEndpointFactory(new EndpointFactoryI(instance, bluetooth.clone(instance, null)));
- }
+ Instance instance = new Instance(_engine, com.zeroc.Ice.SSLEndpointType.value, "ssl");
+ facade.addEndpointFactory(new EndpointFactoryI(instance, com.zeroc.Ice.TCPEndpointType.value));
}
@Override
diff --git a/java/test/src/main/java/test/Ice/background/EndpointFactory.java b/java/test/src/main/java/test/Ice/background/EndpointFactory.java
index fe9835af1f1..92aae87ddec 100644
--- a/java/test/src/main/java/test/Ice/background/EndpointFactory.java
+++ b/java/test/src/main/java/test/Ice/background/EndpointFactory.java
@@ -53,8 +53,7 @@ final class EndpointFactory implements com.zeroc.IceInternal.EndpointFactory
}
@Override
- public com.zeroc.IceInternal.EndpointFactory clone(com.zeroc.IceInternal.ProtocolInstance instance,
- com.zeroc.IceInternal.EndpointFactory del)
+ public com.zeroc.IceInternal.EndpointFactory clone(com.zeroc.IceInternal.ProtocolInstance instance)
{
return this;
}
diff --git a/js/src/Ice/EndpointFactoryManager.js b/js/src/Ice/EndpointFactoryManager.js
index 04e1f6c8f75..5a3db1da8c2 100644
--- a/js/src/Ice/EndpointFactoryManager.js
+++ b/js/src/Ice/EndpointFactoryManager.js
@@ -126,19 +126,25 @@ class EndpointFactoryManager
read(s)
{
const type = s.readShort();
- for(let i = 0; i < this._factories.length; ++i)
+
+ const factory = this.get(type);
+ let e = null;
+ s.startEncapsulation();
+ if(factory)
{
- if(this._factories[i].type() == type)
- {
- s.startEncapsulation();
- const e = this._factories[i].read(s);
- s.endEncapsulation();
- return e;
- }
+ e = factory.read(s);
+ }
+ //
+ // If the factory failed to read the endpoint, return an opaque endpoint. This can
+ // occur if for example the factory delegates to another factory and this factory
+ // isn't available. In this case, the factory needs to make sure the stream position
+ // is preserved for reading the opaque endpoint.
+ //
+ if(!e)
+ {
+ e = new OpaqueEndpointI(type);
+ e.initWithStream(s);
}
- s.startEncapsulation();
- const e = new OpaqueEndpointI(type);
- e.initWithStream(s);
s.endEncapsulation();
return e;
}
diff --git a/objective-c/include/objc/Ice/Initialize.h b/objective-c/include/objc/Ice/Initialize.h
index fb34c1f2ddb..39e8427875b 100644
--- a/objective-c/include/objc/Ice/Initialize.h
+++ b/objective-c/include/objc/Ice/Initialize.h
@@ -91,6 +91,8 @@ ICE_API @interface ICEUtil : NSObject
@end
extern void ICEregisterIceSSL(BOOL);
+extern void ICEregisterIceUDP(BOOL);
+extern void ICEregisterIceWS(BOOL);
extern void ICEregisterIceDiscovery(BOOL);
extern void ICEregisterIceLocatorDiscovery(BOOL);
#if defined(__APPLE__) && TARGET_OS_IPHONE > 0
diff --git a/objective-c/test/Ice/acm/Client.m b/objective-c/test/Ice/acm/Client.m
index ce4ab06ff3b..6b7f64d3131 100644
--- a/objective-c/test/Ice/acm/Client.m
+++ b/objective-c/test/Ice/acm/Client.m
@@ -28,6 +28,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
ICEregisterIceSSL(YES);
+ ICEregisterIceWS(YES);
#if TARGET_OS_IPHONE && !TARGET_IPHONE_SIMULATOR
ICEregisterIceIAP(YES);
#endif
diff --git a/objective-c/test/Ice/acm/Server.m b/objective-c/test/Ice/acm/Server.m
index d174502df00..39c52bf5046 100644
--- a/objective-c/test/Ice/acm/Server.m
+++ b/objective-c/test/Ice/acm/Server.m
@@ -39,6 +39,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
ICEregisterIceSSL(YES);
+ ICEregisterIceWS(YES);
#if TARGET_OS_IPHONE && !TARGET_IPHONE_SIMULATOR
ICEregisterIceIAP(YES);
#endif
diff --git a/objective-c/test/Ice/adapterDeactivation/Client.m b/objective-c/test/Ice/adapterDeactivation/Client.m
index 7966022e713..b15b6c50740 100644
--- a/objective-c/test/Ice/adapterDeactivation/Client.m
+++ b/objective-c/test/Ice/adapterDeactivation/Client.m
@@ -28,6 +28,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
ICEregisterIceSSL(YES);
+ ICEregisterIceWS(YES);
#if TARGET_OS_IPHONE && !TARGET_IPHONE_SIMULATOR
ICEregisterIceIAP(YES);
#endif
diff --git a/objective-c/test/Ice/adapterDeactivation/Collocated.m b/objective-c/test/Ice/adapterDeactivation/Collocated.m
index 0d6da3bb8b3..68c96eddba9 100644
--- a/objective-c/test/Ice/adapterDeactivation/Collocated.m
+++ b/objective-c/test/Ice/adapterDeactivation/Collocated.m
@@ -34,6 +34,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
ICEregisterIceSSL(YES);
+ ICEregisterIceWS(YES);
#if TARGET_OS_IPHONE && !TARGET_IPHONE_SIMULATOR
ICEregisterIceIAP(YES);
#endif
diff --git a/objective-c/test/Ice/adapterDeactivation/Server.m b/objective-c/test/Ice/adapterDeactivation/Server.m
index 530dca4524d..fc1de543ee7 100644
--- a/objective-c/test/Ice/adapterDeactivation/Server.m
+++ b/objective-c/test/Ice/adapterDeactivation/Server.m
@@ -34,6 +34,8 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
ICEregisterIceSSL(YES);
+ ICEregisterIceWS(YES);
+ ICEregisterIceUDP(YES);
#if TARGET_OS_IPHONE && !TARGET_IPHONE_SIMULATOR
ICEregisterIceIAP(YES);
#endif
diff --git a/objective-c/test/Ice/admin/Client.m b/objective-c/test/Ice/admin/Client.m
index 0aa432d5dd0..55e2cddab3c 100644
--- a/objective-c/test/Ice/admin/Client.m
+++ b/objective-c/test/Ice/admin/Client.m
@@ -28,6 +28,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
ICEregisterIceSSL(YES);
+ ICEregisterIceWS(YES);
#if TARGET_OS_IPHONE && !TARGET_IPHONE_SIMULATOR
ICEregisterIceIAP(YES);
#endif
diff --git a/objective-c/test/Ice/admin/Server.m b/objective-c/test/Ice/admin/Server.m
index 33f50100860..1950b40f62d 100644
--- a/objective-c/test/Ice/admin/Server.m
+++ b/objective-c/test/Ice/admin/Server.m
@@ -38,6 +38,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
ICEregisterIceSSL(YES);
+ ICEregisterIceWS(YES);
#if TARGET_OS_IPHONE && !TARGET_IPHONE_SIMULATOR
ICEregisterIceIAP(YES);
#endif
diff --git a/objective-c/test/Ice/ami/Client.m b/objective-c/test/Ice/ami/Client.m
index 565761cf905..4a7755b292a 100644
--- a/objective-c/test/Ice/ami/Client.m
+++ b/objective-c/test/Ice/ami/Client.m
@@ -28,6 +28,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
ICEregisterIceSSL(YES);
+ ICEregisterIceWS(YES);
#if TARGET_OS_IPHONE && !TARGET_IPHONE_SIMULATOR
ICEregisterIceIAP(YES);
#endif
diff --git a/objective-c/test/Ice/ami/Collocated.m b/objective-c/test/Ice/ami/Collocated.m
index 8a7e268cd79..fa80a604c87 100644
--- a/objective-c/test/Ice/ami/Collocated.m
+++ b/objective-c/test/Ice/ami/Collocated.m
@@ -45,6 +45,8 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
ICEregisterIceSSL(YES);
+ ICEregisterIceWS(YES);
+ ICEregisterIceUDP(YES);
#if TARGET_OS_IPHONE && !TARGET_IPHONE_SIMULATOR
ICEregisterIceIAP(YES);
#endif
diff --git a/objective-c/test/Ice/ami/Server.m b/objective-c/test/Ice/ami/Server.m
index f87bcaba752..84475f03aab 100644
--- a/objective-c/test/Ice/ami/Server.m
+++ b/objective-c/test/Ice/ami/Server.m
@@ -45,6 +45,8 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
ICEregisterIceSSL(YES);
+ ICEregisterIceWS(YES);
+ ICEregisterIceUDP(YES);
#if TARGET_OS_IPHONE && !TARGET_IPHONE_SIMULATOR
ICEregisterIceIAP(YES);
#endif
diff --git a/objective-c/test/Ice/binding/Client.m b/objective-c/test/Ice/binding/Client.m
index c92da694f98..11a500b64ed 100644
--- a/objective-c/test/Ice/binding/Client.m
+++ b/objective-c/test/Ice/binding/Client.m
@@ -28,6 +28,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
ICEregisterIceSSL(YES);
+ ICEregisterIceWS(YES);
#if TARGET_OS_IPHONE && !TARGET_IPHONE_SIMULATOR
ICEregisterIceIAP(YES);
#endif
diff --git a/objective-c/test/Ice/binding/Server.m b/objective-c/test/Ice/binding/Server.m
index ad1223f2729..2518bc5ffb5 100644
--- a/objective-c/test/Ice/binding/Server.m
+++ b/objective-c/test/Ice/binding/Server.m
@@ -37,6 +37,8 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
ICEregisterIceSSL(YES);
+ ICEregisterIceWS(YES);
+ ICEregisterIceUDP(YES);
#if TARGET_OS_IPHONE && !TARGET_IPHONE_SIMULATOR
ICEregisterIceIAP(YES);
#endif
diff --git a/objective-c/test/Ice/defaultServant/Client.m b/objective-c/test/Ice/defaultServant/Client.m
index 04f3cd89175..ce90454cc0d 100644
--- a/objective-c/test/Ice/defaultServant/Client.m
+++ b/objective-c/test/Ice/defaultServant/Client.m
@@ -154,6 +154,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
ICEregisterIceSSL(YES);
+ ICEregisterIceWS(YES);
#if TARGET_OS_IPHONE && !TARGET_IPHONE_SIMULATOR
ICEregisterIceIAP(YES);
#endif
diff --git a/objective-c/test/Ice/defaultValue/Client.m b/objective-c/test/Ice/defaultValue/Client.m
index 12238ed5b56..883f9705a66 100644
--- a/objective-c/test/Ice/defaultValue/Client.m
+++ b/objective-c/test/Ice/defaultValue/Client.m
@@ -28,6 +28,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
ICEregisterIceSSL(YES);
+ ICEregisterIceWS(YES);
#if TARGET_OS_IPHONE && !TARGET_IPHONE_SIMULATOR
ICEregisterIceIAP(YES);
#endif
diff --git a/objective-c/test/Ice/dispatcher/Client.m b/objective-c/test/Ice/dispatcher/Client.m
index 5f391eb6720..f263f3a4b74 100644
--- a/objective-c/test/Ice/dispatcher/Client.m
+++ b/objective-c/test/Ice/dispatcher/Client.m
@@ -30,6 +30,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
ICEregisterIceSSL(YES);
+ ICEregisterIceWS(YES);
#if TARGET_OS_IPHONE && !TARGET_IPHONE_SIMULATOR
ICEregisterIceIAP(YES);
#endif
diff --git a/objective-c/test/Ice/dispatcher/Collocated.m b/objective-c/test/Ice/dispatcher/Collocated.m
index 7ee0d881987..7c915d4b2f1 100644
--- a/objective-c/test/Ice/dispatcher/Collocated.m
+++ b/objective-c/test/Ice/dispatcher/Collocated.m
@@ -48,6 +48,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
ICEregisterIceSSL(YES);
+ ICEregisterIceWS(YES);
#if TARGET_OS_IPHONE && !TARGET_IPHONE_SIMULATOR
ICEregisterIceIAP(YES);
#endif
diff --git a/objective-c/test/Ice/dispatcher/Server.m b/objective-c/test/Ice/dispatcher/Server.m
index 5789917506b..d969fb3cfa8 100644
--- a/objective-c/test/Ice/dispatcher/Server.m
+++ b/objective-c/test/Ice/dispatcher/Server.m
@@ -48,6 +48,8 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
ICEregisterIceSSL(YES);
+ ICEregisterIceWS(YES);
+ ICEregisterIceUDP(YES);
#if TARGET_OS_IPHONE && !TARGET_IPHONE_SIMULATOR
ICEregisterIceIAP(YES);
#endif
diff --git a/objective-c/test/Ice/enums/Client.m b/objective-c/test/Ice/enums/Client.m
index c6f44630a3e..2757858624f 100644
--- a/objective-c/test/Ice/enums/Client.m
+++ b/objective-c/test/Ice/enums/Client.m
@@ -31,6 +31,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
ICEregisterIceSSL(YES);
+ ICEregisterIceWS(YES);
#if TARGET_OS_IPHONE && !TARGET_IPHONE_SIMULATOR
ICEregisterIceIAP(YES);
#endif
diff --git a/objective-c/test/Ice/enums/Server.m b/objective-c/test/Ice/enums/Server.m
index 7fb25ab0bd1..8c8eb22f0ef 100644
--- a/objective-c/test/Ice/enums/Server.m
+++ b/objective-c/test/Ice/enums/Server.m
@@ -34,6 +34,8 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
ICEregisterIceSSL(YES);
+ ICEregisterIceWS(YES);
+ ICEregisterIceUDP(YES);
#if TARGET_OS_IPHONE && !TARGET_IPHONE_SIMULATOR
ICEregisterIceIAP(YES);
#endif
diff --git a/objective-c/test/Ice/exceptions/Client.m b/objective-c/test/Ice/exceptions/Client.m
index 3d44232b58c..de9e3a2155f 100644
--- a/objective-c/test/Ice/exceptions/Client.m
+++ b/objective-c/test/Ice/exceptions/Client.m
@@ -29,6 +29,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
ICEregisterIceSSL(YES);
+ ICEregisterIceWS(YES);
#if TARGET_OS_IPHONE && !TARGET_IPHONE_SIMULATOR
ICEregisterIceIAP(YES);
#endif
diff --git a/objective-c/test/Ice/exceptions/Collocated.m b/objective-c/test/Ice/exceptions/Collocated.m
index ddaebc52980..1f759d1dfe5 100644
--- a/objective-c/test/Ice/exceptions/Collocated.m
+++ b/objective-c/test/Ice/exceptions/Collocated.m
@@ -34,6 +34,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
ICEregisterIceSSL(YES);
+ ICEregisterIceWS(YES);
#if TARGET_OS_IPHONE && !TARGET_IPHONE_SIMULATOR
ICEregisterIceIAP(YES);
#endif
diff --git a/objective-c/test/Ice/exceptions/Server.m b/objective-c/test/Ice/exceptions/Server.m
index 24e97a71f92..edb44080987 100644
--- a/objective-c/test/Ice/exceptions/Server.m
+++ b/objective-c/test/Ice/exceptions/Server.m
@@ -46,6 +46,8 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
ICEregisterIceSSL(YES);
+ ICEregisterIceWS(YES);
+ ICEregisterIceUDP(YES);
#if TARGET_OS_IPHONE && !TARGET_IPHONE_SIMULATOR
ICEregisterIceIAP(YES);
#endif
diff --git a/objective-c/test/Ice/facets/Client.m b/objective-c/test/Ice/facets/Client.m
index 153f354b496..442d6d653d7 100644
--- a/objective-c/test/Ice/facets/Client.m
+++ b/objective-c/test/Ice/facets/Client.m
@@ -29,6 +29,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
ICEregisterIceSSL(YES);
+ ICEregisterIceWS(YES);
#if TARGET_OS_IPHONE && !TARGET_IPHONE_SIMULATOR
ICEregisterIceIAP(YES);
#endif
diff --git a/objective-c/test/Ice/facets/Collocated.m b/objective-c/test/Ice/facets/Collocated.m
index e8ef9ec8c58..28fb415b93a 100644
--- a/objective-c/test/Ice/facets/Collocated.m
+++ b/objective-c/test/Ice/facets/Collocated.m
@@ -39,6 +39,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
ICEregisterIceSSL(YES);
+ ICEregisterIceWS(YES);
#if TARGET_OS_IPHONE && !TARGET_IPHONE_SIMULATOR
ICEregisterIceIAP(YES);
#endif
diff --git a/objective-c/test/Ice/facets/Server.m b/objective-c/test/Ice/facets/Server.m
index d276084d57d..b99d047bd55 100644
--- a/objective-c/test/Ice/facets/Server.m
+++ b/objective-c/test/Ice/facets/Server.m
@@ -42,6 +42,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
ICEregisterIceSSL(YES);
+ ICEregisterIceWS(YES);
#if TARGET_OS_IPHONE && !TARGET_IPHONE_SIMULATOR
ICEregisterIceIAP(YES);
#endif
diff --git a/objective-c/test/Ice/faultTolerance/Client.m b/objective-c/test/Ice/faultTolerance/Client.m
index 8c0689e3ad5..2df1bba92f8 100644
--- a/objective-c/test/Ice/faultTolerance/Client.m
+++ b/objective-c/test/Ice/faultTolerance/Client.m
@@ -61,6 +61,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
ICEregisterIceSSL(YES);
+ ICEregisterIceWS(YES);
#if TARGET_OS_IPHONE && !TARGET_IPHONE_SIMULATOR
ICEregisterIceIAP(YES);
#endif
diff --git a/objective-c/test/Ice/faultTolerance/Server.m b/objective-c/test/Ice/faultTolerance/Server.m
index 9532ccac951..db6ffcb151a 100644
--- a/objective-c/test/Ice/faultTolerance/Server.m
+++ b/objective-c/test/Ice/faultTolerance/Server.m
@@ -65,6 +65,8 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
ICEregisterIceSSL(YES);
+ ICEregisterIceWS(YES);
+ ICEregisterIceUDP(YES);
#if TARGET_OS_IPHONE && !TARGET_IPHONE_SIMULATOR
ICEregisterIceIAP(YES);
#endif
diff --git a/objective-c/test/Ice/hash/Client.m b/objective-c/test/Ice/hash/Client.m
index c54ee47e0c6..451ea359303 100644
--- a/objective-c/test/Ice/hash/Client.m
+++ b/objective-c/test/Ice/hash/Client.m
@@ -28,6 +28,8 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
ICEregisterIceSSL(YES);
+ ICEregisterIceWS(YES);
+ ICEregisterIceUDP(YES);
#if TARGET_OS_IPHONE && !TARGET_IPHONE_SIMULATOR
ICEregisterIceIAP(YES);
#endif
diff --git a/objective-c/test/Ice/hold/Client.m b/objective-c/test/Ice/hold/Client.m
index 3571f6f5686..c3a0ba949b7 100644
--- a/objective-c/test/Ice/hold/Client.m
+++ b/objective-c/test/Ice/hold/Client.m
@@ -28,6 +28,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
ICEregisterIceSSL(YES);
+ ICEregisterIceWS(YES);
#if TARGET_OS_IPHONE && !TARGET_IPHONE_SIMULATOR
ICEregisterIceIAP(YES);
#endif
diff --git a/objective-c/test/Ice/hold/Server.m b/objective-c/test/Ice/hold/Server.m
index 000eb894095..4ef3089507e 100644
--- a/objective-c/test/Ice/hold/Server.m
+++ b/objective-c/test/Ice/hold/Server.m
@@ -51,6 +51,8 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
ICEregisterIceSSL(YES);
+ ICEregisterIceWS(YES);
+ ICEregisterIceUDP(YES);
#if TARGET_OS_IPHONE && !TARGET_IPHONE_SIMULATOR
ICEregisterIceIAP(YES);
#endif
diff --git a/objective-c/test/Ice/info/Client.m b/objective-c/test/Ice/info/Client.m
index a2bc84df5b6..f0559d36030 100644
--- a/objective-c/test/Ice/info/Client.m
+++ b/objective-c/test/Ice/info/Client.m
@@ -31,6 +31,8 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
ICEregisterIceSSL(YES);
+ ICEregisterIceWS(YES);
+ ICEregisterIceUDP(YES);
#if TARGET_OS_IPHONE && !TARGET_IPHONE_SIMULATOR
ICEregisterIceIAP(YES);
#endif
diff --git a/objective-c/test/Ice/info/Server.m b/objective-c/test/Ice/info/Server.m
index b5ab40f533b..70e0e0fdbae 100644
--- a/objective-c/test/Ice/info/Server.m
+++ b/objective-c/test/Ice/info/Server.m
@@ -34,6 +34,8 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
ICEregisterIceSSL(YES);
+ ICEregisterIceWS(YES);
+ ICEregisterIceUDP(YES);
#if TARGET_OS_IPHONE && !TARGET_IPHONE_SIMULATOR
ICEregisterIceIAP(YES);
#endif
diff --git a/objective-c/test/Ice/inheritance/Client.m b/objective-c/test/Ice/inheritance/Client.m
index bdc97fdd1a1..facc8d40f4a 100644
--- a/objective-c/test/Ice/inheritance/Client.m
+++ b/objective-c/test/Ice/inheritance/Client.m
@@ -29,6 +29,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
ICEregisterIceSSL(YES);
+ ICEregisterIceWS(YES);
#if TARGET_OS_IPHONE && !TARGET_IPHONE_SIMULATOR
ICEregisterIceIAP(YES);
#endif
diff --git a/objective-c/test/Ice/inheritance/Collocated.m b/objective-c/test/Ice/inheritance/Collocated.m
index e2805b4168c..034300f76db 100644
--- a/objective-c/test/Ice/inheritance/Collocated.m
+++ b/objective-c/test/Ice/inheritance/Collocated.m
@@ -34,6 +34,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
ICEregisterIceSSL(YES);
+ ICEregisterIceWS(YES);
#if TARGET_OS_IPHONE && !TARGET_IPHONE_SIMULATOR
ICEregisterIceIAP(YES);
#endif
diff --git a/objective-c/test/Ice/inheritance/Server.m b/objective-c/test/Ice/inheritance/Server.m
index ddbf8e5b00f..ac2e7d2fcea 100644
--- a/objective-c/test/Ice/inheritance/Server.m
+++ b/objective-c/test/Ice/inheritance/Server.m
@@ -35,6 +35,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
ICEregisterIceSSL(YES);
+ ICEregisterIceWS(YES);
#if TARGET_OS_IPHONE && !TARGET_IPHONE_SIMULATOR
ICEregisterIceIAP(YES);
#endif
diff --git a/objective-c/test/Ice/interceptor/Client.m b/objective-c/test/Ice/interceptor/Client.m
index 7361590fce7..65333166896 100644
--- a/objective-c/test/Ice/interceptor/Client.m
+++ b/objective-c/test/Ice/interceptor/Client.m
@@ -112,6 +112,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
ICEregisterIceSSL(YES);
+ ICEregisterIceWS(YES);
#if TARGET_OS_IPHONE && !TARGET_IPHONE_SIMULATOR
ICEregisterIceIAP(YES);
#endif
diff --git a/objective-c/test/Ice/invoke/Client.m b/objective-c/test/Ice/invoke/Client.m
index f676c9e2887..24ede6ca7a9 100644
--- a/objective-c/test/Ice/invoke/Client.m
+++ b/objective-c/test/Ice/invoke/Client.m
@@ -29,6 +29,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
ICEregisterIceSSL(YES);
+ ICEregisterIceWS(YES);
#if TARGET_OS_IPHONE && !TARGET_IPHONE_SIMULATOR
ICEregisterIceIAP(YES);
#endif
diff --git a/objective-c/test/Ice/invoke/Server.m b/objective-c/test/Ice/invoke/Server.m
index 82f4ad67710..0734b9590b4 100644
--- a/objective-c/test/Ice/invoke/Server.m
+++ b/objective-c/test/Ice/invoke/Server.m
@@ -34,6 +34,8 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
ICEregisterIceSSL(YES);
+ ICEregisterIceWS(YES);
+ ICEregisterIceUDP(YES);
#if TARGET_OS_IPHONE && !TARGET_IPHONE_SIMULATOR
ICEregisterIceIAP(YES);
#endif
diff --git a/objective-c/test/Ice/location/Client.m b/objective-c/test/Ice/location/Client.m
index fc3c6d2fbd3..d762447c36c 100644
--- a/objective-c/test/Ice/location/Client.m
+++ b/objective-c/test/Ice/location/Client.m
@@ -28,6 +28,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
ICEregisterIceSSL(YES);
+ ICEregisterIceWS(YES);
#if TARGET_OS_IPHONE && !TARGET_IPHONE_SIMULATOR
ICEregisterIceIAP(YES);
#endif
diff --git a/objective-c/test/Ice/location/Server.m b/objective-c/test/Ice/location/Server.m
index c53599a4ee5..d13e17ee228 100644
--- a/objective-c/test/Ice/location/Server.m
+++ b/objective-c/test/Ice/location/Server.m
@@ -62,6 +62,8 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
ICEregisterIceSSL(YES);
+ ICEregisterIceWS(YES);
+ ICEregisterIceUDP(YES);
#if TARGET_OS_IPHONE && !TARGET_IPHONE_SIMULATOR
ICEregisterIceIAP(YES);
#endif
diff --git a/objective-c/test/Ice/metrics/Client.m b/objective-c/test/Ice/metrics/Client.m
index c99aa7a97de..1736d9c8023 100644
--- a/objective-c/test/Ice/metrics/Client.m
+++ b/objective-c/test/Ice/metrics/Client.m
@@ -29,6 +29,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
ICEregisterIceSSL(YES);
+ ICEregisterIceWS(YES);
#if TARGET_OS_IPHONE && !TARGET_IPHONE_SIMULATOR
ICEregisterIceIAP(YES);
#endif
diff --git a/objective-c/test/Ice/metrics/Server.m b/objective-c/test/Ice/metrics/Server.m
index fd80b823655..617d52d0f4f 100644
--- a/objective-c/test/Ice/metrics/Server.m
+++ b/objective-c/test/Ice/metrics/Server.m
@@ -44,6 +44,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
ICEregisterIceSSL(YES);
+ ICEregisterIceWS(YES);
#if TARGET_OS_IPHONE && !TARGET_IPHONE_SIMULATOR
ICEregisterIceIAP(YES);
#endif
diff --git a/objective-c/test/Ice/objects/Client.m b/objective-c/test/Ice/objects/Client.m
index 31d1d81c9a8..5319d5a2b52 100644
--- a/objective-c/test/Ice/objects/Client.m
+++ b/objective-c/test/Ice/objects/Client.m
@@ -110,6 +110,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
ICEregisterIceSSL(YES);
+ ICEregisterIceWS(YES);
#if TARGET_OS_IPHONE && !TARGET_IPHONE_SIMULATOR
ICEregisterIceIAP(YES);
#endif
diff --git a/objective-c/test/Ice/objects/Collocated.m b/objective-c/test/Ice/objects/Collocated.m
index 855cf3bbd4a..77a456b280c 100644
--- a/objective-c/test/Ice/objects/Collocated.m
+++ b/objective-c/test/Ice/objects/Collocated.m
@@ -120,6 +120,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
ICEregisterIceSSL(YES);
+ ICEregisterIceWS(YES);
#if TARGET_OS_IPHONE && !TARGET_IPHONE_SIMULATOR
ICEregisterIceIAP(YES);
#endif
diff --git a/objective-c/test/Ice/objects/Server.m b/objective-c/test/Ice/objects/Server.m
index 5b4944e6ffd..0e168022ee8 100644
--- a/objective-c/test/Ice/objects/Server.m
+++ b/objective-c/test/Ice/objects/Server.m
@@ -68,6 +68,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
ICEregisterIceSSL(YES);
+ ICEregisterIceWS(YES);
#if TARGET_OS_IPHONE && !TARGET_IPHONE_SIMULATOR
ICEregisterIceIAP(YES);
#endif
diff --git a/objective-c/test/Ice/operations/Client.m b/objective-c/test/Ice/operations/Client.m
index 413875f8da8..69e1209ab7a 100644
--- a/objective-c/test/Ice/operations/Client.m
+++ b/objective-c/test/Ice/operations/Client.m
@@ -40,6 +40,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
ICEregisterIceSSL(YES);
+ ICEregisterIceWS(YES);
#if TARGET_OS_IPHONE && !TARGET_IPHONE_SIMULATOR
ICEregisterIceIAP(YES);
#endif
diff --git a/objective-c/test/Ice/operations/Collocated.m b/objective-c/test/Ice/operations/Collocated.m
index 4ec378f938d..be0e7772513 100644
--- a/objective-c/test/Ice/operations/Collocated.m
+++ b/objective-c/test/Ice/operations/Collocated.m
@@ -37,6 +37,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
ICEregisterIceSSL(YES);
+ ICEregisterIceWS(YES);
#if TARGET_OS_IPHONE && !TARGET_IPHONE_SIMULATOR
ICEregisterIceIAP(YES);
#endif
diff --git a/objective-c/test/Ice/operations/Server.m b/objective-c/test/Ice/operations/Server.m
index b0d35367ea2..19c2b58e29d 100644
--- a/objective-c/test/Ice/operations/Server.m
+++ b/objective-c/test/Ice/operations/Server.m
@@ -35,6 +35,8 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
ICEregisterIceSSL(YES);
+ ICEregisterIceWS(YES);
+ ICEregisterIceUDP(YES);
#if TARGET_OS_IPHONE && !TARGET_IPHONE_SIMULATOR
ICEregisterIceIAP(YES);
#endif
diff --git a/objective-c/test/Ice/optional/Client.m b/objective-c/test/Ice/optional/Client.m
index d0a90b66eb7..e2a7ca2669a 100644
--- a/objective-c/test/Ice/optional/Client.m
+++ b/objective-c/test/Ice/optional/Client.m
@@ -29,6 +29,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
ICEregisterIceSSL(YES);
+ ICEregisterIceWS(YES);
#if TARGET_OS_IPHONE && !TARGET_IPHONE_SIMULATOR
ICEregisterIceIAP(YES);
#endif
diff --git a/objective-c/test/Ice/optional/Server.m b/objective-c/test/Ice/optional/Server.m
index ebda1e4220c..df864c790c2 100644
--- a/objective-c/test/Ice/optional/Server.m
+++ b/objective-c/test/Ice/optional/Server.m
@@ -35,6 +35,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
ICEregisterIceSSL(YES);
+ ICEregisterIceWS(YES);
#if TARGET_OS_IPHONE && !TARGET_IPHONE_SIMULATOR
ICEregisterIceIAP(YES);
#endif
diff --git a/objective-c/test/Ice/proxy/Client.m b/objective-c/test/Ice/proxy/Client.m
index 05253f0600d..5bfdae67b49 100644
--- a/objective-c/test/Ice/proxy/Client.m
+++ b/objective-c/test/Ice/proxy/Client.m
@@ -31,6 +31,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
ICEregisterIceSSL(YES);
+ ICEregisterIceWS(YES);
#if TARGET_OS_IPHONE && !TARGET_IPHONE_SIMULATOR
ICEregisterIceIAP(YES);
#endif
diff --git a/objective-c/test/Ice/proxy/Collocated.m b/objective-c/test/Ice/proxy/Collocated.m
index aaec643f134..befd16d3407 100644
--- a/objective-c/test/Ice/proxy/Collocated.m
+++ b/objective-c/test/Ice/proxy/Collocated.m
@@ -35,6 +35,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
ICEregisterIceSSL(YES);
+ ICEregisterIceWS(YES);
#if TARGET_OS_IPHONE && !TARGET_IPHONE_SIMULATOR
ICEregisterIceIAP(YES);
#endif
diff --git a/objective-c/test/Ice/proxy/Server.m b/objective-c/test/Ice/proxy/Server.m
index afbaafccc63..c954ab9f077 100644
--- a/objective-c/test/Ice/proxy/Server.m
+++ b/objective-c/test/Ice/proxy/Server.m
@@ -35,6 +35,8 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
ICEregisterIceSSL(YES);
+ ICEregisterIceWS(YES);
+ ICEregisterIceUDP(YES);
#if TARGET_OS_IPHONE && !TARGET_IPHONE_SIMULATOR
ICEregisterIceIAP(YES);
#endif
diff --git a/objective-c/test/Ice/retry/Client.m b/objective-c/test/Ice/retry/Client.m
index 7c2e89261c8..30f0a614c70 100644
--- a/objective-c/test/Ice/retry/Client.m
+++ b/objective-c/test/Ice/retry/Client.m
@@ -29,6 +29,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
ICEregisterIceSSL(YES);
+ ICEregisterIceWS(YES);
#if TARGET_OS_IPHONE && !TARGET_IPHONE_SIMULATOR
ICEregisterIceIAP(YES);
#endif
diff --git a/objective-c/test/Ice/retry/Collocated.m b/objective-c/test/Ice/retry/Collocated.m
index 564b1acad00..14edaad5054 100644
--- a/objective-c/test/Ice/retry/Collocated.m
+++ b/objective-c/test/Ice/retry/Collocated.m
@@ -36,6 +36,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
ICEregisterIceSSL(YES);
+ ICEregisterIceWS(YES);
#if TARGET_OS_IPHONE && !TARGET_IPHONE_SIMULATOR
ICEregisterIceIAP(YES);
#endif
diff --git a/objective-c/test/Ice/retry/Server.m b/objective-c/test/Ice/retry/Server.m
index e6edf5c4947..6da2307a320 100644
--- a/objective-c/test/Ice/retry/Server.m
+++ b/objective-c/test/Ice/retry/Server.m
@@ -35,6 +35,8 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
ICEregisterIceSSL(YES);
+ ICEregisterIceWS(YES);
+ ICEregisterIceUDP(YES);
#if TARGET_OS_IPHONE && !TARGET_IPHONE_SIMULATOR
ICEregisterIceIAP(YES);
#endif
diff --git a/objective-c/test/Ice/servantLocator/Client.m b/objective-c/test/Ice/servantLocator/Client.m
index c2aa07d8d4f..ff1d97fcd82 100644
--- a/objective-c/test/Ice/servantLocator/Client.m
+++ b/objective-c/test/Ice/servantLocator/Client.m
@@ -29,6 +29,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
ICEregisterIceSSL(YES);
+ ICEregisterIceWS(YES);
#if TARGET_OS_IPHONE && !TARGET_IPHONE_SIMULATOR
ICEregisterIceIAP(YES);
#endif
diff --git a/objective-c/test/Ice/servantLocator/Collocated.m b/objective-c/test/Ice/servantLocator/Collocated.m
index 600149678fc..376e568a8f9 100644
--- a/objective-c/test/Ice/servantLocator/Collocated.m
+++ b/objective-c/test/Ice/servantLocator/Collocated.m
@@ -84,6 +84,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
ICEregisterIceSSL(YES);
+ ICEregisterIceWS(YES);
#if TARGET_OS_IPHONE && !TARGET_IPHONE_SIMULATOR
ICEregisterIceIAP(YES);
#endif
diff --git a/objective-c/test/Ice/servantLocator/Server.m b/objective-c/test/Ice/servantLocator/Server.m
index b5642e169e2..154db32fc36 100644
--- a/objective-c/test/Ice/servantLocator/Server.m
+++ b/objective-c/test/Ice/servantLocator/Server.m
@@ -85,6 +85,8 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
ICEregisterIceSSL(YES);
+ ICEregisterIceWS(YES);
+ ICEregisterIceUDP(YES);
#if TARGET_OS_IPHONE && !TARGET_IPHONE_SIMULATOR
ICEregisterIceIAP(YES);
#endif
diff --git a/objective-c/test/Ice/services/Client.m b/objective-c/test/Ice/services/Client.m
index 61113310731..55a9ad88896 100644
--- a/objective-c/test/Ice/services/Client.m
+++ b/objective-c/test/Ice/services/Client.m
@@ -28,6 +28,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
ICEregisterIceSSL(YES);
+ ICEregisterIceWS(YES);
#if TARGET_OS_IPHONE && !TARGET_IPHONE_SIMULATOR
ICEregisterIceIAP(YES);
#endif
diff --git a/objective-c/test/Ice/slicing/exceptions/Client.m b/objective-c/test/Ice/slicing/exceptions/Client.m
index 4580adb8a7c..dd71732368a 100644
--- a/objective-c/test/Ice/slicing/exceptions/Client.m
+++ b/objective-c/test/Ice/slicing/exceptions/Client.m
@@ -29,6 +29,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
ICEregisterIceSSL(YES);
+ ICEregisterIceWS(YES);
#if TARGET_OS_IPHONE && !TARGET_IPHONE_SIMULATOR
ICEregisterIceIAP(YES);
#endif
diff --git a/objective-c/test/Ice/slicing/exceptions/Server.m b/objective-c/test/Ice/slicing/exceptions/Server.m
index df5503f27bb..5a100875740 100644
--- a/objective-c/test/Ice/slicing/exceptions/Server.m
+++ b/objective-c/test/Ice/slicing/exceptions/Server.m
@@ -36,6 +36,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
ICEregisterIceSSL(YES);
+ ICEregisterIceWS(YES);
#if TARGET_OS_IPHONE && !TARGET_IPHONE_SIMULATOR
ICEregisterIceIAP(YES);
#endif
diff --git a/objective-c/test/Ice/slicing/objects/Client.m b/objective-c/test/Ice/slicing/objects/Client.m
index 6ad9a914ac1..36a05f68fca 100644
--- a/objective-c/test/Ice/slicing/objects/Client.m
+++ b/objective-c/test/Ice/slicing/objects/Client.m
@@ -29,6 +29,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
ICEregisterIceSSL(YES);
+ ICEregisterIceWS(YES);
#if TARGET_OS_IPHONE && !TARGET_IPHONE_SIMULATOR
ICEregisterIceIAP(YES);
#endif
diff --git a/objective-c/test/Ice/slicing/objects/Server.m b/objective-c/test/Ice/slicing/objects/Server.m
index 96044c69053..395d044780d 100644
--- a/objective-c/test/Ice/slicing/objects/Server.m
+++ b/objective-c/test/Ice/slicing/objects/Server.m
@@ -37,6 +37,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
ICEregisterIceSSL(YES);
+ ICEregisterIceWS(YES);
#if TARGET_OS_IPHONE && !TARGET_IPHONE_SIMULATOR
ICEregisterIceIAP(YES);
#endif
diff --git a/objective-c/test/Ice/stream/Client.m b/objective-c/test/Ice/stream/Client.m
index 3ac8ce8ee8d..f465c15dfa6 100644
--- a/objective-c/test/Ice/stream/Client.m
+++ b/objective-c/test/Ice/stream/Client.m
@@ -922,6 +922,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
ICEregisterIceSSL(YES);
+ ICEregisterIceWS(YES);
#if TARGET_OS_IPHONE && !TARGET_IPHONE_SIMULATOR
ICEregisterIceIAP(YES);
#endif
diff --git a/objective-c/test/Ice/timeout/Client.m b/objective-c/test/Ice/timeout/Client.m
index 9daf988d8cc..6acae94b5bc 100644
--- a/objective-c/test/Ice/timeout/Client.m
+++ b/objective-c/test/Ice/timeout/Client.m
@@ -29,6 +29,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
ICEregisterIceSSL(YES);
+ ICEregisterIceWS(YES);
#if TARGET_OS_IPHONE && !TARGET_IPHONE_SIMULATOR
ICEregisterIceIAP(YES);
#endif
diff --git a/objective-c/test/Ice/timeout/Server.m b/objective-c/test/Ice/timeout/Server.m
index e56f10fea41..06b96f9a031 100644
--- a/objective-c/test/Ice/timeout/Server.m
+++ b/objective-c/test/Ice/timeout/Server.m
@@ -35,6 +35,8 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
ICEregisterIceSSL(YES);
+ ICEregisterIceWS(YES);
+ ICEregisterIceUDP(YES);
#if TARGET_OS_IPHONE && !TARGET_IPHONE_SIMULATOR
ICEregisterIceIAP(YES);
#endif
diff --git a/objective-c/test/Slice/escape/Client.m b/objective-c/test/Slice/escape/Client.m
index 6a670e0da15..5e7803d169b 100644
--- a/objective-c/test/Slice/escape/Client.m
+++ b/objective-c/test/Slice/escape/Client.m
@@ -178,6 +178,7 @@ main(int argc, char* argv[])
{
#ifdef ICE_STATIC_LIBS
ICEregisterIceSSL(YES);
+ ICEregisterIceWS(YES);
#endif
int status;