zeroc-ice 3.8.2 → 3.8.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/dist/IceRuby/Communicator.cpp +26 -9
- data/dist/IceRuby/Config.h +0 -12
- data/dist/IceRuby/Connection.cpp +18 -9
- data/dist/IceRuby/DefaultSliceLoader.h +1 -1
- data/dist/IceRuby/Endpoint.cpp +21 -8
- data/dist/IceRuby/Operation.cpp +7 -5
- data/dist/IceRuby/Properties.cpp +3 -4
- data/dist/IceRuby/Proxy.cpp +11 -19
- data/dist/IceRuby/RubySliceLoader.cpp +1 -1
- data/dist/IceRuby/RubySliceLoader.h +6 -0
- data/dist/IceRuby/Types.cpp +162 -138
- data/dist/IceRuby/Types.h +68 -28
- data/dist/IceRuby/Util.cpp +14 -78
- data/dist/IceRuby/Util.h +7 -17
- data/dist/ice/cpp/include/Ice/Communicator.h +31 -8
- data/dist/ice/cpp/include/Ice/Config.h +2 -2
- data/dist/ice/cpp/include/Ice/Connection.h +24 -8
- data/dist/ice/cpp/include/Ice/CtrlCHandler.h +1 -1
- data/dist/ice/cpp/include/Ice/Demangle.h +1 -1
- data/dist/ice/cpp/include/Ice/Endpoint.h +4 -4
- data/dist/ice/cpp/include/Ice/Initialize.h +4 -4
- data/dist/ice/cpp/include/Ice/InputStream.h +5 -5
- data/dist/ice/cpp/include/Ice/Instrumentation.h +13 -7
- data/dist/ice/cpp/include/Ice/LocalExceptions.h +5 -5
- data/dist/ice/cpp/include/Ice/Logger.h +7 -0
- data/dist/ice/cpp/include/Ice/LoggerUtil.h +1 -1
- data/dist/ice/cpp/include/Ice/Object.h +10 -8
- data/dist/ice/cpp/include/Ice/ObjectAdapter.h +1 -1
- data/dist/ice/cpp/include/Ice/OutgoingAsync.h +5 -2
- data/dist/ice/cpp/include/Ice/OutgoingResponse.h +2 -1
- data/dist/ice/cpp/include/Ice/OutputStream.h +7 -6
- data/dist/ice/cpp/include/Ice/PluginFactory.h +1 -1
- data/dist/ice/cpp/include/Ice/Properties.h +3 -3
- data/dist/ice/cpp/include/Ice/Proxy.h +192 -50
- data/dist/ice/cpp/include/Ice/SSL/ClientAuthenticationOptions.h +3 -3
- data/dist/ice/cpp/include/Ice/SSL/EndpointInfo.h +1 -1
- data/dist/ice/cpp/include/Ice/SSL/ServerAuthenticationOptions.h +5 -5
- data/dist/ice/cpp/include/Ice/ServantLocator.h +1 -1
- data/dist/ice/cpp/include/Ice/Service.h +2 -5
- data/dist/ice/cpp/include/Ice/SliceLoader.h +1 -1
- data/dist/ice/cpp/include/Ice/SlicedData.h +5 -3
- data/dist/ice/cpp/include/Ice/StreamHelpers.h +1 -1
- data/dist/ice/cpp/include/Ice/StreamableTraits.h +2 -2
- data/dist/ice/cpp/include/Ice/StringConverter.h +2 -3
- data/dist/ice/cpp/include/Ice/StringUtil.h +2 -7
- data/dist/ice/cpp/include/Ice/UUID.h +1 -0
- data/dist/ice/cpp/include/Ice/Value.h +2 -2
- data/dist/ice/cpp/include/generated/Ice/BuiltinSequences.h +2 -2
- data/dist/ice/cpp/include/generated/Ice/Context.h +2 -2
- data/dist/ice/cpp/include/generated/Ice/EndpointTypes.h +2 -2
- data/dist/ice/cpp/include/generated/Ice/Identity.h +2 -2
- data/dist/ice/cpp/include/generated/Ice/Locator.h +50 -14
- data/dist/ice/cpp/include/generated/Ice/LocatorRegistry.h +38 -11
- data/dist/ice/cpp/include/generated/Ice/Metrics.h +94 -39
- data/dist/ice/cpp/include/generated/Ice/OperationMode.h +2 -2
- data/dist/ice/cpp/include/generated/Ice/Process.h +34 -8
- data/dist/ice/cpp/include/generated/Ice/PropertiesAdmin.h +42 -11
- data/dist/ice/cpp/include/generated/Ice/PropertyDict.h +2 -2
- data/dist/ice/cpp/include/generated/Ice/RemoteLogger.h +93 -40
- data/dist/ice/cpp/include/generated/Ice/ReplyStatus.h +2 -2
- data/dist/ice/cpp/include/generated/Ice/Router.h +50 -14
- data/dist/ice/cpp/include/generated/Ice/SliceChecksumDict.h +2 -2
- data/dist/ice/cpp/include/generated/Ice/Version.h +2 -2
- data/dist/ice/cpp/include/generated/IceDiscovery/Lookup.h +66 -14
- data/dist/ice/cpp/include/generated/IceLocatorDiscovery/Lookup.h +34 -8
- data/dist/ice/cpp/src/Ice/AddDefaultPluginFactories_all.cpp +1 -1
- data/dist/ice/cpp/src/Ice/Base64.cpp +47 -137
- data/dist/ice/cpp/src/Ice/Base64.h +2 -2
- data/dist/ice/cpp/src/Ice/BatchRequestQueue.cpp +28 -13
- data/dist/ice/cpp/src/Ice/BatchRequestQueue.h +5 -1
- data/dist/ice/cpp/src/Ice/Buffer.cpp +1 -1
- data/dist/ice/cpp/src/Ice/CollocatedRequestHandler.cpp +1 -1
- data/dist/ice/cpp/src/Ice/CollocatedRequestHandler.h +1 -1
- data/dist/ice/cpp/src/Ice/Communicator.cpp +4 -3
- data/dist/ice/cpp/src/Ice/CommunicatorFlushBatchAsync.cpp +8 -0
- data/dist/ice/cpp/src/Ice/ConnectRequestHandler.cpp +5 -15
- data/dist/ice/cpp/src/Ice/ConnectRequestHandler.h +1 -1
- data/dist/ice/cpp/src/Ice/ConnectionFactory.cpp +6 -8
- data/dist/ice/cpp/src/Ice/ConnectionFactory.h +0 -3
- data/dist/ice/cpp/src/Ice/ConnectionI.cpp +94 -99
- data/dist/ice/cpp/src/Ice/ConnectionI.h +11 -8
- data/dist/ice/cpp/src/Ice/ConsoleUtil.cpp +1 -1
- data/dist/ice/cpp/src/Ice/DefaultsAndOverrides.cpp +10 -14
- data/dist/ice/cpp/src/Ice/EndpointI.h +1 -1
- data/dist/ice/cpp/src/Ice/FileUtil.cpp +12 -12
- data/dist/ice/cpp/src/Ice/FixedRequestHandler.cpp +1 -1
- data/dist/ice/cpp/src/Ice/FixedRequestHandler.h +1 -1
- data/dist/ice/cpp/src/Ice/HttpParser.h +0 -2
- data/dist/ice/cpp/src/Ice/IdleTimeoutTransceiverDecorator.cpp +6 -3
- data/dist/ice/cpp/src/Ice/IncomingRequest.cpp +1 -3
- data/dist/ice/cpp/src/Ice/InputStream.cpp +23 -19
- data/dist/ice/cpp/src/Ice/Instance.cpp +73 -50
- data/dist/ice/cpp/src/Ice/Instance.h +1 -6
- data/dist/ice/cpp/src/Ice/LocalExceptions.cpp +1 -1
- data/dist/ice/cpp/src/Ice/LocatorInfo.cpp +2 -2
- data/dist/ice/cpp/src/Ice/LoggerAdminI.cpp +13 -18
- data/dist/ice/cpp/src/Ice/LoggerI.cpp +1 -1
- data/dist/ice/cpp/src/Ice/LoggerI.h +2 -2
- data/dist/ice/cpp/src/Ice/MetricsAdminI.h +6 -1
- data/dist/ice/cpp/src/Ice/MetricsObserverI.h +22 -18
- data/dist/ice/cpp/src/Ice/NativePropertiesAdmin.cpp +5 -2
- data/dist/ice/cpp/src/Ice/Network.cpp +168 -103
- data/dist/ice/cpp/src/Ice/Network.h +12 -7
- data/dist/ice/cpp/src/Ice/NetworkProxy.cpp +17 -6
- data/dist/ice/cpp/src/Ice/NetworkProxy.h +2 -1
- data/dist/ice/cpp/src/Ice/Object.cpp +1 -1
- data/dist/ice/cpp/src/Ice/ObjectAdapterI.cpp +56 -19
- data/dist/ice/cpp/src/Ice/OpaqueEndpointI.cpp +10 -10
- data/dist/ice/cpp/src/Ice/Options.cpp +7 -2
- data/dist/ice/cpp/src/Ice/OutgoingAsync.cpp +1 -1
- data/dist/ice/cpp/src/Ice/OutputStream.cpp +4 -4
- data/dist/ice/cpp/src/Ice/PluginManagerI.cpp +7 -1
- data/dist/ice/cpp/src/Ice/Properties.cpp +26 -16
- data/dist/ice/cpp/src/Ice/PropertyUtil.cpp +1 -1
- data/dist/ice/cpp/src/Ice/ProtocolInstance.cpp +0 -11
- data/dist/ice/cpp/src/Ice/ProtocolInstance.h +1 -2
- data/dist/ice/cpp/src/Ice/Proxy.cpp +9 -1
- data/dist/ice/cpp/src/Ice/ProxyAsync.cpp +110 -13
- data/dist/ice/cpp/src/Ice/Random.cpp +68 -7
- data/dist/ice/cpp/src/Ice/Random.h +6 -2
- data/dist/ice/cpp/src/Ice/Reference.cpp +22 -11
- data/dist/ice/cpp/src/Ice/Reference.h +3 -0
- data/dist/ice/cpp/src/Ice/ReferenceFactory.cpp +10 -0
- data/dist/ice/cpp/src/Ice/RequestHandler.h +3 -1
- data/dist/ice/cpp/src/Ice/RequestHandlerCache.cpp +1 -1
- data/dist/ice/cpp/src/Ice/RequestHandlerCache.h +1 -1
- data/dist/ice/cpp/src/Ice/ResourceConfig.h +3 -3
- data/dist/ice/cpp/src/Ice/RetryQueue.cpp +8 -12
- data/dist/ice/cpp/src/Ice/SHA1.cpp +11 -11
- data/dist/ice/cpp/src/Ice/SSL/DistinguishedName.cpp +0 -6
- data/dist/ice/cpp/src/Ice/SSL/DistinguishedName.h +0 -6
- data/dist/ice/cpp/src/Ice/SSL/OpenSSLEngine.cpp +15 -1
- data/dist/ice/cpp/src/Ice/SSL/OpenSSLTransceiverI.cpp +77 -27
- data/dist/ice/cpp/src/Ice/SSL/OpenSSLTransceiverI.h +2 -1
- data/dist/ice/cpp/src/Ice/SSL/RFC2253.cpp +2 -2
- data/dist/ice/cpp/src/Ice/SSL/SSLUtil.cpp +39 -34
- data/dist/ice/cpp/src/Ice/SSL/SchannelEngine.cpp +130 -52
- data/dist/ice/cpp/src/Ice/SSL/SchannelTransceiverI.cpp +64 -33
- data/dist/ice/cpp/src/Ice/SSL/SchannelTransceiverI.h +0 -1
- data/dist/ice/cpp/src/Ice/SSL/SecureTransportEngine.cpp +3 -3
- data/dist/ice/cpp/src/Ice/SSL/SecureTransportTransceiverI.cpp +9 -3
- data/dist/ice/cpp/src/Ice/SSL/SecureTransportUtil.cpp +73 -51
- data/dist/ice/cpp/src/Ice/SSL/SecureTransportUtil.h +0 -8
- data/dist/ice/cpp/src/Ice/Selector.cpp +13 -11
- data/dist/ice/cpp/src/Ice/ServantManager.cpp +3 -3
- data/dist/ice/cpp/src/Ice/Service.cpp +33 -115
- data/dist/ice/cpp/src/Ice/StreamSocket.cpp +33 -40
- data/dist/ice/cpp/src/Ice/StreamSocket.h +4 -4
- data/dist/ice/cpp/src/Ice/StringConverter.cpp +1 -1
- data/dist/ice/cpp/src/Ice/StringUtil.cpp +12 -21
- data/dist/ice/cpp/src/Ice/SysLoggerI.cpp +136 -100
- data/dist/ice/cpp/src/Ice/SysLoggerI.h +7 -3
- data/dist/ice/cpp/src/Ice/SystemdJournalI.cpp +1 -1
- data/dist/ice/cpp/src/Ice/TcpAcceptor.cpp +7 -7
- data/dist/ice/cpp/src/Ice/TcpAcceptor.h +2 -1
- data/dist/ice/cpp/src/Ice/TcpBufSize.h +40 -0
- data/dist/ice/cpp/src/Ice/TcpConnector.cpp +5 -2
- data/dist/ice/cpp/src/Ice/TcpConnector.h +2 -0
- data/dist/ice/cpp/src/Ice/TcpTransceiver.cpp +6 -2
- data/dist/ice/cpp/src/Ice/ThreadPool.cpp +2 -8
- data/dist/ice/cpp/src/Ice/ThreadPool.h +0 -2
- data/dist/ice/cpp/src/Ice/Timer.cpp +7 -3
- data/dist/ice/cpp/src/Ice/UUID.cpp +1 -2
- data/dist/ice/cpp/src/Ice/UdpEndpointI.cpp +4 -1
- data/dist/ice/cpp/src/Ice/UdpTransceiver.cpp +136 -123
- data/dist/ice/cpp/src/Ice/UdpTransceiver.h +3 -4
- data/dist/ice/cpp/src/Ice/WSTransceiver.cpp +96 -27
- data/dist/ice/cpp/src/Ice/WSTransceiver.h +1 -1
- data/dist/ice/cpp/src/Ice/generated/BuiltinSequences.cpp +2 -2
- data/dist/ice/cpp/src/Ice/generated/Context.cpp +2 -2
- data/dist/ice/cpp/src/Ice/generated/EndpointTypes.cpp +2 -2
- data/dist/ice/cpp/src/Ice/generated/Identity.cpp +2 -2
- data/dist/ice/cpp/src/Ice/generated/Locator.cpp +2 -2
- data/dist/ice/cpp/src/Ice/generated/LocatorRegistry.cpp +2 -2
- data/dist/ice/cpp/src/Ice/generated/Metrics.cpp +2 -2
- data/dist/ice/cpp/src/Ice/generated/OperationMode.cpp +2 -2
- data/dist/ice/cpp/src/Ice/generated/Process.cpp +2 -2
- data/dist/ice/cpp/src/Ice/generated/PropertiesAdmin.cpp +2 -2
- data/dist/ice/cpp/src/Ice/generated/PropertyDict.cpp +2 -2
- data/dist/ice/cpp/src/Ice/generated/RemoteLogger.cpp +2 -2
- data/dist/ice/cpp/src/Ice/generated/ReplyStatus.cpp +2 -2
- data/dist/ice/cpp/src/Ice/generated/Router.cpp +2 -2
- data/dist/ice/cpp/src/Ice/generated/SliceChecksumDict.cpp +2 -2
- data/dist/ice/cpp/src/Ice/generated/Version.cpp +2 -2
- data/dist/ice/cpp/src/IceDiscovery/LookupI.cpp +47 -9
- data/dist/ice/cpp/src/IceDiscovery/LookupI.h +8 -3
- data/dist/ice/cpp/src/IceDiscovery/generated/Lookup.cpp +2 -2
- data/dist/ice/cpp/src/IceLocatorDiscovery/PluginI.cpp +43 -14
- data/dist/ice/cpp/src/IceLocatorDiscovery/generated/Lookup.cpp +2 -2
- data/dist/ice/cpp/src/Slice/DocCommentParser.cpp +26 -20
- data/dist/ice/cpp/src/Slice/DocCommentParser.h +2 -2
- data/dist/ice/cpp/src/Slice/FileTracker.cpp +3 -11
- data/dist/ice/cpp/src/Slice/FileTracker.h +0 -2
- data/dist/ice/cpp/src/Slice/Grammar.cpp +211 -210
- data/dist/ice/cpp/src/Slice/MetadataValidation.cpp +10 -9
- data/dist/ice/cpp/src/Slice/Parser.cpp +28 -20
- data/dist/ice/cpp/src/Slice/Parser.h +3 -4
- data/dist/ice/cpp/src/Slice/Preprocessor.cpp +3 -11
- data/dist/ice/cpp/src/Slice/Preprocessor.h +0 -2
- data/dist/ice/cpp/src/Slice/Scanner.cpp +3 -3
- data/dist/ice/cpp/src/Slice/SliceUtil.cpp +197 -114
- data/dist/ice/cpp/src/Slice/StringLiteralUtil.cpp +0 -2
- data/dist/ice/cpp/src/Slice/Util.h +21 -9
- data/dist/ice/cpp/src/slice2rb/Ruby.cpp +7 -3
- data/dist/ice/cpp/src/slice2rb/RubyUtil.cpp +16 -12
- data/dist/ice/cpp/src/slice2rb/RubyUtil.h +3 -3
- data/dist/ice/slice/Glacier2/Router.ice +3 -3
- data/dist/ice/slice/Ice/Metrics.ice +6 -5
- data/dist/ice/slice/Ice/RemoteLogger.ice +5 -5
- data/dist/ice/slice/IceGrid/Admin.ice +9 -9
- data/dist/ice/slice/IceGrid/Descriptor.ice +5 -5
- data/dist/ice/slice/IceStorm/Metrics.ice +1 -1
- data/dist/lib/Glacier2/Metrics.rb +1 -1
- data/dist/lib/Glacier2/PermissionsVerifier.rb +1 -1
- data/dist/lib/Glacier2/Router.rb +2 -2
- data/dist/lib/Glacier2/SSLInfo.rb +1 -1
- data/dist/lib/Glacier2/Session.rb +1 -1
- data/dist/lib/Ice/BuiltinSequences.rb +1 -1
- data/dist/lib/Ice/CompressBatch.rb +1 -2
- data/dist/lib/Ice/Context.rb +1 -1
- data/dist/lib/Ice/EndpointSelectionType.rb +1 -2
- data/dist/lib/Ice/EndpointTypes.rb +1 -1
- data/dist/lib/Ice/Identity.rb +1 -1
- data/dist/lib/Ice/IdentitySpaceship.rb +1 -0
- data/dist/lib/Ice/Locator.rb +1 -1
- data/dist/lib/Ice/LocatorRegistry.rb +1 -1
- data/dist/lib/Ice/Metrics.rb +1 -1
- data/dist/lib/Ice/OperationMode.rb +2 -3
- data/dist/lib/Ice/Process.rb +1 -1
- data/dist/lib/Ice/PropertiesAdmin.rb +1 -1
- data/dist/lib/Ice/PropertyDict.rb +1 -1
- data/dist/lib/Ice/RemoteLogger.rb +2 -3
- data/dist/lib/Ice/ReplyStatus.rb +2 -3
- data/dist/lib/Ice/Router.rb +1 -1
- data/dist/lib/Ice/SliceChecksumDict.rb +1 -1
- data/dist/lib/Ice/SliceUtil.rb +2 -2
- data/dist/lib/Ice/Struct.rb +1 -0
- data/dist/lib/Ice/ToStringMode.rb +1 -2
- data/dist/lib/Ice/Value.rb +2 -2
- data/dist/lib/Ice/Version.rb +1 -1
- data/dist/lib/IceBox/ServiceManager.rb +1 -1
- data/dist/lib/IceGrid/Admin.rb +3 -4
- data/dist/lib/IceGrid/Descriptor.rb +1 -1
- data/dist/lib/IceGrid/Exception.rb +1 -1
- data/dist/lib/IceGrid/FileParser.rb +1 -1
- data/dist/lib/IceGrid/Registry.rb +2 -3
- data/dist/lib/IceGrid/Session.rb +2 -2
- data/dist/lib/IceGrid/UserAccountMapper.rb +1 -1
- data/dist/lib/IceStorm/IceStorm.rb +1 -1
- data/dist/lib/IceStorm/Metrics.rb +1 -1
- data/extconf.rb +1 -1
- data/ice.gemspec +3 -3
- metadata +4 -5
- data/dist/ice/cpp/src/Ice/DLLMain.cpp +0 -40
- data/dist/ice/cpp/src/Ice/UndefSysMacros.h +0 -37
|
@@ -28,7 +28,6 @@ namespace Ice
|
|
|
28
28
|
/// - managing properties (configuration), retries, logging, instrumentation, and more.
|
|
29
29
|
/// You create a communicator with `Ice::initialize`, and it's usually the first object you create when programming
|
|
30
30
|
/// with Ice. You can create multiple communicators in a single program, but this is not common.
|
|
31
|
-
/// @see ::initialize(int&, const char*[])
|
|
32
31
|
/// @see ::initialize(InitializationData)
|
|
33
32
|
/// @headerfile Ice/Ice.h
|
|
34
33
|
class ICE_API Communicator final : public std::enable_shared_from_this<Communicator>
|
|
@@ -43,8 +42,8 @@ namespace Ice
|
|
|
43
42
|
void destroy() noexcept;
|
|
44
43
|
|
|
45
44
|
/// Destroys this communicator asynchronously.
|
|
46
|
-
/// @param completed
|
|
47
|
-
/// exception.
|
|
45
|
+
/// @param completed If not @c nullptr, this callback is called when the destruction is complete. It must not
|
|
46
|
+
/// throw any exception.
|
|
48
47
|
/// @remark This function starts a thread to call #destroy and @p completed unless you call this function on a
|
|
49
48
|
/// communicator that has already been destroyed, in which case @p completed is called by the current thread.
|
|
50
49
|
/// @see #destroy
|
|
@@ -65,8 +64,8 @@ namespace Ice
|
|
|
65
64
|
/// Waits until this communicator is shut down.
|
|
66
65
|
/// @param completed The callback to call when the shutdown is complete. This function must not throw any
|
|
67
66
|
/// exception.
|
|
68
|
-
/// @remark
|
|
69
|
-
///
|
|
67
|
+
/// @remark The callback is usually called by a dedicated background thread. It can also be called by the
|
|
68
|
+
/// current thread when the shutdown has already completed.
|
|
70
69
|
/// @see #shutdown
|
|
71
70
|
void waitForShutdownAsync(std::function<void()> completed) noexcept;
|
|
72
71
|
|
|
@@ -80,6 +79,7 @@ namespace Ice
|
|
|
80
79
|
/// @param str The stringified proxy to convert into a proxy.
|
|
81
80
|
/// @return The proxy, or nullopt if @p str is an empty string.
|
|
82
81
|
/// @throws ParseException Thrown when @p str is not a valid proxy string.
|
|
82
|
+
/// @throws CommunicatorDestroyedException Thrown when the communicator has been destroyed.
|
|
83
83
|
/// @see #proxyToString
|
|
84
84
|
template<typename Prx = ObjectPrx, std::enable_if_t<std::is_base_of_v<ObjectPrx, Prx>, bool> = true>
|
|
85
85
|
std::optional<Prx> stringToProxy(std::string_view str) const
|
|
@@ -107,6 +107,8 @@ namespace Ice
|
|
|
107
107
|
/// @tparam Prx The type of the proxy to return.
|
|
108
108
|
/// @param property The base property name.
|
|
109
109
|
/// @return The proxy, or nullopt if the property is not set.
|
|
110
|
+
/// @throws ParseException Thrown when the property value is not a valid proxy string.
|
|
111
|
+
/// @throws CommunicatorDestroyedException Thrown when the communicator has been destroyed.
|
|
110
112
|
template<typename Prx = ObjectPrx, std::enable_if_t<std::is_base_of_v<ObjectPrx, Prx>, bool> = true>
|
|
111
113
|
std::optional<Prx> propertyToProxy(std::string_view property) const
|
|
112
114
|
{
|
|
@@ -139,6 +141,7 @@ namespace Ice
|
|
|
139
141
|
/// @param name The object adapter name.
|
|
140
142
|
/// @param serverAuthenticationOptions The SSL options for server connections.
|
|
141
143
|
/// @return The new object adapter.
|
|
144
|
+
/// @throws CommunicatorDestroyedException Thrown when the communicator has been destroyed.
|
|
142
145
|
/// @see #createObjectAdapterWithEndpoints
|
|
143
146
|
/// @see ObjectAdapter
|
|
144
147
|
/// @see Properties
|
|
@@ -156,6 +159,7 @@ namespace Ice
|
|
|
156
159
|
/// @param endpoints The endpoints of the object adapter.
|
|
157
160
|
/// @param serverAuthenticationOptions The SSL options for server connections.
|
|
158
161
|
/// @return The new object adapter.
|
|
162
|
+
/// @throws CommunicatorDestroyedException Thrown when the communicator has been destroyed.
|
|
159
163
|
/// @see #createObjectAdapter
|
|
160
164
|
/// @see Properties
|
|
161
165
|
/// @see SSL::OpenSSLServerAuthenticationOptions
|
|
@@ -171,6 +175,7 @@ namespace Ice
|
|
|
171
175
|
/// @param name The object adapter name.
|
|
172
176
|
/// @param rtr The router.
|
|
173
177
|
/// @return The new object adapter.
|
|
178
|
+
/// @throws CommunicatorDestroyedException Thrown when the communicator has been destroyed.
|
|
174
179
|
/// @see #createObjectAdapter
|
|
175
180
|
/// @see Properties
|
|
176
181
|
ObjectAdapterPtr createObjectAdapterWithRouter(std::string name, RouterPrx rtr);
|
|
@@ -186,6 +191,7 @@ namespace Ice
|
|
|
186
191
|
/// Sets the object adapter that will be associated with new outgoing connections created by this
|
|
187
192
|
/// communicator. This function has no effect on existing outgoing connections, or on incoming connections.
|
|
188
193
|
/// @param adapter The object adapter to associate with new outgoing connections.
|
|
194
|
+
/// @throws CommunicatorDestroyedException Thrown when the communicator has been destroyed.
|
|
189
195
|
/// @see Connection::setAdapter
|
|
190
196
|
void setDefaultObjectAdapter(ObjectAdapterPtr adapter);
|
|
191
197
|
|
|
@@ -223,6 +229,7 @@ namespace Ice
|
|
|
223
229
|
/// Sets the default router of this communicator. All newly created proxies will use this default router. This
|
|
224
230
|
/// function has no effect on existing proxies.
|
|
225
231
|
/// @param rtr The new default router. Use `nullopt` to remove the default router.
|
|
232
|
+
/// @throws CommunicatorDestroyedException Thrown when the communicator has been destroyed.
|
|
226
233
|
/// @see #getDefaultRouter
|
|
227
234
|
/// @see #createObjectAdapterWithRouter
|
|
228
235
|
/// @see Router
|
|
@@ -230,6 +237,7 @@ namespace Ice
|
|
|
230
237
|
|
|
231
238
|
/// Gets the default locator of this communicator.
|
|
232
239
|
/// @return The default locator of this communicator.
|
|
240
|
+
/// @throws CommunicatorDestroyedException Thrown when the communicator has been destroyed.
|
|
233
241
|
/// @see #setDefaultLocator
|
|
234
242
|
/// @see Locator
|
|
235
243
|
[[nodiscard]] std::optional<Ice::LocatorPrx> getDefaultLocator() const;
|
|
@@ -237,6 +245,7 @@ namespace Ice
|
|
|
237
245
|
/// Sets the default locator of this communicator. All newly created proxies will use this default locator.
|
|
238
246
|
/// This function has no effect on existing proxies or object adapters.
|
|
239
247
|
/// @param loc The new default locator. Use `nullopt` to remove the default locator.
|
|
248
|
+
/// @throws CommunicatorDestroyedException Thrown when the communicator has been destroyed.
|
|
240
249
|
/// @see #getDefaultLocator
|
|
241
250
|
/// @see Locator
|
|
242
251
|
/// @see ObjectAdapter#setLocator
|
|
@@ -253,6 +262,7 @@ namespace Ice
|
|
|
253
262
|
/// are ignored.
|
|
254
263
|
/// @param compress Specifies whether or not the queued batch requests should be compressed before being sent
|
|
255
264
|
/// over the wire.
|
|
265
|
+
/// @throws CommunicatorDestroyedException Thrown when the communicator has been destroyed.
|
|
256
266
|
void flushBatchRequests(CompressBatch compress);
|
|
257
267
|
|
|
258
268
|
/// Flushes any pending batch requests of this communicator. This means all batch requests invoked on fixed
|
|
@@ -260,9 +270,16 @@ namespace Ice
|
|
|
260
270
|
/// are ignored.
|
|
261
271
|
/// @param compress Specifies whether or not the queued batch requests should be compressed before being sent
|
|
262
272
|
/// over the wire.
|
|
263
|
-
/// @param exception The exception callback.
|
|
264
|
-
///
|
|
273
|
+
/// @param exception The exception callback. The Ice runtime never calls this function: errors that occur
|
|
274
|
+
/// while flushing a connection are ignored.
|
|
275
|
+
/// @param sent The sent callback. The Ice runtime calls this function when the flush completes for all
|
|
276
|
+
/// connections; since errors are ignored, a flush that fails on a connection is complete for this connection.
|
|
277
|
+
/// When the flush completes synchronously, the Ice runtime calls this function from the current thread and
|
|
278
|
+
/// passes `true` as argument. Otherwise, the Ice runtime calls this function from an Ice thread pool thread
|
|
279
|
+
/// and passes `false` as argument. If you set InitializationData::executor, the executor determines the
|
|
280
|
+
/// thread that executes this function in the asynchronous case.
|
|
265
281
|
/// @return A function that can be called to cancel the flush.
|
|
282
|
+
/// @throws CommunicatorDestroyedException Thrown synchronously when the communicator has been destroyed.
|
|
266
283
|
std::function<void()> flushBatchRequestsAsync(
|
|
267
284
|
CompressBatch compress,
|
|
268
285
|
std::function<void(std::exception_ptr)> exception,
|
|
@@ -274,6 +291,7 @@ namespace Ice
|
|
|
274
291
|
/// @param compress Specifies whether or not the queued batch requests should be compressed before being sent
|
|
275
292
|
/// over the wire.
|
|
276
293
|
/// @return A future that becomes available when all batch requests have been sent.
|
|
294
|
+
/// @throws CommunicatorDestroyedException Thrown synchronously when the communicator has been destroyed.
|
|
277
295
|
[[nodiscard]] std::future<void> flushBatchRequestsAsync(CompressBatch compress);
|
|
278
296
|
|
|
279
297
|
/// Adds the Admin object with all its facets to the provided object adapter. If `Ice.Admin.ServerId`
|
|
@@ -285,6 +303,7 @@ namespace Ice
|
|
|
285
303
|
/// @param adminId The identity of the Admin object.
|
|
286
304
|
/// @return A proxy to the main ("") facet of the Admin object.
|
|
287
305
|
/// @throws InitializationException Thrown when this function is called more than once.
|
|
306
|
+
/// @throws CommunicatorDestroyedException Thrown when the communicator has been destroyed.
|
|
288
307
|
/// @see #getAdmin
|
|
289
308
|
ObjectPrx createAdmin(const ObjectAdapterPtr& adminAdapter, const Identity& adminId);
|
|
290
309
|
|
|
@@ -302,18 +321,21 @@ namespace Ice
|
|
|
302
321
|
/// @param servant The servant that implements the new Admin facet.
|
|
303
322
|
/// @param facet The name of the new Admin facet.
|
|
304
323
|
/// @throws AlreadyRegisteredException Thrown when a facet with the same name is already registered.
|
|
324
|
+
/// @throws CommunicatorDestroyedException Thrown when the communicator has been destroyed.
|
|
305
325
|
void addAdminFacet(ObjectPtr servant, std::string facet);
|
|
306
326
|
|
|
307
327
|
/// Removes a facet from the Admin object.
|
|
308
328
|
/// @param facet The name of the Admin facet.
|
|
309
329
|
/// @return The servant associated with this Admin facet.
|
|
310
330
|
/// @throws NotRegisteredException Thrown when no facet with the given name is registered.
|
|
331
|
+
/// @throws CommunicatorDestroyedException Thrown when the communicator has been destroyed.
|
|
311
332
|
ObjectPtr removeAdminFacet(std::string_view facet);
|
|
312
333
|
|
|
313
334
|
/// Returns a facet of the Admin object.
|
|
314
335
|
/// @tparam T The type of the facet to return.
|
|
315
336
|
/// @param facet The name of the Admin facet.
|
|
316
337
|
/// @return The servant associated with this Admin facet, or null if no facet is registered with the given name.
|
|
338
|
+
/// @throws CommunicatorDestroyedException Thrown when the communicator has been destroyed.
|
|
317
339
|
template<typename T = Object, std::enable_if_t<std::is_base_of_v<Object, T>, bool> = true>
|
|
318
340
|
std::shared_ptr<T> findAdminFacet(std::string_view facet)
|
|
319
341
|
{
|
|
@@ -322,6 +344,7 @@ namespace Ice
|
|
|
322
344
|
|
|
323
345
|
/// Returns a map of all facets of the Admin object.
|
|
324
346
|
/// @return A collection containing all the facet names and servants of the Admin object.
|
|
347
|
+
/// @throws CommunicatorDestroyedException Thrown when the communicator has been destroyed.
|
|
325
348
|
/// @see #findAdminFacet
|
|
326
349
|
FacetMap findAllAdminFacets();
|
|
327
350
|
|
|
@@ -386,7 +409,7 @@ namespace Ice
|
|
|
386
409
|
CommunicatorHolder& operator=(CommunicatorHolder&& holder) noexcept;
|
|
387
410
|
|
|
388
411
|
/// Determines whether this holder holds a communicator.
|
|
389
|
-
/// @return `true` if the holder currently a
|
|
412
|
+
/// @return `true` if the holder currently holds a communicator, `false` otherwise.
|
|
390
413
|
explicit operator bool() const noexcept { return _communicator != nullptr; }
|
|
391
414
|
|
|
392
415
|
~CommunicatorHolder();
|
|
@@ -35,8 +35,8 @@
|
|
|
35
35
|
#endif
|
|
36
36
|
|
|
37
37
|
// The Ice version.
|
|
38
|
-
#define ICE_STRING_VERSION "3.8.
|
|
39
|
-
#define ICE_INT_VERSION
|
|
38
|
+
#define ICE_STRING_VERSION "3.8.3" // "A.B.C", with A=major, B=minor, C=patch
|
|
39
|
+
#define ICE_INT_VERSION 30803 // AABBCC, with AA=major, BB=minor, CC=patch
|
|
40
40
|
#define ICE_SO_VERSION "38" // "ABC", with A=major, B=minor, C=patch
|
|
41
41
|
|
|
42
42
|
#if defined(_MSC_VER) && !defined(ICE_BUILDING_SLICE_COMPILERS) // Not using the IceUtil static build
|
|
@@ -62,7 +62,8 @@ namespace Ice
|
|
|
62
62
|
/// @remark The response and exception callbacks may be called synchronously (from the calling thread); in
|
|
63
63
|
/// particular, this occurs when you call `close` on a connection that is already closed. The implementation
|
|
64
64
|
/// always calls one of the two callbacks once; it never calls both. If closing the connection takes longer than
|
|
65
|
-
/// the configured close timeout, the connection is aborted with a CloseTimeoutException.
|
|
65
|
+
/// the configured close timeout, the connection is aborted with a CloseTimeoutException. The response and
|
|
66
|
+
/// exception callbacks must not throw any exception.
|
|
66
67
|
virtual void
|
|
67
68
|
close(std::function<void()> response, std::function<void(std::exception_ptr)> exception) noexcept = 0;
|
|
68
69
|
|
|
@@ -74,6 +75,7 @@ namespace Ice
|
|
|
74
75
|
/// @tparam Prx The type of the proxy to create.
|
|
75
76
|
/// @param id The identity of the target object.
|
|
76
77
|
/// @return A fixed proxy with the provided identity.
|
|
78
|
+
/// @throws CommunicatorDestroyedException Thrown when the communicator has been destroyed.
|
|
77
79
|
template<typename Prx = ObjectPrx, std::enable_if_t<std::is_base_of_v<ObjectPrx, Prx>, bool> = true>
|
|
78
80
|
[[nodiscard]] Prx createProxy(Identity id) const
|
|
79
81
|
{
|
|
@@ -86,6 +88,8 @@ namespace Ice
|
|
|
86
88
|
/// The default object adapter of an incoming connection is the object adapter that created this connection;
|
|
87
89
|
/// the default object adapter of an outgoing connection is the communicator's default object adapter.
|
|
88
90
|
/// @param adapter The object adapter to associate with this connection.
|
|
91
|
+
/// @throws std::logic_error Thrown when this connection is an incoming connection: you can only call this
|
|
92
|
+
/// function on outgoing (client) connections.
|
|
89
93
|
/// @see Communicator::getDefaultObjectAdapter
|
|
90
94
|
/// @see #getAdapter
|
|
91
95
|
virtual void setAdapter(const ObjectAdapterPtr& adapter) = 0;
|
|
@@ -103,15 +107,25 @@ namespace Ice
|
|
|
103
107
|
/// This means all batch requests invoked on fixed proxies associated with the connection.
|
|
104
108
|
/// @param compress Specifies whether or not the queued batch requests should be compressed before being sent
|
|
105
109
|
/// over the wire.
|
|
110
|
+
/// @throws LocalException Thrown when the flush fails. For example, this function throws
|
|
111
|
+
/// CommunicatorDestroyedException when the communicator has been destroyed.
|
|
106
112
|
void flushBatchRequests(CompressBatch compress);
|
|
107
113
|
|
|
108
114
|
/// Flushes any pending batch requests for this connection.
|
|
109
115
|
/// This means all batch requests invoked on fixed proxies associated with the connection.
|
|
110
116
|
/// @param compress Specifies whether or not the queued batch requests should be compressed before being sent
|
|
111
117
|
/// over the wire.
|
|
112
|
-
/// @param exception The exception callback.
|
|
113
|
-
///
|
|
118
|
+
/// @param exception The exception callback. The Ice runtime calls this function from an Ice thread pool
|
|
119
|
+
/// thread. If you set InitializationData::executor, the executor determines the thread that executes this
|
|
120
|
+
/// function.
|
|
121
|
+
/// @param sent The sent callback. The Ice runtime calls this function when the batch requests are accepted by
|
|
122
|
+
/// the transport. When the batch requests are accepted synchronously, the Ice runtime calls this function from
|
|
123
|
+
/// the current thread and passes `true` as argument. When the batch requests are accepted asynchronously, the
|
|
124
|
+
/// Ice runtime calls this function from an Ice thread pool thread and passes `false` as argument. If you set
|
|
125
|
+
/// InitializationData::executor, the executor determines the thread that executes this function in the
|
|
126
|
+
/// asynchronous case.
|
|
114
127
|
/// @return A function that can be called to cancel the invocation locally.
|
|
128
|
+
/// @throws CommunicatorDestroyedException Thrown synchronously when the communicator has been destroyed.
|
|
115
129
|
virtual std::function<void()> flushBatchRequestsAsync(
|
|
116
130
|
CompressBatch compress,
|
|
117
131
|
std::function<void(std::exception_ptr)> exception,
|
|
@@ -122,6 +136,7 @@ namespace Ice
|
|
|
122
136
|
/// @param compress Specifies whether or not the queued batch requests should be compressed before being sent
|
|
123
137
|
/// over the wire.
|
|
124
138
|
/// @return A future that becomes available when the flush completes.
|
|
139
|
+
/// @throws CommunicatorDestroyedException Thrown synchronously when the communicator has been destroyed.
|
|
125
140
|
[[nodiscard]] std::future<void> flushBatchRequestsAsync(CompressBatch compress);
|
|
126
141
|
|
|
127
142
|
/// Sets a close callback on the connection. The callback is called by the connection when it's closed.
|
|
@@ -150,10 +165,10 @@ namespace Ice
|
|
|
150
165
|
/// @param sndSize The size of the send buffer.
|
|
151
166
|
virtual void setBufferSize(int rcvSize, int sndSize) = 0;
|
|
152
167
|
|
|
153
|
-
/// Throws
|
|
154
|
-
///
|
|
155
|
-
///
|
|
156
|
-
/// connection
|
|
168
|
+
/// Throws the exception that provides the reason for the closure of this connection. Does nothing if the
|
|
169
|
+
/// connection is not yet closing or closed.
|
|
170
|
+
/// @throws CloseConnectionException Thrown when the connection was closed gracefully by the peer.
|
|
171
|
+
/// @throws ConnectionAbortedException Thrown when the connection was aborted, for example with #abort.
|
|
157
172
|
virtual void throwException() const = 0;
|
|
158
173
|
|
|
159
174
|
protected:
|
|
@@ -341,7 +356,8 @@ namespace Ice
|
|
|
341
356
|
WSConnectionInfo(const WSConnectionInfo&) = delete;
|
|
342
357
|
WSConnectionInfo& operator=(const WSConnectionInfo&) = delete;
|
|
343
358
|
|
|
344
|
-
/// The headers from the
|
|
359
|
+
/// The HTTP headers from the WebSocket upgrade handshake: the request headers for an incoming connection, and
|
|
360
|
+
/// the response headers for an outgoing connection.
|
|
345
361
|
const HeaderDict headers;
|
|
346
362
|
|
|
347
363
|
/// @private
|
|
@@ -27,7 +27,7 @@ namespace Ice
|
|
|
27
27
|
|
|
28
28
|
/// Constructs a CtrlCHandler. Only one instance of this class can exist in a program at any point in time.
|
|
29
29
|
/// On Linux and macOS, this constructor masks the SIGHUP, SIGINT and SIGTERM signals and then creates a thread
|
|
30
|
-
/// that waits for these signals using sigwait. On Windows, this constructor calls
|
|
30
|
+
/// that waits for these signals using sigwait. On Windows, this constructor calls SetConsoleCtrlHandler to
|
|
31
31
|
/// register a handler routine that calls the supplied callback function.
|
|
32
32
|
/// @param cb The callback function to invoke when a signal is received.
|
|
33
33
|
explicit CtrlCHandler(CtrlCHandlerCallback cb);
|
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
|
|
9
9
|
namespace IceInternal
|
|
10
10
|
{
|
|
11
|
-
/// Demangles a C++ type
|
|
11
|
+
/// Demangles a C++ type name.
|
|
12
12
|
/// @param name The possibly mangled type name, as returned by typeid().name().
|
|
13
13
|
/// @return The demangled name.
|
|
14
14
|
ICE_API std::string demangle(const char* name);
|
|
@@ -123,7 +123,7 @@ namespace Ice
|
|
|
123
123
|
}
|
|
124
124
|
};
|
|
125
125
|
|
|
126
|
-
/// Provides access to a TCP endpoint information.
|
|
126
|
+
/// Provides access to a TCP endpoint's information.
|
|
127
127
|
/// @see Endpoint
|
|
128
128
|
/// @headerfile Ice/Ice.h
|
|
129
129
|
class ICE_API TCPEndpointInfo final : public IPEndpointInfo
|
|
@@ -155,7 +155,7 @@ namespace Ice
|
|
|
155
155
|
const bool _secure;
|
|
156
156
|
};
|
|
157
157
|
|
|
158
|
-
/// Provides access to a UDP endpoint information.
|
|
158
|
+
/// Provides access to a UDP endpoint's information.
|
|
159
159
|
/// @see Endpoint
|
|
160
160
|
/// @headerfile Ice/Ice.h
|
|
161
161
|
class ICE_API UDPEndpointInfo final : public IPEndpointInfo
|
|
@@ -189,7 +189,7 @@ namespace Ice
|
|
|
189
189
|
}
|
|
190
190
|
};
|
|
191
191
|
|
|
192
|
-
/// Provides access to a WebSocket endpoint information.
|
|
192
|
+
/// Provides access to a WebSocket endpoint's information.
|
|
193
193
|
/// @headerfile Ice/Ice.h
|
|
194
194
|
class ICE_API WSEndpointInfo final : public EndpointInfo
|
|
195
195
|
{
|
|
@@ -209,7 +209,7 @@ namespace Ice
|
|
|
209
209
|
}
|
|
210
210
|
};
|
|
211
211
|
|
|
212
|
-
/// Provides access to an IAP endpoint information.
|
|
212
|
+
/// Provides access to an IAP endpoint's information.
|
|
213
213
|
/// @headerfile Ice/Ice.h
|
|
214
214
|
class IAPEndpointInfo final : public EndpointInfo
|
|
215
215
|
{
|
|
@@ -112,13 +112,13 @@ namespace Ice
|
|
|
112
112
|
return initialize(std::move(initData));
|
|
113
113
|
}
|
|
114
114
|
|
|
115
|
-
/// Gets the per-process logger.
|
|
116
|
-
/// configured at the time the communicator is created.
|
|
115
|
+
/// Gets the per-process logger.
|
|
117
116
|
/// @return The current per-process logger instance.
|
|
117
|
+
/// @see setProcessLogger
|
|
118
118
|
ICE_API LoggerPtr getProcessLogger();
|
|
119
119
|
|
|
120
|
-
/// Sets the per-process logger.
|
|
121
|
-
/// configured
|
|
120
|
+
/// Sets the per-process logger. Communicators created after this call use this logger unless a logger is set in
|
|
121
|
+
/// InitializationData or configured through logger properties such as `Ice.LogFile`.
|
|
122
122
|
/// @param logger The new per-process logger instance.
|
|
123
123
|
ICE_API void setProcessLogger(const LoggerPtr& logger);
|
|
124
124
|
|
|
@@ -202,7 +202,7 @@ namespace Ice
|
|
|
202
202
|
/// @param[out] v A pointer into the internal marshaling buffer representing the start of the encoded
|
|
203
203
|
/// encapsulation.
|
|
204
204
|
/// @param[out] sz The number of bytes in the encapsulation.
|
|
205
|
-
/// @return
|
|
205
|
+
/// @return The encapsulation's encoding version.
|
|
206
206
|
EncodingVersion readEncapsulation(const std::byte*& v, std::int32_t& sz);
|
|
207
207
|
|
|
208
208
|
/// Gets the current encoding version.
|
|
@@ -270,7 +270,7 @@ namespace Ice
|
|
|
270
270
|
}
|
|
271
271
|
|
|
272
272
|
/// Reads and validates a sequence size.
|
|
273
|
-
/// @param minSize The minimum
|
|
273
|
+
/// @param minSize The minimum number of bytes required to encode each element of the sequence.
|
|
274
274
|
/// @return The extracted size.
|
|
275
275
|
std::int32_t readAndCheckSeqSize(int minSize);
|
|
276
276
|
|
|
@@ -510,7 +510,7 @@ namespace Ice
|
|
|
510
510
|
void read(std::vector<std::int32_t>& v);
|
|
511
511
|
|
|
512
512
|
/// Reads a long from the stream.
|
|
513
|
-
/// @param[out]v The extracted long.
|
|
513
|
+
/// @param[out] v The extracted long.
|
|
514
514
|
void read(std::int64_t& v);
|
|
515
515
|
|
|
516
516
|
/// Reads a sequence of longs from the stream.
|
|
@@ -610,7 +610,7 @@ namespace Ice
|
|
|
610
610
|
|
|
611
611
|
/// Reads a user exception from the stream and throws it.
|
|
612
612
|
/// @param factory The factory function that creates the exception instance. When null, the exception is created
|
|
613
|
-
///
|
|
613
|
+
/// by this stream's Slice loader.
|
|
614
614
|
/// @throws UserException The user exception that was unmarshaled.
|
|
615
615
|
void throwException(UserExceptionFactory factory = nullptr);
|
|
616
616
|
|
|
@@ -625,7 +625,7 @@ namespace Ice
|
|
|
625
625
|
/// @param size The number of bytes to skip.
|
|
626
626
|
void skip(size_type size)
|
|
627
627
|
{
|
|
628
|
-
if (
|
|
628
|
+
if (size > static_cast<size_type>(b.end() - i))
|
|
629
629
|
{
|
|
630
630
|
throwUnmarshalOutOfBoundsException(__FILE__, __LINE__);
|
|
631
631
|
}
|
|
@@ -37,7 +37,7 @@ namespace Ice::Instrumentation
|
|
|
37
37
|
class ObserverUpdater;
|
|
38
38
|
class CommunicatorObserver;
|
|
39
39
|
|
|
40
|
-
/// A shared
|
|
40
|
+
/// A shared pointer to an Observer.
|
|
41
41
|
using ObserverPtr = std::shared_ptr<Observer>;
|
|
42
42
|
|
|
43
43
|
/// A shared pointer to a ThreadObserver.
|
|
@@ -103,6 +103,9 @@ namespace Ice::Instrumentation
|
|
|
103
103
|
};
|
|
104
104
|
|
|
105
105
|
/// The base class for Ice observers.
|
|
106
|
+
/// @remark The Ice runtime calls observers from contexts where exceptions cannot be handled, such as destructors
|
|
107
|
+
/// and `noexcept` functions. Implementations of this interface and its derived interfaces must not throw
|
|
108
|
+
/// exceptions: a thrown exception can terminate the process.
|
|
106
109
|
/// @headerfile Ice/Ice.h
|
|
107
110
|
class Observer
|
|
108
111
|
{
|
|
@@ -222,14 +225,14 @@ namespace Ice::Instrumentation
|
|
|
222
225
|
public:
|
|
223
226
|
virtual ~ObserverUpdater() = default;
|
|
224
227
|
|
|
225
|
-
/// Updates connection observers associated with each of the Ice
|
|
226
|
-
/// adapters.
|
|
228
|
+
/// Updates connection observers associated with each of the Ice connections from the communicator and its
|
|
229
|
+
/// object adapters.
|
|
227
230
|
/// When called, this method goes through all the connections and for each connection
|
|
228
231
|
/// CommunicatorObserver::getConnectionObserver is called. The implementation of getConnectionObserver
|
|
229
232
|
/// has the possibility to return an updated observer if necessary.
|
|
230
233
|
virtual void updateConnectionObservers() = 0;
|
|
231
234
|
|
|
232
|
-
/// Updates thread observers associated with each of the Ice
|
|
235
|
+
/// Updates thread observers associated with each of the Ice threads from the communicator and its object
|
|
233
236
|
/// adapters. When called, this method goes through all the threads and for each thread
|
|
234
237
|
/// CommunicatorObserver::getThreadObserver is called. The implementation of getThreadObserver has the
|
|
235
238
|
/// possibility to return an updated observer if necessary.
|
|
@@ -238,8 +241,11 @@ namespace Ice::Instrumentation
|
|
|
238
241
|
|
|
239
242
|
/// The communicator observer interface used by the Ice runtime to obtain and update observers for its observable
|
|
240
243
|
/// objects. This interface should be implemented by add-ins that wish to observe Ice objects in order to collect
|
|
241
|
-
/// statistics. An instance of this interface can be provided to the Ice
|
|
244
|
+
/// statistics. An instance of this interface can be provided to the Ice runtime through the Ice communicator
|
|
242
245
|
/// initialization data.
|
|
246
|
+
/// @remark The Ice runtime calls this interface from contexts where exceptions cannot be handled, such as
|
|
247
|
+
/// `noexcept` functions. An implementation of this interface must not throw exceptions: a thrown exception can
|
|
248
|
+
/// terminate the process.
|
|
243
249
|
/// @headerfile Ice/Ice.h
|
|
244
250
|
class CommunicatorObserver
|
|
245
251
|
{
|
|
@@ -262,7 +268,7 @@ namespace Ice::Instrumentation
|
|
|
262
268
|
/// @return The observer to instrument the endpoint lookup.
|
|
263
269
|
virtual ObserverPtr getEndpointLookupObserver(const EndpointPtr& endpt) = 0;
|
|
264
270
|
|
|
265
|
-
/// Gets an observer for the given connection. The Ice
|
|
271
|
+
/// Gets an observer for the given connection. The Ice runtime calls this method for each new connection and
|
|
266
272
|
/// for all the Ice communicator connections when ObserverUpdater::updateConnectionObservers is called.
|
|
267
273
|
/// @param c The connection information.
|
|
268
274
|
/// @param e The connection endpoint.
|
|
@@ -305,7 +311,7 @@ namespace Ice::Instrumentation
|
|
|
305
311
|
virtual DispatchObserverPtr getDispatchObserver(const Current& c, int size) = 0;
|
|
306
312
|
|
|
307
313
|
/// Sets the observer updater. The Ice runtime calls this method when the communicator is initialized. The
|
|
308
|
-
/// add-in implementing this interface can use this object to get the Ice
|
|
314
|
+
/// add-in implementing this interface can use this object to get the Ice runtime to re-obtain observers for
|
|
309
315
|
/// observed objects.
|
|
310
316
|
/// @param updater The observer updater object.
|
|
311
317
|
virtual void setObserverUpdater(const ObserverUpdaterPtr& updater) = 0;
|
|
@@ -568,15 +568,15 @@ namespace Ice
|
|
|
568
568
|
class ICE_API AlreadyRegisteredException final : public LocalException
|
|
569
569
|
{
|
|
570
570
|
public:
|
|
571
|
-
/// Constructs
|
|
571
|
+
/// Constructs an AlreadyRegisteredException.
|
|
572
572
|
/// @param file The file where this exception is constructed. This C string is not copied.
|
|
573
573
|
/// @param line The line where this exception is constructed.
|
|
574
574
|
/// @param kindOfObject The kind of object that is already registered.
|
|
575
575
|
/// @param id The ID (or name) of the object that is already registered.
|
|
576
576
|
AlreadyRegisteredException(const char* file, int line, std::string kindOfObject, std::string id);
|
|
577
577
|
|
|
578
|
-
/// Gets the kind of object that is already registered: "servant", "facet", "
|
|
579
|
-
/// "servant locator", "plugin", "object adapter", "object adapter with router"
|
|
578
|
+
/// Gets the kind of object that is already registered: "servant", "facet", "default servant",
|
|
579
|
+
/// "servant locator", "plugin", "object adapter", "object adapter with router".
|
|
580
580
|
[[nodiscard]] const std::string& kindOfObject() const noexcept { return *_kindOfObject; }
|
|
581
581
|
|
|
582
582
|
/// Gets the ID (or name) of the object that is already registered.
|
|
@@ -684,7 +684,7 @@ namespace Ice
|
|
|
684
684
|
[[nodiscard]] const char* ice_id() const noexcept final;
|
|
685
685
|
};
|
|
686
686
|
|
|
687
|
-
/// The exception that is thrown when
|
|
687
|
+
/// The exception that is thrown when a failure occurs during initialization.
|
|
688
688
|
/// @headerfile Ice/Ice.h
|
|
689
689
|
class ICE_API InitializationException final : public LocalException
|
|
690
690
|
{
|
|
@@ -718,7 +718,7 @@ namespace Ice
|
|
|
718
718
|
/// Constructs a NoEndpointException.
|
|
719
719
|
/// @param file The file where this exception is constructed. This C string is not copied.
|
|
720
720
|
/// @param line The line where this exception is constructed.
|
|
721
|
-
/// @param proxy The proxy used to create the message
|
|
721
|
+
/// @param proxy The proxy used to create the message returned by what().
|
|
722
722
|
NoEndpointException(const char* file, int line, const ObjectPrx& proxy);
|
|
723
723
|
|
|
724
724
|
[[nodiscard]] const char* ice_id() const noexcept final;
|
|
@@ -17,6 +17,9 @@ namespace Ice
|
|
|
17
17
|
|
|
18
18
|
/// Represents Ice's abstraction for logging and tracing. Applications can provide their own logger by
|
|
19
19
|
/// implementing this abstraction and setting a logger on the communicator.
|
|
20
|
+
/// @remark The Ice runtime calls #print, #trace, #warning and #error from contexts where exceptions cannot be
|
|
21
|
+
/// handled, such as destructors and `noexcept` functions. Implementations of these functions must not throw
|
|
22
|
+
/// exceptions: a thrown exception can terminate the process.
|
|
20
23
|
/// @see InitializationData
|
|
21
24
|
/// @headerfile Ice/Ice.h
|
|
22
25
|
class ICE_API Logger
|
|
@@ -31,20 +34,24 @@ namespace Ice
|
|
|
31
34
|
/// Prints a message.
|
|
32
35
|
/// The message is printed literally, without any decorations such as executable name or timestamp.
|
|
33
36
|
/// @param message The message to log.
|
|
37
|
+
/// @remark An implementation of this function must not throw exceptions.
|
|
34
38
|
virtual void print(const std::string& message) = 0;
|
|
35
39
|
|
|
36
40
|
/// Logs a trace message.
|
|
37
41
|
/// @param category The trace category.
|
|
38
42
|
/// @param message The trace message to log.
|
|
43
|
+
/// @remark An implementation of this function must not throw exceptions.
|
|
39
44
|
virtual void trace(const std::string& category, const std::string& message) = 0;
|
|
40
45
|
|
|
41
46
|
/// Logs a warning message.
|
|
42
47
|
/// @param message The warning message to log.
|
|
48
|
+
/// @remark An implementation of this function must not throw exceptions.
|
|
43
49
|
/// @see #error
|
|
44
50
|
virtual void warning(const std::string& message) = 0;
|
|
45
51
|
|
|
46
52
|
/// Logs an error message.
|
|
47
53
|
/// @param message The error message to log.
|
|
54
|
+
/// @remark An implementation of this function must not throw exceptions.
|
|
48
55
|
/// @see #warning
|
|
49
56
|
virtual void error(const std::string& message) = 0;
|
|
50
57
|
|
|
@@ -36,12 +36,12 @@ namespace Ice
|
|
|
36
36
|
/// not throw any exception and any @p sendResponse wrapper must not throw any exception. @p sendResponse can be
|
|
37
37
|
/// called by the thread that called dispatch (the "dispatch thread") or by another thread. The implementation
|
|
38
38
|
/// must call @p sendResponse exactly once or throw an exception.
|
|
39
|
-
/// @remark Calling @p sendResponse can be thought as returning the outgoing response. Just like when you
|
|
40
|
-
/// a value from a remote operation, you can only return it once and you don't know if the client
|
|
41
|
-
/// value. In practice, the Ice-provided @p sendResponse attempts to send the response to the
|
|
42
|
-
/// synchronously, but may send it asynchronously. It can also silently fail to send the response back to
|
|
43
|
-
/// client. This function is the main building block for the Ice dispatch pipeline. The implementation
|
|
44
|
-
/// by the base class (Object) dispatches incoming requests to the four `Object` operations (`ice_isA`,
|
|
39
|
+
/// @remark Calling @p sendResponse can be thought of as returning the outgoing response. Just like when you
|
|
40
|
+
/// return a value from a remote operation, you can only return it once and you don't know if the client
|
|
41
|
+
/// receives this value. In practice, the Ice-provided @p sendResponse attempts to send the response to the
|
|
42
|
+
/// client synchronously, but may send it asynchronously. It can also silently fail to send the response back to
|
|
43
|
+
/// the client. This function is the main building block for the Ice dispatch pipeline. The implementation
|
|
44
|
+
/// provided by the base class (Object) dispatches incoming requests to the four `Object` operations (`ice_isA`,
|
|
45
45
|
/// `ice_ping`, `ice_ids` and `ice_id`), and throws OperationNotExistException for all other operations. This
|
|
46
46
|
/// base implementation is trivial and should be overridden and fully replaced by all derived classes.
|
|
47
47
|
virtual void dispatch(IncomingRequest& request, std::function<void(OutgoingResponse)> sendResponse);
|
|
@@ -93,7 +93,8 @@ namespace Ice
|
|
|
93
93
|
public:
|
|
94
94
|
/// Dispatches an incoming request.
|
|
95
95
|
/// @param inEncaps An encapsulation containing the encoded in-parameters for the operation.
|
|
96
|
-
/// @param outEncaps An encapsulation containing the encoded result for the operation.
|
|
96
|
+
/// @param outEncaps An encapsulation containing the encoded result for the operation. You can leave it empty
|
|
97
|
+
/// when the operation returns no results; the Ice runtime then marshals an empty encapsulation.
|
|
97
98
|
/// @param current The Current object of the incoming request.
|
|
98
99
|
/// @return `true` if the dispatch completes successfully, `false` if the dispatch completes with a user
|
|
99
100
|
/// exception encoded in @p outEncaps.
|
|
@@ -133,7 +134,8 @@ namespace Ice
|
|
|
133
134
|
/// @param response The response callback. It accepts:
|
|
134
135
|
/// - `returnValue` `true` if the operation completed successfully, `false` if it completed with a user
|
|
135
136
|
/// exception encoded in @p outEncaps.
|
|
136
|
-
/// - `outEncaps` An encapsulation containing the encoded result.
|
|
137
|
+
/// - `outEncaps` An encapsulation containing the encoded result. You can pass an empty byte sequence when
|
|
138
|
+
/// the operation returns no results; the Ice runtime then marshals an empty encapsulation.
|
|
137
139
|
/// @param exception The exception callback.
|
|
138
140
|
/// @param current The Current object of the incoming request.
|
|
139
141
|
virtual void ice_invokeAsync(
|
|
@@ -290,7 +290,7 @@ namespace Ice
|
|
|
290
290
|
virtual void setLocator(std::optional<LocatorPrx> loc) = 0;
|
|
291
291
|
|
|
292
292
|
/// Gets the Ice locator used by this object adapter.
|
|
293
|
-
/// @return The locator used by this object adapter, or
|
|
293
|
+
/// @return The locator used by this object adapter, or nullopt if no locator is used by this object adapter.
|
|
294
294
|
[[nodiscard]] virtual std::optional<LocatorPrx> getLocator() const noexcept = 0;
|
|
295
295
|
|
|
296
296
|
/// Gets the set of endpoints configured on this object adapter.
|
|
@@ -25,7 +25,6 @@
|
|
|
25
25
|
# pragma warning(disable : 4251) // class ... needs to have dll-interface to be used by clients of class ...
|
|
26
26
|
#elif defined(__clang__)
|
|
27
27
|
# pragma clang diagnostic push
|
|
28
|
-
// See #2747
|
|
29
28
|
# pragma clang diagnostic ignored "-Wshadow-uncaptured-local"
|
|
30
29
|
# pragma clang diagnostic ignored "-Wweak-vtables"
|
|
31
30
|
#endif
|
|
@@ -143,7 +142,7 @@ namespace IceInternal
|
|
|
143
142
|
//
|
|
144
143
|
// Base class for proxy based invocations. This class handles the
|
|
145
144
|
// retry for proxy invocations. It also ensures the child observer is
|
|
146
|
-
//
|
|
145
|
+
// correctly notified of failures and makes sure the retry task is
|
|
147
146
|
// correctly canceled when the invocation completes.
|
|
148
147
|
//
|
|
149
148
|
class ICE_API ProxyOutgoingAsyncBase : public OutgoingAsyncBase, public TimerTask
|
|
@@ -155,7 +154,11 @@ namespace IceInternal
|
|
|
155
154
|
bool exception(std::exception_ptr) override;
|
|
156
155
|
|
|
157
156
|
void retryException();
|
|
157
|
+
|
|
158
|
+
// Retries the invocation; when the retry attempt fails, completes the invocation with the exception. This
|
|
159
|
+
// function never throws.
|
|
158
160
|
void retry();
|
|
161
|
+
|
|
159
162
|
void abort(std::exception_ptr);
|
|
160
163
|
|
|
161
164
|
std::shared_ptr<ProxyOutgoingAsyncBase> shared_from_this()
|