Ice 3.8
C++ API Reference
Loading...
Searching...
No Matches
Admin.h
1// Copyright (c) ZeroC, Inc.
2
3// slice2cpp version 3.8.0-alpha.0
4// <auto-generated>Generated from Slice file 'Admin.ice'.</auto-generated>
5// clang-format off
6
7#ifndef IceGrid_Admin_h_
8#define IceGrid_Admin_h_
9
11#include <Ice/Ice.h>
12#include "Descriptor.h"
13#include "Exception.h"
14#include <Glacier2/Session.h>
15#include <IceGrid/Config.h>
16
17#ifndef ICE_DISABLE_VERSION
18# if ICE_INT_VERSION != 30850
19# error Ice version mismatch: an exact match is required for beta generated code
20# endif
21#endif
22
23#ifndef ICEGRID_API
24# if defined(ICEGRID_API_EXPORTS)
25# define ICEGRID_API ICE_DECLSPEC_EXPORT
26# else
27# define ICEGRID_API ICE_DECLSPEC_IMPORT
28# endif
29#endif
30
31// NOLINTBEGIN(modernize-concat-nested-namespaces)
32
33namespace IceGrid
34{
35 class RegistryPrx;
36
37 /// Represents the state of a server.
38 enum class ServerState : std::uint8_t
39 {
40 /// The server is not running.
42
43 /// The server is being activated and will change to the active state when the registered server object adapters
44 /// are activated or to the activation timed out state if the activation timeout expires.
46
47 /// The server activation timed out.
49
50 /// The server is running.
52
53 /// The server is being deactivated.
55
56 /// The server is being destroyed.
58
59 /// The server is destroyed.
61 };
62
63 /// Outputs the enumerator name or underlying value of a ServerState to a stream.
64 /// @param os The output stream.
65 /// @param value The value to output.
66 /// @return The output stream.
67 ICEGRID_API std::ostream& operator<<(std::ostream& os, ServerState value);
68
69 /// A dictionary of string to proxies.
70 using StringObjectProxyDict = std::map<std::string, std::optional<Ice::ObjectPrx>>;
71
72 struct ObjectInfo;
73
74 /// A sequence of ObjectInfo.
75 using ObjectInfoSeq = std::vector<ObjectInfo>;
76
77 struct AdapterInfo;
78
79 /// A sequence of AdapterInfo.
80 using AdapterInfoSeq = std::vector<AdapterInfo>;
81
82 struct ServerInfo;
83
84 struct NodeInfo;
85
86 struct RegistryInfo;
87
88 /// A sequence of RegistryInfo.
89 using RegistryInfoSeq = std::vector<RegistryInfo>;
90
91 struct LoadInfo;
92
93 struct ApplicationInfo;
94
95 /// A sequence of ApplicationInfo.
96 using ApplicationInfoSeq = std::vector<ApplicationInfo>;
97
99
100 class AdminPrx;
101
102 class FileIteratorPrx;
103
104 struct ServerDynamicInfo;
105
106 /// A sequence of ServerDynamicInfo.
107 using ServerDynamicInfoSeq = std::vector<ServerDynamicInfo>;
108
109 struct AdapterDynamicInfo;
110
111 /// A sequence of AdapterDynamicInfo.
112 using AdapterDynamicInfoSeq = std::vector<AdapterDynamicInfo>;
113
114 struct NodeDynamicInfo;
115
117
118 /// A sequence of NodeDynamicInfo.
119 using NodeDynamicInfoSeq = std::vector<NodeDynamicInfo>;
120
121 class NodeObserverPrx;
122
124
125 class AdapterObserverPrx;
126
127 class ObjectObserverPrx;
128
129 class AdminSessionPrx;
130}
131
132namespace IceGrid
133{
134 /// Provides administrative access to an IceGrid deployment.
135 /// @headerfile IceGrid/IceGrid.h
136 class ICEGRID_API AdminPrx : public Ice::Proxy<AdminPrx, Ice::ObjectPrx>
137 {
138 public:
139 /// Constructs a proxy from a Communicator and a proxy string.
140 /// @param communicator The communicator of the new proxy.
141 /// @param proxyString The proxy string to parse.
142 AdminPrx(const Ice::CommunicatorPtr& communicator, std::string_view proxyString) : Ice::ObjectPrx{communicator, proxyString} {} // NOLINT(modernize-use-equals-default)
143
144 /// Copy constructor. Constructs with a copy of the contents of @p other.
145 /// @param other The proxy to copy from.
146 AdminPrx(const AdminPrx& other) noexcept : Ice::ObjectPrx{other} {} // NOLINT(modernize-use-equals-default)
147
148 /// Move constructor. Constructs a proxy with the contents of @p other using move semantics.
149 /// @param other The proxy to move from.
150 AdminPrx(AdminPrx&& other) noexcept : Ice::ObjectPrx{std::move(other)} {} // NOLINT(modernize-use-equals-default)
151
152 ~AdminPrx() override;
153
154 /// Copy assignment operator. Replaces the contents of this proxy with a copy of the contents of @p rhs.
155 /// @param rhs The proxy to copy from.
156 /// @return A reference to this proxy.
157 AdminPrx& operator=(const AdminPrx& rhs) noexcept
158 {
159 if (this != &rhs)
160 {
162 }
163 return *this;
164 }
165
166 /// Move assignment operator. Replaces the contents of this proxy with the contents of @p rhs using move semantics.
167 /// @param rhs The proxy to move from.
168 AdminPrx& operator=(AdminPrx&& rhs) noexcept
169 {
170 if (this != &rhs)
171 {
172 Ice::ObjectPrx::operator=(std::move(rhs));
173 }
174 return *this;
175 }
176
177 /// Adds an application to IceGrid.
178 /// @param descriptor The application descriptor.
179 /// @param context The request context.
180 /// @throws IceGrid::AccessDeniedException Thrown when the session doesn't hold the exclusive lock or when another
181 /// session is holding the lock.
182 /// @throws IceGrid::DeploymentException Thrown when the application deployment failed.
183 void addApplication(const ApplicationDescriptor& descriptor, const Ice::Context& context = Ice::noExplicitContext) const;
184
185 /// Adds an application to IceGrid.
186 /// @param descriptor The application descriptor.
187 /// @param context The request context.
188 /// @return A future that becomes available when the invocation completes.
189 [[nodiscard]] std::future<void> addApplicationAsync(const ApplicationDescriptor& descriptor, const Ice::Context& context = Ice::noExplicitContext) const;
190
191 /// Adds an application to IceGrid.
192 /// @param descriptor The application descriptor.
193 /// @param response The response callback.
194 /// @param exception The exception callback.
195 /// @param sent The sent callback.
196 /// @param context The request context.
197 /// @return A function that can be called to cancel the invocation locally.
198 // NOLINTNEXTLINE(modernize-use-nodiscard)
199 std::function<void()> addApplicationAsync(const ApplicationDescriptor& descriptor, std::function<void()> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
200
201 /// @private
202 void _iceI_addApplication(const std::shared_ptr<IceInternal::OutgoingAsyncT<void>>&, const ApplicationDescriptor&, const Ice::Context&) const;
203
204 /// Synchronizes a deployed application. This operation replaces the current descriptor with a new descriptor.
205 /// @param descriptor The new application descriptor.
206 /// @param context The request context.
207 /// @throws IceGrid::AccessDeniedException Thrown when the session doesn't hold the exclusive lock or when another
208 /// session is holding the lock.
209 /// @throws IceGrid::ApplicationNotExistException Thrown when the application doesn't exist.
210 /// @throws IceGrid::DeploymentException Thrown when the application deployment failed.
211 void syncApplication(const ApplicationDescriptor& descriptor, const Ice::Context& context = Ice::noExplicitContext) const;
212
213 /// Synchronizes a deployed application. This operation replaces the current descriptor with a new descriptor.
214 /// @param descriptor The new application descriptor.
215 /// @param context The request context.
216 /// @return A future that becomes available when the invocation completes.
217 [[nodiscard]] std::future<void> syncApplicationAsync(const ApplicationDescriptor& descriptor, const Ice::Context& context = Ice::noExplicitContext) const;
218
219 /// Synchronizes a deployed application. This operation replaces the current descriptor with a new descriptor.
220 /// @param descriptor The new application descriptor.
221 /// @param response The response callback.
222 /// @param exception The exception callback.
223 /// @param sent The sent callback.
224 /// @param context The request context.
225 /// @return A function that can be called to cancel the invocation locally.
226 // NOLINTNEXTLINE(modernize-use-nodiscard)
227 std::function<void()> syncApplicationAsync(const ApplicationDescriptor& descriptor, std::function<void()> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
228
229 /// @private
230 void _iceI_syncApplication(const std::shared_ptr<IceInternal::OutgoingAsyncT<void>>&, const ApplicationDescriptor&, const Ice::Context&) const;
231
232 /// Updates a deployed application.
233 /// @param descriptor The update descriptor.
234 /// @param context The request context.
235 /// @throws IceGrid::AccessDeniedException Thrown when the session doesn't hold the exclusive lock or when another
236 /// session is holding the lock.
237 /// @throws IceGrid::ApplicationNotExistException Thrown when the application doesn't exist.
238 /// @throws IceGrid::DeploymentException Thrown when the application deployment failed.
240
241 /// Updates a deployed application.
242 /// @param descriptor The update descriptor.
243 /// @param context The request context.
244 /// @return A future that becomes available when the invocation completes.
245 [[nodiscard]] std::future<void> updateApplicationAsync(const ApplicationUpdateDescriptor& descriptor, const Ice::Context& context = Ice::noExplicitContext) const;
246
247 /// Updates a deployed application.
248 /// @param descriptor The update descriptor.
249 /// @param response The response callback.
250 /// @param exception The exception callback.
251 /// @param sent The sent callback.
252 /// @param context The request context.
253 /// @return A function that can be called to cancel the invocation locally.
254 // NOLINTNEXTLINE(modernize-use-nodiscard)
255 std::function<void()> updateApplicationAsync(const ApplicationUpdateDescriptor& descriptor, std::function<void()> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
256
257 /// @private
258 void _iceI_updateApplication(const std::shared_ptr<IceInternal::OutgoingAsyncT<void>>&, const ApplicationUpdateDescriptor&, const Ice::Context&) const;
259
260 /// Synchronizes a deployed application. This operation replaces the current descriptor with a new descriptor
261 /// only if no server restarts are necessary for the update of the application. If some servers need to be
262 /// restarted, the synchronization is rejected with a DeploymentException.
263 /// @param descriptor The application descriptor.
264 /// @param context The request context.
265 /// @throws IceGrid::AccessDeniedException Thrown when the session doesn't hold the exclusive lock or when another
266 /// session is holding the lock.
267 /// @throws IceGrid::ApplicationNotExistException Thrown when the application doesn't exist.
268 /// @throws IceGrid::DeploymentException Thrown when the application deployment failed.
270
271 /// Synchronizes a deployed application. This operation replaces the current descriptor with a new descriptor
272 /// only if no server restarts are necessary for the update of the application. If some servers need to be
273 /// restarted, the synchronization is rejected with a DeploymentException.
274 /// @param descriptor The application descriptor.
275 /// @param context The request context.
276 /// @return A future that becomes available when the invocation completes.
277 [[nodiscard]] std::future<void> syncApplicationWithoutRestartAsync(const ApplicationDescriptor& descriptor, const Ice::Context& context = Ice::noExplicitContext) const;
278
279 /// Synchronizes a deployed application. This operation replaces the current descriptor with a new descriptor
280 /// only if no server restarts are necessary for the update of the application. If some servers need to be
281 /// restarted, the synchronization is rejected with a DeploymentException.
282 /// @param descriptor The application descriptor.
283 /// @param response The response callback.
284 /// @param exception The exception callback.
285 /// @param sent The sent callback.
286 /// @param context The request context.
287 /// @return A function that can be called to cancel the invocation locally.
288 // NOLINTNEXTLINE(modernize-use-nodiscard)
289 std::function<void()> syncApplicationWithoutRestartAsync(const ApplicationDescriptor& descriptor, std::function<void()> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
290
291 /// @private
292 void _iceI_syncApplicationWithoutRestart(const std::shared_ptr<IceInternal::OutgoingAsyncT<void>>&, const ApplicationDescriptor&, const Ice::Context&) const;
293
294 /// Updates a deployed application. This operation succeeds only when no server restarts are necessary for the
295 /// update of the application. If some servers need to be restarted, the synchronization is rejected with a
296 /// DeploymentException.
297 /// @param descriptor The update descriptor.
298 /// @param context The request context.
299 /// @throws IceGrid::AccessDeniedException Thrown when the session doesn't hold the exclusive lock or when another
300 /// session is holding the lock.
301 /// @throws IceGrid::ApplicationNotExistException Thrown when the application doesn't exist.
302 /// @throws IceGrid::DeploymentException Thrown when the application deployment failed.
304
305 /// Updates a deployed application. This operation succeeds only when no server restarts are necessary for the
306 /// update of the application. If some servers need to be restarted, the synchronization is rejected with a
307 /// DeploymentException.
308 /// @param descriptor The update descriptor.
309 /// @param context The request context.
310 /// @return A future that becomes available when the invocation completes.
311 [[nodiscard]] std::future<void> updateApplicationWithoutRestartAsync(const ApplicationUpdateDescriptor& descriptor, const Ice::Context& context = Ice::noExplicitContext) const;
312
313 /// Updates a deployed application. This operation succeeds only when no server restarts are necessary for the
314 /// update of the application. If some servers need to be restarted, the synchronization is rejected with a
315 /// DeploymentException.
316 /// @param descriptor The update descriptor.
317 /// @param response The response callback.
318 /// @param exception The exception callback.
319 /// @param sent The sent callback.
320 /// @param context The request context.
321 /// @return A function that can be called to cancel the invocation locally.
322 // NOLINTNEXTLINE(modernize-use-nodiscard)
323 std::function<void()> updateApplicationWithoutRestartAsync(const ApplicationUpdateDescriptor& descriptor, std::function<void()> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
324
325 /// @private
326 void _iceI_updateApplicationWithoutRestart(const std::shared_ptr<IceInternal::OutgoingAsyncT<void>>&, const ApplicationUpdateDescriptor&, const Ice::Context&) const;
327
328 /// Removes an application from IceGrid.
329 /// @param name The application name.
330 /// @param context The request context.
331 /// @throws IceGrid::AccessDeniedException Thrown when the session doesn't hold the exclusive lock or when another
332 /// session is holding the lock.
333 /// @throws IceGrid::ApplicationNotExistException Thrown when the application doesn't exist.
334 /// @throws IceGrid::DeploymentException Thrown when the application deployment failed.
335 void removeApplication(std::string_view name, const Ice::Context& context = Ice::noExplicitContext) const;
336
337 /// Removes an application from IceGrid.
338 /// @param name The application name.
339 /// @param context The request context.
340 /// @return A future that becomes available when the invocation completes.
341 [[nodiscard]] std::future<void> removeApplicationAsync(std::string_view name, const Ice::Context& context = Ice::noExplicitContext) const;
342
343 /// Removes an application from IceGrid.
344 /// @param name The application name.
345 /// @param response The response callback.
346 /// @param exception The exception callback.
347 /// @param sent The sent callback.
348 /// @param context The request context.
349 /// @return A function that can be called to cancel the invocation locally.
350 // NOLINTNEXTLINE(modernize-use-nodiscard)
351 std::function<void()> removeApplicationAsync(std::string_view name, std::function<void()> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
352
353 /// @private
354 void _iceI_removeApplication(const std::shared_ptr<IceInternal::OutgoingAsyncT<void>>&, std::string_view, const Ice::Context&) const;
355
356 /// Instantiates a server template.
357 /// @param application The application name.
358 /// @param node The name of the node where the server will be deployed.
359 /// @param desc The descriptor of the server instance to deploy.
360 /// @param context The request context.
361 /// @throws IceGrid::AccessDeniedException Thrown when the session doesn't hold the exclusive lock or when another
362 /// session is holding the lock.
363 /// @throws IceGrid::ApplicationNotExistException Thrown when the application doesn't exist.
364 /// @throws IceGrid::DeploymentException Thrown when the application deployment failed.
365 void instantiateServer(std::string_view application, std::string_view node, const ServerInstanceDescriptor& desc, const Ice::Context& context = Ice::noExplicitContext) const;
366
367 /// Instantiates a server template.
368 /// @param application The application name.
369 /// @param node The name of the node where the server will be deployed.
370 /// @param desc The descriptor of the server instance to deploy.
371 /// @param context The request context.
372 /// @return A future that becomes available when the invocation completes.
373 [[nodiscard]] std::future<void> instantiateServerAsync(std::string_view application, std::string_view node, const ServerInstanceDescriptor& desc, const Ice::Context& context = Ice::noExplicitContext) const;
374
375 /// Instantiates a server template.
376 /// @param application The application name.
377 /// @param node The name of the node where the server will be deployed.
378 /// @param desc The descriptor of the server instance to deploy.
379 /// @param response The response callback.
380 /// @param exception The exception callback.
381 /// @param sent The sent callback.
382 /// @param context The request context.
383 /// @return A function that can be called to cancel the invocation locally.
384 // NOLINTNEXTLINE(modernize-use-nodiscard)
385 std::function<void()> instantiateServerAsync(std::string_view application, std::string_view node, const ServerInstanceDescriptor& desc, std::function<void()> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
386
387 /// @private
388 void _iceI_instantiateServer(const std::shared_ptr<IceInternal::OutgoingAsyncT<void>>&, std::string_view, std::string_view, const ServerInstanceDescriptor&, const Ice::Context&) const;
389
390 /// Gets an application descriptor.
391 /// @param name The application name.
392 /// @param context The request context.
393 /// @return The application descriptor.
394 /// @throws IceGrid::ApplicationNotExistException Thrown when the application doesn't exist.
395 ApplicationInfo getApplicationInfo(std::string_view name, const Ice::Context& context = Ice::noExplicitContext) const; // NOLINT(modernize-use-nodiscard)
396
397 /// Gets an application descriptor.
398 /// @param name The application name.
399 /// @param context The request context.
400 /// @return A future that becomes available when the invocation completes. This future holds:
401 /// - The application descriptor.
402 [[nodiscard]] std::future<ApplicationInfo> getApplicationInfoAsync(std::string_view name, const Ice::Context& context = Ice::noExplicitContext) const;
403
404 /// Gets an application descriptor.
405 /// @param name The application name.
406 /// @param response The response callback. It accepts:
407 /// - The application descriptor.
408 /// @param exception The exception callback.
409 /// @param sent The sent callback.
410 /// @param context The request context.
411 /// @return A function that can be called to cancel the invocation locally.
412 // NOLINTNEXTLINE(modernize-use-nodiscard)
413 std::function<void()> getApplicationInfoAsync(std::string_view name, std::function<void(::IceGrid::ApplicationInfo)> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
414
415 /// @private
416 void _iceI_getApplicationInfo(const std::shared_ptr<IceInternal::OutgoingAsyncT<ApplicationInfo>>&, std::string_view, const Ice::Context&) const;
417
418 /// Gets the default application descriptor.
419 /// @param context The request context.
420 /// @return The default application descriptor.
421 /// @throws IceGrid::DeploymentException Thrown when the default application descriptor is invalid or unreachable.
422 ApplicationDescriptor getDefaultApplicationDescriptor(const Ice::Context& context = Ice::noExplicitContext) const; // NOLINT(modernize-use-nodiscard)
423
424 /// Gets the default application descriptor.
425 /// @param context The request context.
426 /// @return A future that becomes available when the invocation completes. This future holds:
427 /// - The default application descriptor.
428 [[nodiscard]] std::future<ApplicationDescriptor> getDefaultApplicationDescriptorAsync(const Ice::Context& context = Ice::noExplicitContext) const;
429
430 /// Gets the default application descriptor.
431 /// @param response The response callback. It accepts:
432 /// - The default application descriptor.
433 /// @param exception The exception callback.
434 /// @param sent The sent callback.
435 /// @param context The request context.
436 /// @return A function that can be called to cancel the invocation locally.
437 // NOLINTNEXTLINE(modernize-use-nodiscard)
438 std::function<void()> getDefaultApplicationDescriptorAsync(std::function<void(::IceGrid::ApplicationDescriptor)> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
439
440 /// @private
441 void _iceI_getDefaultApplicationDescriptor(const std::shared_ptr<IceInternal::OutgoingAsyncT<ApplicationDescriptor>>&, const Ice::Context&) const;
442
443 /// Gets all the IceGrid applications currently registered.
444 /// @param context The request context.
445 /// @return The application names.
446 ::Ice::StringSeq getAllApplicationNames(const Ice::Context& context = Ice::noExplicitContext) const; // NOLINT(modernize-use-nodiscard)
447
448 /// Gets all the IceGrid applications currently registered.
449 /// @param context The request context.
450 /// @return A future that becomes available when the invocation completes. This future holds:
451 /// - The application names.
452 [[nodiscard]] std::future<::Ice::StringSeq> getAllApplicationNamesAsync(const Ice::Context& context = Ice::noExplicitContext) const;
453
454 /// Gets all the IceGrid applications currently registered.
455 /// @param response The response callback. It accepts:
456 /// - The application names.
457 /// @param exception The exception callback.
458 /// @param sent The sent callback.
459 /// @param context The request context.
460 /// @return A function that can be called to cancel the invocation locally.
461 // NOLINTNEXTLINE(modernize-use-nodiscard)
462 std::function<void()> getAllApplicationNamesAsync(std::function<void(::Ice::StringSeq)> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
463
464 /// @private
465 void _iceI_getAllApplicationNames(const std::shared_ptr<IceInternal::OutgoingAsyncT<::Ice::StringSeq>>&, const Ice::Context&) const;
466
467 /// Gets information about a server.
468 /// @param id The server ID.
469 /// @param context The request context.
470 /// @return The server information.
471 /// @throws IceGrid::ServerNotExistException Thrown when the server doesn't exist.
472 ServerInfo getServerInfo(std::string_view id, const Ice::Context& context = Ice::noExplicitContext) const; // NOLINT(modernize-use-nodiscard)
473
474 /// Gets information about a server.
475 /// @param id The server ID.
476 /// @param context The request context.
477 /// @return A future that becomes available when the invocation completes. This future holds:
478 /// - The server information.
479 [[nodiscard]] std::future<ServerInfo> getServerInfoAsync(std::string_view id, const Ice::Context& context = Ice::noExplicitContext) const;
480
481 /// Gets information about a server.
482 /// @param id The server ID.
483 /// @param response The response callback. It accepts:
484 /// - The server information.
485 /// @param exception The exception callback.
486 /// @param sent The sent callback.
487 /// @param context The request context.
488 /// @return A function that can be called to cancel the invocation locally.
489 // NOLINTNEXTLINE(modernize-use-nodiscard)
490 std::function<void()> getServerInfoAsync(std::string_view id, std::function<void(::IceGrid::ServerInfo)> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
491
492 /// @private
493 void _iceI_getServerInfo(const std::shared_ptr<IceInternal::OutgoingAsyncT<ServerInfo>>&, std::string_view, const Ice::Context&) const;
494
495 /// Gets the state of a server.
496 /// @param id The server ID.
497 /// @param context The request context.
498 /// @return The server state.
499 /// @throws IceGrid::DeploymentException Thrown when the deployment of the server failed.
500 /// @throws IceGrid::NodeUnreachableException Thrown when the node is unreachable.
501 /// @throws IceGrid::ServerNotExistException Thrown when the server doesn't exist.
502 ServerState getServerState(std::string_view id, const Ice::Context& context = Ice::noExplicitContext) const; // NOLINT(modernize-use-nodiscard)
503
504 /// Gets the state of a server.
505 /// @param id The server ID.
506 /// @param context The request context.
507 /// @return A future that becomes available when the invocation completes. This future holds:
508 /// - The server state.
509 [[nodiscard]] std::future<ServerState> getServerStateAsync(std::string_view id, const Ice::Context& context = Ice::noExplicitContext) const;
510
511 /// Gets the state of a server.
512 /// @param id The server ID.
513 /// @param response The response callback. It accepts:
514 /// - The server state.
515 /// @param exception The exception callback.
516 /// @param sent The sent callback.
517 /// @param context The request context.
518 /// @return A function that can be called to cancel the invocation locally.
519 // NOLINTNEXTLINE(modernize-use-nodiscard)
520 std::function<void()> getServerStateAsync(std::string_view id, std::function<void(::IceGrid::ServerState)> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
521
522 /// @private
523 void _iceI_getServerState(const std::shared_ptr<IceInternal::OutgoingAsyncT<ServerState>>&, std::string_view, const Ice::Context&) const;
524
525 /// Gets the system process ID of a server. The process ID is operating system dependent.
526 /// @param id The server ID.
527 /// @param context The request context.
528 /// @return The process ID.
529 /// @throws IceGrid::DeploymentException Thrown when the deployment of the server failed.
530 /// @throws IceGrid::NodeUnreachableException Thrown when the node is unreachable.
531 /// @throws IceGrid::ServerNotExistException Thrown when the server doesn't exist.
532 std::int32_t getServerPid(std::string_view id, const Ice::Context& context = Ice::noExplicitContext) const; // NOLINT(modernize-use-nodiscard)
533
534 /// Gets the system process ID of a server. The process ID is operating system dependent.
535 /// @param id The server ID.
536 /// @param context The request context.
537 /// @return A future that becomes available when the invocation completes. This future holds:
538 /// - The process ID.
539 [[nodiscard]] std::future<std::int32_t> getServerPidAsync(std::string_view id, const Ice::Context& context = Ice::noExplicitContext) const;
540
541 /// Gets the system process ID of a server. The process ID is operating system dependent.
542 /// @param id The server ID.
543 /// @param response The response callback. It accepts:
544 /// - The process ID.
545 /// @param exception The exception callback.
546 /// @param sent The sent callback.
547 /// @param context The request context.
548 /// @return A function that can be called to cancel the invocation locally.
549 // NOLINTNEXTLINE(modernize-use-nodiscard)
550 std::function<void()> getServerPidAsync(std::string_view id, std::function<void(std::int32_t)> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
551
552 /// @private
553 void _iceI_getServerPid(const std::shared_ptr<IceInternal::OutgoingAsyncT<std::int32_t>>&, std::string_view, const Ice::Context&) const;
554
555 /// Gets the category for server admin objects. You can manufacture a server admin proxy from the admin proxy by
556 /// changing its identity: use the server ID as name and the returned category as category.
557 /// @param context The request context.
558 /// @return The category for server admin objects.
559 std::string getServerAdminCategory(const Ice::Context& context = Ice::noExplicitContext) const; // NOLINT(modernize-use-nodiscard)
560
561 /// Gets the category for server admin objects. You can manufacture a server admin proxy from the admin proxy by
562 /// changing its identity: use the server ID as name and the returned category as category.
563 /// @param context The request context.
564 /// @return A future that becomes available when the invocation completes. This future holds:
565 /// - The category for server admin objects.
566 [[nodiscard]] std::future<std::string> getServerAdminCategoryAsync(const Ice::Context& context = Ice::noExplicitContext) const;
567
568 /// Gets the category for server admin objects. You can manufacture a server admin proxy from the admin proxy by
569 /// changing its identity: use the server ID as name and the returned category as category.
570 /// @param response The response callback. It accepts:
571 /// - The category for server admin objects.
572 /// @param exception The exception callback.
573 /// @param sent The sent callback.
574 /// @param context The request context.
575 /// @return A function that can be called to cancel the invocation locally.
576 // NOLINTNEXTLINE(modernize-use-nodiscard)
577 std::function<void()> getServerAdminCategoryAsync(std::function<void(std::string)> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
578
579 /// @private
580 void _iceI_getServerAdminCategory(const std::shared_ptr<IceInternal::OutgoingAsyncT<std::string>>&, const Ice::Context&) const;
581
582 /// Gets a proxy to the admin object of a server.
583 /// @param id The server ID.
584 /// @param context The request context.
585 /// @return A proxy to the admin object of the server. This proxy is never null.
586 /// @throws IceGrid::DeploymentException Thrown when the deployment of the server failed.
587 /// @throws IceGrid::NodeUnreachableException Thrown when the node is unreachable.
588 /// @throws IceGrid::ServerNotExistException Thrown when the server doesn't exist.
589 std::optional<Ice::ObjectPrx> getServerAdmin(std::string_view id, const Ice::Context& context = Ice::noExplicitContext) const; // NOLINT(modernize-use-nodiscard)
590
591 /// Gets a proxy to the admin object of a server.
592 /// @param id The server ID.
593 /// @param context The request context.
594 /// @return A future that becomes available when the invocation completes. This future holds:
595 /// - A proxy to the admin object of the server. This proxy is never null.
596 [[nodiscard]] std::future<std::optional<Ice::ObjectPrx>> getServerAdminAsync(std::string_view id, const Ice::Context& context = Ice::noExplicitContext) const;
597
598 /// Gets a proxy to the admin object of a server.
599 /// @param id The server ID.
600 /// @param response The response callback. It accepts:
601 /// - A proxy to the admin object of the server. This proxy is never null.
602 /// @param exception The exception callback.
603 /// @param sent The sent callback.
604 /// @param context The request context.
605 /// @return A function that can be called to cancel the invocation locally.
606 // NOLINTNEXTLINE(modernize-use-nodiscard)
607 std::function<void()> getServerAdminAsync(std::string_view id, std::function<void(std::optional<Ice::ObjectPrx>)> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
608
609 /// @private
610 void _iceI_getServerAdmin(const std::shared_ptr<IceInternal::OutgoingAsyncT<std::optional<Ice::ObjectPrx>>>&, std::string_view, const Ice::Context&) const;
611
612 /// Enables or disables a server. A disabled server can't be started on demand or administratively. The enable
613 /// state of the server is not persistent: if the node is shut down and restarted, the server will be enabled by
614 /// default.
615 /// @param id The server ID.
616 /// @param enabled `true` to enable the server, `false` to disable it.
617 /// @param context The request context.
618 /// @throws IceGrid::DeploymentException Thrown when the deployment of the server failed.
619 /// @throws IceGrid::NodeUnreachableException Thrown when the node is unreachable.
620 /// @throws IceGrid::ServerNotExistException Thrown when the server doesn't exist.
621 void enableServer(std::string_view id, bool enabled, const Ice::Context& context = Ice::noExplicitContext) const;
622
623 /// Enables or disables a server. A disabled server can't be started on demand or administratively. The enable
624 /// state of the server is not persistent: if the node is shut down and restarted, the server will be enabled by
625 /// default.
626 /// @param id The server ID.
627 /// @param enabled `true` to enable the server, `false` to disable it.
628 /// @param context The request context.
629 /// @return A future that becomes available when the invocation completes.
630 [[nodiscard]] std::future<void> enableServerAsync(std::string_view id, bool enabled, const Ice::Context& context = Ice::noExplicitContext) const;
631
632 /// Enables or disables a server. A disabled server can't be started on demand or administratively. The enable
633 /// state of the server is not persistent: if the node is shut down and restarted, the server will be enabled by
634 /// default.
635 /// @param id The server ID.
636 /// @param enabled `true` to enable the server, `false` to disable it.
637 /// @param response The response callback.
638 /// @param exception The exception callback.
639 /// @param sent The sent callback.
640 /// @param context The request context.
641 /// @return A function that can be called to cancel the invocation locally.
642 // NOLINTNEXTLINE(modernize-use-nodiscard)
643 std::function<void()> enableServerAsync(std::string_view id, bool enabled, std::function<void()> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
644
645 /// @private
646 void _iceI_enableServer(const std::shared_ptr<IceInternal::OutgoingAsyncT<void>>&, std::string_view, bool, const Ice::Context&) const;
647
648 /// Checks if the server is enabled or disabled.
649 /// @param id The server ID.
650 /// @param context The request context.
651 /// @return `true` if the server is enabled, `false` otherwise.
652 /// @throws IceGrid::DeploymentException Thrown when the deployment of the server failed.
653 /// @throws IceGrid::NodeUnreachableException Thrown when the node is unreachable.
654 /// @throws IceGrid::ServerNotExistException Thrown when the server doesn't exist.
655 bool isServerEnabled(std::string_view id, const Ice::Context& context = Ice::noExplicitContext) const; // NOLINT(modernize-use-nodiscard)
656
657 /// Checks if the server is enabled or disabled.
658 /// @param id The server ID.
659 /// @param context The request context.
660 /// @return A future that becomes available when the invocation completes. This future holds:
661 /// - `true` if the server is enabled, `false` otherwise.
662 [[nodiscard]] std::future<bool> isServerEnabledAsync(std::string_view id, const Ice::Context& context = Ice::noExplicitContext) const;
663
664 /// Checks if the server is enabled or disabled.
665 /// @param id The server ID.
666 /// @param response The response callback. It accepts:
667 /// - `true` if the server is enabled, `false` otherwise.
668 /// @param exception The exception callback.
669 /// @param sent The sent callback.
670 /// @param context The request context.
671 /// @return A function that can be called to cancel the invocation locally.
672 // NOLINTNEXTLINE(modernize-use-nodiscard)
673 std::function<void()> isServerEnabledAsync(std::string_view id, std::function<void(bool)> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
674
675 /// @private
676 void _iceI_isServerEnabled(const std::shared_ptr<IceInternal::OutgoingAsyncT<bool>>&, std::string_view, const Ice::Context&) const;
677
678 /// Starts a server and waits for its activation.
679 /// @param id The server id.
680 /// @param context The request context.
681 /// @throws IceGrid::DeploymentException Thrown when the deployment of the server failed.
682 /// @throws IceGrid::NodeUnreachableException Thrown when the node is unreachable.
683 /// @throws IceGrid::ServerNotExistException Thrown when the server doesn't exist.
684 /// @throws IceGrid::ServerStartException Thrown when the server startup failed.
685 void startServer(std::string_view id, const Ice::Context& context = Ice::noExplicitContext) const;
686
687 /// Starts a server and waits for its activation.
688 /// @param id The server id.
689 /// @param context The request context.
690 /// @return A future that becomes available when the invocation completes.
691 [[nodiscard]] std::future<void> startServerAsync(std::string_view id, const Ice::Context& context = Ice::noExplicitContext) const;
692
693 /// Starts a server and waits for its activation.
694 /// @param id The server id.
695 /// @param response The response callback.
696 /// @param exception The exception callback.
697 /// @param sent The sent callback.
698 /// @param context The request context.
699 /// @return A function that can be called to cancel the invocation locally.
700 // NOLINTNEXTLINE(modernize-use-nodiscard)
701 std::function<void()> startServerAsync(std::string_view id, std::function<void()> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
702
703 /// @private
704 void _iceI_startServer(const std::shared_ptr<IceInternal::OutgoingAsyncT<void>>&, std::string_view, const Ice::Context&) const;
705
706 /// Stops a server.
707 /// @param id The server ID.
708 /// @param context The request context.
709 /// @throws IceGrid::DeploymentException Thrown when the deployment of the server failed.
710 /// @throws IceGrid::NodeUnreachableException Thrown when the node is unreachable.
711 /// @throws IceGrid::ServerNotExistException Thrown when the server doesn't exist.
712 /// @throws IceGrid::ServerStopException Thrown when the server stop failed.
713 void stopServer(std::string_view id, const Ice::Context& context = Ice::noExplicitContext) const;
714
715 /// Stops a server.
716 /// @param id The server ID.
717 /// @param context The request context.
718 /// @return A future that becomes available when the invocation completes.
719 [[nodiscard]] std::future<void> stopServerAsync(std::string_view id, const Ice::Context& context = Ice::noExplicitContext) const;
720
721 /// Stops a server.
722 /// @param id The server ID.
723 /// @param response The response callback.
724 /// @param exception The exception callback.
725 /// @param sent The sent callback.
726 /// @param context The request context.
727 /// @return A function that can be called to cancel the invocation locally.
728 // NOLINTNEXTLINE(modernize-use-nodiscard)
729 std::function<void()> stopServerAsync(std::string_view id, std::function<void()> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
730
731 /// @private
732 void _iceI_stopServer(const std::shared_ptr<IceInternal::OutgoingAsyncT<void>>&, std::string_view, const Ice::Context&) const;
733
734 /// Sends a signal to a server.
735 /// @param id The server ID.
736 /// @param signal The signal, for example SIGTERM or 15.
737 /// @param context The request context.
738 /// @throws IceGrid::BadSignalException Thrown when the signal is not recognized by the target server.
739 /// @throws IceGrid::DeploymentException Thrown when the deployment of the server failed.
740 /// @throws IceGrid::NodeUnreachableException Thrown when the node is unreachable.
741 /// @throws IceGrid::ServerNotExistException Thrown when the server doesn't exist.
742 void sendSignal(std::string_view id, std::string_view signal, const Ice::Context& context = Ice::noExplicitContext) const;
743
744 /// Sends a signal to a server.
745 /// @param id The server ID.
746 /// @param signal The signal, for example SIGTERM or 15.
747 /// @param context The request context.
748 /// @return A future that becomes available when the invocation completes.
749 [[nodiscard]] std::future<void> sendSignalAsync(std::string_view id, std::string_view signal, const Ice::Context& context = Ice::noExplicitContext) const;
750
751 /// Sends a signal to a server.
752 /// @param id The server ID.
753 /// @param signal The signal, for example SIGTERM or 15.
754 /// @param response The response callback.
755 /// @param exception The exception callback.
756 /// @param sent The sent callback.
757 /// @param context The request context.
758 /// @return A function that can be called to cancel the invocation locally.
759 // NOLINTNEXTLINE(modernize-use-nodiscard)
760 std::function<void()> sendSignalAsync(std::string_view id, std::string_view signal, std::function<void()> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
761
762 /// @private
763 void _iceI_sendSignal(const std::shared_ptr<IceInternal::OutgoingAsyncT<void>>&, std::string_view, std::string_view, const Ice::Context&) const;
764
765 /// Gets the IDs of all the servers registered with IceGrid.
766 /// @param context The request context.
767 /// @return The server IDs.
768 ::Ice::StringSeq getAllServerIds(const Ice::Context& context = Ice::noExplicitContext) const; // NOLINT(modernize-use-nodiscard)
769
770 /// Gets the IDs of all the servers registered with IceGrid.
771 /// @param context The request context.
772 /// @return A future that becomes available when the invocation completes. This future holds:
773 /// - The server IDs.
774 [[nodiscard]] std::future<::Ice::StringSeq> getAllServerIdsAsync(const Ice::Context& context = Ice::noExplicitContext) const;
775
776 /// Gets the IDs of all the servers registered with IceGrid.
777 /// @param response The response callback. It accepts:
778 /// - The server IDs.
779 /// @param exception The exception callback.
780 /// @param sent The sent callback.
781 /// @param context The request context.
782 /// @return A function that can be called to cancel the invocation locally.
783 // NOLINTNEXTLINE(modernize-use-nodiscard)
784 std::function<void()> getAllServerIdsAsync(std::function<void(::Ice::StringSeq)> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
785
786 /// @private
787 void _iceI_getAllServerIds(const std::shared_ptr<IceInternal::OutgoingAsyncT<::Ice::StringSeq>>&, const Ice::Context&) const;
788
789 /// Gets adapter information for the replica group or adapter with the given ID.
790 /// @param id The adapter or replica group ID.
791 /// @param context The request context.
792 /// @return A sequence of AdapterInfo. If @p id refers to an adapter, this sequence contains a single element.
793 /// If @p id refers to a replica group, this sequence contains adapter information for each member of the
794 /// replica group.
795 /// @throws IceGrid::AdapterNotExistException Thrown when the adapter or replica group doesn't exist.
796 AdapterInfoSeq getAdapterInfo(std::string_view id, const Ice::Context& context = Ice::noExplicitContext) const; // NOLINT(modernize-use-nodiscard)
797
798 /// Gets adapter information for the replica group or adapter with the given ID.
799 /// @param id The adapter or replica group ID.
800 /// @param context The request context.
801 /// @return A future that becomes available when the invocation completes. This future holds:
802 /// - A sequence of AdapterInfo. If @p id refers to an adapter, this sequence contains a single element.
803 /// If @p id refers to a replica group, this sequence contains adapter information for each member of the
804 /// replica group.
805 [[nodiscard]] std::future<AdapterInfoSeq> getAdapterInfoAsync(std::string_view id, const Ice::Context& context = Ice::noExplicitContext) const;
806
807 /// Gets adapter information for the replica group or adapter with the given ID.
808 /// @param id The adapter or replica group ID.
809 /// @param response The response callback. It accepts:
810 /// - A sequence of AdapterInfo. If @p id refers to an adapter, this sequence contains a single element.
811 /// If @p id refers to a replica group, this sequence contains adapter information for each member of the
812 /// replica group.
813 /// @param exception The exception callback.
814 /// @param sent The sent callback.
815 /// @param context The request context.
816 /// @return A function that can be called to cancel the invocation locally.
817 // NOLINTNEXTLINE(modernize-use-nodiscard)
818 std::function<void()> getAdapterInfoAsync(std::string_view id, std::function<void(::IceGrid::AdapterInfoSeq)> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
819
820 /// @private
821 void _iceI_getAdapterInfo(const std::shared_ptr<IceInternal::OutgoingAsyncT<AdapterInfoSeq>>&, std::string_view, const Ice::Context&) const;
822
823 /// Removes the adapter with the given ID.
824 /// @param id The adapter ID.
825 /// @param context The request context.
826 /// @throws IceGrid::AdapterNotExistException Thrown when the adapter doesn't exist.
827 /// @throws IceGrid::DeploymentException Thrown when the application deployment failed.
828 void removeAdapter(std::string_view id, const Ice::Context& context = Ice::noExplicitContext) const;
829
830 /// Removes the adapter with the given ID.
831 /// @param id The adapter ID.
832 /// @param context The request context.
833 /// @return A future that becomes available when the invocation completes.
834 [[nodiscard]] std::future<void> removeAdapterAsync(std::string_view id, const Ice::Context& context = Ice::noExplicitContext) const;
835
836 /// Removes the adapter with the given ID.
837 /// @param id The adapter ID.
838 /// @param response The response callback.
839 /// @param exception The exception callback.
840 /// @param sent The sent callback.
841 /// @param context The request context.
842 /// @return A function that can be called to cancel the invocation locally.
843 // NOLINTNEXTLINE(modernize-use-nodiscard)
844 std::function<void()> removeAdapterAsync(std::string_view id, std::function<void()> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
845
846 /// @private
847 void _iceI_removeAdapter(const std::shared_ptr<IceInternal::OutgoingAsyncT<void>>&, std::string_view, const Ice::Context&) const;
848
849 /// Gets the IDs of all adapters registered with IceGrid.
850 /// @param context The request context.
851 /// @return The adapter IDs.
852 ::Ice::StringSeq getAllAdapterIds(const Ice::Context& context = Ice::noExplicitContext) const; // NOLINT(modernize-use-nodiscard)
853
854 /// Gets the IDs of all adapters registered with IceGrid.
855 /// @param context The request context.
856 /// @return A future that becomes available when the invocation completes. This future holds:
857 /// - The adapter IDs.
858 [[nodiscard]] std::future<::Ice::StringSeq> getAllAdapterIdsAsync(const Ice::Context& context = Ice::noExplicitContext) const;
859
860 /// Gets the IDs of all adapters registered with IceGrid.
861 /// @param response The response callback. It accepts:
862 /// - The adapter IDs.
863 /// @param exception The exception callback.
864 /// @param sent The sent callback.
865 /// @param context The request context.
866 /// @return A function that can be called to cancel the invocation locally.
867 // NOLINTNEXTLINE(modernize-use-nodiscard)
868 std::function<void()> getAllAdapterIdsAsync(std::function<void(::Ice::StringSeq)> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
869
870 /// @private
871 void _iceI_getAllAdapterIds(const std::shared_ptr<IceInternal::OutgoingAsyncT<::Ice::StringSeq>>&, const Ice::Context&) const;
872
873 /// Adds an object to the object registry. IceGrid gets the object type by calling `ice_id` on @p obj. The
874 /// object must be reachable.
875 /// @param obj A proxy to the object. This proxy is never null.
876 /// @param context The request context.
877 /// @throws IceGrid::DeploymentException Thrown when the object can't be added.
878 /// @throws IceGrid::ObjectExistsException Thrown when the object is already registered.
879 void addObject(const std::optional<Ice::ObjectPrx>& obj, const Ice::Context& context = Ice::noExplicitContext) const;
880
881 /// Adds an object to the object registry. IceGrid gets the object type by calling `ice_id` on @p obj. The
882 /// object must be reachable.
883 /// @param obj A proxy to the object. This proxy is never null.
884 /// @param context The request context.
885 /// @return A future that becomes available when the invocation completes.
886 [[nodiscard]] std::future<void> addObjectAsync(const std::optional<Ice::ObjectPrx>& obj, const Ice::Context& context = Ice::noExplicitContext) const;
887
888 /// Adds an object to the object registry. IceGrid gets the object type by calling `ice_id` on @p obj. The
889 /// object must be reachable.
890 /// @param obj A proxy to the object. This proxy is never null.
891 /// @param response The response callback.
892 /// @param exception The exception callback.
893 /// @param sent The sent callback.
894 /// @param context The request context.
895 /// @return A function that can be called to cancel the invocation locally.
896 // NOLINTNEXTLINE(modernize-use-nodiscard)
897 std::function<void()> addObjectAsync(const std::optional<Ice::ObjectPrx>& obj, std::function<void()> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
898
899 /// @private
900 void _iceI_addObject(const std::shared_ptr<IceInternal::OutgoingAsyncT<void>>&, const std::optional<Ice::ObjectPrx>&, const Ice::Context&) const;
901
902 /// Updates an object in the object registry. Only objects added with this interface can be updated with this
903 /// operation. Objects added with deployment descriptors should be updated with the deployment mechanism.
904 /// @param obj A proxy to the object. This proxy is never null.
905 /// @param context The request context.
906 /// @throws IceGrid::DeploymentException Thrown when the object can't be updated.
907 /// @throws IceGrid::ObjectNotRegisteredException Thrown when the object isn't registered with the registry.
908 void updateObject(const std::optional<Ice::ObjectPrx>& obj, const Ice::Context& context = Ice::noExplicitContext) const;
909
910 /// Updates an object in the object registry. Only objects added with this interface can be updated with this
911 /// operation. Objects added with deployment descriptors should be updated with the deployment mechanism.
912 /// @param obj A proxy to the object. This proxy is never null.
913 /// @param context The request context.
914 /// @return A future that becomes available when the invocation completes.
915 [[nodiscard]] std::future<void> updateObjectAsync(const std::optional<Ice::ObjectPrx>& obj, const Ice::Context& context = Ice::noExplicitContext) const;
916
917 /// Updates an object in the object registry. Only objects added with this interface can be updated with this
918 /// operation. Objects added with deployment descriptors should be updated with the deployment mechanism.
919 /// @param obj A proxy to the object. This proxy is never null.
920 /// @param response The response callback.
921 /// @param exception The exception callback.
922 /// @param sent The sent callback.
923 /// @param context The request context.
924 /// @return A function that can be called to cancel the invocation locally.
925 // NOLINTNEXTLINE(modernize-use-nodiscard)
926 std::function<void()> updateObjectAsync(const std::optional<Ice::ObjectPrx>& obj, std::function<void()> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
927
928 /// @private
929 void _iceI_updateObject(const std::shared_ptr<IceInternal::OutgoingAsyncT<void>>&, const std::optional<Ice::ObjectPrx>&, const Ice::Context&) const;
930
931 /// Adds an object to the object registry and explicitly specifies its type.
932 /// @param obj The object to be added to the registry. The proxy is never null.
933 /// @param type The type name.
934 /// @param context The request context.
935 /// @throws IceGrid::DeploymentException Thrown when the application deployment failed.
936 /// @throws IceGrid::ObjectExistsException Thrown when the object is already registered.
937 void addObjectWithType(const std::optional<Ice::ObjectPrx>& obj, std::string_view type, const Ice::Context& context = Ice::noExplicitContext) const;
938
939 /// Adds an object to the object registry and explicitly specifies its type.
940 /// @param obj The object to be added to the registry. The proxy is never null.
941 /// @param type The type name.
942 /// @param context The request context.
943 /// @return A future that becomes available when the invocation completes.
944 [[nodiscard]] std::future<void> addObjectWithTypeAsync(const std::optional<Ice::ObjectPrx>& obj, std::string_view type, const Ice::Context& context = Ice::noExplicitContext) const;
945
946 /// Adds an object to the object registry and explicitly specifies its type.
947 /// @param obj The object to be added to the registry. The proxy is never null.
948 /// @param type The type name.
949 /// @param response The response callback.
950 /// @param exception The exception callback.
951 /// @param sent The sent callback.
952 /// @param context The request context.
953 /// @return A function that can be called to cancel the invocation locally.
954 // NOLINTNEXTLINE(modernize-use-nodiscard)
955 std::function<void()> addObjectWithTypeAsync(const std::optional<Ice::ObjectPrx>& obj, std::string_view type, std::function<void()> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
956
957 /// @private
958 void _iceI_addObjectWithType(const std::shared_ptr<IceInternal::OutgoingAsyncT<void>>&, const std::optional<Ice::ObjectPrx>&, std::string_view, const Ice::Context&) const;
959
960 /// Removes an object from the object registry. Only objects added with this interface can be removed with this
961 /// operation. Objects added with deployment descriptors should be removed with the deployment mechanism.
962 /// @param id The identity of the object to remove.
963 /// @param context The request context.
964 /// @throws IceGrid::DeploymentException Thrown when the object can't be removed.
965 /// @throws IceGrid::ObjectNotRegisteredException Thrown when the object isn't registered with the registry.
966 void removeObject(const ::Ice::Identity& id, const Ice::Context& context = Ice::noExplicitContext) const;
967
968 /// Removes an object from the object registry. Only objects added with this interface can be removed with this
969 /// operation. Objects added with deployment descriptors should be removed with the deployment mechanism.
970 /// @param id The identity of the object to remove.
971 /// @param context The request context.
972 /// @return A future that becomes available when the invocation completes.
973 [[nodiscard]] std::future<void> removeObjectAsync(const ::Ice::Identity& id, const Ice::Context& context = Ice::noExplicitContext) const;
974
975 /// Removes an object from the object registry. Only objects added with this interface can be removed with this
976 /// operation. Objects added with deployment descriptors should be removed with the deployment mechanism.
977 /// @param id The identity of the object to remove.
978 /// @param response The response callback.
979 /// @param exception The exception callback.
980 /// @param sent The sent callback.
981 /// @param context The request context.
982 /// @return A function that can be called to cancel the invocation locally.
983 // NOLINTNEXTLINE(modernize-use-nodiscard)
984 std::function<void()> removeObjectAsync(const ::Ice::Identity& id, std::function<void()> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
985
986 /// @private
987 void _iceI_removeObject(const std::shared_ptr<IceInternal::OutgoingAsyncT<void>>&, const ::Ice::Identity&, const Ice::Context&) const;
988
989 /// Gets the object info for the object.
990 /// @param id The identity of the object.
991 /// @param context The request context.
992 /// @return The object info.
993 /// @throws IceGrid::ObjectNotRegisteredException Thrown when the object isn't registered with the registry.
994 ObjectInfo getObjectInfo(const ::Ice::Identity& id, const Ice::Context& context = Ice::noExplicitContext) const; // NOLINT(modernize-use-nodiscard)
995
996 /// Gets the object info for the object.
997 /// @param id The identity of the object.
998 /// @param context The request context.
999 /// @return A future that becomes available when the invocation completes. This future holds:
1000 /// - The object info.
1001 [[nodiscard]] std::future<ObjectInfo> getObjectInfoAsync(const ::Ice::Identity& id, const Ice::Context& context = Ice::noExplicitContext) const;
1002
1003 /// Gets the object info for the object.
1004 /// @param id The identity of the object.
1005 /// @param response The response callback. It accepts:
1006 /// - The object info.
1007 /// @param exception The exception callback.
1008 /// @param sent The sent callback.
1009 /// @param context The request context.
1010 /// @return A function that can be called to cancel the invocation locally.
1011 // NOLINTNEXTLINE(modernize-use-nodiscard)
1012 std::function<void()> getObjectInfoAsync(const ::Ice::Identity& id, std::function<void(::IceGrid::ObjectInfo)> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
1013
1014 /// @private
1015 void _iceI_getObjectInfo(const std::shared_ptr<IceInternal::OutgoingAsyncT<ObjectInfo>>&, const ::Ice::Identity&, const Ice::Context&) const;
1016
1017 /// Gets the object info of all the registered objects with a given type.
1018 /// @param type The type name.
1019 /// @param context The request context.
1020 /// @return The object infos.
1021 ObjectInfoSeq getObjectInfosByType(std::string_view type, const Ice::Context& context = Ice::noExplicitContext) const; // NOLINT(modernize-use-nodiscard)
1022
1023 /// Gets the object info of all the registered objects with a given type.
1024 /// @param type The type name.
1025 /// @param context The request context.
1026 /// @return A future that becomes available when the invocation completes. This future holds:
1027 /// - The object infos.
1028 [[nodiscard]] std::future<ObjectInfoSeq> getObjectInfosByTypeAsync(std::string_view type, const Ice::Context& context = Ice::noExplicitContext) const;
1029
1030 /// Gets the object info of all the registered objects with a given type.
1031 /// @param type The type name.
1032 /// @param response The response callback. It accepts:
1033 /// - The object infos.
1034 /// @param exception The exception callback.
1035 /// @param sent The sent callback.
1036 /// @param context The request context.
1037 /// @return A function that can be called to cancel the invocation locally.
1038 // NOLINTNEXTLINE(modernize-use-nodiscard)
1039 std::function<void()> getObjectInfosByTypeAsync(std::string_view type, std::function<void(::IceGrid::ObjectInfoSeq)> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
1040
1041 /// @private
1042 void _iceI_getObjectInfosByType(const std::shared_ptr<IceInternal::OutgoingAsyncT<ObjectInfoSeq>>&, std::string_view, const Ice::Context&) const;
1043
1044 /// Gets the object info of all the registered objects whose stringified identities match the given expression.
1045 /// @param expr The expression to match against the stringified identities of registered objects. The expression
1046 /// may contain a trailing wildcard (`*`) character.
1047 /// @param context The request context.
1048 /// @return All the object infos with a stringified identity matching the given expression.
1049 ObjectInfoSeq getAllObjectInfos(std::string_view expr, const Ice::Context& context = Ice::noExplicitContext) const; // NOLINT(modernize-use-nodiscard)
1050
1051 /// Gets the object info of all the registered objects whose stringified identities match the given expression.
1052 /// @param expr The expression to match against the stringified identities of registered objects. The expression
1053 /// may contain a trailing wildcard (`*`) character.
1054 /// @param context The request context.
1055 /// @return A future that becomes available when the invocation completes. This future holds:
1056 /// - All the object infos with a stringified identity matching the given expression.
1057 [[nodiscard]] std::future<ObjectInfoSeq> getAllObjectInfosAsync(std::string_view expr, const Ice::Context& context = Ice::noExplicitContext) const;
1058
1059 /// Gets the object info of all the registered objects whose stringified identities match the given expression.
1060 /// @param expr The expression to match against the stringified identities of registered objects. The expression
1061 /// may contain a trailing wildcard (`*`) character.
1062 /// @param response The response callback. It accepts:
1063 /// - All the object infos with a stringified identity matching the given expression.
1064 /// @param exception The exception callback.
1065 /// @param sent The sent callback.
1066 /// @param context The request context.
1067 /// @return A function that can be called to cancel the invocation locally.
1068 // NOLINTNEXTLINE(modernize-use-nodiscard)
1069 std::function<void()> getAllObjectInfosAsync(std::string_view expr, std::function<void(::IceGrid::ObjectInfoSeq)> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
1070
1071 /// @private
1072 void _iceI_getAllObjectInfos(const std::shared_ptr<IceInternal::OutgoingAsyncT<ObjectInfoSeq>>&, std::string_view, const Ice::Context&) const;
1073
1074 /// Pings an IceGrid node to see if it is active.
1075 /// @param name The node name.
1076 /// @param context The request context.
1077 /// @return `true` if the node ping succeeded, `false` otherwise.
1078 /// @throws IceGrid::NodeNotExistException Thrown when the node doesn't exist.
1079 bool pingNode(std::string_view name, const Ice::Context& context = Ice::noExplicitContext) const; // NOLINT(modernize-use-nodiscard)
1080
1081 /// Pings an IceGrid node to see if it is active.
1082 /// @param name The node name.
1083 /// @param context The request context.
1084 /// @return A future that becomes available when the invocation completes. This future holds:
1085 /// - `true` if the node ping succeeded, `false` otherwise.
1086 [[nodiscard]] std::future<bool> pingNodeAsync(std::string_view name, const Ice::Context& context = Ice::noExplicitContext) const;
1087
1088 /// Pings an IceGrid node to see if it is active.
1089 /// @param name The node name.
1090 /// @param response The response callback. It accepts:
1091 /// - `true` if the node ping succeeded, `false` otherwise.
1092 /// @param exception The exception callback.
1093 /// @param sent The sent callback.
1094 /// @param context The request context.
1095 /// @return A function that can be called to cancel the invocation locally.
1096 // NOLINTNEXTLINE(modernize-use-nodiscard)
1097 std::function<void()> pingNodeAsync(std::string_view name, std::function<void(bool)> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
1098
1099 /// @private
1100 void _iceI_pingNode(const std::shared_ptr<IceInternal::OutgoingAsyncT<bool>>&, std::string_view, const Ice::Context&) const;
1101
1102 /// Gets the load averages of a node.
1103 /// @param name The node name.
1104 /// @param context The request context.
1105 /// @return The node load information.
1106 /// @throws IceGrid::NodeNotExistException Thrown when the node doesn't exist.
1107 /// @throws IceGrid::NodeUnreachableException Thrown when the node is unreachable.
1108 LoadInfo getNodeLoad(std::string_view name, const Ice::Context& context = Ice::noExplicitContext) const; // NOLINT(modernize-use-nodiscard)
1109
1110 /// Gets the load averages of a node.
1111 /// @param name The node name.
1112 /// @param context The request context.
1113 /// @return A future that becomes available when the invocation completes. This future holds:
1114 /// - The node load information.
1115 [[nodiscard]] std::future<LoadInfo> getNodeLoadAsync(std::string_view name, const Ice::Context& context = Ice::noExplicitContext) const;
1116
1117 /// Gets the load averages of a node.
1118 /// @param name The node name.
1119 /// @param response The response callback. It accepts:
1120 /// - The node load information.
1121 /// @param exception The exception callback.
1122 /// @param sent The sent callback.
1123 /// @param context The request context.
1124 /// @return A function that can be called to cancel the invocation locally.
1125 // NOLINTNEXTLINE(modernize-use-nodiscard)
1126 std::function<void()> getNodeLoadAsync(std::string_view name, std::function<void(::IceGrid::LoadInfo)> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
1127
1128 /// @private
1129 void _iceI_getNodeLoad(const std::shared_ptr<IceInternal::OutgoingAsyncT<LoadInfo>>&, std::string_view, const Ice::Context&) const;
1130
1131 /// Gets the node information of a node.
1132 /// @param name The node name.
1133 /// @param context The request context.
1134 /// @return The node information.
1135 /// @throws IceGrid::NodeNotExistException Thrown when the node doesn't exist.
1136 /// @throws IceGrid::NodeUnreachableException Thrown when the node is unreachable.
1137 NodeInfo getNodeInfo(std::string_view name, const Ice::Context& context = Ice::noExplicitContext) const; // NOLINT(modernize-use-nodiscard)
1138
1139 /// Gets the node information of a node.
1140 /// @param name The node name.
1141 /// @param context The request context.
1142 /// @return A future that becomes available when the invocation completes. This future holds:
1143 /// - The node information.
1144 [[nodiscard]] std::future<NodeInfo> getNodeInfoAsync(std::string_view name, const Ice::Context& context = Ice::noExplicitContext) const;
1145
1146 /// Gets the node information of a node.
1147 /// @param name The node name.
1148 /// @param response The response callback. It accepts:
1149 /// - The node information.
1150 /// @param exception The exception callback.
1151 /// @param sent The sent callback.
1152 /// @param context The request context.
1153 /// @return A function that can be called to cancel the invocation locally.
1154 // NOLINTNEXTLINE(modernize-use-nodiscard)
1155 std::function<void()> getNodeInfoAsync(std::string_view name, std::function<void(::IceGrid::NodeInfo)> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
1156
1157 /// @private
1158 void _iceI_getNodeInfo(const std::shared_ptr<IceInternal::OutgoingAsyncT<NodeInfo>>&, std::string_view, const Ice::Context&) const;
1159
1160 /// Gets a proxy to the admin object of an IceGrid node.
1161 /// @param name The IceGrid node name.
1162 /// @param context The request context.
1163 /// @return A proxy to the IceGrid node's admin object. This proxy is never null.
1164 /// @throws IceGrid::NodeNotExistException Thrown when the node doesn't exist.
1165 /// @throws IceGrid::NodeUnreachableException Thrown when the node is unreachable.
1166 std::optional<Ice::ObjectPrx> getNodeAdmin(std::string_view name, const Ice::Context& context = Ice::noExplicitContext) const; // NOLINT(modernize-use-nodiscard)
1167
1168 /// Gets a proxy to the admin object of an IceGrid node.
1169 /// @param name The IceGrid node name.
1170 /// @param context The request context.
1171 /// @return A future that becomes available when the invocation completes. This future holds:
1172 /// - A proxy to the IceGrid node's admin object. This proxy is never null.
1173 [[nodiscard]] std::future<std::optional<Ice::ObjectPrx>> getNodeAdminAsync(std::string_view name, const Ice::Context& context = Ice::noExplicitContext) const;
1174
1175 /// Gets a proxy to the admin object of an IceGrid node.
1176 /// @param name The IceGrid node name.
1177 /// @param response The response callback. It accepts:
1178 /// - A proxy to the IceGrid node's admin object. This proxy is never null.
1179 /// @param exception The exception callback.
1180 /// @param sent The sent callback.
1181 /// @param context The request context.
1182 /// @return A function that can be called to cancel the invocation locally.
1183 // NOLINTNEXTLINE(modernize-use-nodiscard)
1184 std::function<void()> getNodeAdminAsync(std::string_view name, std::function<void(std::optional<Ice::ObjectPrx>)> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
1185
1186 /// @private
1187 void _iceI_getNodeAdmin(const std::shared_ptr<IceInternal::OutgoingAsyncT<std::optional<Ice::ObjectPrx>>>&, std::string_view, const Ice::Context&) const;
1188
1189 /// Gets the number of physical processor sockets in the computer where an IceGrid node is deployed.
1190 /// Note that this operation returns 1 on operating systems where this can't be automatically determined and
1191 /// where the `IceGrid.Node.ProcessorSocketCount` property for the node is not set.
1192 /// @param name The node name.
1193 /// @param context The request context.
1194 /// @return The number of processor sockets or 1 if the number of sockets can't be determined.
1195 /// @throws IceGrid::NodeNotExistException Thrown when the node doesn't exist.
1196 /// @throws IceGrid::NodeUnreachableException Thrown when the node is unreachable.
1197 std::int32_t getNodeProcessorSocketCount(std::string_view name, const Ice::Context& context = Ice::noExplicitContext) const; // NOLINT(modernize-use-nodiscard)
1198
1199 /// Gets the number of physical processor sockets in the computer where an IceGrid node is deployed.
1200 /// Note that this operation returns 1 on operating systems where this can't be automatically determined and
1201 /// where the `IceGrid.Node.ProcessorSocketCount` property for the node is not set.
1202 /// @param name The node name.
1203 /// @param context The request context.
1204 /// @return A future that becomes available when the invocation completes. This future holds:
1205 /// - The number of processor sockets or 1 if the number of sockets can't be determined.
1206 [[nodiscard]] std::future<std::int32_t> getNodeProcessorSocketCountAsync(std::string_view name, const Ice::Context& context = Ice::noExplicitContext) const;
1207
1208 /// Gets the number of physical processor sockets in the computer where an IceGrid node is deployed.
1209 /// Note that this operation returns 1 on operating systems where this can't be automatically determined and
1210 /// where the `IceGrid.Node.ProcessorSocketCount` property for the node is not set.
1211 /// @param name The node name.
1212 /// @param response The response callback. It accepts:
1213 /// - The number of processor sockets or 1 if the number of sockets can't be determined.
1214 /// @param exception The exception callback.
1215 /// @param sent The sent callback.
1216 /// @param context The request context.
1217 /// @return A function that can be called to cancel the invocation locally.
1218 // NOLINTNEXTLINE(modernize-use-nodiscard)
1219 std::function<void()> getNodeProcessorSocketCountAsync(std::string_view name, std::function<void(std::int32_t)> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
1220
1221 /// @private
1222 void _iceI_getNodeProcessorSocketCount(const std::shared_ptr<IceInternal::OutgoingAsyncT<std::int32_t>>&, std::string_view, const Ice::Context&) const;
1223
1224 /// Shuts down an IceGrid node.
1225 /// @param name The node name.
1226 /// @param context The request context.
1227 /// @throws IceGrid::NodeNotExistException Thrown when the node doesn't exist.
1228 /// @throws IceGrid::NodeUnreachableException Thrown when the node is unreachable.
1229 void shutdownNode(std::string_view name, const Ice::Context& context = Ice::noExplicitContext) const;
1230
1231 /// Shuts down an IceGrid node.
1232 /// @param name The node name.
1233 /// @param context The request context.
1234 /// @return A future that becomes available when the invocation completes.
1235 [[nodiscard]] std::future<void> shutdownNodeAsync(std::string_view name, const Ice::Context& context = Ice::noExplicitContext) const;
1236
1237 /// Shuts down an IceGrid node.
1238 /// @param name The node name.
1239 /// @param response The response callback.
1240 /// @param exception The exception callback.
1241 /// @param sent The sent callback.
1242 /// @param context The request context.
1243 /// @return A function that can be called to cancel the invocation locally.
1244 // NOLINTNEXTLINE(modernize-use-nodiscard)
1245 std::function<void()> shutdownNodeAsync(std::string_view name, std::function<void()> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
1246
1247 /// @private
1248 void _iceI_shutdownNode(const std::shared_ptr<IceInternal::OutgoingAsyncT<void>>&, std::string_view, const Ice::Context&) const;
1249
1250 /// Get the hostname of a node.
1251 /// @param name The node name.
1252 /// @param context The request context.
1253 /// @return The node hostname.
1254 /// @throws IceGrid::NodeNotExistException Thrown when the node doesn't exist.
1255 /// @throws IceGrid::NodeUnreachableException Thrown when the node is unreachable.
1256 std::string getNodeHostname(std::string_view name, const Ice::Context& context = Ice::noExplicitContext) const; // NOLINT(modernize-use-nodiscard)
1257
1258 /// Get the hostname of a node.
1259 /// @param name The node name.
1260 /// @param context The request context.
1261 /// @return A future that becomes available when the invocation completes. This future holds:
1262 /// - The node hostname.
1263 [[nodiscard]] std::future<std::string> getNodeHostnameAsync(std::string_view name, const Ice::Context& context = Ice::noExplicitContext) const;
1264
1265 /// Get the hostname of a node.
1266 /// @param name The node name.
1267 /// @param response The response callback. It accepts:
1268 /// - The node hostname.
1269 /// @param exception The exception callback.
1270 /// @param sent The sent callback.
1271 /// @param context The request context.
1272 /// @return A function that can be called to cancel the invocation locally.
1273 // NOLINTNEXTLINE(modernize-use-nodiscard)
1274 std::function<void()> getNodeHostnameAsync(std::string_view name, std::function<void(std::string)> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
1275
1276 /// @private
1277 void _iceI_getNodeHostname(const std::shared_ptr<IceInternal::OutgoingAsyncT<std::string>>&, std::string_view, const Ice::Context&) const;
1278
1279 /// Gets the names of all IceGrid nodes currently registered.
1280 /// @param context The request context.
1281 /// @return The node names.
1282 ::Ice::StringSeq getAllNodeNames(const Ice::Context& context = Ice::noExplicitContext) const; // NOLINT(modernize-use-nodiscard)
1283
1284 /// Gets the names of all IceGrid nodes currently registered.
1285 /// @param context The request context.
1286 /// @return A future that becomes available when the invocation completes. This future holds:
1287 /// - The node names.
1288 [[nodiscard]] std::future<::Ice::StringSeq> getAllNodeNamesAsync(const Ice::Context& context = Ice::noExplicitContext) const;
1289
1290 /// Gets the names of all IceGrid nodes currently registered.
1291 /// @param response The response callback. It accepts:
1292 /// - The node names.
1293 /// @param exception The exception callback.
1294 /// @param sent The sent callback.
1295 /// @param context The request context.
1296 /// @return A function that can be called to cancel the invocation locally.
1297 // NOLINTNEXTLINE(modernize-use-nodiscard)
1298 std::function<void()> getAllNodeNamesAsync(std::function<void(::Ice::StringSeq)> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
1299
1300 /// @private
1301 void _iceI_getAllNodeNames(const std::shared_ptr<IceInternal::OutgoingAsyncT<::Ice::StringSeq>>&, const Ice::Context&) const;
1302
1303 /// Pings an IceGrid registry to see if it is active.
1304 /// @param name The registry name.
1305 /// @param context The request context.
1306 /// @return `true` if the registry ping succeeded, `false` otherwise.
1307 /// @throws IceGrid::RegistryNotExistException Thrown when the registry doesn't exist.
1308 bool pingRegistry(std::string_view name, const Ice::Context& context = Ice::noExplicitContext) const; // NOLINT(modernize-use-nodiscard)
1309
1310 /// Pings an IceGrid registry to see if it is active.
1311 /// @param name The registry name.
1312 /// @param context The request context.
1313 /// @return A future that becomes available when the invocation completes. This future holds:
1314 /// - `true` if the registry ping succeeded, `false` otherwise.
1315 [[nodiscard]] std::future<bool> pingRegistryAsync(std::string_view name, const Ice::Context& context = Ice::noExplicitContext) const;
1316
1317 /// Pings an IceGrid registry to see if it is active.
1318 /// @param name The registry name.
1319 /// @param response The response callback. It accepts:
1320 /// - `true` if the registry ping succeeded, `false` otherwise.
1321 /// @param exception The exception callback.
1322 /// @param sent The sent callback.
1323 /// @param context The request context.
1324 /// @return A function that can be called to cancel the invocation locally.
1325 // NOLINTNEXTLINE(modernize-use-nodiscard)
1326 std::function<void()> pingRegistryAsync(std::string_view name, std::function<void(bool)> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
1327
1328 /// @private
1329 void _iceI_pingRegistry(const std::shared_ptr<IceInternal::OutgoingAsyncT<bool>>&, std::string_view, const Ice::Context&) const;
1330
1331 /// Gets the registry information of an IceGrid registry.
1332 /// @param name The registry name.
1333 /// @param context The request context.
1334 /// @return The registry information.
1335 /// @throws IceGrid::RegistryNotExistException Thrown when the registry doesn't exist.
1336 /// @throws IceGrid::RegistryUnreachableException Thrown when the registry is unreachable.
1337 RegistryInfo getRegistryInfo(std::string_view name, const Ice::Context& context = Ice::noExplicitContext) const; // NOLINT(modernize-use-nodiscard)
1338
1339 /// Gets the registry information of an IceGrid registry.
1340 /// @param name The registry name.
1341 /// @param context The request context.
1342 /// @return A future that becomes available when the invocation completes. This future holds:
1343 /// - The registry information.
1344 [[nodiscard]] std::future<RegistryInfo> getRegistryInfoAsync(std::string_view name, const Ice::Context& context = Ice::noExplicitContext) const;
1345
1346 /// Gets the registry information of an IceGrid registry.
1347 /// @param name The registry name.
1348 /// @param response The response callback. It accepts:
1349 /// - The registry information.
1350 /// @param exception The exception callback.
1351 /// @param sent The sent callback.
1352 /// @param context The request context.
1353 /// @return A function that can be called to cancel the invocation locally.
1354 // NOLINTNEXTLINE(modernize-use-nodiscard)
1355 std::function<void()> getRegistryInfoAsync(std::string_view name, std::function<void(::IceGrid::RegistryInfo)> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
1356
1357 /// @private
1358 void _iceI_getRegistryInfo(const std::shared_ptr<IceInternal::OutgoingAsyncT<RegistryInfo>>&, std::string_view, const Ice::Context&) const;
1359
1360 /// Gets a proxy to the admin object of an IceGrid registry.
1361 /// @param name The registry name.
1362 /// @param context The request context.
1363 /// @return A proxy to the admin object of an IceGrid registry. This proxy is never null.
1364 /// @throws IceGrid::RegistryNotExistException Thrown when the registry doesn't exist.
1365 std::optional<Ice::ObjectPrx> getRegistryAdmin(std::string_view name, const Ice::Context& context = Ice::noExplicitContext) const; // NOLINT(modernize-use-nodiscard)
1366
1367 /// Gets a proxy to the admin object of an IceGrid registry.
1368 /// @param name The registry name.
1369 /// @param context The request context.
1370 /// @return A future that becomes available when the invocation completes. This future holds:
1371 /// - A proxy to the admin object of an IceGrid registry. This proxy is never null.
1372 [[nodiscard]] std::future<std::optional<Ice::ObjectPrx>> getRegistryAdminAsync(std::string_view name, const Ice::Context& context = Ice::noExplicitContext) const;
1373
1374 /// Gets a proxy to the admin object of an IceGrid registry.
1375 /// @param name The registry name.
1376 /// @param response The response callback. It accepts:
1377 /// - A proxy to the admin object of an IceGrid registry. This proxy is never null.
1378 /// @param exception The exception callback.
1379 /// @param sent The sent callback.
1380 /// @param context The request context.
1381 /// @return A function that can be called to cancel the invocation locally.
1382 // NOLINTNEXTLINE(modernize-use-nodiscard)
1383 std::function<void()> getRegistryAdminAsync(std::string_view name, std::function<void(std::optional<Ice::ObjectPrx>)> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
1384
1385 /// @private
1386 void _iceI_getRegistryAdmin(const std::shared_ptr<IceInternal::OutgoingAsyncT<std::optional<Ice::ObjectPrx>>>&, std::string_view, const Ice::Context&) const;
1387
1388 /// Shuts down an IceGrid registry.
1389 /// @param name The registry name.
1390 /// @param context The request context.
1391 /// @throws IceGrid::RegistryNotExistException Thrown when the registry doesn't exist.
1392 /// @throws IceGrid::RegistryUnreachableException Thrown when the registry is unreachable.
1393 void shutdownRegistry(std::string_view name, const Ice::Context& context = Ice::noExplicitContext) const;
1394
1395 /// Shuts down an IceGrid registry.
1396 /// @param name The registry name.
1397 /// @param context The request context.
1398 /// @return A future that becomes available when the invocation completes.
1399 [[nodiscard]] std::future<void> shutdownRegistryAsync(std::string_view name, const Ice::Context& context = Ice::noExplicitContext) const;
1400
1401 /// Shuts down an IceGrid registry.
1402 /// @param name The registry name.
1403 /// @param response The response callback.
1404 /// @param exception The exception callback.
1405 /// @param sent The sent callback.
1406 /// @param context The request context.
1407 /// @return A function that can be called to cancel the invocation locally.
1408 // NOLINTNEXTLINE(modernize-use-nodiscard)
1409 std::function<void()> shutdownRegistryAsync(std::string_view name, std::function<void()> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
1410
1411 /// @private
1412 void _iceI_shutdownRegistry(const std::shared_ptr<IceInternal::OutgoingAsyncT<void>>&, std::string_view, const Ice::Context&) const;
1413
1414 /// Gets the names of all the IceGrid registries currently registered.
1415 /// @param context The request context.
1416 /// @return The registry names.
1417 ::Ice::StringSeq getAllRegistryNames(const Ice::Context& context = Ice::noExplicitContext) const; // NOLINT(modernize-use-nodiscard)
1418
1419 /// Gets the names of all the IceGrid registries currently registered.
1420 /// @param context The request context.
1421 /// @return A future that becomes available when the invocation completes. This future holds:
1422 /// - The registry names.
1423 [[nodiscard]] std::future<::Ice::StringSeq> getAllRegistryNamesAsync(const Ice::Context& context = Ice::noExplicitContext) const;
1424
1425 /// Gets the names of all the IceGrid registries currently registered.
1426 /// @param response The response callback. It accepts:
1427 /// - The registry names.
1428 /// @param exception The exception callback.
1429 /// @param sent The sent callback.
1430 /// @param context The request context.
1431 /// @return A function that can be called to cancel the invocation locally.
1432 // NOLINTNEXTLINE(modernize-use-nodiscard)
1433 std::function<void()> getAllRegistryNamesAsync(std::function<void(::Ice::StringSeq)> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
1434
1435 /// @private
1436 void _iceI_getAllRegistryNames(const std::shared_ptr<IceInternal::OutgoingAsyncT<::Ice::StringSeq>>&, const Ice::Context&) const;
1437
1438 /// Shuts down the IceGrid registry.
1439 /// @param context The request context.
1440 void shutdown(const Ice::Context& context = Ice::noExplicitContext) const;
1441
1442 /// Shuts down the IceGrid registry.
1443 /// @param context The request context.
1444 /// @return A future that becomes available when the invocation completes.
1445 [[nodiscard]] std::future<void> shutdownAsync(const Ice::Context& context = Ice::noExplicitContext) const;
1446
1447 /// Shuts down the IceGrid registry.
1448 /// @param response The response callback.
1449 /// @param exception The exception callback.
1450 /// @param sent The sent callback.
1451 /// @param context The request context.
1452 /// @return A function that can be called to cancel the invocation locally.
1453 // NOLINTNEXTLINE(modernize-use-nodiscard)
1454 std::function<void()> shutdownAsync(std::function<void()> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
1455
1456 /// @private
1457 void _iceI_shutdown(const std::shared_ptr<IceInternal::OutgoingAsyncT<void>>&, const Ice::Context&) const;
1458
1459 /// Gets the type ID of the associated Slice interface.
1460 /// @return The string `"::IceGrid::Admin"`.
1461 static const char* ice_staticId() noexcept;
1462
1463 /// @private
1464 static AdminPrx _fromReference(IceInternal::ReferencePtr ref) { return AdminPrx{std::move(ref)}; }
1465
1466 protected:
1467 /// @private
1468 AdminPrx() = default;
1469
1470 /// @private
1471 explicit AdminPrx(IceInternal::ReferencePtr&& ref) : Ice::ObjectPrx{std::move(ref)}
1472 {
1473 }
1474 };
1475
1476 /// Iterates over an IceGrid log file.
1477 /// @headerfile IceGrid/IceGrid.h
1478 class ICEGRID_API FileIteratorPrx : public Ice::Proxy<FileIteratorPrx, Ice::ObjectPrx>
1479 {
1480 public:
1481 /// Constructs a proxy from a Communicator and a proxy string.
1482 /// @param communicator The communicator of the new proxy.
1483 /// @param proxyString The proxy string to parse.
1484 FileIteratorPrx(const Ice::CommunicatorPtr& communicator, std::string_view proxyString) : Ice::ObjectPrx{communicator, proxyString} {} // NOLINT(modernize-use-equals-default)
1485
1486 /// Copy constructor. Constructs with a copy of the contents of @p other.
1487 /// @param other The proxy to copy from.
1488 FileIteratorPrx(const FileIteratorPrx& other) noexcept : Ice::ObjectPrx{other} {} // NOLINT(modernize-use-equals-default)
1489
1490 /// Move constructor. Constructs a proxy with the contents of @p other using move semantics.
1491 /// @param other The proxy to move from.
1492 FileIteratorPrx(FileIteratorPrx&& other) noexcept : Ice::ObjectPrx{std::move(other)} {} // NOLINT(modernize-use-equals-default)
1493
1494 ~FileIteratorPrx() override;
1495
1496 /// Copy assignment operator. Replaces the contents of this proxy with a copy of the contents of @p rhs.
1497 /// @param rhs The proxy to copy from.
1498 /// @return A reference to this proxy.
1500 {
1501 if (this != &rhs)
1502 {
1504 }
1505 return *this;
1506 }
1507
1508 /// Move assignment operator. Replaces the contents of this proxy with the contents of @p rhs using move semantics.
1509 /// @param rhs The proxy to move from.
1511 {
1512 if (this != &rhs)
1513 {
1514 Ice::ObjectPrx::operator=(std::move(rhs));
1515 }
1516 return *this;
1517 }
1518
1519 /// Read lines from the log file.
1520 /// @param size Specifies the maximum number of bytes to be received. The server will ensure that the returned
1521 /// message doesn't exceed the given size.
1522 /// @param[out] lines The lines read from the file. If there was nothing to read from the file since the last call to
1523 /// read, an empty sequence is returned. The last line of the sequence is always incomplete (and therefore no
1524 /// newline character should be added when writing the last line to the to the output device).
1525 /// @param context The request context.
1526 /// @return `true` if EOF is encountered.
1527 /// @throws IceGrid::FileNotAvailableException Thrown when the implementation failed to read from the file.
1528 bool read(std::int32_t size, ::Ice::StringSeq& lines, const Ice::Context& context = Ice::noExplicitContext) const;
1529
1530 /// Read lines from the log file.
1531 /// @param size Specifies the maximum number of bytes to be received. The server will ensure that the returned
1532 /// message doesn't exceed the given size.
1533 /// @param context The request context.
1534 /// @return A future that becomes available when the invocation completes. This future holds:
1535 /// - `returnValue` `true` if EOF is encountered.
1536 /// - `lines` The lines read from the file. If there was nothing to read from the file since the last call to
1537 /// read, an empty sequence is returned. The last line of the sequence is always incomplete (and therefore no
1538 /// newline character should be added when writing the last line to the to the output device).
1539 [[nodiscard]] std::future<std::tuple<bool, ::Ice::StringSeq>> readAsync(std::int32_t size, const Ice::Context& context = Ice::noExplicitContext) const;
1540
1541 /// Read lines from the log file.
1542 /// @param size Specifies the maximum number of bytes to be received. The server will ensure that the returned
1543 /// message doesn't exceed the given size.
1544 /// @param response The response callback. It accepts:
1545 /// - `returnValue` `true` if EOF is encountered.
1546 /// - `lines` The lines read from the file. If there was nothing to read from the file since the last call to
1547 /// read, an empty sequence is returned. The last line of the sequence is always incomplete (and therefore no
1548 /// newline character should be added when writing the last line to the to the output device).
1549 /// @param exception The exception callback.
1550 /// @param sent The sent callback.
1551 /// @param context The request context.
1552 /// @return A function that can be called to cancel the invocation locally.
1553 // NOLINTNEXTLINE(modernize-use-nodiscard)
1554 std::function<void()> readAsync(std::int32_t size, std::function<void(bool, ::Ice::StringSeq)> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
1555
1556 /// @private
1557 void _iceI_read(const std::shared_ptr<IceInternal::OutgoingAsyncT<std::tuple<bool, ::Ice::StringSeq>>>&, std::int32_t, const Ice::Context&) const;
1558
1559 /// Destroys the iterator.
1560 /// @param context The request context.
1561 void destroy(const Ice::Context& context = Ice::noExplicitContext) const;
1562
1563 /// Destroys the iterator.
1564 /// @param context The request context.
1565 /// @return A future that becomes available when the invocation completes.
1566 [[nodiscard]] std::future<void> destroyAsync(const Ice::Context& context = Ice::noExplicitContext) const;
1567
1568 /// Destroys the iterator.
1569 /// @param response The response callback.
1570 /// @param exception The exception callback.
1571 /// @param sent The sent callback.
1572 /// @param context The request context.
1573 /// @return A function that can be called to cancel the invocation locally.
1574 // NOLINTNEXTLINE(modernize-use-nodiscard)
1575 std::function<void()> destroyAsync(std::function<void()> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
1576
1577 /// @private
1578 void _iceI_destroy(const std::shared_ptr<IceInternal::OutgoingAsyncT<void>>&, const Ice::Context&) const;
1579
1580 /// Gets the type ID of the associated Slice interface.
1581 /// @return The string `"::IceGrid::FileIterator"`.
1582 static const char* ice_staticId() noexcept;
1583
1584 /// @private
1585 static FileIteratorPrx _fromReference(IceInternal::ReferencePtr ref) { return FileIteratorPrx{std::move(ref)}; }
1586
1587 protected:
1588 /// @private
1589 FileIteratorPrx() = default;
1590
1591 /// @private
1592 explicit FileIteratorPrx(IceInternal::ReferencePtr&& ref) : Ice::ObjectPrx{std::move(ref)}
1593 {
1594 }
1595 };
1596
1597 /// Monitors changes to the state of the registries.
1598 /// @headerfile IceGrid/IceGrid.h
1599 class ICEGRID_API RegistryObserverPrx : public Ice::Proxy<RegistryObserverPrx, Ice::ObjectPrx>
1600 {
1601 public:
1602 /// Constructs a proxy from a Communicator and a proxy string.
1603 /// @param communicator The communicator of the new proxy.
1604 /// @param proxyString The proxy string to parse.
1605 RegistryObserverPrx(const Ice::CommunicatorPtr& communicator, std::string_view proxyString) : Ice::ObjectPrx{communicator, proxyString} {} // NOLINT(modernize-use-equals-default)
1606
1607 /// Copy constructor. Constructs with a copy of the contents of @p other.
1608 /// @param other The proxy to copy from.
1609 RegistryObserverPrx(const RegistryObserverPrx& other) noexcept : Ice::ObjectPrx{other} {} // NOLINT(modernize-use-equals-default)
1610
1611 /// Move constructor. Constructs a proxy with the contents of @p other using move semantics.
1612 /// @param other The proxy to move from.
1613 RegistryObserverPrx(RegistryObserverPrx&& other) noexcept : Ice::ObjectPrx{std::move(other)} {} // NOLINT(modernize-use-equals-default)
1614
1615 ~RegistryObserverPrx() override;
1616
1617 /// Copy assignment operator. Replaces the contents of this proxy with a copy of the contents of @p rhs.
1618 /// @param rhs The proxy to copy from.
1619 /// @return A reference to this proxy.
1621 {
1622 if (this != &rhs)
1623 {
1625 }
1626 return *this;
1627 }
1628
1629 /// Move assignment operator. Replaces the contents of this proxy with the contents of @p rhs using move semantics.
1630 /// @param rhs The proxy to move from.
1632 {
1633 if (this != &rhs)
1634 {
1635 Ice::ObjectPrx::operator=(std::move(rhs));
1636 }
1637 return *this;
1638 }
1639
1640 /// Provides the initial state of the registries to the observer.
1641 /// @param registries The current state of the registries.
1642 /// @param context The request context.
1643 void registryInit(const RegistryInfoSeq& registries, const Ice::Context& context = Ice::noExplicitContext) const;
1644
1645 /// Provides the initial state of the registries to the observer.
1646 /// @param registries The current state of the registries.
1647 /// @param context The request context.
1648 /// @return A future that becomes available when the invocation completes.
1649 [[nodiscard]] std::future<void> registryInitAsync(const RegistryInfoSeq& registries, const Ice::Context& context = Ice::noExplicitContext) const;
1650
1651 /// Provides the initial state of the registries to the observer.
1652 /// @param registries The current state of the registries.
1653 /// @param response The response callback.
1654 /// @param exception The exception callback.
1655 /// @param sent The sent callback.
1656 /// @param context The request context.
1657 /// @return A function that can be called to cancel the invocation locally.
1658 // NOLINTNEXTLINE(modernize-use-nodiscard)
1659 std::function<void()> registryInitAsync(const RegistryInfoSeq& registries, std::function<void()> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
1660
1661 /// @private
1662 void _iceI_registryInit(const std::shared_ptr<IceInternal::OutgoingAsyncT<void>>&, const RegistryInfoSeq&, const Ice::Context&) const;
1663
1664 /// Notifies the observer that a registry replica came up.
1665 /// @param registryReplica The registry state.
1666 /// @param context The request context.
1667 void registryUp(const RegistryInfo& registryReplica, const Ice::Context& context = Ice::noExplicitContext) const;
1668
1669 /// Notifies the observer that a registry replica came up.
1670 /// @param registryReplica The registry state.
1671 /// @param context The request context.
1672 /// @return A future that becomes available when the invocation completes.
1673 [[nodiscard]] std::future<void> registryUpAsync(const RegistryInfo& registryReplica, const Ice::Context& context = Ice::noExplicitContext) const;
1674
1675 /// Notifies the observer that a registry replica came up.
1676 /// @param registryReplica The registry state.
1677 /// @param response The response callback.
1678 /// @param exception The exception callback.
1679 /// @param sent The sent callback.
1680 /// @param context The request context.
1681 /// @return A function that can be called to cancel the invocation locally.
1682 // NOLINTNEXTLINE(modernize-use-nodiscard)
1683 std::function<void()> registryUpAsync(const RegistryInfo& registryReplica, std::function<void()> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
1684
1685 /// @private
1686 void _iceI_registryUp(const std::shared_ptr<IceInternal::OutgoingAsyncT<void>>&, const RegistryInfo&, const Ice::Context&) const;
1687
1688 /// Notifies the observer that a registry replica went down.
1689 /// @param name The registry name.
1690 /// @param context The request context.
1691 void registryDown(std::string_view name, const Ice::Context& context = Ice::noExplicitContext) const;
1692
1693 /// Notifies the observer that a registry replica went down.
1694 /// @param name The registry name.
1695 /// @param context The request context.
1696 /// @return A future that becomes available when the invocation completes.
1697 [[nodiscard]] std::future<void> registryDownAsync(std::string_view name, const Ice::Context& context = Ice::noExplicitContext) const;
1698
1699 /// Notifies the observer that a registry replica went down.
1700 /// @param name The registry name.
1701 /// @param response The response callback.
1702 /// @param exception The exception callback.
1703 /// @param sent The sent callback.
1704 /// @param context The request context.
1705 /// @return A function that can be called to cancel the invocation locally.
1706 // NOLINTNEXTLINE(modernize-use-nodiscard)
1707 std::function<void()> registryDownAsync(std::string_view name, std::function<void()> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
1708
1709 /// @private
1710 void _iceI_registryDown(const std::shared_ptr<IceInternal::OutgoingAsyncT<void>>&, std::string_view, const Ice::Context&) const;
1711
1712 /// Gets the type ID of the associated Slice interface.
1713 /// @return The string `"::IceGrid::RegistryObserver"`.
1714 static const char* ice_staticId() noexcept;
1715
1716 /// @private
1717 static RegistryObserverPrx _fromReference(IceInternal::ReferencePtr ref) { return RegistryObserverPrx{std::move(ref)}; }
1718
1719 protected:
1720 /// @private
1721 RegistryObserverPrx() = default;
1722
1723 /// @private
1724 explicit RegistryObserverPrx(IceInternal::ReferencePtr&& ref) : Ice::ObjectPrx{std::move(ref)}
1725 {
1726 }
1727 };
1728
1729 /// Monitors changes to the state of the nodes.
1730 /// @headerfile IceGrid/IceGrid.h
1731 class ICEGRID_API NodeObserverPrx : public Ice::Proxy<NodeObserverPrx, Ice::ObjectPrx>
1732 {
1733 public:
1734 /// Constructs a proxy from a Communicator and a proxy string.
1735 /// @param communicator The communicator of the new proxy.
1736 /// @param proxyString The proxy string to parse.
1737 NodeObserverPrx(const Ice::CommunicatorPtr& communicator, std::string_view proxyString) : Ice::ObjectPrx{communicator, proxyString} {} // NOLINT(modernize-use-equals-default)
1738
1739 /// Copy constructor. Constructs with a copy of the contents of @p other.
1740 /// @param other The proxy to copy from.
1741 NodeObserverPrx(const NodeObserverPrx& other) noexcept : Ice::ObjectPrx{other} {} // NOLINT(modernize-use-equals-default)
1742
1743 /// Move constructor. Constructs a proxy with the contents of @p other using move semantics.
1744 /// @param other The proxy to move from.
1745 NodeObserverPrx(NodeObserverPrx&& other) noexcept : Ice::ObjectPrx{std::move(other)} {} // NOLINT(modernize-use-equals-default)
1746
1747 ~NodeObserverPrx() override;
1748
1749 /// Copy assignment operator. Replaces the contents of this proxy with a copy of the contents of @p rhs.
1750 /// @param rhs The proxy to copy from.
1751 /// @return A reference to this proxy.
1753 {
1754 if (this != &rhs)
1755 {
1757 }
1758 return *this;
1759 }
1760
1761 /// Move assignment operator. Replaces the contents of this proxy with the contents of @p rhs using move semantics.
1762 /// @param rhs The proxy to move from.
1764 {
1765 if (this != &rhs)
1766 {
1767 Ice::ObjectPrx::operator=(std::move(rhs));
1768 }
1769 return *this;
1770 }
1771
1772 /// Provides the initial state of the nodes to the observer.
1773 /// @param nodes The current state of the nodes.
1774 /// @param context The request context.
1775 void nodeInit(const NodeDynamicInfoSeq& nodes, const Ice::Context& context = Ice::noExplicitContext) const;
1776
1777 /// Provides the initial state of the nodes to the observer.
1778 /// @param nodes The current state of the nodes.
1779 /// @param context The request context.
1780 /// @return A future that becomes available when the invocation completes.
1781 [[nodiscard]] std::future<void> nodeInitAsync(const NodeDynamicInfoSeq& nodes, const Ice::Context& context = Ice::noExplicitContext) const;
1782
1783 /// Provides the initial state of the nodes to the observer.
1784 /// @param nodes The current state of the nodes.
1785 /// @param response The response callback.
1786 /// @param exception The exception callback.
1787 /// @param sent The sent callback.
1788 /// @param context The request context.
1789 /// @return A function that can be called to cancel the invocation locally.
1790 // NOLINTNEXTLINE(modernize-use-nodiscard)
1791 std::function<void()> nodeInitAsync(const NodeDynamicInfoSeq& nodes, std::function<void()> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
1792
1793 /// @private
1794 void _iceI_nodeInit(const std::shared_ptr<IceInternal::OutgoingAsyncT<void>>&, const NodeDynamicInfoSeq&, const Ice::Context&) const;
1795
1796 /// Notifies the observer that a node came up.
1797 /// @param node The node state.
1798 /// @param context The request context.
1799 void nodeUp(const NodeDynamicInfo& node, const Ice::Context& context = Ice::noExplicitContext) const;
1800
1801 /// Notifies the observer that a node came up.
1802 /// @param node The node state.
1803 /// @param context The request context.
1804 /// @return A future that becomes available when the invocation completes.
1805 [[nodiscard]] std::future<void> nodeUpAsync(const NodeDynamicInfo& node, const Ice::Context& context = Ice::noExplicitContext) const;
1806
1807 /// Notifies the observer that a node came up.
1808 /// @param node The node state.
1809 /// @param response The response callback.
1810 /// @param exception The exception callback.
1811 /// @param sent The sent callback.
1812 /// @param context The request context.
1813 /// @return A function that can be called to cancel the invocation locally.
1814 // NOLINTNEXTLINE(modernize-use-nodiscard)
1815 std::function<void()> nodeUpAsync(const NodeDynamicInfo& node, std::function<void()> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
1816
1817 /// @private
1818 void _iceI_nodeUp(const std::shared_ptr<IceInternal::OutgoingAsyncT<void>>&, const NodeDynamicInfo&, const Ice::Context&) const;
1819
1820 /// Notifies the observer that a node went down.
1821 /// @param name The node name.
1822 /// @param context The request context.
1823 void nodeDown(std::string_view name, const Ice::Context& context = Ice::noExplicitContext) const;
1824
1825 /// Notifies the observer that a node went down.
1826 /// @param name The node name.
1827 /// @param context The request context.
1828 /// @return A future that becomes available when the invocation completes.
1829 [[nodiscard]] std::future<void> nodeDownAsync(std::string_view name, const Ice::Context& context = Ice::noExplicitContext) const;
1830
1831 /// Notifies the observer that a node went down.
1832 /// @param name The node name.
1833 /// @param response The response callback.
1834 /// @param exception The exception callback.
1835 /// @param sent The sent callback.
1836 /// @param context The request context.
1837 /// @return A function that can be called to cancel the invocation locally.
1838 // NOLINTNEXTLINE(modernize-use-nodiscard)
1839 std::function<void()> nodeDownAsync(std::string_view name, std::function<void()> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
1840
1841 /// @private
1842 void _iceI_nodeDown(const std::shared_ptr<IceInternal::OutgoingAsyncT<void>>&, std::string_view, const Ice::Context&) const;
1843
1844 /// Notifies the observer that the state of a server changed.
1845 /// @param node The node hosting the server.
1846 /// @param updatedInfo The new server state.
1847 /// @param context The request context.
1848 void updateServer(std::string_view node, const ServerDynamicInfo& updatedInfo, const Ice::Context& context = Ice::noExplicitContext) const;
1849
1850 /// Notifies the observer that the state of a server changed.
1851 /// @param node The node hosting the server.
1852 /// @param updatedInfo The new server state.
1853 /// @param context The request context.
1854 /// @return A future that becomes available when the invocation completes.
1855 [[nodiscard]] std::future<void> updateServerAsync(std::string_view node, const ServerDynamicInfo& updatedInfo, const Ice::Context& context = Ice::noExplicitContext) const;
1856
1857 /// Notifies the observer that the state of a server changed.
1858 /// @param node The node hosting the server.
1859 /// @param updatedInfo The new server state.
1860 /// @param response The response callback.
1861 /// @param exception The exception callback.
1862 /// @param sent The sent callback.
1863 /// @param context The request context.
1864 /// @return A function that can be called to cancel the invocation locally.
1865 // NOLINTNEXTLINE(modernize-use-nodiscard)
1866 std::function<void()> updateServerAsync(std::string_view node, const ServerDynamicInfo& updatedInfo, std::function<void()> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
1867
1868 /// @private
1869 void _iceI_updateServer(const std::shared_ptr<IceInternal::OutgoingAsyncT<void>>&, std::string_view, const ServerDynamicInfo&, const Ice::Context&) const;
1870
1871 /// Notifies the observer that the state of an object adapter changed.
1872 /// @param node The node hosting the adapter.
1873 /// @param updatedInfo The new adapter state.
1874 /// @param context The request context.
1875 void updateAdapter(std::string_view node, const AdapterDynamicInfo& updatedInfo, const Ice::Context& context = Ice::noExplicitContext) const;
1876
1877 /// Notifies the observer that the state of an object adapter changed.
1878 /// @param node The node hosting the adapter.
1879 /// @param updatedInfo The new adapter state.
1880 /// @param context The request context.
1881 /// @return A future that becomes available when the invocation completes.
1882 [[nodiscard]] std::future<void> updateAdapterAsync(std::string_view node, const AdapterDynamicInfo& updatedInfo, const Ice::Context& context = Ice::noExplicitContext) const;
1883
1884 /// Notifies the observer that the state of an object adapter changed.
1885 /// @param node The node hosting the adapter.
1886 /// @param updatedInfo The new adapter state.
1887 /// @param response The response callback.
1888 /// @param exception The exception callback.
1889 /// @param sent The sent callback.
1890 /// @param context The request context.
1891 /// @return A function that can be called to cancel the invocation locally.
1892 // NOLINTNEXTLINE(modernize-use-nodiscard)
1893 std::function<void()> updateAdapterAsync(std::string_view node, const AdapterDynamicInfo& updatedInfo, std::function<void()> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
1894
1895 /// @private
1896 void _iceI_updateAdapter(const std::shared_ptr<IceInternal::OutgoingAsyncT<void>>&, std::string_view, const AdapterDynamicInfo&, const Ice::Context&) const;
1897
1898 /// Gets the type ID of the associated Slice interface.
1899 /// @return The string `"::IceGrid::NodeObserver"`.
1900 static const char* ice_staticId() noexcept;
1901
1902 /// @private
1903 static NodeObserverPrx _fromReference(IceInternal::ReferencePtr ref) { return NodeObserverPrx{std::move(ref)}; }
1904
1905 protected:
1906 /// @private
1907 NodeObserverPrx() = default;
1908
1909 /// @private
1910 explicit NodeObserverPrx(IceInternal::ReferencePtr&& ref) : Ice::ObjectPrx{std::move(ref)}
1911 {
1912 }
1913 };
1914
1915 /// Monitors applications.
1916 /// @headerfile IceGrid/IceGrid.h
1917 class ICEGRID_API ApplicationObserverPrx : public Ice::Proxy<ApplicationObserverPrx, Ice::ObjectPrx>
1918 {
1919 public:
1920 /// Constructs a proxy from a Communicator and a proxy string.
1921 /// @param communicator The communicator of the new proxy.
1922 /// @param proxyString The proxy string to parse.
1923 ApplicationObserverPrx(const Ice::CommunicatorPtr& communicator, std::string_view proxyString) : Ice::ObjectPrx{communicator, proxyString} {} // NOLINT(modernize-use-equals-default)
1924
1925 /// Copy constructor. Constructs with a copy of the contents of @p other.
1926 /// @param other The proxy to copy from.
1927 ApplicationObserverPrx(const ApplicationObserverPrx& other) noexcept : Ice::ObjectPrx{other} {} // NOLINT(modernize-use-equals-default)
1928
1929 /// Move constructor. Constructs a proxy with the contents of @p other using move semantics.
1930 /// @param other The proxy to move from.
1931 ApplicationObserverPrx(ApplicationObserverPrx&& other) noexcept : Ice::ObjectPrx{std::move(other)} {} // NOLINT(modernize-use-equals-default)
1932
1933 ~ApplicationObserverPrx() override;
1934
1935 /// Copy assignment operator. Replaces the contents of this proxy with a copy of the contents of @p rhs.
1936 /// @param rhs The proxy to copy from.
1937 /// @return A reference to this proxy.
1939 {
1940 if (this != &rhs)
1941 {
1943 }
1944 return *this;
1945 }
1946
1947 /// Move assignment operator. Replaces the contents of this proxy with the contents of @p rhs using move semantics.
1948 /// @param rhs The proxy to move from.
1950 {
1951 if (this != &rhs)
1952 {
1953 Ice::ObjectPrx::operator=(std::move(rhs));
1954 }
1955 return *this;
1956 }
1957
1958 /// Provides the initial application infos to the observer.
1959 /// @param serial The current serial number of the registry database. This serial number allows observers to
1960 /// make sure that their internal state is synchronized with the registry.
1961 /// @param applications The applications currently registered with the registry.
1962 /// @param context The request context.
1963 void applicationInit(std::int32_t serial, const ApplicationInfoSeq& applications, const Ice::Context& context = Ice::noExplicitContext) const;
1964
1965 /// Provides the initial application infos to the observer.
1966 /// @param serial The current serial number of the registry database. This serial number allows observers to
1967 /// make sure that their internal state is synchronized with the registry.
1968 /// @param applications The applications currently registered with the registry.
1969 /// @param context The request context.
1970 /// @return A future that becomes available when the invocation completes.
1971 [[nodiscard]] std::future<void> applicationInitAsync(std::int32_t serial, const ApplicationInfoSeq& applications, const Ice::Context& context = Ice::noExplicitContext) const;
1972
1973 /// Provides the initial application infos to the observer.
1974 /// @param serial The current serial number of the registry database. This serial number allows observers to
1975 /// make sure that their internal state is synchronized with the registry.
1976 /// @param applications The applications currently registered with the registry.
1977 /// @param response The response callback.
1978 /// @param exception The exception callback.
1979 /// @param sent The sent callback.
1980 /// @param context The request context.
1981 /// @return A function that can be called to cancel the invocation locally.
1982 // NOLINTNEXTLINE(modernize-use-nodiscard)
1983 std::function<void()> applicationInitAsync(std::int32_t serial, const ApplicationInfoSeq& applications, std::function<void()> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
1984
1985 /// @private
1986 void _iceI_applicationInit(const std::shared_ptr<IceInternal::OutgoingAsyncT<void>>&, std::int32_t, const ApplicationInfoSeq&, const Ice::Context&) const;
1987
1988 /// Notifies the observer that an application was added.
1989 /// @param serial The new serial number of the registry database.
1990 /// @param desc The descriptor of the new application.
1991 /// @param context The request context.
1992 void applicationAdded(std::int32_t serial, const ApplicationInfo& desc, const Ice::Context& context = Ice::noExplicitContext) const;
1993
1994 /// Notifies the observer that an application was added.
1995 /// @param serial The new serial number of the registry database.
1996 /// @param desc The descriptor of the new application.
1997 /// @param context The request context.
1998 /// @return A future that becomes available when the invocation completes.
1999 [[nodiscard]] std::future<void> applicationAddedAsync(std::int32_t serial, const ApplicationInfo& desc, const Ice::Context& context = Ice::noExplicitContext) const;
2000
2001 /// Notifies the observer that an application was added.
2002 /// @param serial The new serial number of the registry database.
2003 /// @param desc The descriptor of the new application.
2004 /// @param response The response callback.
2005 /// @param exception The exception callback.
2006 /// @param sent The sent callback.
2007 /// @param context The request context.
2008 /// @return A function that can be called to cancel the invocation locally.
2009 // NOLINTNEXTLINE(modernize-use-nodiscard)
2010 std::function<void()> applicationAddedAsync(std::int32_t serial, const ApplicationInfo& desc, std::function<void()> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
2011
2012 /// @private
2013 void _iceI_applicationAdded(const std::shared_ptr<IceInternal::OutgoingAsyncT<void>>&, std::int32_t, const ApplicationInfo&, const Ice::Context&) const;
2014
2015 /// Notifies the observer that an application was removed.
2016 /// @param serial The new serial number of the registry database.
2017 /// @param name The name of the application that was removed.
2018 /// @param context The request context.
2019 void applicationRemoved(std::int32_t serial, std::string_view name, const Ice::Context& context = Ice::noExplicitContext) const;
2020
2021 /// Notifies the observer that an application was removed.
2022 /// @param serial The new serial number of the registry database.
2023 /// @param name The name of the application that was removed.
2024 /// @param context The request context.
2025 /// @return A future that becomes available when the invocation completes.
2026 [[nodiscard]] std::future<void> applicationRemovedAsync(std::int32_t serial, std::string_view name, const Ice::Context& context = Ice::noExplicitContext) const;
2027
2028 /// Notifies the observer that an application was removed.
2029 /// @param serial The new serial number of the registry database.
2030 /// @param name The name of the application that was removed.
2031 /// @param response The response callback.
2032 /// @param exception The exception callback.
2033 /// @param sent The sent callback.
2034 /// @param context The request context.
2035 /// @return A function that can be called to cancel the invocation locally.
2036 // NOLINTNEXTLINE(modernize-use-nodiscard)
2037 std::function<void()> applicationRemovedAsync(std::int32_t serial, std::string_view name, std::function<void()> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
2038
2039 /// @private
2040 void _iceI_applicationRemoved(const std::shared_ptr<IceInternal::OutgoingAsyncT<void>>&, std::int32_t, std::string_view, const Ice::Context&) const;
2041
2042 /// Notifies the observer that an application was updated.
2043 /// @param serial The new serial number of the registry database.
2044 /// @param desc The descriptor of the update.
2045 /// @param context The request context.
2046 void applicationUpdated(std::int32_t serial, const ApplicationUpdateInfo& desc, const Ice::Context& context = Ice::noExplicitContext) const;
2047
2048 /// Notifies the observer that an application was updated.
2049 /// @param serial The new serial number of the registry database.
2050 /// @param desc The descriptor of the update.
2051 /// @param context The request context.
2052 /// @return A future that becomes available when the invocation completes.
2053 [[nodiscard]] std::future<void> applicationUpdatedAsync(std::int32_t serial, const ApplicationUpdateInfo& desc, const Ice::Context& context = Ice::noExplicitContext) const;
2054
2055 /// Notifies the observer that an application was updated.
2056 /// @param serial The new serial number of the registry database.
2057 /// @param desc The descriptor of the update.
2058 /// @param response The response callback.
2059 /// @param exception The exception callback.
2060 /// @param sent The sent callback.
2061 /// @param context The request context.
2062 /// @return A function that can be called to cancel the invocation locally.
2063 // NOLINTNEXTLINE(modernize-use-nodiscard)
2064 std::function<void()> applicationUpdatedAsync(std::int32_t serial, const ApplicationUpdateInfo& desc, std::function<void()> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
2065
2066 /// @private
2067 void _iceI_applicationUpdated(const std::shared_ptr<IceInternal::OutgoingAsyncT<void>>&, std::int32_t, const ApplicationUpdateInfo&, const Ice::Context&) const;
2068
2069 /// Gets the type ID of the associated Slice interface.
2070 /// @return The string `"::IceGrid::ApplicationObserver"`.
2071 static const char* ice_staticId() noexcept;
2072
2073 /// @private
2074 static ApplicationObserverPrx _fromReference(IceInternal::ReferencePtr ref) { return ApplicationObserverPrx{std::move(ref)}; }
2075
2076 protected:
2077 /// @private
2078 ApplicationObserverPrx() = default;
2079
2080 /// @private
2081 explicit ApplicationObserverPrx(IceInternal::ReferencePtr&& ref) : Ice::ObjectPrx{std::move(ref)}
2082 {
2083 }
2084 };
2085
2086 /// Monitors dynamically-registered object adapters.
2087 /// @headerfile IceGrid/IceGrid.h
2088 class ICEGRID_API AdapterObserverPrx : public Ice::Proxy<AdapterObserverPrx, Ice::ObjectPrx>
2089 {
2090 public:
2091 /// Constructs a proxy from a Communicator and a proxy string.
2092 /// @param communicator The communicator of the new proxy.
2093 /// @param proxyString The proxy string to parse.
2094 AdapterObserverPrx(const Ice::CommunicatorPtr& communicator, std::string_view proxyString) : Ice::ObjectPrx{communicator, proxyString} {} // NOLINT(modernize-use-equals-default)
2095
2096 /// Copy constructor. Constructs with a copy of the contents of @p other.
2097 /// @param other The proxy to copy from.
2098 AdapterObserverPrx(const AdapterObserverPrx& other) noexcept : Ice::ObjectPrx{other} {} // NOLINT(modernize-use-equals-default)
2099
2100 /// Move constructor. Constructs a proxy with the contents of @p other using move semantics.
2101 /// @param other The proxy to move from.
2102 AdapterObserverPrx(AdapterObserverPrx&& other) noexcept : Ice::ObjectPrx{std::move(other)} {} // NOLINT(modernize-use-equals-default)
2103
2104 ~AdapterObserverPrx() override;
2105
2106 /// Copy assignment operator. Replaces the contents of this proxy with a copy of the contents of @p rhs.
2107 /// @param rhs The proxy to copy from.
2108 /// @return A reference to this proxy.
2110 {
2111 if (this != &rhs)
2112 {
2114 }
2115 return *this;
2116 }
2117
2118 /// Move assignment operator. Replaces the contents of this proxy with the contents of @p rhs using move semantics.
2119 /// @param rhs The proxy to move from.
2121 {
2122 if (this != &rhs)
2123 {
2124 Ice::ObjectPrx::operator=(std::move(rhs));
2125 }
2126 return *this;
2127 }
2128
2129 /// Provides the initial list of dynamically registered adapters to the observer.
2130 /// @param adpts The adapters that were dynamically registered with the registry.
2131 /// @param context The request context.
2132 void adapterInit(const AdapterInfoSeq& adpts, const Ice::Context& context = Ice::noExplicitContext) const;
2133
2134 /// Provides the initial list of dynamically registered adapters to the observer.
2135 /// @param adpts The adapters that were dynamically registered with the registry.
2136 /// @param context The request context.
2137 /// @return A future that becomes available when the invocation completes.
2138 [[nodiscard]] std::future<void> adapterInitAsync(const AdapterInfoSeq& adpts, const Ice::Context& context = Ice::noExplicitContext) const;
2139
2140 /// Provides the initial list of dynamically registered adapters to the observer.
2141 /// @param adpts The adapters that were dynamically registered with the registry.
2142 /// @param response The response callback.
2143 /// @param exception The exception callback.
2144 /// @param sent The sent callback.
2145 /// @param context The request context.
2146 /// @return A function that can be called to cancel the invocation locally.
2147 // NOLINTNEXTLINE(modernize-use-nodiscard)
2148 std::function<void()> adapterInitAsync(const AdapterInfoSeq& adpts, std::function<void()> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
2149
2150 /// @private
2151 void _iceI_adapterInit(const std::shared_ptr<IceInternal::OutgoingAsyncT<void>>&, const AdapterInfoSeq&, const Ice::Context&) const;
2152
2153 /// Notifies the observer that a dynamically-registered adapter was added.
2154 /// @param info The details of the new adapter.
2155 /// @param context The request context.
2156 void adapterAdded(const AdapterInfo& info, const Ice::Context& context = Ice::noExplicitContext) const;
2157
2158 /// Notifies the observer that a dynamically-registered adapter was added.
2159 /// @param info The details of the new adapter.
2160 /// @param context The request context.
2161 /// @return A future that becomes available when the invocation completes.
2162 [[nodiscard]] std::future<void> adapterAddedAsync(const AdapterInfo& info, const Ice::Context& context = Ice::noExplicitContext) const;
2163
2164 /// Notifies the observer that a dynamically-registered adapter was added.
2165 /// @param info The details of the new adapter.
2166 /// @param response The response callback.
2167 /// @param exception The exception callback.
2168 /// @param sent The sent callback.
2169 /// @param context The request context.
2170 /// @return A function that can be called to cancel the invocation locally.
2171 // NOLINTNEXTLINE(modernize-use-nodiscard)
2172 std::function<void()> adapterAddedAsync(const AdapterInfo& info, std::function<void()> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
2173
2174 /// @private
2175 void _iceI_adapterAdded(const std::shared_ptr<IceInternal::OutgoingAsyncT<void>>&, const AdapterInfo&, const Ice::Context&) const;
2176
2177 /// @param info The details of the updated adapter.
2178 /// @param context The request context.
2179 void adapterUpdated(const AdapterInfo& info, const Ice::Context& context = Ice::noExplicitContext) const;
2180
2181 /// @param info The details of the updated adapter.
2182 /// @param context The request context.
2183 /// @return A future that becomes available when the invocation completes.
2184 [[nodiscard]] std::future<void> adapterUpdatedAsync(const AdapterInfo& info, const Ice::Context& context = Ice::noExplicitContext) const;
2185
2186 /// @param info The details of the updated adapter.
2187 /// @param response The response callback.
2188 /// @param exception The exception callback.
2189 /// @param sent The sent callback.
2190 /// @param context The request context.
2191 /// @return A function that can be called to cancel the invocation locally.
2192 // NOLINTNEXTLINE(modernize-use-nodiscard)
2193 std::function<void()> adapterUpdatedAsync(const AdapterInfo& info, std::function<void()> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
2194
2195 /// @private
2196 void _iceI_adapterUpdated(const std::shared_ptr<IceInternal::OutgoingAsyncT<void>>&, const AdapterInfo&, const Ice::Context&) const;
2197
2198 /// Notifies the observer that a dynamically-registered adapter was removed.
2199 /// @param id The ID of the removed adapter.
2200 /// @param context The request context.
2201 void adapterRemoved(std::string_view id, const Ice::Context& context = Ice::noExplicitContext) const;
2202
2203 /// Notifies the observer that a dynamically-registered adapter was removed.
2204 /// @param id The ID of the removed adapter.
2205 /// @param context The request context.
2206 /// @return A future that becomes available when the invocation completes.
2207 [[nodiscard]] std::future<void> adapterRemovedAsync(std::string_view id, const Ice::Context& context = Ice::noExplicitContext) const;
2208
2209 /// Notifies the observer that a dynamically-registered adapter was removed.
2210 /// @param id The ID of the removed adapter.
2211 /// @param response The response callback.
2212 /// @param exception The exception callback.
2213 /// @param sent The sent callback.
2214 /// @param context The request context.
2215 /// @return A function that can be called to cancel the invocation locally.
2216 // NOLINTNEXTLINE(modernize-use-nodiscard)
2217 std::function<void()> adapterRemovedAsync(std::string_view id, std::function<void()> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
2218
2219 /// @private
2220 void _iceI_adapterRemoved(const std::shared_ptr<IceInternal::OutgoingAsyncT<void>>&, std::string_view, const Ice::Context&) const;
2221
2222 /// Gets the type ID of the associated Slice interface.
2223 /// @return The string `"::IceGrid::AdapterObserver"`.
2224 static const char* ice_staticId() noexcept;
2225
2226 /// @private
2227 static AdapterObserverPrx _fromReference(IceInternal::ReferencePtr ref) { return AdapterObserverPrx{std::move(ref)}; }
2228
2229 protected:
2230 /// @private
2231 AdapterObserverPrx() = default;
2232
2233 /// @private
2234 explicit AdapterObserverPrx(IceInternal::ReferencePtr&& ref) : Ice::ObjectPrx{std::move(ref)}
2235 {
2236 }
2237 };
2238
2239 /// Monitors well-known objects that are added, updated or removed using AdminPrx.
2240 /// @headerfile IceGrid/IceGrid.h
2241 class ICEGRID_API ObjectObserverPrx : public Ice::Proxy<ObjectObserverPrx, Ice::ObjectPrx>
2242 {
2243 public:
2244 /// Constructs a proxy from a Communicator and a proxy string.
2245 /// @param communicator The communicator of the new proxy.
2246 /// @param proxyString The proxy string to parse.
2247 ObjectObserverPrx(const Ice::CommunicatorPtr& communicator, std::string_view proxyString) : Ice::ObjectPrx{communicator, proxyString} {} // NOLINT(modernize-use-equals-default)
2248
2249 /// Copy constructor. Constructs with a copy of the contents of @p other.
2250 /// @param other The proxy to copy from.
2251 ObjectObserverPrx(const ObjectObserverPrx& other) noexcept : Ice::ObjectPrx{other} {} // NOLINT(modernize-use-equals-default)
2252
2253 /// Move constructor. Constructs a proxy with the contents of @p other using move semantics.
2254 /// @param other The proxy to move from.
2255 ObjectObserverPrx(ObjectObserverPrx&& other) noexcept : Ice::ObjectPrx{std::move(other)} {} // NOLINT(modernize-use-equals-default)
2256
2257 ~ObjectObserverPrx() override;
2258
2259 /// Copy assignment operator. Replaces the contents of this proxy with a copy of the contents of @p rhs.
2260 /// @param rhs The proxy to copy from.
2261 /// @return A reference to this proxy.
2263 {
2264 if (this != &rhs)
2265 {
2267 }
2268 return *this;
2269 }
2270
2271 /// Move assignment operator. Replaces the contents of this proxy with the contents of @p rhs using move semantics.
2272 /// @param rhs The proxy to move from.
2274 {
2275 if (this != &rhs)
2276 {
2277 Ice::ObjectPrx::operator=(std::move(rhs));
2278 }
2279 return *this;
2280 }
2281
2282 /// Provides the initial list of well-known objects to the observer.
2283 /// @param objects The well-known objects registered using ::IceGrid::AdminPrx.
2284 /// @param context The request context.
2285 void objectInit(const ObjectInfoSeq& objects, const Ice::Context& context = Ice::noExplicitContext) const;
2286
2287 /// Provides the initial list of well-known objects to the observer.
2288 /// @param objects The well-known objects registered using ::IceGrid::AdminPrx.
2289 /// @param context The request context.
2290 /// @return A future that becomes available when the invocation completes.
2291 [[nodiscard]] std::future<void> objectInitAsync(const ObjectInfoSeq& objects, const Ice::Context& context = Ice::noExplicitContext) const;
2292
2293 /// Provides the initial list of well-known objects to the observer.
2294 /// @param objects The well-known objects registered using ::IceGrid::AdminPrx.
2295 /// @param response The response callback.
2296 /// @param exception The exception callback.
2297 /// @param sent The sent callback.
2298 /// @param context The request context.
2299 /// @return A function that can be called to cancel the invocation locally.
2300 // NOLINTNEXTLINE(modernize-use-nodiscard)
2301 std::function<void()> objectInitAsync(const ObjectInfoSeq& objects, std::function<void()> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
2302
2303 /// @private
2304 void _iceI_objectInit(const std::shared_ptr<IceInternal::OutgoingAsyncT<void>>&, const ObjectInfoSeq&, const Ice::Context&) const;
2305
2306 /// Notifies the observer that a well-known object was added.
2307 /// @param info The details of the new object.
2308 /// @param context The request context.
2309 void objectAdded(const ObjectInfo& info, const Ice::Context& context = Ice::noExplicitContext) const;
2310
2311 /// Notifies the observer that a well-known object was added.
2312 /// @param info The details of the new object.
2313 /// @param context The request context.
2314 /// @return A future that becomes available when the invocation completes.
2315 [[nodiscard]] std::future<void> objectAddedAsync(const ObjectInfo& info, const Ice::Context& context = Ice::noExplicitContext) const;
2316
2317 /// Notifies the observer that a well-known object was added.
2318 /// @param info The details of the new object.
2319 /// @param response The response callback.
2320 /// @param exception The exception callback.
2321 /// @param sent The sent callback.
2322 /// @param context The request context.
2323 /// @return A function that can be called to cancel the invocation locally.
2324 // NOLINTNEXTLINE(modernize-use-nodiscard)
2325 std::function<void()> objectAddedAsync(const ObjectInfo& info, std::function<void()> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
2326
2327 /// @private
2328 void _iceI_objectAdded(const std::shared_ptr<IceInternal::OutgoingAsyncT<void>>&, const ObjectInfo&, const Ice::Context&) const;
2329
2330 /// Notifies the observer that a well-known object was updated.
2331 /// @param info The details of the updated object.
2332 /// @param context The request context.
2333 void objectUpdated(const ObjectInfo& info, const Ice::Context& context = Ice::noExplicitContext) const;
2334
2335 /// Notifies the observer that a well-known object was updated.
2336 /// @param info The details of the updated object.
2337 /// @param context The request context.
2338 /// @return A future that becomes available when the invocation completes.
2339 [[nodiscard]] std::future<void> objectUpdatedAsync(const ObjectInfo& info, const Ice::Context& context = Ice::noExplicitContext) const;
2340
2341 /// Notifies the observer that a well-known object was updated.
2342 /// @param info The details of the updated object.
2343 /// @param response The response callback.
2344 /// @param exception The exception callback.
2345 /// @param sent The sent callback.
2346 /// @param context The request context.
2347 /// @return A function that can be called to cancel the invocation locally.
2348 // NOLINTNEXTLINE(modernize-use-nodiscard)
2349 std::function<void()> objectUpdatedAsync(const ObjectInfo& info, std::function<void()> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
2350
2351 /// @private
2352 void _iceI_objectUpdated(const std::shared_ptr<IceInternal::OutgoingAsyncT<void>>&, const ObjectInfo&, const Ice::Context&) const;
2353
2354 /// Notifies the observer that a well-known object was removed.
2355 /// @param id The identity of the removed object.
2356 /// @param context The request context.
2357 void objectRemoved(const ::Ice::Identity& id, const Ice::Context& context = Ice::noExplicitContext) const;
2358
2359 /// Notifies the observer that a well-known object was removed.
2360 /// @param id The identity of the removed object.
2361 /// @param context The request context.
2362 /// @return A future that becomes available when the invocation completes.
2363 [[nodiscard]] std::future<void> objectRemovedAsync(const ::Ice::Identity& id, const Ice::Context& context = Ice::noExplicitContext) const;
2364
2365 /// Notifies the observer that a well-known object was removed.
2366 /// @param id The identity of the removed object.
2367 /// @param response The response callback.
2368 /// @param exception The exception callback.
2369 /// @param sent The sent callback.
2370 /// @param context The request context.
2371 /// @return A function that can be called to cancel the invocation locally.
2372 // NOLINTNEXTLINE(modernize-use-nodiscard)
2373 std::function<void()> objectRemovedAsync(const ::Ice::Identity& id, std::function<void()> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
2374
2375 /// @private
2376 void _iceI_objectRemoved(const std::shared_ptr<IceInternal::OutgoingAsyncT<void>>&, const ::Ice::Identity&, const Ice::Context&) const;
2377
2378 /// Gets the type ID of the associated Slice interface.
2379 /// @return The string `"::IceGrid::ObjectObserver"`.
2380 static const char* ice_staticId() noexcept;
2381
2382 /// @private
2383 static ObjectObserverPrx _fromReference(IceInternal::ReferencePtr ref) { return ObjectObserverPrx{std::move(ref)}; }
2384
2385 protected:
2386 /// @private
2387 ObjectObserverPrx() = default;
2388
2389 /// @private
2390 explicit ObjectObserverPrx(IceInternal::ReferencePtr&& ref) : Ice::ObjectPrx{std::move(ref)}
2391 {
2392 }
2393 };
2394
2395 /// Represents an administrative session between an admin tool and an IceGrid registry.
2396 /// @see Registry
2397 /// @headerfile IceGrid/IceGrid.h
2398 class ICEGRID_API AdminSessionPrx : public Ice::Proxy<AdminSessionPrx, ::Glacier2::SessionPrx>
2399 {
2400 public:
2401#if defined(__GNUC__) && !defined(__clang__)
2402# pragma GCC diagnostic push
2403# pragma GCC diagnostic ignored "-Wextra" // initialize all virtual bases in correct order
2404#endif
2405
2406 /// Constructs a proxy from a Communicator and a proxy string.
2407 /// @param communicator The communicator of the new proxy.
2408 /// @param proxyString The proxy string to parse.
2409 AdminSessionPrx(const Ice::CommunicatorPtr& communicator, std::string_view proxyString) : Ice::ObjectPrx{communicator, proxyString} {} // NOLINT(modernize-use-equals-default)
2410
2411 /// Copy constructor. Constructs with a copy of the contents of @p other.
2412 /// @param other The proxy to copy from.
2413 AdminSessionPrx(const AdminSessionPrx& other) noexcept : Ice::ObjectPrx{other} {} // NOLINT(modernize-use-equals-default)
2414
2415 /// Move constructor. Constructs a proxy with the contents of @p other using move semantics.
2416 /// @param other The proxy to move from.
2417 AdminSessionPrx(AdminSessionPrx&& other) noexcept : Ice::ObjectPrx{std::move(other)} {} // NOLINT(modernize-use-equals-default)
2418
2419 ~AdminSessionPrx() override;
2420
2421 /// Copy assignment operator. Replaces the contents of this proxy with a copy of the contents of @p rhs.
2422 /// @param rhs The proxy to copy from.
2423 /// @return A reference to this proxy.
2425 {
2426 if (this != &rhs)
2427 {
2429 }
2430 return *this;
2431 }
2432
2433 /// Move assignment operator. Replaces the contents of this proxy with the contents of @p rhs using move semantics.
2434 /// @param rhs The proxy to move from.
2436 {
2437 if (this != &rhs)
2438 {
2439 Ice::ObjectPrx::operator=(std::move(rhs));
2440 }
2441 return *this;
2442 }
2443
2444 /// Keeps the session alive.
2445 /// @param context The request context.
2446 [[deprecated("As of Ice 3.8, there is no need to call this operation, and its implementation does nothing.")]] void keepAlive(const Ice::Context& context = Ice::noExplicitContext) const;
2447
2448 /// Keeps the session alive.
2449 /// @param context The request context.
2450 /// @return A future that becomes available when the invocation completes.
2451 [[deprecated("As of Ice 3.8, there is no need to call this operation, and its implementation does nothing.")]] [[nodiscard]] std::future<void> keepAliveAsync(const Ice::Context& context = Ice::noExplicitContext) const;
2452
2453 /// Keeps the session alive.
2454 /// @param response The response callback.
2455 /// @param exception The exception callback.
2456 /// @param sent The sent callback.
2457 /// @param context The request context.
2458 /// @return A function that can be called to cancel the invocation locally.
2459 // NOLINTNEXTLINE(modernize-use-nodiscard)
2460 [[deprecated("As of Ice 3.8, there is no need to call this operation, and its implementation does nothing.")]] std::function<void()> keepAliveAsync(std::function<void()> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
2461
2462 /// @private
2463 void _iceI_keepAlive(const std::shared_ptr<IceInternal::OutgoingAsyncT<void>>&, const Ice::Context&) const;
2464
2465 /// Gets a proxy to the IceGrid admin object. The admin object returned by this operation can only be accessed
2466 /// by the session.
2467 /// @param context The request context.
2468 /// @return A proxy to the IceGrid admin object. This proxy is never null.
2469 std::optional<AdminPrx> getAdmin(const Ice::Context& context = Ice::noExplicitContext) const; // NOLINT(modernize-use-nodiscard)
2470
2471 /// Gets a proxy to the IceGrid admin object. The admin object returned by this operation can only be accessed
2472 /// by the session.
2473 /// @param context The request context.
2474 /// @return A future that becomes available when the invocation completes. This future holds:
2475 /// - A proxy to the IceGrid admin object. This proxy is never null.
2476 [[nodiscard]] std::future<std::optional<AdminPrx>> getAdminAsync(const Ice::Context& context = Ice::noExplicitContext) const;
2477
2478 /// Gets a proxy to the IceGrid admin object. The admin object returned by this operation can only be accessed
2479 /// by the session.
2480 /// @param response The response callback. It accepts:
2481 /// - A proxy to the IceGrid admin object. This proxy is never null.
2482 /// @param exception The exception callback.
2483 /// @param sent The sent callback.
2484 /// @param context The request context.
2485 /// @return A function that can be called to cancel the invocation locally.
2486 // NOLINTNEXTLINE(modernize-use-nodiscard)
2487 std::function<void()> getAdminAsync(std::function<void(std::optional<::IceGrid::AdminPrx>)> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
2488
2489 /// @private
2490 void _iceI_getAdmin(const std::shared_ptr<IceInternal::OutgoingAsyncT<std::optional<AdminPrx>>>&, const Ice::Context&) const;
2491
2492 /// Gets a "template" proxy for admin callback objects. An Admin client uses this proxy to set the category of
2493 /// its callback objects, and the published endpoints of the object adapter hosting the admin callback objects.
2494 /// @param context The request context.
2495 /// @return A template proxy. The returned proxy is null when the Admin session was established using Glacier2.
2496 std::optional<Ice::ObjectPrx> getAdminCallbackTemplate(const Ice::Context& context = Ice::noExplicitContext) const; // NOLINT(modernize-use-nodiscard)
2497
2498 /// Gets a "template" proxy for admin callback objects. An Admin client uses this proxy to set the category of
2499 /// its callback objects, and the published endpoints of the object adapter hosting the admin callback objects.
2500 /// @param context The request context.
2501 /// @return A future that becomes available when the invocation completes. This future holds:
2502 /// - A template proxy. The returned proxy is null when the Admin session was established using Glacier2.
2503 [[nodiscard]] std::future<std::optional<Ice::ObjectPrx>> getAdminCallbackTemplateAsync(const Ice::Context& context = Ice::noExplicitContext) const;
2504
2505 /// Gets a "template" proxy for admin callback objects. An Admin client uses this proxy to set the category of
2506 /// its callback objects, and the published endpoints of the object adapter hosting the admin callback objects.
2507 /// @param response The response callback. It accepts:
2508 /// - A template proxy. The returned proxy is null when the Admin session was established using Glacier2.
2509 /// @param exception The exception callback.
2510 /// @param sent The sent callback.
2511 /// @param context The request context.
2512 /// @return A function that can be called to cancel the invocation locally.
2513 // NOLINTNEXTLINE(modernize-use-nodiscard)
2514 std::function<void()> getAdminCallbackTemplateAsync(std::function<void(std::optional<Ice::ObjectPrx>)> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
2515
2516 /// @private
2517 void _iceI_getAdminCallbackTemplate(const std::shared_ptr<IceInternal::OutgoingAsyncT<std::optional<Ice::ObjectPrx>>>&, const Ice::Context&) const;
2518
2519 /// Sets the observer proxies that receive notifications when the state of the registry or nodes changes.
2520 /// @param registryObs The registry observer.
2521 /// @param nodeObs The node observer.
2522 /// @param appObs The application observer.
2523 /// @param adptObs The adapter observer.
2524 /// @param objObs The object observer.
2525 /// @param context The request context.
2526 /// @throws IceGrid::ObserverAlreadyRegisteredException Thrown when an observer is already registered with this registry.
2527 void setObservers(const std::optional<RegistryObserverPrx>& registryObs, const std::optional<NodeObserverPrx>& nodeObs, const std::optional<ApplicationObserverPrx>& appObs, const std::optional<AdapterObserverPrx>& adptObs, const std::optional<ObjectObserverPrx>& objObs, const Ice::Context& context = Ice::noExplicitContext) const;
2528
2529 /// Sets the observer proxies that receive notifications when the state of the registry or nodes changes.
2530 /// @param registryObs The registry observer.
2531 /// @param nodeObs The node observer.
2532 /// @param appObs The application observer.
2533 /// @param adptObs The adapter observer.
2534 /// @param objObs The object observer.
2535 /// @param context The request context.
2536 /// @return A future that becomes available when the invocation completes.
2537 [[nodiscard]] std::future<void> setObserversAsync(const std::optional<RegistryObserverPrx>& registryObs, const std::optional<NodeObserverPrx>& nodeObs, const std::optional<ApplicationObserverPrx>& appObs, const std::optional<AdapterObserverPrx>& adptObs, const std::optional<ObjectObserverPrx>& objObs, const Ice::Context& context = Ice::noExplicitContext) const;
2538
2539 /// Sets the observer proxies that receive notifications when the state of the registry or nodes changes.
2540 /// @param registryObs The registry observer.
2541 /// @param nodeObs The node observer.
2542 /// @param appObs The application observer.
2543 /// @param adptObs The adapter observer.
2544 /// @param objObs The object observer.
2545 /// @param response The response callback.
2546 /// @param exception The exception callback.
2547 /// @param sent The sent callback.
2548 /// @param context The request context.
2549 /// @return A function that can be called to cancel the invocation locally.
2550 // NOLINTNEXTLINE(modernize-use-nodiscard)
2551 std::function<void()> setObserversAsync(const std::optional<RegistryObserverPrx>& registryObs, const std::optional<NodeObserverPrx>& nodeObs, const std::optional<ApplicationObserverPrx>& appObs, const std::optional<AdapterObserverPrx>& adptObs, const std::optional<ObjectObserverPrx>& objObs, std::function<void()> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
2552
2553 /// @private
2554 void _iceI_setObservers(const std::shared_ptr<IceInternal::OutgoingAsyncT<void>>&, const std::optional<RegistryObserverPrx>&, const std::optional<NodeObserverPrx>&, const std::optional<ApplicationObserverPrx>&, const std::optional<AdapterObserverPrx>&, const std::optional<ObjectObserverPrx>&, const Ice::Context&) const;
2555
2556 /// Sets the observer identities that receive notifications when the state of the registry or nodes changes.
2557 /// This operation should be used by clients that are using a bidirectional connection to communicate with the
2558 /// session.
2559 /// @param registryObs The registry observer identity.
2560 /// @param nodeObs The node observer identity.
2561 /// @param appObs The application observer.
2562 /// @param adptObs The adapter observer.
2563 /// @param objObs The object observer.
2564 /// @param context The request context.
2565 /// @throws IceGrid::ObserverAlreadyRegisteredException Thrown when an observer is already registered with this registry.
2566 void setObserversByIdentity(const ::Ice::Identity& registryObs, const ::Ice::Identity& nodeObs, const ::Ice::Identity& appObs, const ::Ice::Identity& adptObs, const ::Ice::Identity& objObs, const Ice::Context& context = Ice::noExplicitContext) const;
2567
2568 /// Sets the observer identities that receive notifications when the state of the registry or nodes changes.
2569 /// This operation should be used by clients that are using a bidirectional connection to communicate with the
2570 /// session.
2571 /// @param registryObs The registry observer identity.
2572 /// @param nodeObs The node observer identity.
2573 /// @param appObs The application observer.
2574 /// @param adptObs The adapter observer.
2575 /// @param objObs The object observer.
2576 /// @param context The request context.
2577 /// @return A future that becomes available when the invocation completes.
2578 [[nodiscard]] std::future<void> setObserversByIdentityAsync(const ::Ice::Identity& registryObs, const ::Ice::Identity& nodeObs, const ::Ice::Identity& appObs, const ::Ice::Identity& adptObs, const ::Ice::Identity& objObs, const Ice::Context& context = Ice::noExplicitContext) const;
2579
2580 /// Sets the observer identities that receive notifications when the state of the registry or nodes changes.
2581 /// This operation should be used by clients that are using a bidirectional connection to communicate with the
2582 /// session.
2583 /// @param registryObs The registry observer identity.
2584 /// @param nodeObs The node observer identity.
2585 /// @param appObs The application observer.
2586 /// @param adptObs The adapter observer.
2587 /// @param objObs The object observer.
2588 /// @param response The response callback.
2589 /// @param exception The exception callback.
2590 /// @param sent The sent callback.
2591 /// @param context The request context.
2592 /// @return A function that can be called to cancel the invocation locally.
2593 // NOLINTNEXTLINE(modernize-use-nodiscard)
2594 std::function<void()> setObserversByIdentityAsync(const ::Ice::Identity& registryObs, const ::Ice::Identity& nodeObs, const ::Ice::Identity& appObs, const ::Ice::Identity& adptObs, const ::Ice::Identity& objObs, std::function<void()> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
2595
2596 /// @private
2597 void _iceI_setObserversByIdentity(const std::shared_ptr<IceInternal::OutgoingAsyncT<void>>&, const ::Ice::Identity&, const ::Ice::Identity&, const ::Ice::Identity&, const ::Ice::Identity&, const ::Ice::Identity&, const Ice::Context&) const;
2598
2599 /// Acquires an exclusive lock to start updating the registry applications.
2600 /// @param context The request context.
2601 /// @return The current serial.
2602 /// @throws IceGrid::AccessDeniedException Thrown when the exclusive lock can't be acquired. This might happen if the
2603 /// lock is currently acquired by another session.
2604 std::int32_t startUpdate(const Ice::Context& context = Ice::noExplicitContext) const; // NOLINT(modernize-use-nodiscard)
2605
2606 /// Acquires an exclusive lock to start updating the registry applications.
2607 /// @param context The request context.
2608 /// @return A future that becomes available when the invocation completes. This future holds:
2609 /// - The current serial.
2610 [[nodiscard]] std::future<std::int32_t> startUpdateAsync(const Ice::Context& context = Ice::noExplicitContext) const;
2611
2612 /// Acquires an exclusive lock to start updating the registry applications.
2613 /// @param response The response callback. It accepts:
2614 /// - The current serial.
2615 /// @param exception The exception callback.
2616 /// @param sent The sent callback.
2617 /// @param context The request context.
2618 /// @return A function that can be called to cancel the invocation locally.
2619 // NOLINTNEXTLINE(modernize-use-nodiscard)
2620 std::function<void()> startUpdateAsync(std::function<void(std::int32_t)> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
2621
2622 /// @private
2623 void _iceI_startUpdate(const std::shared_ptr<IceInternal::OutgoingAsyncT<std::int32_t>>&, const Ice::Context&) const;
2624
2625 /// Finishes updating the registry and releases the exclusive lock.
2626 /// @param context The request context.
2627 /// @throws IceGrid::AccessDeniedException Thrown when the session doesn't hold the exclusive lock.
2629
2630 /// Finishes updating the registry and releases the exclusive lock.
2631 /// @param context The request context.
2632 /// @return A future that becomes available when the invocation completes.
2633 [[nodiscard]] std::future<void> finishUpdateAsync(const Ice::Context& context = Ice::noExplicitContext) const;
2634
2635 /// Finishes updating the registry and releases the exclusive lock.
2636 /// @param response The response callback.
2637 /// @param exception The exception callback.
2638 /// @param sent The sent callback.
2639 /// @param context The request context.
2640 /// @return A function that can be called to cancel the invocation locally.
2641 // NOLINTNEXTLINE(modernize-use-nodiscard)
2642 std::function<void()> finishUpdateAsync(std::function<void()> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
2643
2644 /// @private
2645 void _iceI_finishUpdate(const std::shared_ptr<IceInternal::OutgoingAsyncT<void>>&, const Ice::Context&) const;
2646
2647 /// Gets the name of the registry replica hosting this session.
2648 /// @param context The request context.
2649 /// @return The replica name of the registry.
2650 std::string getReplicaName(const Ice::Context& context = Ice::noExplicitContext) const; // NOLINT(modernize-use-nodiscard)
2651
2652 /// Gets the name of the registry replica hosting this session.
2653 /// @param context The request context.
2654 /// @return A future that becomes available when the invocation completes. This future holds:
2655 /// - The replica name of the registry.
2656 [[nodiscard]] std::future<std::string> getReplicaNameAsync(const Ice::Context& context = Ice::noExplicitContext) const;
2657
2658 /// Gets the name of the registry replica hosting this session.
2659 /// @param response The response callback. It accepts:
2660 /// - The replica name of the registry.
2661 /// @param exception The exception callback.
2662 /// @param sent The sent callback.
2663 /// @param context The request context.
2664 /// @return A function that can be called to cancel the invocation locally.
2665 // NOLINTNEXTLINE(modernize-use-nodiscard)
2666 std::function<void()> getReplicaNameAsync(std::function<void(std::string)> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
2667
2668 /// @private
2669 void _iceI_getReplicaName(const std::shared_ptr<IceInternal::OutgoingAsyncT<std::string>>&, const Ice::Context&) const;
2670
2671 /// Opens a server log file for reading.
2672 /// @param id The server ID.
2673 /// @param path The path of the log file. A log file can be opened only if it's declared in the server or
2674 /// service deployment descriptor.
2675 /// @param count Specifies where to start reading the file. If negative, the file is read from the beginning.
2676 /// Otherwise, the file is read from the last @p count lines.
2677 /// @param context The request context.
2678 /// @return An iterator to read the file. This proxy is never null.
2679 /// @throws IceGrid::DeploymentException Thrown when the server couldn't be deployed on the node.
2680 /// @throws IceGrid::FileNotAvailableException Thrown when the file can't be read.
2681 /// @throws IceGrid::NodeUnreachableException Thrown when the node is unreachable.
2682 /// @throws IceGrid::ServerNotExistException Thrown when the server doesn't exist.
2683 std::optional<FileIteratorPrx> openServerLog(std::string_view id, std::string_view path, std::int32_t count, const Ice::Context& context = Ice::noExplicitContext) const; // NOLINT(modernize-use-nodiscard)
2684
2685 /// Opens a server log file for reading.
2686 /// @param id The server ID.
2687 /// @param path The path of the log file. A log file can be opened only if it's declared in the server or
2688 /// service deployment descriptor.
2689 /// @param count Specifies where to start reading the file. If negative, the file is read from the beginning.
2690 /// Otherwise, the file is read from the last @p count lines.
2691 /// @param context The request context.
2692 /// @return A future that becomes available when the invocation completes. This future holds:
2693 /// - An iterator to read the file. This proxy is never null.
2694 [[nodiscard]] std::future<std::optional<FileIteratorPrx>> openServerLogAsync(std::string_view id, std::string_view path, std::int32_t count, const Ice::Context& context = Ice::noExplicitContext) const;
2695
2696 /// Opens a server log file for reading.
2697 /// @param id The server ID.
2698 /// @param path The path of the log file. A log file can be opened only if it's declared in the server or
2699 /// service deployment descriptor.
2700 /// @param count Specifies where to start reading the file. If negative, the file is read from the beginning.
2701 /// Otherwise, the file is read from the last @p count lines.
2702 /// @param response The response callback. It accepts:
2703 /// - An iterator to read the file. This proxy is never null.
2704 /// @param exception The exception callback.
2705 /// @param sent The sent callback.
2706 /// @param context The request context.
2707 /// @return A function that can be called to cancel the invocation locally.
2708 // NOLINTNEXTLINE(modernize-use-nodiscard)
2709 std::function<void()> openServerLogAsync(std::string_view id, std::string_view path, std::int32_t count, std::function<void(std::optional<::IceGrid::FileIteratorPrx>)> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
2710
2711 /// @private
2712 void _iceI_openServerLog(const std::shared_ptr<IceInternal::OutgoingAsyncT<std::optional<FileIteratorPrx>>>&, std::string_view, std::string_view, std::int32_t, const Ice::Context&) const;
2713
2714 /// Opens a server stderr file for reading.
2715 /// @param id The server ID.
2716 /// @param count Specifies where to start reading the file. If negative, the file is read from the beginning.
2717 /// Otherwise, the file is read from the last @p count lines.
2718 /// @param context The request context.
2719 /// @return An iterator to read the file. This proxy is never null.
2720 /// @throws IceGrid::DeploymentException Thrown when the server couldn't be deployed on the node.
2721 /// @throws IceGrid::FileNotAvailableException Thrown when the file can't be read.
2722 /// @throws IceGrid::NodeUnreachableException Thrown when the node is unreachable.
2723 /// @throws IceGrid::ServerNotExistException Thrown when the server doesn't exist.
2724 std::optional<FileIteratorPrx> openServerStdErr(std::string_view id, std::int32_t count, const Ice::Context& context = Ice::noExplicitContext) const; // NOLINT(modernize-use-nodiscard)
2725
2726 /// Opens a server stderr file for reading.
2727 /// @param id The server ID.
2728 /// @param count Specifies where to start reading the file. If negative, the file is read from the beginning.
2729 /// Otherwise, the file is read from the last @p count lines.
2730 /// @param context The request context.
2731 /// @return A future that becomes available when the invocation completes. This future holds:
2732 /// - An iterator to read the file. This proxy is never null.
2733 [[nodiscard]] std::future<std::optional<FileIteratorPrx>> openServerStdErrAsync(std::string_view id, std::int32_t count, const Ice::Context& context = Ice::noExplicitContext) const;
2734
2735 /// Opens a server stderr file for reading.
2736 /// @param id The server ID.
2737 /// @param count Specifies where to start reading the file. If negative, the file is read from the beginning.
2738 /// Otherwise, the file is read from the last @p count lines.
2739 /// @param response The response callback. It accepts:
2740 /// - An iterator to read the file. This proxy is never null.
2741 /// @param exception The exception callback.
2742 /// @param sent The sent callback.
2743 /// @param context The request context.
2744 /// @return A function that can be called to cancel the invocation locally.
2745 // NOLINTNEXTLINE(modernize-use-nodiscard)
2746 std::function<void()> openServerStdErrAsync(std::string_view id, std::int32_t count, std::function<void(std::optional<::IceGrid::FileIteratorPrx>)> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
2747
2748 /// @private
2749 void _iceI_openServerStdErr(const std::shared_ptr<IceInternal::OutgoingAsyncT<std::optional<FileIteratorPrx>>>&, std::string_view, std::int32_t, const Ice::Context&) const;
2750
2751 /// Opens a server stdout file for reading.
2752 /// @param id The server id.
2753 /// @param count Specifies where to start reading the file. If negative, the file is read from the beginning.
2754 /// Otherwise, the file is read from the last @p count lines.
2755 /// @param context The request context.
2756 /// @return An iterator to read the file. This proxy is never null.
2757 /// @throws IceGrid::DeploymentException Thrown when the server couldn't be deployed on the node.
2758 /// @throws IceGrid::FileNotAvailableException Thrown when the file can't be read.
2759 /// @throws IceGrid::NodeUnreachableException Thrown when the node is unreachable.
2760 /// @throws IceGrid::ServerNotExistException Thrown when the server doesn't exist.
2761 std::optional<FileIteratorPrx> openServerStdOut(std::string_view id, std::int32_t count, const Ice::Context& context = Ice::noExplicitContext) const; // NOLINT(modernize-use-nodiscard)
2762
2763 /// Opens a server stdout file for reading.
2764 /// @param id The server id.
2765 /// @param count Specifies where to start reading the file. If negative, the file is read from the beginning.
2766 /// Otherwise, the file is read from the last @p count lines.
2767 /// @param context The request context.
2768 /// @return A future that becomes available when the invocation completes. This future holds:
2769 /// - An iterator to read the file. This proxy is never null.
2770 [[nodiscard]] std::future<std::optional<FileIteratorPrx>> openServerStdOutAsync(std::string_view id, std::int32_t count, const Ice::Context& context = Ice::noExplicitContext) const;
2771
2772 /// Opens a server stdout file for reading.
2773 /// @param id The server id.
2774 /// @param count Specifies where to start reading the file. If negative, the file is read from the beginning.
2775 /// Otherwise, the file is read from the last @p count lines.
2776 /// @param response The response callback. It accepts:
2777 /// - An iterator to read the file. This proxy is never null.
2778 /// @param exception The exception callback.
2779 /// @param sent The sent callback.
2780 /// @param context The request context.
2781 /// @return A function that can be called to cancel the invocation locally.
2782 // NOLINTNEXTLINE(modernize-use-nodiscard)
2783 std::function<void()> openServerStdOutAsync(std::string_view id, std::int32_t count, std::function<void(std::optional<::IceGrid::FileIteratorPrx>)> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
2784
2785 /// @private
2786 void _iceI_openServerStdOut(const std::shared_ptr<IceInternal::OutgoingAsyncT<std::optional<FileIteratorPrx>>>&, std::string_view, std::int32_t, const Ice::Context&) const;
2787
2788 /// Opens a node stderr file for reading.
2789 /// @param name The node name.
2790 /// @param count Specifies where to start reading the file. If negative, the file is read from the beginning.
2791 /// Otherwise, the file is read from the last @p count lines.
2792 /// @param context The request context.
2793 /// @return An iterator to read the file. This proxy is never null.
2794 /// @throws IceGrid::FileNotAvailableException Thrown when the file can't be read.
2795 /// @throws IceGrid::NodeNotExistException Thrown when the node doesn't exist.
2796 /// @throws IceGrid::NodeUnreachableException Thrown when the node is unreachable.
2797 std::optional<FileIteratorPrx> openNodeStdErr(std::string_view name, std::int32_t count, const Ice::Context& context = Ice::noExplicitContext) const; // NOLINT(modernize-use-nodiscard)
2798
2799 /// Opens a node stderr file for reading.
2800 /// @param name The node name.
2801 /// @param count Specifies where to start reading the file. If negative, the file is read from the beginning.
2802 /// Otherwise, the file is read from the last @p count lines.
2803 /// @param context The request context.
2804 /// @return A future that becomes available when the invocation completes. This future holds:
2805 /// - An iterator to read the file. This proxy is never null.
2806 [[nodiscard]] std::future<std::optional<FileIteratorPrx>> openNodeStdErrAsync(std::string_view name, std::int32_t count, const Ice::Context& context = Ice::noExplicitContext) const;
2807
2808 /// Opens a node stderr file for reading.
2809 /// @param name The node name.
2810 /// @param count Specifies where to start reading the file. If negative, the file is read from the beginning.
2811 /// Otherwise, the file is read from the last @p count lines.
2812 /// @param response The response callback. It accepts:
2813 /// - An iterator to read the file. This proxy is never null.
2814 /// @param exception The exception callback.
2815 /// @param sent The sent callback.
2816 /// @param context The request context.
2817 /// @return A function that can be called to cancel the invocation locally.
2818 // NOLINTNEXTLINE(modernize-use-nodiscard)
2819 std::function<void()> openNodeStdErrAsync(std::string_view name, std::int32_t count, std::function<void(std::optional<::IceGrid::FileIteratorPrx>)> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
2820
2821 /// @private
2822 void _iceI_openNodeStdErr(const std::shared_ptr<IceInternal::OutgoingAsyncT<std::optional<FileIteratorPrx>>>&, std::string_view, std::int32_t, const Ice::Context&) const;
2823
2824 /// Opens a node stdout file for reading.
2825 /// @param name The node name.
2826 /// @param count Specifies where to start reading the file. If negative, the file is read from the beginning.
2827 /// Otherwise, the file is read from the last @p count lines.
2828 /// @param context The request context.
2829 /// @return An iterator to read the file. This proxy is never null.
2830 /// @throws IceGrid::FileNotAvailableException Thrown when the file can't be read.
2831 /// @throws IceGrid::NodeNotExistException Thrown when the node doesn't exist.
2832 /// @throws IceGrid::NodeUnreachableException Thrown when the node is unreachable.
2833 std::optional<FileIteratorPrx> openNodeStdOut(std::string_view name, std::int32_t count, const Ice::Context& context = Ice::noExplicitContext) const; // NOLINT(modernize-use-nodiscard)
2834
2835 /// Opens a node stdout file for reading.
2836 /// @param name The node name.
2837 /// @param count Specifies where to start reading the file. If negative, the file is read from the beginning.
2838 /// Otherwise, the file is read from the last @p count lines.
2839 /// @param context The request context.
2840 /// @return A future that becomes available when the invocation completes. This future holds:
2841 /// - An iterator to read the file. This proxy is never null.
2842 [[nodiscard]] std::future<std::optional<FileIteratorPrx>> openNodeStdOutAsync(std::string_view name, std::int32_t count, const Ice::Context& context = Ice::noExplicitContext) const;
2843
2844 /// Opens a node stdout file for reading.
2845 /// @param name The node name.
2846 /// @param count Specifies where to start reading the file. If negative, the file is read from the beginning.
2847 /// Otherwise, the file is read from the last @p count lines.
2848 /// @param response The response callback. It accepts:
2849 /// - An iterator to read the file. This proxy is never null.
2850 /// @param exception The exception callback.
2851 /// @param sent The sent callback.
2852 /// @param context The request context.
2853 /// @return A function that can be called to cancel the invocation locally.
2854 // NOLINTNEXTLINE(modernize-use-nodiscard)
2855 std::function<void()> openNodeStdOutAsync(std::string_view name, std::int32_t count, std::function<void(std::optional<::IceGrid::FileIteratorPrx>)> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
2856
2857 /// @private
2858 void _iceI_openNodeStdOut(const std::shared_ptr<IceInternal::OutgoingAsyncT<std::optional<FileIteratorPrx>>>&, std::string_view, std::int32_t, const Ice::Context&) const;
2859
2860 /// Opens a registry stderr file for reading.
2861 /// @param name The registry name.
2862 /// @param count Specifies where to start reading the file. If negative, the file is read from the beginning.
2863 /// Otherwise, the file is read from the last @p count lines.
2864 /// @param context The request context.
2865 /// @return An iterator to read the file. This proxy is never null.
2866 /// @throws IceGrid::FileNotAvailableException Thrown when the file can't be read.
2867 /// @throws IceGrid::RegistryNotExistException Thrown when the registry doesn't exist.
2868 /// @throws IceGrid::RegistryUnreachableException Thrown when the registry is unreachable.
2869 std::optional<FileIteratorPrx> openRegistryStdErr(std::string_view name, std::int32_t count, const Ice::Context& context = Ice::noExplicitContext) const; // NOLINT(modernize-use-nodiscard)
2870
2871 /// Opens a registry stderr file for reading.
2872 /// @param name The registry name.
2873 /// @param count Specifies where to start reading the file. If negative, the file is read from the beginning.
2874 /// Otherwise, the file is read from the last @p count lines.
2875 /// @param context The request context.
2876 /// @return A future that becomes available when the invocation completes. This future holds:
2877 /// - An iterator to read the file. This proxy is never null.
2878 [[nodiscard]] std::future<std::optional<FileIteratorPrx>> openRegistryStdErrAsync(std::string_view name, std::int32_t count, const Ice::Context& context = Ice::noExplicitContext) const;
2879
2880 /// Opens a registry stderr file for reading.
2881 /// @param name The registry name.
2882 /// @param count Specifies where to start reading the file. If negative, the file is read from the beginning.
2883 /// Otherwise, the file is read from the last @p count lines.
2884 /// @param response The response callback. It accepts:
2885 /// - An iterator to read the file. This proxy is never null.
2886 /// @param exception The exception callback.
2887 /// @param sent The sent callback.
2888 /// @param context The request context.
2889 /// @return A function that can be called to cancel the invocation locally.
2890 // NOLINTNEXTLINE(modernize-use-nodiscard)
2891 std::function<void()> openRegistryStdErrAsync(std::string_view name, std::int32_t count, std::function<void(std::optional<::IceGrid::FileIteratorPrx>)> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
2892
2893 /// @private
2894 void _iceI_openRegistryStdErr(const std::shared_ptr<IceInternal::OutgoingAsyncT<std::optional<FileIteratorPrx>>>&, std::string_view, std::int32_t, const Ice::Context&) const;
2895
2896 /// Opens a registry stdout file for reading.
2897 /// @param name The registry name.
2898 /// @param count Specifies where to start reading the file. If negative, the file is read from the beginning.
2899 /// Otherwise, the file is read from the last @p count lines.
2900 /// @param context The request context.
2901 /// @return An iterator to read the file. This proxy is never null.
2902 /// @throws IceGrid::FileNotAvailableException Thrown when the file can't be read.
2903 /// @throws IceGrid::RegistryNotExistException Thrown when the registry doesn't exist.
2904 /// @throws IceGrid::RegistryUnreachableException Thrown when the registry is unreachable.
2905 std::optional<FileIteratorPrx> openRegistryStdOut(std::string_view name, std::int32_t count, const Ice::Context& context = Ice::noExplicitContext) const; // NOLINT(modernize-use-nodiscard)
2906
2907 /// Opens a registry stdout file for reading.
2908 /// @param name The registry name.
2909 /// @param count Specifies where to start reading the file. If negative, the file is read from the beginning.
2910 /// Otherwise, the file is read from the last @p count lines.
2911 /// @param context The request context.
2912 /// @return A future that becomes available when the invocation completes. This future holds:
2913 /// - An iterator to read the file. This proxy is never null.
2914 [[nodiscard]] std::future<std::optional<FileIteratorPrx>> openRegistryStdOutAsync(std::string_view name, std::int32_t count, const Ice::Context& context = Ice::noExplicitContext) const;
2915
2916 /// Opens a registry stdout file for reading.
2917 /// @param name The registry name.
2918 /// @param count Specifies where to start reading the file. If negative, the file is read from the beginning.
2919 /// Otherwise, the file is read from the last @p count lines.
2920 /// @param response The response callback. It accepts:
2921 /// - An iterator to read the file. This proxy is never null.
2922 /// @param exception The exception callback.
2923 /// @param sent The sent callback.
2924 /// @param context The request context.
2925 /// @return A function that can be called to cancel the invocation locally.
2926 // NOLINTNEXTLINE(modernize-use-nodiscard)
2927 std::function<void()> openRegistryStdOutAsync(std::string_view name, std::int32_t count, std::function<void(std::optional<::IceGrid::FileIteratorPrx>)> response, std::function<void(std::exception_ptr)> exception = nullptr, std::function<void(bool)> sent = nullptr, const Ice::Context& context = Ice::noExplicitContext) const;
2928
2929 /// @private
2930 void _iceI_openRegistryStdOut(const std::shared_ptr<IceInternal::OutgoingAsyncT<std::optional<FileIteratorPrx>>>&, std::string_view, std::int32_t, const Ice::Context&) const;
2931
2932 /// Gets the type ID of the associated Slice interface.
2933 /// @return The string `"::IceGrid::AdminSession"`.
2934 static const char* ice_staticId() noexcept;
2935
2936 /// @private
2937 static AdminSessionPrx _fromReference(IceInternal::ReferencePtr ref) { return AdminSessionPrx{std::move(ref)}; }
2938
2939 protected:
2940 /// @private
2941 AdminSessionPrx() = default;
2942
2943 /// @private
2944 explicit AdminSessionPrx(IceInternal::ReferencePtr&& ref) : Ice::ObjectPrx{std::move(ref)}
2945 {
2946 }
2947
2948#if defined(__GNUC__) && !defined(__clang__)
2949# pragma GCC diagnostic pop
2950#endif
2951 };
2952}
2953
2954namespace IceGrid
2955{
2956 /// Information about an Ice well-known object.
2957 /// @headerfile IceGrid/IceGrid.h
2959 {
2960 /// The proxy of the object.
2961 std::optional<Ice::ObjectPrx> proxy;
2962
2963 /// The type of the object.
2964 std::string type;
2965
2966 /// Creates a tuple with all the fields of this struct.
2967 /// @return A tuple with all the fields of this struct.
2968 [[nodiscard]] std::tuple<const std::optional<Ice::ObjectPrx>&, const std::string&> ice_tuple() const
2969 {
2970 return std::tie(proxy, type);
2971 }
2972
2973 /// Outputs the name and value of each field of this instance to the stream.
2974 /// @param os The output stream.
2975 ICEGRID_API void ice_printFields(std::ostream& os) const;
2976 };
2977
2978 /// Outputs the description of an ObjectInfo to a stream, including all its fields.
2979 /// @param os The output stream.
2980 /// @param value The instance to output.
2981 /// @return The output stream.
2982 ICEGRID_API std::ostream& operator<<(std::ostream& os, const ObjectInfo& value);
2983
2984 /// Information about an adapter registered with the IceGrid registry.
2985 /// @headerfile IceGrid/IceGrid.h
2987 {
2988 /// The ID of the adapter.
2989 std::string id;
2990
2991 /// A dummy direct proxy that contains the adapter endpoints.
2992 std::optional<Ice::ObjectPrx> proxy;
2993
2994 /// The replica group ID of the object adapter, or empty if the adapter doesn't belong to a replica group.
2995 std::string replicaGroupId;
2996
2997 /// Creates a tuple with all the fields of this struct.
2998 /// @return A tuple with all the fields of this struct.
2999 [[nodiscard]] std::tuple<const std::string&, const std::optional<Ice::ObjectPrx>&, const std::string&> ice_tuple() const
3000 {
3001 return std::tie(id, proxy, replicaGroupId);
3002 }
3003
3004 /// Outputs the name and value of each field of this instance to the stream.
3005 /// @param os The output stream.
3006 ICEGRID_API void ice_printFields(std::ostream& os) const;
3007 };
3008
3009 /// Outputs the description of an AdapterInfo to a stream, including all its fields.
3010 /// @param os The output stream.
3011 /// @param value The instance to output.
3012 /// @return The output stream.
3013 ICEGRID_API std::ostream& operator<<(std::ostream& os, const AdapterInfo& value);
3014
3015 /// Information about a server managed by an IceGrid node.
3016 /// @headerfile IceGrid/IceGrid.h
3018 {
3019 /// The application to which this server belongs.
3020 std::string application;
3021
3022 /// The application UUID.
3023 std::string uuid;
3024
3025 /// The application revision.
3026 std::int32_t revision;
3027
3028 /// The IceGrid node where this server is deployed.
3029 std::string node;
3030
3031 /// The server descriptor.
3033
3034 /// The ID of the session which allocated the server.
3035 std::string sessionId;
3036
3037 /// Creates a tuple with all the fields of this struct.
3038 /// @return A tuple with all the fields of this struct.
3039 [[nodiscard]] std::tuple<const std::string&, const std::string&, const std::int32_t&, const std::string&, const ::IceGrid::ServerDescriptorPtr&, const std::string&> ice_tuple() const
3040 {
3041 return std::tie(application, uuid, revision, node, descriptor, sessionId);
3042 }
3043
3044 /// Outputs the name and value of each field of this instance to the stream.
3045 /// @param os The output stream.
3046 ICEGRID_API void ice_printFields(std::ostream& os) const;
3047 };
3048
3049 /// Outputs the description of a ServerInfo to a stream, including all its fields.
3050 /// @param os The output stream.
3051 /// @param value The instance to output.
3052 /// @return The output stream.
3053 ICEGRID_API std::ostream& operator<<(std::ostream& os, const ServerInfo& value);
3054
3055 /// Information about an IceGrid node.
3056 /// @headerfile IceGrid/IceGrid.h
3058 {
3059 /// The name of the node.
3060 std::string name;
3061
3062 /// The operating system name.
3063 std::string os;
3064
3065 /// The network name of the host running this node.
3066 std::string hostname;
3067
3068 /// The operation system release level.
3069 std::string release;
3070
3071 /// The operation system version.
3072 std::string version;
3073
3074 /// The machine hardware type.
3075 std::string machine;
3076
3077 /// The number of processor threads on the node.
3078 /// For example, nProcessors is 8 on a computer with a single quad-core processor and two threads per core.
3079 std::int32_t nProcessors;
3080
3081 /// The path to the node data directory.
3082 std::string dataDir;
3083
3084 /// Creates a tuple with all the fields of this struct.
3085 /// @return A tuple with all the fields of this struct.
3086 [[nodiscard]] std::tuple<const std::string&, const std::string&, const std::string&, const std::string&, const std::string&, const std::string&, const std::int32_t&, const std::string&> ice_tuple() const
3087 {
3088 return std::tie(name, os, hostname, release, version, machine, nProcessors, dataDir);
3089 }
3090
3091 /// Outputs the name and value of each field of this instance to the stream.
3092 /// @param os The output stream.
3093 ICEGRID_API void ice_printFields(std::ostream& os) const;
3094 };
3095
3096 /// Outputs the description of a NodeInfo to a stream, including all its fields.
3097 /// @param os The output stream.
3098 /// @param value The instance to output.
3099 /// @return The output stream.
3100 ICEGRID_API std::ostream& operator<<(std::ostream& os, const NodeInfo& value);
3101
3102 /// Information about an IceGrid registry replica.
3103 /// @headerfile IceGrid/IceGrid.h
3105 {
3106 /// The name of the registry.
3107 std::string name;
3108
3109 /// The network name of the host running this registry.
3110 std::string hostname;
3111
3112 /// Creates a tuple with all the fields of this struct.
3113 /// @return A tuple with all the fields of this struct.
3114 [[nodiscard]] std::tuple<const std::string&, const std::string&> ice_tuple() const
3115 {
3116 return std::tie(name, hostname);
3117 }
3118
3119 /// Outputs the name and value of each field of this instance to the stream.
3120 /// @param os The output stream.
3121 ICEGRID_API void ice_printFields(std::ostream& os) const;
3122 };
3123
3124 /// Outputs the description of a RegistryInfo to a stream, including all its fields.
3125 /// @param os The output stream.
3126 /// @param value The instance to output.
3127 /// @return The output stream.
3128 ICEGRID_API std::ostream& operator<<(std::ostream& os, const RegistryInfo& value);
3129
3130 /// Information about the load of a node.
3131 /// @headerfile IceGrid/IceGrid.h
3133 {
3134 /// The load average over the past minute.
3135 float avg1;
3136
3137 /// The load average over the past 5 minutes.
3138 float avg5;
3139
3140 /// The load average over the past 15 minutes.
3141 float avg15;
3142
3143 /// Creates a tuple with all the fields of this struct.
3144 /// @return A tuple with all the fields of this struct.
3145 [[nodiscard]] std::tuple<const float&, const float&, const float&> ice_tuple() const
3146 {
3147 return std::tie(avg1, avg5, avg15);
3148 }
3149
3150 /// Outputs the name and value of each field of this instance to the stream.
3151 /// @param os The output stream.
3152 ICEGRID_API void ice_printFields(std::ostream& os) const;
3153 };
3154
3155 /// Outputs the description of a LoadInfo to a stream, including all its fields.
3156 /// @param os The output stream.
3157 /// @param value The instance to output.
3158 /// @return The output stream.
3159 ICEGRID_API std::ostream& operator<<(std::ostream& os, const LoadInfo& value);
3160
3161 /// Information about an IceGrid application.
3162 /// @headerfile IceGrid/IceGrid.h
3164 {
3165 /// Unique application identifier.
3166 std::string uuid;
3167
3168 /// The creation time.
3169 std::int64_t createTime;
3170
3171 /// The user who created the application.
3172 std::string createUser;
3173
3174 /// The last update time.
3175 std::int64_t updateTime;
3176
3177 /// The user who updated the application.
3178 std::string updateUser;
3179
3180 /// The application revision number.
3181 std::int32_t revision;
3182
3183 /// The application descriptor.
3185
3186 /// Creates a tuple with all the fields of this struct.
3187 /// @return A tuple with all the fields of this struct.
3188 [[nodiscard]] std::tuple<const std::string&, const std::int64_t&, const std::string&, const std::int64_t&, const std::string&, const std::int32_t&, const ::IceGrid::ApplicationDescriptor&> ice_tuple() const
3189 {
3191 }
3192
3193 /// Outputs the name and value of each field of this instance to the stream.
3194 /// @param os The output stream.
3195 ICEGRID_API void ice_printFields(std::ostream& os) const;
3196 };
3197
3198 /// Outputs the description of an ApplicationInfo to a stream, including all its fields.
3199 /// @param os The output stream.
3200 /// @param value The instance to output.
3201 /// @return The output stream.
3202 ICEGRID_API std::ostream& operator<<(std::ostream& os, const ApplicationInfo& value);
3203
3204 /// Information about updates to an IceGrid application.
3205 /// @headerfile IceGrid/IceGrid.h
3207 {
3208 /// The update time.
3209 std::int64_t updateTime;
3210
3211 /// The user who updated the application.
3212 std::string updateUser;
3213
3214 /// The application revision number.
3215 std::int32_t revision;
3216
3217 /// The update descriptor.
3219
3220 /// Creates a tuple with all the fields of this struct.
3221 /// @return A tuple with all the fields of this struct.
3222 [[nodiscard]] std::tuple<const std::int64_t&, const std::string&, const std::int32_t&, const ::IceGrid::ApplicationUpdateDescriptor&> ice_tuple() const
3223 {
3224 return std::tie(updateTime, updateUser, revision, descriptor);
3225 }
3226
3227 /// Outputs the name and value of each field of this instance to the stream.
3228 /// @param os The output stream.
3229 ICEGRID_API void ice_printFields(std::ostream& os) const;
3230 };
3231
3232 /// Outputs the description of an ApplicationUpdateInfo to a stream, including all its fields.
3233 /// @param os The output stream.
3234 /// @param value The instance to output.
3235 /// @return The output stream.
3236 ICEGRID_API std::ostream& operator<<(std::ostream& os, const ApplicationUpdateInfo& value);
3237
3238 /// Dynamic information about the state of a server.
3239 /// @headerfile IceGrid/IceGrid.h
3241 {
3242 /// The ID of the server.
3243 std::string id;
3244
3245 /// The state of the server.
3247
3248 /// The process ID of the server.
3249 std::int32_t pid;
3250
3251 /// Indicates whether the server is enabled.
3253
3254 /// Creates a tuple with all the fields of this struct.
3255 /// @return A tuple with all the fields of this struct.
3256 [[nodiscard]] std::tuple<const std::string&, const ::IceGrid::ServerState&, const std::int32_t&, const bool&> ice_tuple() const
3257 {
3258 return std::tie(id, state, pid, enabled);
3259 }
3260
3261 /// Outputs the name and value of each field of this instance to the stream.
3262 /// @param os The output stream.
3263 ICEGRID_API void ice_printFields(std::ostream& os) const;
3264 };
3265
3266 /// Outputs the description of a ServerDynamicInfo to a stream, including all its fields.
3267 /// @param os The output stream.
3268 /// @param value The instance to output.
3269 /// @return The output stream.
3270 ICEGRID_API std::ostream& operator<<(std::ostream& os, const ServerDynamicInfo& value);
3271
3272 /// Dynamic information about the state of an adapter.
3273 /// @headerfile IceGrid/IceGrid.h
3275 {
3276 /// The id of the adapter.
3277 std::string id;
3278
3279 /// The direct proxy containing the adapter endpoints. This proxy is never null.
3280 std::optional<Ice::ObjectPrx> proxy;
3281
3282 /// Creates a tuple with all the fields of this struct.
3283 /// @return A tuple with all the fields of this struct.
3284 [[nodiscard]] std::tuple<const std::string&, const std::optional<Ice::ObjectPrx>&> ice_tuple() const
3285 {
3286 return std::tie(id, proxy);
3287 }
3288
3289 /// Outputs the name and value of each field of this instance to the stream.
3290 /// @param os The output stream.
3291 ICEGRID_API void ice_printFields(std::ostream& os) const;
3292 };
3293
3294 /// Outputs the description of an AdapterDynamicInfo to a stream, including all its fields.
3295 /// @param os The output stream.
3296 /// @param value The instance to output.
3297 /// @return The output stream.
3298 ICEGRID_API std::ostream& operator<<(std::ostream& os, const AdapterDynamicInfo& value);
3299
3300 /// Dynamic information about the state of a node.
3301 /// @headerfile IceGrid/IceGrid.h
3303 {
3304 /// Some static information about the node.
3306
3307 /// The dynamic information of the servers deployed on this node.
3309
3310 /// The dynamic information of the adapters deployed on this node.
3312
3313 /// Creates a tuple with all the fields of this struct.
3314 /// @return A tuple with all the fields of this struct.
3315 [[nodiscard]] std::tuple<const ::IceGrid::NodeInfo&, const ::IceGrid::ServerDynamicInfoSeq&, const ::IceGrid::AdapterDynamicInfoSeq&> ice_tuple() const
3316 {
3317 return std::tie(info, servers, adapters);
3318 }
3319
3320 /// Outputs the name and value of each field of this instance to the stream.
3321 /// @param os The output stream.
3322 ICEGRID_API void ice_printFields(std::ostream& os) const;
3323 };
3324
3325 /// Outputs the description of a NodeDynamicInfo to a stream, including all its fields.
3326 /// @param os The output stream.
3327 /// @param value The instance to output.
3328 /// @return The output stream.
3329 ICEGRID_API std::ostream& operator<<(std::ostream& os, const NodeDynamicInfo& value);
3330
3331 /// @cond INTERNAL
3332 using Ice::Tuple::operator<;
3333 using Ice::Tuple::operator<=;
3334 using Ice::Tuple::operator>;
3335 using Ice::Tuple::operator>=;
3336 using Ice::Tuple::operator==;
3337 using Ice::Tuple::operator!=;
3338 /// @endcond
3339}
3340
3341namespace IceGrid
3342{
3343 /// Provides administrative access to an IceGrid deployment.
3344 /// @headerfile IceGrid/IceGrid.h
3345 class ICEGRID_API Admin : public virtual Ice::Object
3346 {
3347 public:
3348 /// The associated proxy type.
3349 using ProxyType = AdminPrx;
3350
3351 /// Dispatches an incoming request to one of the member functions of this generated class, based on the operation name carried by the request.
3352 /// @param request The incoming request.
3353 /// @param sendResponse The callback to send the response.
3354 void dispatch(Ice::IncomingRequest& request, std::function<void(Ice::OutgoingResponse)> sendResponse) override;
3355
3356 [[nodiscard]] std::vector<std::string> ice_ids(const Ice::Current& current) const override;
3357
3358 [[nodiscard]] std::string ice_id(const Ice::Current& current) const override;
3359
3360 /// Adds an application to IceGrid.
3361 /// @param descriptor The application descriptor.
3362 /// @param current The Current object of the incoming request.
3363 /// @throws IceGrid::AccessDeniedException Thrown when the session doesn't hold the exclusive lock or when another
3364 /// session is holding the lock.
3365 /// @throws IceGrid::DeploymentException Thrown when the application deployment failed.
3366 virtual void addApplication(ApplicationDescriptor descriptor, const Ice::Current& current) = 0;
3367
3368 /// @private
3369 void _iceD_addApplication(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>);
3370
3371 /// Synchronizes a deployed application. This operation replaces the current descriptor with a new descriptor.
3372 /// @param descriptor The new application descriptor.
3373 /// @param current The Current object of the incoming request.
3374 /// @throws IceGrid::AccessDeniedException Thrown when the session doesn't hold the exclusive lock or when another
3375 /// session is holding the lock.
3376 /// @throws IceGrid::ApplicationNotExistException Thrown when the application doesn't exist.
3377 /// @throws IceGrid::DeploymentException Thrown when the application deployment failed.
3378 virtual void syncApplication(ApplicationDescriptor descriptor, const Ice::Current& current) = 0;
3379
3380 /// @private
3381 void _iceD_syncApplication(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>);
3382
3383 /// Updates a deployed application.
3384 /// @param descriptor The update descriptor.
3385 /// @param current The Current object of the incoming request.
3386 /// @throws IceGrid::AccessDeniedException Thrown when the session doesn't hold the exclusive lock or when another
3387 /// session is holding the lock.
3388 /// @throws IceGrid::ApplicationNotExistException Thrown when the application doesn't exist.
3389 /// @throws IceGrid::DeploymentException Thrown when the application deployment failed.
3390 virtual void updateApplication(ApplicationUpdateDescriptor descriptor, const Ice::Current& current) = 0;
3391
3392 /// @private
3393 void _iceD_updateApplication(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>);
3394
3395 /// Synchronizes a deployed application. This operation replaces the current descriptor with a new descriptor
3396 /// only if no server restarts are necessary for the update of the application. If some servers need to be
3397 /// restarted, the synchronization is rejected with a DeploymentException.
3398 /// @param descriptor The application descriptor.
3399 /// @param current The Current object of the incoming request.
3400 /// @throws IceGrid::AccessDeniedException Thrown when the session doesn't hold the exclusive lock or when another
3401 /// session is holding the lock.
3402 /// @throws IceGrid::ApplicationNotExistException Thrown when the application doesn't exist.
3403 /// @throws IceGrid::DeploymentException Thrown when the application deployment failed.
3404 virtual void syncApplicationWithoutRestart(ApplicationDescriptor descriptor, const Ice::Current& current) = 0;
3405
3406 /// @private
3407 void _iceD_syncApplicationWithoutRestart(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>);
3408
3409 /// Updates a deployed application. This operation succeeds only when no server restarts are necessary for the
3410 /// update of the application. If some servers need to be restarted, the synchronization is rejected with a
3411 /// DeploymentException.
3412 /// @param descriptor The update descriptor.
3413 /// @param current The Current object of the incoming request.
3414 /// @throws IceGrid::AccessDeniedException Thrown when the session doesn't hold the exclusive lock or when another
3415 /// session is holding the lock.
3416 /// @throws IceGrid::ApplicationNotExistException Thrown when the application doesn't exist.
3417 /// @throws IceGrid::DeploymentException Thrown when the application deployment failed.
3418 virtual void updateApplicationWithoutRestart(ApplicationUpdateDescriptor descriptor, const Ice::Current& current) = 0;
3419
3420 /// @private
3421 void _iceD_updateApplicationWithoutRestart(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>);
3422
3423 /// Removes an application from IceGrid.
3424 /// @param name The application name.
3425 /// @param current The Current object of the incoming request.
3426 /// @throws IceGrid::AccessDeniedException Thrown when the session doesn't hold the exclusive lock or when another
3427 /// session is holding the lock.
3428 /// @throws IceGrid::ApplicationNotExistException Thrown when the application doesn't exist.
3429 /// @throws IceGrid::DeploymentException Thrown when the application deployment failed.
3430 virtual void removeApplication(std::string name, const Ice::Current& current) = 0;
3431
3432 /// @private
3433 void _iceD_removeApplication(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>);
3434
3435 /// Instantiates a server template.
3436 /// @param application The application name.
3437 /// @param node The name of the node where the server will be deployed.
3438 /// @param desc The descriptor of the server instance to deploy.
3439 /// @param current The Current object of the incoming request.
3440 /// @throws IceGrid::AccessDeniedException Thrown when the session doesn't hold the exclusive lock or when another
3441 /// session is holding the lock.
3442 /// @throws IceGrid::ApplicationNotExistException Thrown when the application doesn't exist.
3443 /// @throws IceGrid::DeploymentException Thrown when the application deployment failed.
3444 virtual void instantiateServer(std::string application, std::string node, ServerInstanceDescriptor desc, const Ice::Current& current) = 0;
3445
3446 /// @private
3447 void _iceD_instantiateServer(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>);
3448
3449 /// Gets an application descriptor.
3450 /// @param name The application name.
3451 /// @param current The Current object of the incoming request.
3452 /// @return The application descriptor.
3453 /// @throws IceGrid::ApplicationNotExistException Thrown when the application doesn't exist.
3454 [[nodiscard]] virtual ApplicationInfo getApplicationInfo(std::string name, const Ice::Current& current) const = 0;
3455
3456 /// @private
3457 void _iceD_getApplicationInfo(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>) const;
3458
3459 /// Gets the default application descriptor.
3460 /// @param current The Current object of the incoming request.
3461 /// @return The default application descriptor.
3462 /// @throws IceGrid::DeploymentException Thrown when the default application descriptor is invalid or unreachable.
3463 [[nodiscard]] virtual ApplicationDescriptor getDefaultApplicationDescriptor(const Ice::Current& current) const = 0;
3464
3465 /// @private
3466 void _iceD_getDefaultApplicationDescriptor(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>) const;
3467
3468 /// Gets all the IceGrid applications currently registered.
3469 /// @param current The Current object of the incoming request.
3470 /// @return The application names.
3471 [[nodiscard]] virtual ::Ice::StringSeq getAllApplicationNames(const Ice::Current& current) const = 0;
3472
3473 /// @private
3474 void _iceD_getAllApplicationNames(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>) const;
3475
3476 /// Gets information about a server.
3477 /// @param id The server ID.
3478 /// @param current The Current object of the incoming request.
3479 /// @return The server information.
3480 /// @throws IceGrid::ServerNotExistException Thrown when the server doesn't exist.
3481 [[nodiscard]] virtual ServerInfo getServerInfo(std::string id, const Ice::Current& current) const = 0;
3482
3483 /// @private
3484 void _iceD_getServerInfo(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>) const;
3485
3486 /// Gets the state of a server.
3487 /// @param id The server ID.
3488 /// @param current The Current object of the incoming request.
3489 /// @return The server state.
3490 /// @throws IceGrid::DeploymentException Thrown when the deployment of the server failed.
3491 /// @throws IceGrid::NodeUnreachableException Thrown when the node is unreachable.
3492 /// @throws IceGrid::ServerNotExistException Thrown when the server doesn't exist.
3493 [[nodiscard]] virtual ServerState getServerState(std::string id, const Ice::Current& current) const = 0;
3494
3495 /// @private
3496 void _iceD_getServerState(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>) const;
3497
3498 /// Gets the system process ID of a server. The process ID is operating system dependent.
3499 /// @param id The server ID.
3500 /// @param current The Current object of the incoming request.
3501 /// @return The process ID.
3502 /// @throws IceGrid::DeploymentException Thrown when the deployment of the server failed.
3503 /// @throws IceGrid::NodeUnreachableException Thrown when the node is unreachable.
3504 /// @throws IceGrid::ServerNotExistException Thrown when the server doesn't exist.
3505 [[nodiscard]] virtual std::int32_t getServerPid(std::string id, const Ice::Current& current) const = 0;
3506
3507 /// @private
3508 void _iceD_getServerPid(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>) const;
3509
3510 /// Gets the category for server admin objects. You can manufacture a server admin proxy from the admin proxy by
3511 /// changing its identity: use the server ID as name and the returned category as category.
3512 /// @param current The Current object of the incoming request.
3513 /// @return The category for server admin objects.
3514 [[nodiscard]] virtual std::string getServerAdminCategory(const Ice::Current& current) const = 0;
3515
3516 /// @private
3517 void _iceD_getServerAdminCategory(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>) const;
3518
3519 /// Gets a proxy to the admin object of a server.
3520 /// @param id The server ID.
3521 /// @param current The Current object of the incoming request.
3522 /// @return A proxy to the admin object of the server. This proxy is never null.
3523 /// @throws IceGrid::DeploymentException Thrown when the deployment of the server failed.
3524 /// @throws IceGrid::NodeUnreachableException Thrown when the node is unreachable.
3525 /// @throws IceGrid::ServerNotExistException Thrown when the server doesn't exist.
3526 [[nodiscard]] virtual std::optional<Ice::ObjectPrx> getServerAdmin(std::string id, const Ice::Current& current) const = 0;
3527
3528 /// @private
3529 void _iceD_getServerAdmin(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>) const;
3530
3531 /// Enables or disables a server. A disabled server can't be started on demand or administratively. The enable
3532 /// state of the server is not persistent: if the node is shut down and restarted, the server will be enabled by
3533 /// default.
3534 /// @param id The server ID.
3535 /// @param enabled `true` to enable the server, `false` to disable it.
3536 /// @param current The Current object of the incoming request.
3537 /// @throws IceGrid::DeploymentException Thrown when the deployment of the server failed.
3538 /// @throws IceGrid::NodeUnreachableException Thrown when the node is unreachable.
3539 /// @throws IceGrid::ServerNotExistException Thrown when the server doesn't exist.
3540 virtual void enableServer(std::string id, bool enabled, const Ice::Current& current) = 0;
3541
3542 /// @private
3543 void _iceD_enableServer(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>);
3544
3545 /// Checks if the server is enabled or disabled.
3546 /// @param id The server ID.
3547 /// @param current The Current object of the incoming request.
3548 /// @return `true` if the server is enabled, `false` otherwise.
3549 /// @throws IceGrid::DeploymentException Thrown when the deployment of the server failed.
3550 /// @throws IceGrid::NodeUnreachableException Thrown when the node is unreachable.
3551 /// @throws IceGrid::ServerNotExistException Thrown when the server doesn't exist.
3552 [[nodiscard]] virtual bool isServerEnabled(std::string id, const Ice::Current& current) const = 0;
3553
3554 /// @private
3555 void _iceD_isServerEnabled(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>) const;
3556
3557 /// Starts a server and waits for its activation.
3558 /// @param id The server id.
3559 /// @param response The response callback.
3560 /// @param exception The exception callback.
3561 /// @param current The Current object of the incoming request.
3562 /// @throws IceGrid::DeploymentException Thrown when the deployment of the server failed.
3563 /// @throws IceGrid::NodeUnreachableException Thrown when the node is unreachable.
3564 /// @throws IceGrid::ServerNotExistException Thrown when the server doesn't exist.
3565 /// @throws IceGrid::ServerStartException Thrown when the server startup failed.
3566 virtual void startServerAsync(std::string id, std::function<void()> response, std::function<void(std::exception_ptr)> exception, const Ice::Current& current) = 0;
3567
3568 /// @private
3569 void _iceD_startServer(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>);
3570
3571 /// Stops a server.
3572 /// @param id The server ID.
3573 /// @param response The response callback.
3574 /// @param exception The exception callback.
3575 /// @param current The Current object of the incoming request.
3576 /// @throws IceGrid::DeploymentException Thrown when the deployment of the server failed.
3577 /// @throws IceGrid::NodeUnreachableException Thrown when the node is unreachable.
3578 /// @throws IceGrid::ServerNotExistException Thrown when the server doesn't exist.
3579 /// @throws IceGrid::ServerStopException Thrown when the server stop failed.
3580 virtual void stopServerAsync(std::string id, std::function<void()> response, std::function<void(std::exception_ptr)> exception, const Ice::Current& current) = 0;
3581
3582 /// @private
3583 void _iceD_stopServer(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>);
3584
3585 /// Sends a signal to a server.
3586 /// @param id The server ID.
3587 /// @param signal The signal, for example SIGTERM or 15.
3588 /// @param current The Current object of the incoming request.
3589 /// @throws IceGrid::BadSignalException Thrown when the signal is not recognized by the target server.
3590 /// @throws IceGrid::DeploymentException Thrown when the deployment of the server failed.
3591 /// @throws IceGrid::NodeUnreachableException Thrown when the node is unreachable.
3592 /// @throws IceGrid::ServerNotExistException Thrown when the server doesn't exist.
3593 virtual void sendSignal(std::string id, std::string signal, const Ice::Current& current) = 0;
3594
3595 /// @private
3596 void _iceD_sendSignal(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>);
3597
3598 /// Gets the IDs of all the servers registered with IceGrid.
3599 /// @param current The Current object of the incoming request.
3600 /// @return The server IDs.
3601 [[nodiscard]] virtual ::Ice::StringSeq getAllServerIds(const Ice::Current& current) const = 0;
3602
3603 /// @private
3604 void _iceD_getAllServerIds(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>) const;
3605
3606 /// Gets adapter information for the replica group or adapter with the given ID.
3607 /// @param id The adapter or replica group ID.
3608 /// @param current The Current object of the incoming request.
3609 /// @return A sequence of AdapterInfo. If @p id refers to an adapter, this sequence contains a single element.
3610 /// If @p id refers to a replica group, this sequence contains adapter information for each member of the
3611 /// replica group.
3612 /// @throws IceGrid::AdapterNotExistException Thrown when the adapter or replica group doesn't exist.
3613 [[nodiscard]] virtual AdapterInfoSeq getAdapterInfo(std::string id, const Ice::Current& current) const = 0;
3614
3615 /// @private
3616 void _iceD_getAdapterInfo(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>) const;
3617
3618 /// Removes the adapter with the given ID.
3619 /// @param id The adapter ID.
3620 /// @param current The Current object of the incoming request.
3621 /// @throws IceGrid::AdapterNotExistException Thrown when the adapter doesn't exist.
3622 /// @throws IceGrid::DeploymentException Thrown when the application deployment failed.
3623 virtual void removeAdapter(std::string id, const Ice::Current& current) = 0;
3624
3625 /// @private
3626 void _iceD_removeAdapter(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>);
3627
3628 /// Gets the IDs of all adapters registered with IceGrid.
3629 /// @param current The Current object of the incoming request.
3630 /// @return The adapter IDs.
3631 [[nodiscard]] virtual ::Ice::StringSeq getAllAdapterIds(const Ice::Current& current) const = 0;
3632
3633 /// @private
3634 void _iceD_getAllAdapterIds(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>) const;
3635
3636 /// Adds an object to the object registry. IceGrid gets the object type by calling `ice_id` on @p obj. The
3637 /// object must be reachable.
3638 /// @param obj A proxy to the object. This proxy is never null.
3639 /// @param current The Current object of the incoming request.
3640 /// @throws IceGrid::DeploymentException Thrown when the object can't be added.
3641 /// @throws IceGrid::ObjectExistsException Thrown when the object is already registered.
3642 virtual void addObject(std::optional<Ice::ObjectPrx> obj, const Ice::Current& current) = 0;
3643
3644 /// @private
3645 void _iceD_addObject(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>);
3646
3647 /// Updates an object in the object registry. Only objects added with this interface can be updated with this
3648 /// operation. Objects added with deployment descriptors should be updated with the deployment mechanism.
3649 /// @param obj A proxy to the object. This proxy is never null.
3650 /// @param current The Current object of the incoming request.
3651 /// @throws IceGrid::DeploymentException Thrown when the object can't be updated.
3652 /// @throws IceGrid::ObjectNotRegisteredException Thrown when the object isn't registered with the registry.
3653 virtual void updateObject(std::optional<Ice::ObjectPrx> obj, const Ice::Current& current) = 0;
3654
3655 /// @private
3656 void _iceD_updateObject(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>);
3657
3658 /// Adds an object to the object registry and explicitly specifies its type.
3659 /// @param obj The object to be added to the registry. The proxy is never null.
3660 /// @param type The type name.
3661 /// @param current The Current object of the incoming request.
3662 /// @throws IceGrid::DeploymentException Thrown when the application deployment failed.
3663 /// @throws IceGrid::ObjectExistsException Thrown when the object is already registered.
3664 virtual void addObjectWithType(std::optional<Ice::ObjectPrx> obj, std::string type, const Ice::Current& current) = 0;
3665
3666 /// @private
3667 void _iceD_addObjectWithType(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>);
3668
3669 /// Removes an object from the object registry. Only objects added with this interface can be removed with this
3670 /// operation. Objects added with deployment descriptors should be removed with the deployment mechanism.
3671 /// @param id The identity of the object to remove.
3672 /// @param current The Current object of the incoming request.
3673 /// @throws IceGrid::DeploymentException Thrown when the object can't be removed.
3674 /// @throws IceGrid::ObjectNotRegisteredException Thrown when the object isn't registered with the registry.
3675 virtual void removeObject(::Ice::Identity id, const Ice::Current& current) = 0;
3676
3677 /// @private
3678 void _iceD_removeObject(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>);
3679
3680 /// Gets the object info for the object.
3681 /// @param id The identity of the object.
3682 /// @param current The Current object of the incoming request.
3683 /// @return The object info.
3684 /// @throws IceGrid::ObjectNotRegisteredException Thrown when the object isn't registered with the registry.
3685 [[nodiscard]] virtual ObjectInfo getObjectInfo(::Ice::Identity id, const Ice::Current& current) const = 0;
3686
3687 /// @private
3688 void _iceD_getObjectInfo(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>) const;
3689
3690 /// Gets the object info of all the registered objects with a given type.
3691 /// @param type The type name.
3692 /// @param current The Current object of the incoming request.
3693 /// @return The object infos.
3694 [[nodiscard]] virtual ObjectInfoSeq getObjectInfosByType(std::string type, const Ice::Current& current) const = 0;
3695
3696 /// @private
3697 void _iceD_getObjectInfosByType(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>) const;
3698
3699 /// Gets the object info of all the registered objects whose stringified identities match the given expression.
3700 /// @param expr The expression to match against the stringified identities of registered objects. The expression
3701 /// may contain a trailing wildcard (`*`) character.
3702 /// @param current The Current object of the incoming request.
3703 /// @return All the object infos with a stringified identity matching the given expression.
3704 [[nodiscard]] virtual ObjectInfoSeq getAllObjectInfos(std::string expr, const Ice::Current& current) const = 0;
3705
3706 /// @private
3707 void _iceD_getAllObjectInfos(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>) const;
3708
3709 /// Pings an IceGrid node to see if it is active.
3710 /// @param name The node name.
3711 /// @param current The Current object of the incoming request.
3712 /// @return `true` if the node ping succeeded, `false` otherwise.
3713 /// @throws IceGrid::NodeNotExistException Thrown when the node doesn't exist.
3714 [[nodiscard]] virtual bool pingNode(std::string name, const Ice::Current& current) const = 0;
3715
3716 /// @private
3717 void _iceD_pingNode(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>) const;
3718
3719 /// Gets the load averages of a node.
3720 /// @param name The node name.
3721 /// @param current The Current object of the incoming request.
3722 /// @return The node load information.
3723 /// @throws IceGrid::NodeNotExistException Thrown when the node doesn't exist.
3724 /// @throws IceGrid::NodeUnreachableException Thrown when the node is unreachable.
3725 [[nodiscard]] virtual LoadInfo getNodeLoad(std::string name, const Ice::Current& current) const = 0;
3726
3727 /// @private
3728 void _iceD_getNodeLoad(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>) const;
3729
3730 /// Gets the node information of a node.
3731 /// @param name The node name.
3732 /// @param current The Current object of the incoming request.
3733 /// @return The node information.
3734 /// @throws IceGrid::NodeNotExistException Thrown when the node doesn't exist.
3735 /// @throws IceGrid::NodeUnreachableException Thrown when the node is unreachable.
3736 [[nodiscard]] virtual NodeInfo getNodeInfo(std::string name, const Ice::Current& current) const = 0;
3737
3738 /// @private
3739 void _iceD_getNodeInfo(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>) const;
3740
3741 /// Gets a proxy to the admin object of an IceGrid node.
3742 /// @param name The IceGrid node name.
3743 /// @param current The Current object of the incoming request.
3744 /// @return A proxy to the IceGrid node's admin object. This proxy is never null.
3745 /// @throws IceGrid::NodeNotExistException Thrown when the node doesn't exist.
3746 /// @throws IceGrid::NodeUnreachableException Thrown when the node is unreachable.
3747 [[nodiscard]] virtual std::optional<Ice::ObjectPrx> getNodeAdmin(std::string name, const Ice::Current& current) const = 0;
3748
3749 /// @private
3750 void _iceD_getNodeAdmin(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>) const;
3751
3752 /// Gets the number of physical processor sockets in the computer where an IceGrid node is deployed.
3753 /// Note that this operation returns 1 on operating systems where this can't be automatically determined and
3754 /// where the `IceGrid.Node.ProcessorSocketCount` property for the node is not set.
3755 /// @param name The node name.
3756 /// @param current The Current object of the incoming request.
3757 /// @return The number of processor sockets or 1 if the number of sockets can't be determined.
3758 /// @throws IceGrid::NodeNotExistException Thrown when the node doesn't exist.
3759 /// @throws IceGrid::NodeUnreachableException Thrown when the node is unreachable.
3760 [[nodiscard]] virtual std::int32_t getNodeProcessorSocketCount(std::string name, const Ice::Current& current) const = 0;
3761
3762 /// @private
3763 void _iceD_getNodeProcessorSocketCount(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>) const;
3764
3765 /// Shuts down an IceGrid node.
3766 /// @param name The node name.
3767 /// @param current The Current object of the incoming request.
3768 /// @throws IceGrid::NodeNotExistException Thrown when the node doesn't exist.
3769 /// @throws IceGrid::NodeUnreachableException Thrown when the node is unreachable.
3770 virtual void shutdownNode(std::string name, const Ice::Current& current) = 0;
3771
3772 /// @private
3773 void _iceD_shutdownNode(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>);
3774
3775 /// Get the hostname of a node.
3776 /// @param name The node name.
3777 /// @param current The Current object of the incoming request.
3778 /// @return The node hostname.
3779 /// @throws IceGrid::NodeNotExistException Thrown when the node doesn't exist.
3780 /// @throws IceGrid::NodeUnreachableException Thrown when the node is unreachable.
3781 [[nodiscard]] virtual std::string getNodeHostname(std::string name, const Ice::Current& current) const = 0;
3782
3783 /// @private
3784 void _iceD_getNodeHostname(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>) const;
3785
3786 /// Gets the names of all IceGrid nodes currently registered.
3787 /// @param current The Current object of the incoming request.
3788 /// @return The node names.
3789 [[nodiscard]] virtual ::Ice::StringSeq getAllNodeNames(const Ice::Current& current) const = 0;
3790
3791 /// @private
3792 void _iceD_getAllNodeNames(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>) const;
3793
3794 /// Pings an IceGrid registry to see if it is active.
3795 /// @param name The registry name.
3796 /// @param current The Current object of the incoming request.
3797 /// @return `true` if the registry ping succeeded, `false` otherwise.
3798 /// @throws IceGrid::RegistryNotExistException Thrown when the registry doesn't exist.
3799 [[nodiscard]] virtual bool pingRegistry(std::string name, const Ice::Current& current) const = 0;
3800
3801 /// @private
3802 void _iceD_pingRegistry(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>) const;
3803
3804 /// Gets the registry information of an IceGrid registry.
3805 /// @param name The registry name.
3806 /// @param current The Current object of the incoming request.
3807 /// @return The registry information.
3808 /// @throws IceGrid::RegistryNotExistException Thrown when the registry doesn't exist.
3809 /// @throws IceGrid::RegistryUnreachableException Thrown when the registry is unreachable.
3810 [[nodiscard]] virtual RegistryInfo getRegistryInfo(std::string name, const Ice::Current& current) const = 0;
3811
3812 /// @private
3813 void _iceD_getRegistryInfo(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>) const;
3814
3815 /// Gets a proxy to the admin object of an IceGrid registry.
3816 /// @param name The registry name.
3817 /// @param current The Current object of the incoming request.
3818 /// @return A proxy to the admin object of an IceGrid registry. This proxy is never null.
3819 /// @throws IceGrid::RegistryNotExistException Thrown when the registry doesn't exist.
3820 [[nodiscard]] virtual std::optional<Ice::ObjectPrx> getRegistryAdmin(std::string name, const Ice::Current& current) const = 0;
3821
3822 /// @private
3823 void _iceD_getRegistryAdmin(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>) const;
3824
3825 /// Shuts down an IceGrid registry.
3826 /// @param name The registry name.
3827 /// @param current The Current object of the incoming request.
3828 /// @throws IceGrid::RegistryNotExistException Thrown when the registry doesn't exist.
3829 /// @throws IceGrid::RegistryUnreachableException Thrown when the registry is unreachable.
3830 virtual void shutdownRegistry(std::string name, const Ice::Current& current) = 0;
3831
3832 /// @private
3833 void _iceD_shutdownRegistry(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>);
3834
3835 /// Gets the names of all the IceGrid registries currently registered.
3836 /// @param current The Current object of the incoming request.
3837 /// @return The registry names.
3838 [[nodiscard]] virtual ::Ice::StringSeq getAllRegistryNames(const Ice::Current& current) const = 0;
3839
3840 /// @private
3841 void _iceD_getAllRegistryNames(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>) const;
3842
3843 /// Shuts down the IceGrid registry.
3844 /// @param current The Current object of the incoming request.
3845 virtual void shutdown(const Ice::Current& current) = 0;
3846
3847 /// @private
3848 void _iceD_shutdown(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>);
3849
3850 /// Gets the type ID of the associated Slice interface.
3851 /// @return The string `"::IceGrid::Admin"`.
3852 static const char* ice_staticId() noexcept;
3853 };
3854
3855 /// A shared pointer to an Admin.
3856 using AdminPtr = std::shared_ptr<Admin>;
3857
3858 /// Iterates over an IceGrid log file.
3859 /// @headerfile IceGrid/IceGrid.h
3860 class ICEGRID_API FileIterator : public virtual Ice::Object
3861 {
3862 public:
3863 /// The associated proxy type.
3864 using ProxyType = FileIteratorPrx;
3865
3866 /// Dispatches an incoming request to one of the member functions of this generated class, based on the operation name carried by the request.
3867 /// @param request The incoming request.
3868 /// @param sendResponse The callback to send the response.
3869 void dispatch(Ice::IncomingRequest& request, std::function<void(Ice::OutgoingResponse)> sendResponse) override;
3870
3871 [[nodiscard]] std::vector<std::string> ice_ids(const Ice::Current& current) const override;
3872
3873 [[nodiscard]] std::string ice_id(const Ice::Current& current) const override;
3874
3875 /// Read lines from the log file.
3876 /// @param size Specifies the maximum number of bytes to be received. The server will ensure that the returned
3877 /// message doesn't exceed the given size.
3878 /// @param[out] lines The lines read from the file. If there was nothing to read from the file since the last call to
3879 /// read, an empty sequence is returned. The last line of the sequence is always incomplete (and therefore no
3880 /// newline character should be added when writing the last line to the to the output device).
3881 /// @param current The Current object of the incoming request.
3882 /// @return `true` if EOF is encountered.
3883 /// @throws IceGrid::FileNotAvailableException Thrown when the implementation failed to read from the file.
3884 virtual bool read(std::int32_t size, ::Ice::StringSeq& lines, const Ice::Current& current) = 0;
3885
3886 /// @private
3887 void _iceD_read(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>);
3888
3889 /// Destroys the iterator.
3890 /// @param current The Current object of the incoming request.
3891 virtual void destroy(const Ice::Current& current) = 0;
3892
3893 /// @private
3894 void _iceD_destroy(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>);
3895
3896 /// Gets the type ID of the associated Slice interface.
3897 /// @return The string `"::IceGrid::FileIterator"`.
3898 static const char* ice_staticId() noexcept;
3899 };
3900
3901 /// A shared pointer to a FileIterator.
3902 using FileIteratorPtr = std::shared_ptr<FileIterator>;
3903
3904 /// Monitors changes to the state of the registries.
3905 /// @headerfile IceGrid/IceGrid.h
3906 class ICEGRID_API RegistryObserver : public virtual Ice::Object
3907 {
3908 public:
3909 /// The associated proxy type.
3911
3912 /// Dispatches an incoming request to one of the member functions of this generated class, based on the operation name carried by the request.
3913 /// @param request The incoming request.
3914 /// @param sendResponse The callback to send the response.
3915 void dispatch(Ice::IncomingRequest& request, std::function<void(Ice::OutgoingResponse)> sendResponse) override;
3916
3917 [[nodiscard]] std::vector<std::string> ice_ids(const Ice::Current& current) const override;
3918
3919 [[nodiscard]] std::string ice_id(const Ice::Current& current) const override;
3920
3921 /// Provides the initial state of the registries to the observer.
3922 /// @param registries The current state of the registries.
3923 /// @param current The Current object of the incoming request.
3924 virtual void registryInit(RegistryInfoSeq registries, const Ice::Current& current) = 0;
3925
3926 /// @private
3927 void _iceD_registryInit(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>);
3928
3929 /// Notifies the observer that a registry replica came up.
3930 /// @param registryReplica The registry state.
3931 /// @param current The Current object of the incoming request.
3932 virtual void registryUp(RegistryInfo registryReplica, const Ice::Current& current) = 0;
3933
3934 /// @private
3935 void _iceD_registryUp(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>);
3936
3937 /// Notifies the observer that a registry replica went down.
3938 /// @param name The registry name.
3939 /// @param current The Current object of the incoming request.
3940 virtual void registryDown(std::string name, const Ice::Current& current) = 0;
3941
3942 /// @private
3943 void _iceD_registryDown(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>);
3944
3945 /// Gets the type ID of the associated Slice interface.
3946 /// @return The string `"::IceGrid::RegistryObserver"`.
3947 static const char* ice_staticId() noexcept;
3948 };
3949
3950 /// A shared pointer to a RegistryObserver.
3951 using RegistryObserverPtr = std::shared_ptr<RegistryObserver>;
3952
3953 /// Monitors changes to the state of the nodes.
3954 /// @headerfile IceGrid/IceGrid.h
3955 class ICEGRID_API NodeObserver : public virtual Ice::Object
3956 {
3957 public:
3958 /// The associated proxy type.
3960
3961 /// Dispatches an incoming request to one of the member functions of this generated class, based on the operation name carried by the request.
3962 /// @param request The incoming request.
3963 /// @param sendResponse The callback to send the response.
3964 void dispatch(Ice::IncomingRequest& request, std::function<void(Ice::OutgoingResponse)> sendResponse) override;
3965
3966 [[nodiscard]] std::vector<std::string> ice_ids(const Ice::Current& current) const override;
3967
3968 [[nodiscard]] std::string ice_id(const Ice::Current& current) const override;
3969
3970 /// Provides the initial state of the nodes to the observer.
3971 /// @param nodes The current state of the nodes.
3972 /// @param current The Current object of the incoming request.
3973 virtual void nodeInit(NodeDynamicInfoSeq nodes, const Ice::Current& current) = 0;
3974
3975 /// @private
3976 void _iceD_nodeInit(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>);
3977
3978 /// Notifies the observer that a node came up.
3979 /// @param node The node state.
3980 /// @param current The Current object of the incoming request.
3981 virtual void nodeUp(NodeDynamicInfo node, const Ice::Current& current) = 0;
3982
3983 /// @private
3984 void _iceD_nodeUp(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>);
3985
3986 /// Notifies the observer that a node went down.
3987 /// @param name The node name.
3988 /// @param current The Current object of the incoming request.
3989 virtual void nodeDown(std::string name, const Ice::Current& current) = 0;
3990
3991 /// @private
3992 void _iceD_nodeDown(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>);
3993
3994 /// Notifies the observer that the state of a server changed.
3995 /// @param node The node hosting the server.
3996 /// @param updatedInfo The new server state.
3997 /// @param current The Current object of the incoming request.
3998 virtual void updateServer(std::string node, ServerDynamicInfo updatedInfo, const Ice::Current& current) = 0;
3999
4000 /// @private
4001 void _iceD_updateServer(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>);
4002
4003 /// Notifies the observer that the state of an object adapter changed.
4004 /// @param node The node hosting the adapter.
4005 /// @param updatedInfo The new adapter state.
4006 /// @param current The Current object of the incoming request.
4007 virtual void updateAdapter(std::string node, AdapterDynamicInfo updatedInfo, const Ice::Current& current) = 0;
4008
4009 /// @private
4010 void _iceD_updateAdapter(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>);
4011
4012 /// Gets the type ID of the associated Slice interface.
4013 /// @return The string `"::IceGrid::NodeObserver"`.
4014 static const char* ice_staticId() noexcept;
4015 };
4016
4017 /// A shared pointer to a NodeObserver.
4018 using NodeObserverPtr = std::shared_ptr<NodeObserver>;
4019
4020 /// Monitors applications.
4021 /// @headerfile IceGrid/IceGrid.h
4022 class ICEGRID_API ApplicationObserver : public virtual Ice::Object
4023 {
4024 public:
4025 /// The associated proxy type.
4027
4028 /// Dispatches an incoming request to one of the member functions of this generated class, based on the operation name carried by the request.
4029 /// @param request The incoming request.
4030 /// @param sendResponse The callback to send the response.
4031 void dispatch(Ice::IncomingRequest& request, std::function<void(Ice::OutgoingResponse)> sendResponse) override;
4032
4033 [[nodiscard]] std::vector<std::string> ice_ids(const Ice::Current& current) const override;
4034
4035 [[nodiscard]] std::string ice_id(const Ice::Current& current) const override;
4036
4037 /// Provides the initial application infos to the observer.
4038 /// @param serial The current serial number of the registry database. This serial number allows observers to
4039 /// make sure that their internal state is synchronized with the registry.
4040 /// @param applications The applications currently registered with the registry.
4041 /// @param current The Current object of the incoming request.
4042 virtual void applicationInit(std::int32_t serial, ApplicationInfoSeq applications, const Ice::Current& current) = 0;
4043
4044 /// @private
4045 void _iceD_applicationInit(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>);
4046
4047 /// Notifies the observer that an application was added.
4048 /// @param serial The new serial number of the registry database.
4049 /// @param desc The descriptor of the new application.
4050 /// @param current The Current object of the incoming request.
4051 virtual void applicationAdded(std::int32_t serial, ApplicationInfo desc, const Ice::Current& current) = 0;
4052
4053 /// @private
4054 void _iceD_applicationAdded(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>);
4055
4056 /// Notifies the observer that an application was removed.
4057 /// @param serial The new serial number of the registry database.
4058 /// @param name The name of the application that was removed.
4059 /// @param current The Current object of the incoming request.
4060 virtual void applicationRemoved(std::int32_t serial, std::string name, const Ice::Current& current) = 0;
4061
4062 /// @private
4063 void _iceD_applicationRemoved(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>);
4064
4065 /// Notifies the observer that an application was updated.
4066 /// @param serial The new serial number of the registry database.
4067 /// @param desc The descriptor of the update.
4068 /// @param current The Current object of the incoming request.
4069 virtual void applicationUpdated(std::int32_t serial, ApplicationUpdateInfo desc, const Ice::Current& current) = 0;
4070
4071 /// @private
4072 void _iceD_applicationUpdated(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>);
4073
4074 /// Gets the type ID of the associated Slice interface.
4075 /// @return The string `"::IceGrid::ApplicationObserver"`.
4076 static const char* ice_staticId() noexcept;
4077 };
4078
4079 /// A shared pointer to an ApplicationObserver.
4081
4082 /// Monitors dynamically-registered object adapters.
4083 /// @headerfile IceGrid/IceGrid.h
4084 class ICEGRID_API AdapterObserver : public virtual Ice::Object
4085 {
4086 public:
4087 /// The associated proxy type.
4089
4090 /// Dispatches an incoming request to one of the member functions of this generated class, based on the operation name carried by the request.
4091 /// @param request The incoming request.
4092 /// @param sendResponse The callback to send the response.
4093 void dispatch(Ice::IncomingRequest& request, std::function<void(Ice::OutgoingResponse)> sendResponse) override;
4094
4095 [[nodiscard]] std::vector<std::string> ice_ids(const Ice::Current& current) const override;
4096
4097 [[nodiscard]] std::string ice_id(const Ice::Current& current) const override;
4098
4099 /// Provides the initial list of dynamically registered adapters to the observer.
4100 /// @param adpts The adapters that were dynamically registered with the registry.
4101 /// @param current The Current object of the incoming request.
4102 virtual void adapterInit(AdapterInfoSeq adpts, const Ice::Current& current) = 0;
4103
4104 /// @private
4105 void _iceD_adapterInit(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>);
4106
4107 /// Notifies the observer that a dynamically-registered adapter was added.
4108 /// @param info The details of the new adapter.
4109 /// @param current The Current object of the incoming request.
4110 virtual void adapterAdded(AdapterInfo info, const Ice::Current& current) = 0;
4111
4112 /// @private
4113 void _iceD_adapterAdded(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>);
4114
4115 /// @param info The details of the updated adapter.
4116 /// @param current The Current object of the incoming request.
4117 virtual void adapterUpdated(AdapterInfo info, const Ice::Current& current) = 0;
4118
4119 /// @private
4120 void _iceD_adapterUpdated(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>);
4121
4122 /// Notifies the observer that a dynamically-registered adapter was removed.
4123 /// @param id The ID of the removed adapter.
4124 /// @param current The Current object of the incoming request.
4125 virtual void adapterRemoved(std::string id, const Ice::Current& current) = 0;
4126
4127 /// @private
4128 void _iceD_adapterRemoved(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>);
4129
4130 /// Gets the type ID of the associated Slice interface.
4131 /// @return The string `"::IceGrid::AdapterObserver"`.
4132 static const char* ice_staticId() noexcept;
4133 };
4134
4135 /// A shared pointer to an AdapterObserver.
4136 using AdapterObserverPtr = std::shared_ptr<AdapterObserver>;
4137
4138 /// Monitors well-known objects that are added, updated or removed using AdminPrx.
4139 /// @headerfile IceGrid/IceGrid.h
4140 class ICEGRID_API ObjectObserver : public virtual Ice::Object
4141 {
4142 public:
4143 /// The associated proxy type.
4145
4146 /// Dispatches an incoming request to one of the member functions of this generated class, based on the operation name carried by the request.
4147 /// @param request The incoming request.
4148 /// @param sendResponse The callback to send the response.
4149 void dispatch(Ice::IncomingRequest& request, std::function<void(Ice::OutgoingResponse)> sendResponse) override;
4150
4151 [[nodiscard]] std::vector<std::string> ice_ids(const Ice::Current& current) const override;
4152
4153 [[nodiscard]] std::string ice_id(const Ice::Current& current) const override;
4154
4155 /// Provides the initial list of well-known objects to the observer.
4156 /// @param objects The well-known objects registered using ::IceGrid::AdminPrx.
4157 /// @param current The Current object of the incoming request.
4158 virtual void objectInit(ObjectInfoSeq objects, const Ice::Current& current) = 0;
4159
4160 /// @private
4161 void _iceD_objectInit(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>);
4162
4163 /// Notifies the observer that a well-known object was added.
4164 /// @param info The details of the new object.
4165 /// @param current The Current object of the incoming request.
4166 virtual void objectAdded(ObjectInfo info, const Ice::Current& current) = 0;
4167
4168 /// @private
4169 void _iceD_objectAdded(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>);
4170
4171 /// Notifies the observer that a well-known object was updated.
4172 /// @param info The details of the updated object.
4173 /// @param current The Current object of the incoming request.
4174 virtual void objectUpdated(ObjectInfo info, const Ice::Current& current) = 0;
4175
4176 /// @private
4177 void _iceD_objectUpdated(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>);
4178
4179 /// Notifies the observer that a well-known object was removed.
4180 /// @param id The identity of the removed object.
4181 /// @param current The Current object of the incoming request.
4182 virtual void objectRemoved(::Ice::Identity id, const Ice::Current& current) = 0;
4183
4184 /// @private
4185 void _iceD_objectRemoved(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>);
4186
4187 /// Gets the type ID of the associated Slice interface.
4188 /// @return The string `"::IceGrid::ObjectObserver"`.
4189 static const char* ice_staticId() noexcept;
4190 };
4191
4192 /// A shared pointer to an ObjectObserver.
4193 using ObjectObserverPtr = std::shared_ptr<ObjectObserver>;
4194
4195 /// Represents an administrative session between an admin tool and an IceGrid registry.
4196 /// @see Registry
4197 /// @headerfile IceGrid/IceGrid.h
4198 class ICEGRID_API AdminSession : public virtual ::Glacier2::Session
4199 {
4200 public:
4201 /// The associated proxy type.
4202 using ProxyType = AdminSessionPrx;
4203
4204 /// Dispatches an incoming request to one of the member functions of this generated class, based on the operation name carried by the request.
4205 /// @param request The incoming request.
4206 /// @param sendResponse The callback to send the response.
4207 void dispatch(Ice::IncomingRequest& request, std::function<void(Ice::OutgoingResponse)> sendResponse) override;
4208
4209 [[nodiscard]] std::vector<std::string> ice_ids(const Ice::Current& current) const override;
4210
4211 [[nodiscard]] std::string ice_id(const Ice::Current& current) const override;
4212
4213 /// Keeps the session alive.
4214 /// @param current The Current object of the incoming request.
4215 virtual void keepAlive(const Ice::Current& current) = 0;
4216
4217 /// @private
4218 void _iceD_keepAlive(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>);
4219
4220 /// Gets a proxy to the IceGrid admin object. The admin object returned by this operation can only be accessed
4221 /// by the session.
4222 /// @param current The Current object of the incoming request.
4223 /// @return A proxy to the IceGrid admin object. This proxy is never null.
4224 [[nodiscard]] virtual std::optional<AdminPrx> getAdmin(const Ice::Current& current) const = 0;
4225
4226 /// @private
4227 void _iceD_getAdmin(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>) const;
4228
4229 /// Gets a "template" proxy for admin callback objects. An Admin client uses this proxy to set the category of
4230 /// its callback objects, and the published endpoints of the object adapter hosting the admin callback objects.
4231 /// @param current The Current object of the incoming request.
4232 /// @return A template proxy. The returned proxy is null when the Admin session was established using Glacier2.
4233 [[nodiscard]] virtual std::optional<Ice::ObjectPrx> getAdminCallbackTemplate(const Ice::Current& current) const = 0;
4234
4235 /// @private
4236 void _iceD_getAdminCallbackTemplate(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>) const;
4237
4238 /// Sets the observer proxies that receive notifications when the state of the registry or nodes changes.
4239 /// @param registryObs The registry observer.
4240 /// @param nodeObs The node observer.
4241 /// @param appObs The application observer.
4242 /// @param adptObs The adapter observer.
4243 /// @param objObs The object observer.
4244 /// @param current The Current object of the incoming request.
4245 /// @throws IceGrid::ObserverAlreadyRegisteredException Thrown when an observer is already registered with this registry.
4246 virtual void setObservers(std::optional<RegistryObserverPrx> registryObs, std::optional<NodeObserverPrx> nodeObs, std::optional<ApplicationObserverPrx> appObs, std::optional<AdapterObserverPrx> adptObs, std::optional<ObjectObserverPrx> objObs, const Ice::Current& current) = 0;
4247
4248 /// @private
4249 void _iceD_setObservers(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>);
4250
4251 /// Sets the observer identities that receive notifications when the state of the registry or nodes changes.
4252 /// This operation should be used by clients that are using a bidirectional connection to communicate with the
4253 /// session.
4254 /// @param registryObs The registry observer identity.
4255 /// @param nodeObs The node observer identity.
4256 /// @param appObs The application observer.
4257 /// @param adptObs The adapter observer.
4258 /// @param objObs The object observer.
4259 /// @param current The Current object of the incoming request.
4260 /// @throws IceGrid::ObserverAlreadyRegisteredException Thrown when an observer is already registered with this registry.
4261 virtual void setObserversByIdentity(::Ice::Identity registryObs, ::Ice::Identity nodeObs, ::Ice::Identity appObs, ::Ice::Identity adptObs, ::Ice::Identity objObs, const Ice::Current& current) = 0;
4262
4263 /// @private
4264 void _iceD_setObserversByIdentity(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>);
4265
4266 /// Acquires an exclusive lock to start updating the registry applications.
4267 /// @param current The Current object of the incoming request.
4268 /// @return The current serial.
4269 /// @throws IceGrid::AccessDeniedException Thrown when the exclusive lock can't be acquired. This might happen if the
4270 /// lock is currently acquired by another session.
4271 virtual std::int32_t startUpdate(const Ice::Current& current) = 0;
4272
4273 /// @private
4274 void _iceD_startUpdate(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>);
4275
4276 /// Finishes updating the registry and releases the exclusive lock.
4277 /// @param current The Current object of the incoming request.
4278 /// @throws IceGrid::AccessDeniedException Thrown when the session doesn't hold the exclusive lock.
4279 virtual void finishUpdate(const Ice::Current& current) = 0;
4280
4281 /// @private
4282 void _iceD_finishUpdate(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>);
4283
4284 /// Gets the name of the registry replica hosting this session.
4285 /// @param current The Current object of the incoming request.
4286 /// @return The replica name of the registry.
4287 [[nodiscard]] virtual std::string getReplicaName(const Ice::Current& current) const = 0;
4288
4289 /// @private
4290 void _iceD_getReplicaName(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>) const;
4291
4292 /// Opens a server log file for reading.
4293 /// @param id The server ID.
4294 /// @param path The path of the log file. A log file can be opened only if it's declared in the server or
4295 /// service deployment descriptor.
4296 /// @param count Specifies where to start reading the file. If negative, the file is read from the beginning.
4297 /// Otherwise, the file is read from the last @p count lines.
4298 /// @param current The Current object of the incoming request.
4299 /// @return An iterator to read the file. This proxy is never null.
4300 /// @throws IceGrid::DeploymentException Thrown when the server couldn't be deployed on the node.
4301 /// @throws IceGrid::FileNotAvailableException Thrown when the file can't be read.
4302 /// @throws IceGrid::NodeUnreachableException Thrown when the node is unreachable.
4303 /// @throws IceGrid::ServerNotExistException Thrown when the server doesn't exist.
4304 virtual std::optional<FileIteratorPrx> openServerLog(std::string id, std::string path, std::int32_t count, const Ice::Current& current) = 0;
4305
4306 /// @private
4307 void _iceD_openServerLog(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>);
4308
4309 /// Opens a server stderr file for reading.
4310 /// @param id The server ID.
4311 /// @param count Specifies where to start reading the file. If negative, the file is read from the beginning.
4312 /// Otherwise, the file is read from the last @p count lines.
4313 /// @param current The Current object of the incoming request.
4314 /// @return An iterator to read the file. This proxy is never null.
4315 /// @throws IceGrid::DeploymentException Thrown when the server couldn't be deployed on the node.
4316 /// @throws IceGrid::FileNotAvailableException Thrown when the file can't be read.
4317 /// @throws IceGrid::NodeUnreachableException Thrown when the node is unreachable.
4318 /// @throws IceGrid::ServerNotExistException Thrown when the server doesn't exist.
4319 virtual std::optional<FileIteratorPrx> openServerStdErr(std::string id, std::int32_t count, const Ice::Current& current) = 0;
4320
4321 /// @private
4322 void _iceD_openServerStdErr(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>);
4323
4324 /// Opens a server stdout file for reading.
4325 /// @param id The server id.
4326 /// @param count Specifies where to start reading the file. If negative, the file is read from the beginning.
4327 /// Otherwise, the file is read from the last @p count lines.
4328 /// @param current The Current object of the incoming request.
4329 /// @return An iterator to read the file. This proxy is never null.
4330 /// @throws IceGrid::DeploymentException Thrown when the server couldn't be deployed on the node.
4331 /// @throws IceGrid::FileNotAvailableException Thrown when the file can't be read.
4332 /// @throws IceGrid::NodeUnreachableException Thrown when the node is unreachable.
4333 /// @throws IceGrid::ServerNotExistException Thrown when the server doesn't exist.
4334 virtual std::optional<FileIteratorPrx> openServerStdOut(std::string id, std::int32_t count, const Ice::Current& current) = 0;
4335
4336 /// @private
4337 void _iceD_openServerStdOut(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>);
4338
4339 /// Opens a node stderr file for reading.
4340 /// @param name The node name.
4341 /// @param count Specifies where to start reading the file. If negative, the file is read from the beginning.
4342 /// Otherwise, the file is read from the last @p count lines.
4343 /// @param current The Current object of the incoming request.
4344 /// @return An iterator to read the file. This proxy is never null.
4345 /// @throws IceGrid::FileNotAvailableException Thrown when the file can't be read.
4346 /// @throws IceGrid::NodeNotExistException Thrown when the node doesn't exist.
4347 /// @throws IceGrid::NodeUnreachableException Thrown when the node is unreachable.
4348 virtual std::optional<FileIteratorPrx> openNodeStdErr(std::string name, std::int32_t count, const Ice::Current& current) = 0;
4349
4350 /// @private
4351 void _iceD_openNodeStdErr(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>);
4352
4353 /// Opens a node stdout file for reading.
4354 /// @param name The node name.
4355 /// @param count Specifies where to start reading the file. If negative, the file is read from the beginning.
4356 /// Otherwise, the file is read from the last @p count lines.
4357 /// @param current The Current object of the incoming request.
4358 /// @return An iterator to read the file. This proxy is never null.
4359 /// @throws IceGrid::FileNotAvailableException Thrown when the file can't be read.
4360 /// @throws IceGrid::NodeNotExistException Thrown when the node doesn't exist.
4361 /// @throws IceGrid::NodeUnreachableException Thrown when the node is unreachable.
4362 virtual std::optional<FileIteratorPrx> openNodeStdOut(std::string name, std::int32_t count, const Ice::Current& current) = 0;
4363
4364 /// @private
4365 void _iceD_openNodeStdOut(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>);
4366
4367 /// Opens a registry stderr file for reading.
4368 /// @param name The registry name.
4369 /// @param count Specifies where to start reading the file. If negative, the file is read from the beginning.
4370 /// Otherwise, the file is read from the last @p count lines.
4371 /// @param current The Current object of the incoming request.
4372 /// @return An iterator to read the file. This proxy is never null.
4373 /// @throws IceGrid::FileNotAvailableException Thrown when the file can't be read.
4374 /// @throws IceGrid::RegistryNotExistException Thrown when the registry doesn't exist.
4375 /// @throws IceGrid::RegistryUnreachableException Thrown when the registry is unreachable.
4376 virtual std::optional<FileIteratorPrx> openRegistryStdErr(std::string name, std::int32_t count, const Ice::Current& current) = 0;
4377
4378 /// @private
4379 void _iceD_openRegistryStdErr(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>);
4380
4381 /// Opens a registry stdout file for reading.
4382 /// @param name The registry name.
4383 /// @param count Specifies where to start reading the file. If negative, the file is read from the beginning.
4384 /// Otherwise, the file is read from the last @p count lines.
4385 /// @param current The Current object of the incoming request.
4386 /// @return An iterator to read the file. This proxy is never null.
4387 /// @throws IceGrid::FileNotAvailableException Thrown when the file can't be read.
4388 /// @throws IceGrid::RegistryNotExistException Thrown when the registry doesn't exist.
4389 /// @throws IceGrid::RegistryUnreachableException Thrown when the registry is unreachable.
4390 virtual std::optional<FileIteratorPrx> openRegistryStdOut(std::string name, std::int32_t count, const Ice::Current& current) = 0;
4391
4392 /// @private
4393 void _iceD_openRegistryStdOut(Ice::IncomingRequest&, std::function<void(Ice::OutgoingResponse)>);
4394
4395 /// Gets the type ID of the associated Slice interface.
4396 /// @return The string `"::IceGrid::AdminSession"`.
4397 static const char* ice_staticId() noexcept;
4398 };
4399
4400 /// A shared pointer to an AdminSession.
4401 using AdminSessionPtr = std::shared_ptr<AdminSession>;
4402}
4403
4404namespace Ice
4405{
4406 /// @cond INTERNAL
4407 template<>
4408 struct StreamableTraits<::IceGrid::ServerState>
4409 {
4410 static constexpr StreamHelperCategory helper = StreamHelperCategoryEnum;
4411 static constexpr int minValue = 0;
4412 static constexpr int maxValue = 6;
4413 static constexpr int minWireSize = 1;
4414 static constexpr bool fixedLength = false;
4415 };
4416 /// @endcond
4417
4418 /// @cond INTERNAL
4419 template<>
4420 struct StreamableTraits<::IceGrid::ObjectInfo>
4421 {
4422 static constexpr StreamHelperCategory helper = StreamHelperCategoryStruct;
4423 static constexpr int minWireSize = 3;
4424 static constexpr bool fixedLength = false;
4425 };
4426
4427 template<>
4428 struct StreamReader<::IceGrid::ObjectInfo>
4429 {
4430 /// Unmarshals a ::IceGrid::ObjectInfo from the input stream.
4431 static void read(InputStream* istr, ::IceGrid::ObjectInfo& v)
4432 {
4433 istr->readAll(v.proxy, v.type);
4434 }
4435 };
4436 /// @endcond
4437
4438 /// @cond INTERNAL
4439 template<>
4440 struct StreamableTraits<::IceGrid::AdapterInfo>
4441 {
4442 static constexpr StreamHelperCategory helper = StreamHelperCategoryStruct;
4443 static constexpr int minWireSize = 4;
4444 static constexpr bool fixedLength = false;
4445 };
4446
4447 template<>
4448 struct StreamReader<::IceGrid::AdapterInfo>
4449 {
4450 /// Unmarshals a ::IceGrid::AdapterInfo from the input stream.
4451 static void read(InputStream* istr, ::IceGrid::AdapterInfo& v)
4452 {
4453 istr->readAll(v.id, v.proxy, v.replicaGroupId);
4454 }
4455 };
4456 /// @endcond
4457
4458 /// @cond INTERNAL
4459 template<>
4460 struct StreamableTraits<::IceGrid::ServerInfo>
4461 {
4462 static constexpr StreamHelperCategory helper = StreamHelperCategoryStruct;
4463 static constexpr int minWireSize = 9;
4464 static constexpr bool fixedLength = false;
4465 };
4466
4467 template<>
4468 struct StreamReader<::IceGrid::ServerInfo>
4469 {
4470 /// Unmarshals a ::IceGrid::ServerInfo from the input stream.
4471 static void read(InputStream* istr, ::IceGrid::ServerInfo& v)
4472 {
4473 istr->readAll(v.application, v.uuid, v.revision, v.node, v.descriptor, v.sessionId);
4474 }
4475 };
4476 /// @endcond
4477
4478 /// @cond INTERNAL
4479 template<>
4480 struct StreamableTraits<::IceGrid::NodeInfo>
4481 {
4482 static constexpr StreamHelperCategory helper = StreamHelperCategoryStruct;
4483 static constexpr int minWireSize = 11;
4484 static constexpr bool fixedLength = false;
4485 };
4486
4487 template<>
4488 struct StreamReader<::IceGrid::NodeInfo>
4489 {
4490 /// Unmarshals a ::IceGrid::NodeInfo from the input stream.
4491 static void read(InputStream* istr, ::IceGrid::NodeInfo& v)
4492 {
4493 istr->readAll(v.name, v.os, v.hostname, v.release, v.version, v.machine, v.nProcessors, v.dataDir);
4494 }
4495 };
4496 /// @endcond
4497
4498 /// @cond INTERNAL
4499 template<>
4500 struct StreamableTraits<::IceGrid::RegistryInfo>
4501 {
4502 static constexpr StreamHelperCategory helper = StreamHelperCategoryStruct;
4503 static constexpr int minWireSize = 2;
4504 static constexpr bool fixedLength = false;
4505 };
4506
4507 template<>
4508 struct StreamReader<::IceGrid::RegistryInfo>
4509 {
4510 /// Unmarshals a ::IceGrid::RegistryInfo from the input stream.
4511 static void read(InputStream* istr, ::IceGrid::RegistryInfo& v)
4512 {
4513 istr->readAll(v.name, v.hostname);
4514 }
4515 };
4516 /// @endcond
4517
4518 /// @cond INTERNAL
4519 template<>
4520 struct StreamableTraits<::IceGrid::LoadInfo>
4521 {
4522 static constexpr StreamHelperCategory helper = StreamHelperCategoryStruct;
4523 static constexpr int minWireSize = 12;
4524 static constexpr bool fixedLength = true;
4525 };
4526
4527 template<>
4528 struct StreamReader<::IceGrid::LoadInfo>
4529 {
4530 /// Unmarshals a ::IceGrid::LoadInfo from the input stream.
4531 static void read(InputStream* istr, ::IceGrid::LoadInfo& v)
4532 {
4533 istr->readAll(v.avg1, v.avg5, v.avg15);
4534 }
4535 };
4536 /// @endcond
4537
4538 /// @cond INTERNAL
4539 template<>
4540 struct StreamableTraits<::IceGrid::ApplicationInfo>
4541 {
4542 static constexpr StreamHelperCategory helper = StreamHelperCategoryStruct;
4543 static constexpr int minWireSize = 33;
4544 static constexpr bool fixedLength = false;
4545 };
4546
4547 template<>
4548 struct StreamReader<::IceGrid::ApplicationInfo>
4549 {
4550 /// Unmarshals a ::IceGrid::ApplicationInfo from the input stream.
4551 static void read(InputStream* istr, ::IceGrid::ApplicationInfo& v)
4552 {
4553 istr->readAll(v.uuid, v.createTime, v.createUser, v.updateTime, v.updateUser, v.revision, v.descriptor);
4554 }
4555 };
4556 /// @endcond
4557
4558 /// @cond INTERNAL
4559 template<>
4560 struct StreamableTraits<::IceGrid::ApplicationUpdateInfo>
4561 {
4562 static constexpr StreamHelperCategory helper = StreamHelperCategoryStruct;
4563 static constexpr int minWireSize = 28;
4564 static constexpr bool fixedLength = false;
4565 };
4566
4567 template<>
4568 struct StreamReader<::IceGrid::ApplicationUpdateInfo>
4569 {
4570 /// Unmarshals a ::IceGrid::ApplicationUpdateInfo from the input stream.
4571 static void read(InputStream* istr, ::IceGrid::ApplicationUpdateInfo& v)
4572 {
4573 istr->readAll(v.updateTime, v.updateUser, v.revision, v.descriptor);
4574 }
4575 };
4576 /// @endcond
4577
4578 /// @cond INTERNAL
4579 template<>
4580 struct StreamableTraits<::IceGrid::ServerDynamicInfo>
4581 {
4582 static constexpr StreamHelperCategory helper = StreamHelperCategoryStruct;
4583 static constexpr int minWireSize = 7;
4584 static constexpr bool fixedLength = false;
4585 };
4586
4587 template<>
4588 struct StreamReader<::IceGrid::ServerDynamicInfo>
4589 {
4590 /// Unmarshals a ::IceGrid::ServerDynamicInfo from the input stream.
4591 static void read(InputStream* istr, ::IceGrid::ServerDynamicInfo& v)
4592 {
4593 istr->readAll(v.id, v.state, v.pid, v.enabled);
4594 }
4595 };
4596 /// @endcond
4597
4598 /// @cond INTERNAL
4599 template<>
4600 struct StreamableTraits<::IceGrid::AdapterDynamicInfo>
4601 {
4602 static constexpr StreamHelperCategory helper = StreamHelperCategoryStruct;
4603 static constexpr int minWireSize = 3;
4604 static constexpr bool fixedLength = false;
4605 };
4606
4607 template<>
4608 struct StreamReader<::IceGrid::AdapterDynamicInfo>
4609 {
4610 /// Unmarshals a ::IceGrid::AdapterDynamicInfo from the input stream.
4611 static void read(InputStream* istr, ::IceGrid::AdapterDynamicInfo& v)
4612 {
4613 istr->readAll(v.id, v.proxy);
4614 }
4615 };
4616 /// @endcond
4617
4618 /// @cond INTERNAL
4619 template<>
4620 struct StreamableTraits<::IceGrid::NodeDynamicInfo>
4621 {
4622 static constexpr StreamHelperCategory helper = StreamHelperCategoryStruct;
4623 static constexpr int minWireSize = 13;
4624 static constexpr bool fixedLength = false;
4625 };
4626
4627 template<>
4628 struct StreamReader<::IceGrid::NodeDynamicInfo>
4629 {
4630 /// Unmarshals a ::IceGrid::NodeDynamicInfo from the input stream.
4631 static void read(InputStream* istr, ::IceGrid::NodeDynamicInfo& v)
4632 {
4633 istr->readAll(v.info, v.servers, v.adapters);
4634 }
4635 };
4636 /// @endcond
4637}
4638
4639// NOLINTEND(modernize-concat-nested-namespaces)
4640
4641#include <Ice/PopDisableWarnings.h>
4642#endif
std::future< void > adapterAddedAsync(const AdapterInfo &info, const Ice::Context &context=Ice::noExplicitContext) const
Notifies the observer that a dynamically-registered adapter was added.
void adapterUpdated(const AdapterInfo &info, const Ice::Context &context=Ice::noExplicitContext) const
std::future< void > adapterUpdatedAsync(const AdapterInfo &info, const Ice::Context &context=Ice::noExplicitContext) const
AdapterObserverPrx(AdapterObserverPrx &&other) noexcept
Move constructor.
Definition Admin.h:2102
std::function< void()> adapterUpdatedAsync(const AdapterInfo &info, std::function< void()> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
void adapterInit(const AdapterInfoSeq &adpts, const Ice::Context &context=Ice::noExplicitContext) const
Provides the initial list of dynamically registered adapters to the observer.
static const char * ice_staticId() noexcept
Gets the type ID of the associated Slice interface.
std::function< void()> adapterAddedAsync(const AdapterInfo &info, std::function< void()> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Notifies the observer that a dynamically-registered adapter was added.
void adapterRemoved(std::string_view id, const Ice::Context &context=Ice::noExplicitContext) const
Notifies the observer that a dynamically-registered adapter was removed.
AdapterObserverPrx & operator=(const AdapterObserverPrx &rhs) noexcept
Copy assignment operator.
Definition Admin.h:2109
AdapterObserverPrx & operator=(AdapterObserverPrx &&rhs) noexcept
Move assignment operator.
Definition Admin.h:2120
std::future< void > adapterInitAsync(const AdapterInfoSeq &adpts, const Ice::Context &context=Ice::noExplicitContext) const
Provides the initial list of dynamically registered adapters to the observer.
std::function< void()> adapterInitAsync(const AdapterInfoSeq &adpts, std::function< void()> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Provides the initial list of dynamically registered adapters to the observer.
std::function< void()> adapterRemovedAsync(std::string_view id, std::function< void()> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Notifies the observer that a dynamically-registered adapter was removed.
AdapterObserverPrx(const Ice::CommunicatorPtr &communicator, std::string_view proxyString)
Constructs a proxy from a Communicator and a proxy string.
Definition Admin.h:2094
AdapterObserverPrx(const AdapterObserverPrx &other) noexcept
Copy constructor.
Definition Admin.h:2098
void adapterAdded(const AdapterInfo &info, const Ice::Context &context=Ice::noExplicitContext) const
Notifies the observer that a dynamically-registered adapter was added.
std::future< void > adapterRemovedAsync(std::string_view id, const Ice::Context &context=Ice::noExplicitContext) const
Notifies the observer that a dynamically-registered adapter was removed.
Monitors dynamically-registered object adapters.
Definition Admin.h:2089
std::vector< std::string > ice_ids(const Ice::Current &current) const override
Gets the Slice interfaces supported by this object as a list of type IDs.
virtual void adapterUpdated(AdapterInfo info, const Ice::Current &current)=0
virtual void adapterAdded(AdapterInfo info, const Ice::Current &current)=0
Notifies the observer that a dynamically-registered adapter was added.
virtual void adapterInit(AdapterInfoSeq adpts, const Ice::Current &current)=0
Provides the initial list of dynamically registered adapters to the observer.
virtual void adapterRemoved(std::string id, const Ice::Current &current)=0
Notifies the observer that a dynamically-registered adapter was removed.
static const char * ice_staticId() noexcept
Gets the type ID of the associated Slice interface.
std::string ice_id(const Ice::Current &current) const override
Gets the type ID of the most-derived Slice interface supported by this object.
void dispatch(Ice::IncomingRequest &request, std::function< void(Ice::OutgoingResponse)> sendResponse) override
Dispatches an incoming request to one of the member functions of this generated class,...
AdapterObserverPrx ProxyType
The associated proxy type.
Definition Admin.h:4088
Monitors dynamically-registered object adapters.
Definition Admin.h:4085
ObjectInfoSeq getObjectInfosByType(std::string_view type, const Ice::Context &context=Ice::noExplicitContext) const
Gets the object info of all the registered objects with a given type.
void startServer(std::string_view id, const Ice::Context &context=Ice::noExplicitContext) const
Starts a server and waits for its activation.
void syncApplicationWithoutRestart(const ApplicationDescriptor &descriptor, const Ice::Context &context=Ice::noExplicitContext) const
Synchronizes a deployed application.
::Ice::StringSeq getAllNodeNames(const Ice::Context &context=Ice::noExplicitContext) const
Gets the names of all IceGrid nodes currently registered.
void shutdownRegistry(std::string_view name, const Ice::Context &context=Ice::noExplicitContext) const
Shuts down an IceGrid registry.
void stopServer(std::string_view id, const Ice::Context &context=Ice::noExplicitContext) const
Stops a server.
std::future<::Ice::StringSeq > getAllAdapterIdsAsync(const Ice::Context &context=Ice::noExplicitContext) const
Gets the IDs of all adapters registered with IceGrid.
void enableServer(std::string_view id, bool enabled, const Ice::Context &context=Ice::noExplicitContext) const
Enables or disables a server.
std::function< void()> shutdownAsync(std::function< void()> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Shuts down the IceGrid registry.
std::future< void > updateObjectAsync(const std::optional< Ice::ObjectPrx > &obj, const Ice::Context &context=Ice::noExplicitContext) const
Updates an object in the object registry.
std::future< std::int32_t > getServerPidAsync(std::string_view id, const Ice::Context &context=Ice::noExplicitContext) const
Gets the system process ID of a server.
std::function< void()> removeObjectAsync(const ::Ice::Identity &id, std::function< void()> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Removes an object from the object registry.
LoadInfo getNodeLoad(std::string_view name, const Ice::Context &context=Ice::noExplicitContext) const
Gets the load averages of a node.
void addApplication(const ApplicationDescriptor &descriptor, const Ice::Context &context=Ice::noExplicitContext) const
Adds an application to IceGrid.
std::future< void > removeApplicationAsync(std::string_view name, const Ice::Context &context=Ice::noExplicitContext) const
Removes an application from IceGrid.
::Ice::StringSeq getAllAdapterIds(const Ice::Context &context=Ice::noExplicitContext) const
Gets the IDs of all adapters registered with IceGrid.
std::future< std::optional< Ice::ObjectPrx > > getNodeAdminAsync(std::string_view name, const Ice::Context &context=Ice::noExplicitContext) const
Gets a proxy to the admin object of an IceGrid node.
std::int32_t getServerPid(std::string_view id, const Ice::Context &context=Ice::noExplicitContext) const
Gets the system process ID of a server.
std::future< void > addObjectWithTypeAsync(const std::optional< Ice::ObjectPrx > &obj, std::string_view type, const Ice::Context &context=Ice::noExplicitContext) const
Adds an object to the object registry and explicitly specifies its type.
std::future< bool > isServerEnabledAsync(std::string_view id, const Ice::Context &context=Ice::noExplicitContext) const
Checks if the server is enabled or disabled.
std::function< void()> addObjectWithTypeAsync(const std::optional< Ice::ObjectPrx > &obj, std::string_view type, std::function< void()> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Adds an object to the object registry and explicitly specifies its type.
void updateApplicationWithoutRestart(const ApplicationUpdateDescriptor &descriptor, const Ice::Context &context=Ice::noExplicitContext) const
Updates a deployed application.
std::int32_t getNodeProcessorSocketCount(std::string_view name, const Ice::Context &context=Ice::noExplicitContext) const
Gets the number of physical processor sockets in the computer where an IceGrid node is deployed.
std::future< RegistryInfo > getRegistryInfoAsync(std::string_view name, const Ice::Context &context=Ice::noExplicitContext) const
Gets the registry information of an IceGrid registry.
std::future< ServerState > getServerStateAsync(std::string_view id, const Ice::Context &context=Ice::noExplicitContext) const
Gets the state of a server.
std::future< ServerInfo > getServerInfoAsync(std::string_view id, const Ice::Context &context=Ice::noExplicitContext) const
Gets information about a server.
std::optional< Ice::ObjectPrx > getServerAdmin(std::string_view id, const Ice::Context &context=Ice::noExplicitContext) const
Gets a proxy to the admin object of a server.
std::function< void()> getNodeLoadAsync(std::string_view name, std::function< void(::IceGrid::LoadInfo)> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Gets the load averages of a node.
std::string getNodeHostname(std::string_view name, const Ice::Context &context=Ice::noExplicitContext) const
Get the hostname of a node.
std::optional< Ice::ObjectPrx > getNodeAdmin(std::string_view name, const Ice::Context &context=Ice::noExplicitContext) const
Gets a proxy to the admin object of an IceGrid node.
std::function< void()> pingNodeAsync(std::string_view name, std::function< void(bool)> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Pings an IceGrid node to see if it is active.
std::future< std::optional< Ice::ObjectPrx > > getServerAdminAsync(std::string_view id, const Ice::Context &context=Ice::noExplicitContext) const
Gets a proxy to the admin object of a server.
std::function< void()> updateApplicationAsync(const ApplicationUpdateDescriptor &descriptor, std::function< void()> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Updates a deployed application.
std::future< ObjectInfo > getObjectInfoAsync(const ::Ice::Identity &id, const Ice::Context &context=Ice::noExplicitContext) const
Gets the object info for the object.
std::function< void()> getRegistryAdminAsync(std::string_view name, std::function< void(std::optional< Ice::ObjectPrx >)> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Gets a proxy to the admin object of an IceGrid registry.
NodeInfo getNodeInfo(std::string_view name, const Ice::Context &context=Ice::noExplicitContext) const
Gets the node information of a node.
std::function< void()> getAllObjectInfosAsync(std::string_view expr, std::function< void(::IceGrid::ObjectInfoSeq)> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Gets the object info of all the registered objects whose stringified identities match the given expre...
std::future<::Ice::StringSeq > getAllRegistryNamesAsync(const Ice::Context &context=Ice::noExplicitContext) const
Gets the names of all the IceGrid registries currently registered.
void shutdown(const Ice::Context &context=Ice::noExplicitContext) const
Shuts down the IceGrid registry.
std::function< void()> getAdapterInfoAsync(std::string_view id, std::function< void(::IceGrid::AdapterInfoSeq)> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Gets adapter information for the replica group or adapter with the given ID.
RegistryInfo getRegistryInfo(std::string_view name, const Ice::Context &context=Ice::noExplicitContext) const
Gets the registry information of an IceGrid registry.
std::future< std::string > getNodeHostnameAsync(std::string_view name, const Ice::Context &context=Ice::noExplicitContext) const
Get the hostname of a node.
std::function< void()> getNodeInfoAsync(std::string_view name, std::function< void(::IceGrid::NodeInfo)> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Gets the node information of a node.
bool pingNode(std::string_view name, const Ice::Context &context=Ice::noExplicitContext) const
Pings an IceGrid node to see if it is active.
std::function< void()> getAllAdapterIdsAsync(std::function< void(::Ice::StringSeq)> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Gets the IDs of all adapters registered with IceGrid.
std::function< void()> getObjectInfoAsync(const ::Ice::Identity &id, std::function< void(::IceGrid::ObjectInfo)> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Gets the object info for the object.
std::future< bool > pingRegistryAsync(std::string_view name, const Ice::Context &context=Ice::noExplicitContext) const
Pings an IceGrid registry to see if it is active.
std::future< std::optional< Ice::ObjectPrx > > getRegistryAdminAsync(std::string_view name, const Ice::Context &context=Ice::noExplicitContext) const
Gets a proxy to the admin object of an IceGrid registry.
std::future< void > shutdownAsync(const Ice::Context &context=Ice::noExplicitContext) const
Shuts down the IceGrid registry.
std::function< void()> getDefaultApplicationDescriptorAsync(std::function< void(::IceGrid::ApplicationDescriptor)> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Gets the default application descriptor.
std::function< void()> getNodeAdminAsync(std::string_view name, std::function< void(std::optional< Ice::ObjectPrx >)> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Gets a proxy to the admin object of an IceGrid node.
::Ice::StringSeq getAllRegistryNames(const Ice::Context &context=Ice::noExplicitContext) const
Gets the names of all the IceGrid registries currently registered.
void updateObject(const std::optional< Ice::ObjectPrx > &obj, const Ice::Context &context=Ice::noExplicitContext) const
Updates an object in the object registry.
std::future< std::string > getServerAdminCategoryAsync(const Ice::Context &context=Ice::noExplicitContext) const
Gets the category for server admin objects.
std::future< void > removeAdapterAsync(std::string_view id, const Ice::Context &context=Ice::noExplicitContext) const
Removes the adapter with the given ID.
std::future< void > shutdownNodeAsync(std::string_view name, const Ice::Context &context=Ice::noExplicitContext) const
Shuts down an IceGrid node.
ApplicationInfo getApplicationInfo(std::string_view name, const Ice::Context &context=Ice::noExplicitContext) const
Gets an application descriptor.
std::future< LoadInfo > getNodeLoadAsync(std::string_view name, const Ice::Context &context=Ice::noExplicitContext) const
Gets the load averages of a node.
std::function< void()> getServerAdminAsync(std::string_view id, std::function< void(std::optional< Ice::ObjectPrx >)> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Gets a proxy to the admin object of a server.
std::function< void()> getNodeProcessorSocketCountAsync(std::string_view name, std::function< void(std::int32_t)> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Gets the number of physical processor sockets in the computer where an IceGrid node is deployed.
std::future< void > sendSignalAsync(std::string_view id, std::string_view signal, const Ice::Context &context=Ice::noExplicitContext) const
Sends a signal to a server.
std::function< void()> getServerStateAsync(std::string_view id, std::function< void(::IceGrid::ServerState)> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Gets the state of a server.
std::function< void()> updateObjectAsync(const std::optional< Ice::ObjectPrx > &obj, std::function< void()> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Updates an object in the object registry.
std::optional< Ice::ObjectPrx > getRegistryAdmin(std::string_view name, const Ice::Context &context=Ice::noExplicitContext) const
Gets a proxy to the admin object of an IceGrid registry.
std::function< void()> enableServerAsync(std::string_view id, bool enabled, std::function< void()> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Enables or disables a server.
bool isServerEnabled(std::string_view id, const Ice::Context &context=Ice::noExplicitContext) const
Checks if the server is enabled or disabled.
std::future< void > enableServerAsync(std::string_view id, bool enabled, const Ice::Context &context=Ice::noExplicitContext) const
Enables or disables a server.
std::function< void()> syncApplicationWithoutRestartAsync(const ApplicationDescriptor &descriptor, std::function< void()> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Synchronizes a deployed application.
std::function< void()> isServerEnabledAsync(std::string_view id, std::function< void(bool)> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Checks if the server is enabled or disabled.
AdapterInfoSeq getAdapterInfo(std::string_view id, const Ice::Context &context=Ice::noExplicitContext) const
Gets adapter information for the replica group or adapter with the given ID.
void removeObject(const ::Ice::Identity &id, const Ice::Context &context=Ice::noExplicitContext) const
Removes an object from the object registry.
std::function< void()> getAllServerIdsAsync(std::function< void(::Ice::StringSeq)> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Gets the IDs of all the servers registered with IceGrid.
std::future<::Ice::StringSeq > getAllApplicationNamesAsync(const Ice::Context &context=Ice::noExplicitContext) const
Gets all the IceGrid applications currently registered.
void shutdownNode(std::string_view name, const Ice::Context &context=Ice::noExplicitContext) const
Shuts down an IceGrid node.
ServerInfo getServerInfo(std::string_view id, const Ice::Context &context=Ice::noExplicitContext) const
Gets information about a server.
std::string getServerAdminCategory(const Ice::Context &context=Ice::noExplicitContext) const
Gets the category for server admin objects.
std::function< void()> addApplicationAsync(const ApplicationDescriptor &descriptor, std::function< void()> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Adds an application to IceGrid.
void addObject(const std::optional< Ice::ObjectPrx > &obj, const Ice::Context &context=Ice::noExplicitContext) const
Adds an object to the object registry.
AdminPrx & operator=(const AdminPrx &rhs) noexcept
Copy assignment operator.
Definition Admin.h:157
bool pingRegistry(std::string_view name, const Ice::Context &context=Ice::noExplicitContext) const
Pings an IceGrid registry to see if it is active.
std::function< void()> removeAdapterAsync(std::string_view id, std::function< void()> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Removes the adapter with the given ID.
::Ice::StringSeq getAllApplicationNames(const Ice::Context &context=Ice::noExplicitContext) const
Gets all the IceGrid applications currently registered.
std::future< void > stopServerAsync(std::string_view id, const Ice::Context &context=Ice::noExplicitContext) const
Stops a server.
void updateApplication(const ApplicationUpdateDescriptor &descriptor, const Ice::Context &context=Ice::noExplicitContext) const
Updates a deployed application.
std::function< void()> getAllNodeNamesAsync(std::function< void(::Ice::StringSeq)> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Gets the names of all IceGrid nodes currently registered.
std::function< void()> instantiateServerAsync(std::string_view application, std::string_view node, const ServerInstanceDescriptor &desc, std::function< void()> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Instantiates a server template.
std::future<::Ice::StringSeq > getAllServerIdsAsync(const Ice::Context &context=Ice::noExplicitContext) const
Gets the IDs of all the servers registered with IceGrid.
std::function< void()> shutdownNodeAsync(std::string_view name, std::function< void()> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Shuts down an IceGrid node.
ServerState getServerState(std::string_view id, const Ice::Context &context=Ice::noExplicitContext) const
Gets the state of a server.
std::future< std::int32_t > getNodeProcessorSocketCountAsync(std::string_view name, const Ice::Context &context=Ice::noExplicitContext) const
Gets the number of physical processor sockets in the computer where an IceGrid node is deployed.
std::function< void()> getServerAdminCategoryAsync(std::function< void(std::string)> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Gets the category for server admin objects.
std::function< void()> shutdownRegistryAsync(std::string_view name, std::function< void()> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Shuts down an IceGrid registry.
std::future< void > startServerAsync(std::string_view id, const Ice::Context &context=Ice::noExplicitContext) const
Starts a server and waits for its activation.
std::future< void > syncApplicationAsync(const ApplicationDescriptor &descriptor, const Ice::Context &context=Ice::noExplicitContext) const
Synchronizes a deployed application.
std::function< void()> updateApplicationWithoutRestartAsync(const ApplicationUpdateDescriptor &descriptor, std::function< void()> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Updates a deployed application.
std::future< ApplicationInfo > getApplicationInfoAsync(std::string_view name, const Ice::Context &context=Ice::noExplicitContext) const
Gets an application descriptor.
void removeAdapter(std::string_view id, const Ice::Context &context=Ice::noExplicitContext) const
Removes the adapter with the given ID.
std::future< void > shutdownRegistryAsync(std::string_view name, const Ice::Context &context=Ice::noExplicitContext) const
Shuts down an IceGrid registry.
std::future< AdapterInfoSeq > getAdapterInfoAsync(std::string_view id, const Ice::Context &context=Ice::noExplicitContext) const
Gets adapter information for the replica group or adapter with the given ID.
std::function< void()> getApplicationInfoAsync(std::string_view name, std::function< void(::IceGrid::ApplicationInfo)> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Gets an application descriptor.
std::future< bool > pingNodeAsync(std::string_view name, const Ice::Context &context=Ice::noExplicitContext) const
Pings an IceGrid node to see if it is active.
std::future< ApplicationDescriptor > getDefaultApplicationDescriptorAsync(const Ice::Context &context=Ice::noExplicitContext) const
Gets the default application descriptor.
std::function< void()> startServerAsync(std::string_view id, std::function< void()> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Starts a server and waits for its activation.
std::future< void > addApplicationAsync(const ApplicationDescriptor &descriptor, const Ice::Context &context=Ice::noExplicitContext) const
Adds an application to IceGrid.
void sendSignal(std::string_view id, std::string_view signal, const Ice::Context &context=Ice::noExplicitContext) const
Sends a signal to a server.
std::function< void()> pingRegistryAsync(std::string_view name, std::function< void(bool)> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Pings an IceGrid registry to see if it is active.
std::future< void > updateApplicationWithoutRestartAsync(const ApplicationUpdateDescriptor &descriptor, const Ice::Context &context=Ice::noExplicitContext) const
Updates a deployed application.
std::future< NodeInfo > getNodeInfoAsync(std::string_view name, const Ice::Context &context=Ice::noExplicitContext) const
Gets the node information of a node.
AdminPrx(const Ice::CommunicatorPtr &communicator, std::string_view proxyString)
Constructs a proxy from a Communicator and a proxy string.
Definition Admin.h:142
ObjectInfoSeq getAllObjectInfos(std::string_view expr, const Ice::Context &context=Ice::noExplicitContext) const
Gets the object info of all the registered objects whose stringified identities match the given expre...
std::future< void > updateApplicationAsync(const ApplicationUpdateDescriptor &descriptor, const Ice::Context &context=Ice::noExplicitContext) const
Updates a deployed application.
void addObjectWithType(const std::optional< Ice::ObjectPrx > &obj, std::string_view type, const Ice::Context &context=Ice::noExplicitContext) const
Adds an object to the object registry and explicitly specifies its type.
std::function< void()> removeApplicationAsync(std::string_view name, std::function< void()> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Removes an application from IceGrid.
AdminPrx(const AdminPrx &other) noexcept
Copy constructor.
Definition Admin.h:146
static const char * ice_staticId() noexcept
Gets the type ID of the associated Slice interface.
std::future< ObjectInfoSeq > getAllObjectInfosAsync(std::string_view expr, const Ice::Context &context=Ice::noExplicitContext) const
Gets the object info of all the registered objects whose stringified identities match the given expre...
std::future<::Ice::StringSeq > getAllNodeNamesAsync(const Ice::Context &context=Ice::noExplicitContext) const
Gets the names of all IceGrid nodes currently registered.
AdminPrx(AdminPrx &&other) noexcept
Move constructor.
Definition Admin.h:150
std::future< ObjectInfoSeq > getObjectInfosByTypeAsync(std::string_view type, const Ice::Context &context=Ice::noExplicitContext) const
Gets the object info of all the registered objects with a given type.
std::function< void()> stopServerAsync(std::string_view id, std::function< void()> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Stops a server.
std::function< void()> getObjectInfosByTypeAsync(std::string_view type, std::function< void(::IceGrid::ObjectInfoSeq)> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Gets the object info of all the registered objects with a given type.
ObjectInfo getObjectInfo(const ::Ice::Identity &id, const Ice::Context &context=Ice::noExplicitContext) const
Gets the object info for the object.
void instantiateServer(std::string_view application, std::string_view node, const ServerInstanceDescriptor &desc, const Ice::Context &context=Ice::noExplicitContext) const
Instantiates a server template.
std::function< void()> getAllApplicationNamesAsync(std::function< void(::Ice::StringSeq)> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Gets all the IceGrid applications currently registered.
AdminPrx & operator=(AdminPrx &&rhs) noexcept
Move assignment operator.
Definition Admin.h:168
std::function< void()> addObjectAsync(const std::optional< Ice::ObjectPrx > &obj, std::function< void()> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Adds an object to the object registry.
std::future< void > addObjectAsync(const std::optional< Ice::ObjectPrx > &obj, const Ice::Context &context=Ice::noExplicitContext) const
Adds an object to the object registry.
std::function< void()> getNodeHostnameAsync(std::string_view name, std::function< void(std::string)> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Get the hostname of a node.
std::future< void > removeObjectAsync(const ::Ice::Identity &id, const Ice::Context &context=Ice::noExplicitContext) const
Removes an object from the object registry.
std::function< void()> getRegistryInfoAsync(std::string_view name, std::function< void(::IceGrid::RegistryInfo)> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Gets the registry information of an IceGrid registry.
std::function< void()> getServerInfoAsync(std::string_view id, std::function< void(::IceGrid::ServerInfo)> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Gets information about a server.
std::function< void()> sendSignalAsync(std::string_view id, std::string_view signal, std::function< void()> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Sends a signal to a server.
std::future< void > syncApplicationWithoutRestartAsync(const ApplicationDescriptor &descriptor, const Ice::Context &context=Ice::noExplicitContext) const
Synchronizes a deployed application.
std::function< void()> getAllRegistryNamesAsync(std::function< void(::Ice::StringSeq)> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Gets the names of all the IceGrid registries currently registered.
ApplicationDescriptor getDefaultApplicationDescriptor(const Ice::Context &context=Ice::noExplicitContext) const
Gets the default application descriptor.
std::future< void > instantiateServerAsync(std::string_view application, std::string_view node, const ServerInstanceDescriptor &desc, const Ice::Context &context=Ice::noExplicitContext) const
Instantiates a server template.
std::function< void()> getServerPidAsync(std::string_view id, std::function< void(std::int32_t)> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Gets the system process ID of a server.
void syncApplication(const ApplicationDescriptor &descriptor, const Ice::Context &context=Ice::noExplicitContext) const
Synchronizes a deployed application.
void removeApplication(std::string_view name, const Ice::Context &context=Ice::noExplicitContext) const
Removes an application from IceGrid.
std::function< void()> syncApplicationAsync(const ApplicationDescriptor &descriptor, std::function< void()> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Synchronizes a deployed application.
::Ice::StringSeq getAllServerIds(const Ice::Context &context=Ice::noExplicitContext) const
Gets the IDs of all the servers registered with IceGrid.
Provides administrative access to an IceGrid deployment.
Definition Admin.h:137
std::function< void()> startUpdateAsync(std::function< void(std::int32_t)> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Acquires an exclusive lock to start updating the registry applications.
std::optional< FileIteratorPrx > openNodeStdOut(std::string_view name, std::int32_t count, const Ice::Context &context=Ice::noExplicitContext) const
Opens a node stdout file for reading.
std::future< void > setObserversAsync(const std::optional< RegistryObserverPrx > &registryObs, const std::optional< NodeObserverPrx > &nodeObs, const std::optional< ApplicationObserverPrx > &appObs, const std::optional< AdapterObserverPrx > &adptObs, const std::optional< ObjectObserverPrx > &objObs, const Ice::Context &context=Ice::noExplicitContext) const
Sets the observer proxies that receive notifications when the state of the registry or nodes changes.
std::function< void()> openServerStdErrAsync(std::string_view id, std::int32_t count, std::function< void(std::optional<::IceGrid::FileIteratorPrx >)> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Opens a server stderr file for reading.
std::function< void()> openServerLogAsync(std::string_view id, std::string_view path, std::int32_t count, std::function< void(std::optional<::IceGrid::FileIteratorPrx >)> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Opens a server log file for reading.
std::future< std::optional< FileIteratorPrx > > openNodeStdOutAsync(std::string_view name, std::int32_t count, const Ice::Context &context=Ice::noExplicitContext) const
Opens a node stdout file for reading.
std::optional< FileIteratorPrx > openNodeStdErr(std::string_view name, std::int32_t count, const Ice::Context &context=Ice::noExplicitContext) const
Opens a node stderr file for reading.
std::future< std::optional< FileIteratorPrx > > openRegistryStdErrAsync(std::string_view name, std::int32_t count, const Ice::Context &context=Ice::noExplicitContext) const
Opens a registry stderr file for reading.
AdminSessionPrx & operator=(const AdminSessionPrx &rhs) noexcept
Copy assignment operator.
Definition Admin.h:2424
std::future< std::optional< FileIteratorPrx > > openNodeStdErrAsync(std::string_view name, std::int32_t count, const Ice::Context &context=Ice::noExplicitContext) const
Opens a node stderr file for reading.
std::future< void > finishUpdateAsync(const Ice::Context &context=Ice::noExplicitContext) const
Finishes updating the registry and releases the exclusive lock.
std::future< std::optional< FileIteratorPrx > > openServerStdOutAsync(std::string_view id, std::int32_t count, const Ice::Context &context=Ice::noExplicitContext) const
Opens a server stdout file for reading.
AdminSessionPrx & operator=(AdminSessionPrx &&rhs) noexcept
Move assignment operator.
Definition Admin.h:2435
std::optional< AdminPrx > getAdmin(const Ice::Context &context=Ice::noExplicitContext) const
Gets a proxy to the IceGrid admin object.
std::function< void()> keepAliveAsync(std::function< void()> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Keeps the session alive.
void setObserversByIdentity(const ::Ice::Identity &registryObs, const ::Ice::Identity &nodeObs, const ::Ice::Identity &appObs, const ::Ice::Identity &adptObs, const ::Ice::Identity &objObs, const Ice::Context &context=Ice::noExplicitContext) const
Sets the observer identities that receive notifications when the state of the registry or nodes chang...
std::optional< FileIteratorPrx > openServerLog(std::string_view id, std::string_view path, std::int32_t count, const Ice::Context &context=Ice::noExplicitContext) const
Opens a server log file for reading.
std::future< std::optional< AdminPrx > > getAdminAsync(const Ice::Context &context=Ice::noExplicitContext) const
Gets a proxy to the IceGrid admin object.
void setObservers(const std::optional< RegistryObserverPrx > &registryObs, const std::optional< NodeObserverPrx > &nodeObs, const std::optional< ApplicationObserverPrx > &appObs, const std::optional< AdapterObserverPrx > &adptObs, const std::optional< ObjectObserverPrx > &objObs, const Ice::Context &context=Ice::noExplicitContext) const
Sets the observer proxies that receive notifications when the state of the registry or nodes changes.
std::future< std::optional< FileIteratorPrx > > openServerLogAsync(std::string_view id, std::string_view path, std::int32_t count, const Ice::Context &context=Ice::noExplicitContext) const
Opens a server log file for reading.
std::function< void()> openRegistryStdErrAsync(std::string_view name, std::int32_t count, std::function< void(std::optional<::IceGrid::FileIteratorPrx >)> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Opens a registry stderr file for reading.
AdminSessionPrx(AdminSessionPrx &&other) noexcept
Move constructor.
Definition Admin.h:2417
std::future< std::string > getReplicaNameAsync(const Ice::Context &context=Ice::noExplicitContext) const
Gets the name of the registry replica hosting this session.
void keepAlive(const Ice::Context &context=Ice::noExplicitContext) const
Keeps the session alive.
AdminSessionPrx(const Ice::CommunicatorPtr &communicator, std::string_view proxyString)
Constructs a proxy from a Communicator and a proxy string.
Definition Admin.h:2409
std::function< void()> openNodeStdOutAsync(std::string_view name, std::int32_t count, std::function< void(std::optional<::IceGrid::FileIteratorPrx >)> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Opens a node stdout file for reading.
std::function< void()> setObserversAsync(const std::optional< RegistryObserverPrx > &registryObs, const std::optional< NodeObserverPrx > &nodeObs, const std::optional< ApplicationObserverPrx > &appObs, const std::optional< AdapterObserverPrx > &adptObs, const std::optional< ObjectObserverPrx > &objObs, std::function< void()> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Sets the observer proxies that receive notifications when the state of the registry or nodes changes.
std::function< void()> finishUpdateAsync(std::function< void()> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Finishes updating the registry and releases the exclusive lock.
std::future< void > setObserversByIdentityAsync(const ::Ice::Identity &registryObs, const ::Ice::Identity &nodeObs, const ::Ice::Identity &appObs, const ::Ice::Identity &adptObs, const ::Ice::Identity &objObs, const Ice::Context &context=Ice::noExplicitContext) const
Sets the observer identities that receive notifications when the state of the registry or nodes chang...
std::future< std::optional< FileIteratorPrx > > openRegistryStdOutAsync(std::string_view name, std::int32_t count, const Ice::Context &context=Ice::noExplicitContext) const
Opens a registry stdout file for reading.
std::optional< FileIteratorPrx > openServerStdErr(std::string_view id, std::int32_t count, const Ice::Context &context=Ice::noExplicitContext) const
Opens a server stderr file for reading.
std::future< std::optional< FileIteratorPrx > > openServerStdErrAsync(std::string_view id, std::int32_t count, const Ice::Context &context=Ice::noExplicitContext) const
Opens a server stderr file for reading.
std::optional< Ice::ObjectPrx > getAdminCallbackTemplate(const Ice::Context &context=Ice::noExplicitContext) const
Gets a "template" proxy for admin callback objects.
static const char * ice_staticId() noexcept
Gets the type ID of the associated Slice interface.
std::string getReplicaName(const Ice::Context &context=Ice::noExplicitContext) const
Gets the name of the registry replica hosting this session.
std::function< void()> openServerStdOutAsync(std::string_view id, std::int32_t count, std::function< void(std::optional<::IceGrid::FileIteratorPrx >)> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Opens a server stdout file for reading.
std::future< std::int32_t > startUpdateAsync(const Ice::Context &context=Ice::noExplicitContext) const
Acquires an exclusive lock to start updating the registry applications.
std::function< void()> openNodeStdErrAsync(std::string_view name, std::int32_t count, std::function< void(std::optional<::IceGrid::FileIteratorPrx >)> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Opens a node stderr file for reading.
std::function< void()> getAdminAsync(std::function< void(std::optional<::IceGrid::AdminPrx >)> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Gets a proxy to the IceGrid admin object.
std::function< void()> getAdminCallbackTemplateAsync(std::function< void(std::optional< Ice::ObjectPrx >)> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Gets a "template" proxy for admin callback objects.
std::optional< FileIteratorPrx > openRegistryStdOut(std::string_view name, std::int32_t count, const Ice::Context &context=Ice::noExplicitContext) const
Opens a registry stdout file for reading.
std::optional< FileIteratorPrx > openServerStdOut(std::string_view id, std::int32_t count, const Ice::Context &context=Ice::noExplicitContext) const
Opens a server stdout file for reading.
std::function< void()> openRegistryStdOutAsync(std::string_view name, std::int32_t count, std::function< void(std::optional<::IceGrid::FileIteratorPrx >)> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Opens a registry stdout file for reading.
AdminSessionPrx(const AdminSessionPrx &other) noexcept
Copy constructor.
Definition Admin.h:2413
void finishUpdate(const Ice::Context &context=Ice::noExplicitContext) const
Finishes updating the registry and releases the exclusive lock.
std::optional< FileIteratorPrx > openRegistryStdErr(std::string_view name, std::int32_t count, const Ice::Context &context=Ice::noExplicitContext) const
Opens a registry stderr file for reading.
std::function< void()> setObserversByIdentityAsync(const ::Ice::Identity &registryObs, const ::Ice::Identity &nodeObs, const ::Ice::Identity &appObs, const ::Ice::Identity &adptObs, const ::Ice::Identity &objObs, std::function< void()> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Sets the observer identities that receive notifications when the state of the registry or nodes chang...
std::future< std::optional< Ice::ObjectPrx > > getAdminCallbackTemplateAsync(const Ice::Context &context=Ice::noExplicitContext) const
Gets a "template" proxy for admin callback objects.
std::future< void > keepAliveAsync(const Ice::Context &context=Ice::noExplicitContext) const
Keeps the session alive.
std::function< void()> getReplicaNameAsync(std::function< void(std::string)> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Gets the name of the registry replica hosting this session.
std::int32_t startUpdate(const Ice::Context &context=Ice::noExplicitContext) const
Acquires an exclusive lock to start updating the registry applications.
Represents an administrative session between an admin tool and an IceGrid registry.
Definition Admin.h:2399
std::function< void()> applicationInitAsync(std::int32_t serial, const ApplicationInfoSeq &applications, std::function< void()> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Provides the initial application infos to the observer.
static const char * ice_staticId() noexcept
Gets the type ID of the associated Slice interface.
std::future< void > applicationUpdatedAsync(std::int32_t serial, const ApplicationUpdateInfo &desc, const Ice::Context &context=Ice::noExplicitContext) const
Notifies the observer that an application was updated.
void applicationInit(std::int32_t serial, const ApplicationInfoSeq &applications, const Ice::Context &context=Ice::noExplicitContext) const
Provides the initial application infos to the observer.
std::future< void > applicationAddedAsync(std::int32_t serial, const ApplicationInfo &desc, const Ice::Context &context=Ice::noExplicitContext) const
Notifies the observer that an application was added.
std::future< void > applicationRemovedAsync(std::int32_t serial, std::string_view name, const Ice::Context &context=Ice::noExplicitContext) const
Notifies the observer that an application was removed.
std::function< void()> applicationRemovedAsync(std::int32_t serial, std::string_view name, std::function< void()> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Notifies the observer that an application was removed.
ApplicationObserverPrx & operator=(const ApplicationObserverPrx &rhs) noexcept
Copy assignment operator.
Definition Admin.h:1938
void applicationAdded(std::int32_t serial, const ApplicationInfo &desc, const Ice::Context &context=Ice::noExplicitContext) const
Notifies the observer that an application was added.
ApplicationObserverPrx(const Ice::CommunicatorPtr &communicator, std::string_view proxyString)
Constructs a proxy from a Communicator and a proxy string.
Definition Admin.h:1923
std::future< void > applicationInitAsync(std::int32_t serial, const ApplicationInfoSeq &applications, const Ice::Context &context=Ice::noExplicitContext) const
Provides the initial application infos to the observer.
std::function< void()> applicationAddedAsync(std::int32_t serial, const ApplicationInfo &desc, std::function< void()> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Notifies the observer that an application was added.
void applicationUpdated(std::int32_t serial, const ApplicationUpdateInfo &desc, const Ice::Context &context=Ice::noExplicitContext) const
Notifies the observer that an application was updated.
ApplicationObserverPrx & operator=(ApplicationObserverPrx &&rhs) noexcept
Move assignment operator.
Definition Admin.h:1949
void applicationRemoved(std::int32_t serial, std::string_view name, const Ice::Context &context=Ice::noExplicitContext) const
Notifies the observer that an application was removed.
std::function< void()> applicationUpdatedAsync(std::int32_t serial, const ApplicationUpdateInfo &desc, std::function< void()> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Notifies the observer that an application was updated.
ApplicationObserverPrx(ApplicationObserverPrx &&other) noexcept
Move constructor.
Definition Admin.h:1931
ApplicationObserverPrx(const ApplicationObserverPrx &other) noexcept
Copy constructor.
Definition Admin.h:1927
Monitors applications.
Definition Admin.h:1918
virtual void applicationInit(std::int32_t serial, ApplicationInfoSeq applications, const Ice::Current &current)=0
Provides the initial application infos to the observer.
virtual void applicationAdded(std::int32_t serial, ApplicationInfo desc, const Ice::Current &current)=0
Notifies the observer that an application was added.
static const char * ice_staticId() noexcept
Gets the type ID of the associated Slice interface.
std::vector< std::string > ice_ids(const Ice::Current &current) const override
Gets the Slice interfaces supported by this object as a list of type IDs.
virtual void applicationUpdated(std::int32_t serial, ApplicationUpdateInfo desc, const Ice::Current &current)=0
Notifies the observer that an application was updated.
virtual void applicationRemoved(std::int32_t serial, std::string name, const Ice::Current &current)=0
Notifies the observer that an application was removed.
std::string ice_id(const Ice::Current &current) const override
Gets the type ID of the most-derived Slice interface supported by this object.
void dispatch(Ice::IncomingRequest &request, std::function< void(Ice::OutgoingResponse)> sendResponse) override
Dispatches an incoming request to one of the member functions of this generated class,...
ApplicationObserverPrx ProxyType
The associated proxy type.
Definition Admin.h:4026
Monitors applications.
Definition Admin.h:4023
std::future< std::tuple< bool, ::Ice::StringSeq > > readAsync(std::int32_t size, const Ice::Context &context=Ice::noExplicitContext) const
Read lines from the log file.
FileIteratorPrx(const Ice::CommunicatorPtr &communicator, std::string_view proxyString)
Constructs a proxy from a Communicator and a proxy string.
Definition Admin.h:1484
FileIteratorPrx(FileIteratorPrx &&other) noexcept
Move constructor.
Definition Admin.h:1492
std::function< void()> readAsync(std::int32_t size, std::function< void(bool, ::Ice::StringSeq)> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Read lines from the log file.
bool read(std::int32_t size, ::Ice::StringSeq &lines, const Ice::Context &context=Ice::noExplicitContext) const
Read lines from the log file.
std::future< void > destroyAsync(const Ice::Context &context=Ice::noExplicitContext) const
Destroys the iterator.
FileIteratorPrx & operator=(FileIteratorPrx &&rhs) noexcept
Move assignment operator.
Definition Admin.h:1510
FileIteratorPrx(const FileIteratorPrx &other) noexcept
Copy constructor.
Definition Admin.h:1488
static const char * ice_staticId() noexcept
Gets the type ID of the associated Slice interface.
FileIteratorPrx & operator=(const FileIteratorPrx &rhs) noexcept
Copy assignment operator.
Definition Admin.h:1499
void destroy(const Ice::Context &context=Ice::noExplicitContext) const
Destroys the iterator.
std::function< void()> destroyAsync(std::function< void()> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Destroys the iterator.
Iterates over an IceGrid log file.
Definition Admin.h:1479
NodeObserverPrx & operator=(const NodeObserverPrx &rhs) noexcept
Copy assignment operator.
Definition Admin.h:1752
std::future< void > updateServerAsync(std::string_view node, const ServerDynamicInfo &updatedInfo, const Ice::Context &context=Ice::noExplicitContext) const
Notifies the observer that the state of a server changed.
std::function< void()> nodeUpAsync(const NodeDynamicInfo &node, std::function< void()> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Notifies the observer that a node came up.
std::function< void()> updateAdapterAsync(std::string_view node, const AdapterDynamicInfo &updatedInfo, std::function< void()> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Notifies the observer that the state of an object adapter changed.
NodeObserverPrx(const Ice::CommunicatorPtr &communicator, std::string_view proxyString)
Constructs a proxy from a Communicator and a proxy string.
Definition Admin.h:1737
std::future< void > nodeInitAsync(const NodeDynamicInfoSeq &nodes, const Ice::Context &context=Ice::noExplicitContext) const
Provides the initial state of the nodes to the observer.
void nodeInit(const NodeDynamicInfoSeq &nodes, const Ice::Context &context=Ice::noExplicitContext) const
Provides the initial state of the nodes to the observer.
void nodeUp(const NodeDynamicInfo &node, const Ice::Context &context=Ice::noExplicitContext) const
Notifies the observer that a node came up.
std::future< void > nodeDownAsync(std::string_view name, const Ice::Context &context=Ice::noExplicitContext) const
Notifies the observer that a node went down.
std::future< void > nodeUpAsync(const NodeDynamicInfo &node, const Ice::Context &context=Ice::noExplicitContext) const
Notifies the observer that a node came up.
NodeObserverPrx & operator=(NodeObserverPrx &&rhs) noexcept
Move assignment operator.
Definition Admin.h:1763
std::function< void()> nodeInitAsync(const NodeDynamicInfoSeq &nodes, std::function< void()> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Provides the initial state of the nodes to the observer.
std::future< void > updateAdapterAsync(std::string_view node, const AdapterDynamicInfo &updatedInfo, const Ice::Context &context=Ice::noExplicitContext) const
Notifies the observer that the state of an object adapter changed.
void updateAdapter(std::string_view node, const AdapterDynamicInfo &updatedInfo, const Ice::Context &context=Ice::noExplicitContext) const
Notifies the observer that the state of an object adapter changed.
NodeObserverPrx(const NodeObserverPrx &other) noexcept
Copy constructor.
Definition Admin.h:1741
std::function< void()> updateServerAsync(std::string_view node, const ServerDynamicInfo &updatedInfo, std::function< void()> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Notifies the observer that the state of a server changed.
std::function< void()> nodeDownAsync(std::string_view name, std::function< void()> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Notifies the observer that a node went down.
void nodeDown(std::string_view name, const Ice::Context &context=Ice::noExplicitContext) const
Notifies the observer that a node went down.
NodeObserverPrx(NodeObserverPrx &&other) noexcept
Move constructor.
Definition Admin.h:1745
static const char * ice_staticId() noexcept
Gets the type ID of the associated Slice interface.
void updateServer(std::string_view node, const ServerDynamicInfo &updatedInfo, const Ice::Context &context=Ice::noExplicitContext) const
Notifies the observer that the state of a server changed.
Monitors changes to the state of the nodes.
Definition Admin.h:1732
virtual void nodeUp(NodeDynamicInfo node, const Ice::Current &current)=0
Notifies the observer that a node came up.
std::string ice_id(const Ice::Current &current) const override
Gets the type ID of the most-derived Slice interface supported by this object.
static const char * ice_staticId() noexcept
Gets the type ID of the associated Slice interface.
void dispatch(Ice::IncomingRequest &request, std::function< void(Ice::OutgoingResponse)> sendResponse) override
Dispatches an incoming request to one of the member functions of this generated class,...
virtual void nodeInit(NodeDynamicInfoSeq nodes, const Ice::Current &current)=0
Provides the initial state of the nodes to the observer.
NodeObserverPrx ProxyType
The associated proxy type.
Definition Admin.h:3959
virtual void nodeDown(std::string name, const Ice::Current &current)=0
Notifies the observer that a node went down.
std::vector< std::string > ice_ids(const Ice::Current &current) const override
Gets the Slice interfaces supported by this object as a list of type IDs.
virtual void updateAdapter(std::string node, AdapterDynamicInfo updatedInfo, const Ice::Current &current)=0
Notifies the observer that the state of an object adapter changed.
virtual void updateServer(std::string node, ServerDynamicInfo updatedInfo, const Ice::Current &current)=0
Notifies the observer that the state of a server changed.
Monitors changes to the state of the nodes.
Definition Admin.h:3956
std::function< void()> objectInitAsync(const ObjectInfoSeq &objects, std::function< void()> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Provides the initial list of well-known objects to the observer.
static const char * ice_staticId() noexcept
Gets the type ID of the associated Slice interface.
void objectRemoved(const ::Ice::Identity &id, const Ice::Context &context=Ice::noExplicitContext) const
Notifies the observer that a well-known object was removed.
ObjectObserverPrx & operator=(const ObjectObserverPrx &rhs) noexcept
Copy assignment operator.
Definition Admin.h:2262
std::function< void()> objectRemovedAsync(const ::Ice::Identity &id, std::function< void()> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Notifies the observer that a well-known object was removed.
void objectAdded(const ObjectInfo &info, const Ice::Context &context=Ice::noExplicitContext) const
Notifies the observer that a well-known object was added.
ObjectObserverPrx(ObjectObserverPrx &&other) noexcept
Move constructor.
Definition Admin.h:2255
std::future< void > objectRemovedAsync(const ::Ice::Identity &id, const Ice::Context &context=Ice::noExplicitContext) const
Notifies the observer that a well-known object was removed.
std::future< void > objectInitAsync(const ObjectInfoSeq &objects, const Ice::Context &context=Ice::noExplicitContext) const
Provides the initial list of well-known objects to the observer.
ObjectObserverPrx & operator=(ObjectObserverPrx &&rhs) noexcept
Move assignment operator.
Definition Admin.h:2273
std::future< void > objectUpdatedAsync(const ObjectInfo &info, const Ice::Context &context=Ice::noExplicitContext) const
Notifies the observer that a well-known object was updated.
std::future< void > objectAddedAsync(const ObjectInfo &info, const Ice::Context &context=Ice::noExplicitContext) const
Notifies the observer that a well-known object was added.
std::function< void()> objectUpdatedAsync(const ObjectInfo &info, std::function< void()> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Notifies the observer that a well-known object was updated.
std::function< void()> objectAddedAsync(const ObjectInfo &info, std::function< void()> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Notifies the observer that a well-known object was added.
ObjectObserverPrx(const Ice::CommunicatorPtr &communicator, std::string_view proxyString)
Constructs a proxy from a Communicator and a proxy string.
Definition Admin.h:2247
void objectUpdated(const ObjectInfo &info, const Ice::Context &context=Ice::noExplicitContext) const
Notifies the observer that a well-known object was updated.
ObjectObserverPrx(const ObjectObserverPrx &other) noexcept
Copy constructor.
Definition Admin.h:2251
void objectInit(const ObjectInfoSeq &objects, const Ice::Context &context=Ice::noExplicitContext) const
Provides the initial list of well-known objects to the observer.
Monitors well-known objects that are added, updated or removed using AdminPrx.
Definition Admin.h:2242
std::string ice_id(const Ice::Current &current) const override
Gets the type ID of the most-derived Slice interface supported by this object.
std::vector< std::string > ice_ids(const Ice::Current &current) const override
Gets the Slice interfaces supported by this object as a list of type IDs.
virtual void objectInit(ObjectInfoSeq objects, const Ice::Current &current)=0
Provides the initial list of well-known objects to the observer.
void dispatch(Ice::IncomingRequest &request, std::function< void(Ice::OutgoingResponse)> sendResponse) override
Dispatches an incoming request to one of the member functions of this generated class,...
virtual void objectRemoved(::Ice::Identity id, const Ice::Current &current)=0
Notifies the observer that a well-known object was removed.
virtual void objectUpdated(ObjectInfo info, const Ice::Current &current)=0
Notifies the observer that a well-known object was updated.
ObjectObserverPrx ProxyType
The associated proxy type.
Definition Admin.h:4144
static const char * ice_staticId() noexcept
Gets the type ID of the associated Slice interface.
virtual void objectAdded(ObjectInfo info, const Ice::Current &current)=0
Notifies the observer that a well-known object was added.
Monitors well-known objects that are added, updated or removed using AdminPrx.
Definition Admin.h:4141
std::future< void > registryUpAsync(const RegistryInfo &registryReplica, const Ice::Context &context=Ice::noExplicitContext) const
Notifies the observer that a registry replica came up.
RegistryObserverPrx(const Ice::CommunicatorPtr &communicator, std::string_view proxyString)
Constructs a proxy from a Communicator and a proxy string.
Definition Admin.h:1605
std::future< void > registryDownAsync(std::string_view name, const Ice::Context &context=Ice::noExplicitContext) const
Notifies the observer that a registry replica went down.
static const char * ice_staticId() noexcept
Gets the type ID of the associated Slice interface.
void registryDown(std::string_view name, const Ice::Context &context=Ice::noExplicitContext) const
Notifies the observer that a registry replica went down.
RegistryObserverPrx(const RegistryObserverPrx &other) noexcept
Copy constructor.
Definition Admin.h:1609
void registryInit(const RegistryInfoSeq &registries, const Ice::Context &context=Ice::noExplicitContext) const
Provides the initial state of the registries to the observer.
std::function< void()> registryInitAsync(const RegistryInfoSeq &registries, std::function< void()> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Provides the initial state of the registries to the observer.
RegistryObserverPrx & operator=(RegistryObserverPrx &&rhs) noexcept
Move assignment operator.
Definition Admin.h:1631
std::future< void > registryInitAsync(const RegistryInfoSeq &registries, const Ice::Context &context=Ice::noExplicitContext) const
Provides the initial state of the registries to the observer.
std::function< void()> registryDownAsync(std::string_view name, std::function< void()> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Notifies the observer that a registry replica went down.
std::function< void()> registryUpAsync(const RegistryInfo &registryReplica, std::function< void()> response, std::function< void(std::exception_ptr)> exception=nullptr, std::function< void(bool)> sent=nullptr, const Ice::Context &context=Ice::noExplicitContext) const
Notifies the observer that a registry replica came up.
void registryUp(const RegistryInfo &registryReplica, const Ice::Context &context=Ice::noExplicitContext) const
Notifies the observer that a registry replica came up.
RegistryObserverPrx & operator=(const RegistryObserverPrx &rhs) noexcept
Copy assignment operator.
Definition Admin.h:1620
RegistryObserverPrx(RegistryObserverPrx &&other) noexcept
Move constructor.
Definition Admin.h:1613
Monitors changes to the state of the registries.
Definition Admin.h:1600
RegistryObserverPrx ProxyType
The associated proxy type.
Definition Admin.h:3910
virtual void registryInit(RegistryInfoSeq registries, const Ice::Current &current)=0
Provides the initial state of the registries to the observer.
static const char * ice_staticId() noexcept
Gets the type ID of the associated Slice interface.
std::vector< std::string > ice_ids(const Ice::Current &current) const override
Gets the Slice interfaces supported by this object as a list of type IDs.
std::string ice_id(const Ice::Current &current) const override
Gets the type ID of the most-derived Slice interface supported by this object.
virtual void registryUp(RegistryInfo registryReplica, const Ice::Current &current)=0
Notifies the observer that a registry replica came up.
void dispatch(Ice::IncomingRequest &request, std::function< void(Ice::OutgoingResponse)> sendResponse) override
Dispatches an incoming request to one of the member functions of this generated class,...
virtual void registryDown(std::string name, const Ice::Current &current)=0
Notifies the observer that a registry replica went down.
Monitors changes to the state of the registries.
Definition Admin.h:3907
Represents the main entry point into the IceGrid registry service.
Definition Registry.h:275
Represents a request received by a connection.
ObjectPrx & operator=(const ObjectPrx &rhs) noexcept=default
Copy assignment operator.
The base class for all Ice proxies.
Definition Proxy.h:232
Object() noexcept=default
Default constructor.
The base class for servants.
Definition Object.h:21
Represents the response to an incoming request.
Provides typed proxy functions.
Definition Proxy.h:45
Communicate through firewalls and across NATs.
std::shared_ptr< AdminSession > AdminSessionPtr
A shared pointer to an AdminSession.
Definition Admin.h:4401
std::shared_ptr< ApplicationObserver > ApplicationObserverPtr
A shared pointer to an ApplicationObserver.
Definition Admin.h:4080
std::ostream & operator<<(std::ostream &os, ServerState value)
Outputs the enumerator name or underlying value of a ServerState to a stream.
std::vector< AdapterDynamicInfo > AdapterDynamicInfoSeq
A sequence of AdapterDynamicInfo.
Definition Admin.h:112
std::shared_ptr< AdapterObserver > AdapterObserverPtr
A shared pointer to an AdapterObserver.
Definition Admin.h:4136
std::vector< AdapterInfo > AdapterInfoSeq
A sequence of AdapterInfo.
Definition Admin.h:80
std::vector< NodeDynamicInfo > NodeDynamicInfoSeq
A sequence of NodeDynamicInfo.
Definition Admin.h:119
ServerState
Represents the state of a server.
Definition Admin.h:39
@ Deactivating
The server is being deactivated.
Definition Admin.h:54
@ Inactive
The server is not running.
Definition Admin.h:41
@ Active
The server is running.
Definition Admin.h:51
@ Destroying
The server is being destroyed.
Definition Admin.h:57
@ ActivationTimedOut
The server activation timed out.
Definition Admin.h:48
@ Destroyed
The server is destroyed.
Definition Admin.h:60
@ Activating
The server is being activated and will change to the active state when the registered server object a...
Definition Admin.h:45
std::shared_ptr< FileIterator > FileIteratorPtr
A shared pointer to a FileIterator.
Definition Admin.h:3902
std::vector< RegistryInfo > RegistryInfoSeq
A sequence of RegistryInfo.
Definition Admin.h:89
std::shared_ptr< ServerDescriptor > ServerDescriptorPtr
A shared pointer to a ServerDescriptor.
Definition Descriptor.h:72
std::shared_ptr< RegistryObserver > RegistryObserverPtr
A shared pointer to a RegistryObserver.
Definition Admin.h:3951
std::map< std::string, std::optional< Ice::ObjectPrx > > StringObjectProxyDict
A dictionary of string to proxies.
Definition Admin.h:70
std::shared_ptr< NodeObserver > NodeObserverPtr
A shared pointer to a NodeObserver.
Definition Admin.h:4018
std::shared_ptr< Admin > AdminPtr
A shared pointer to an Admin.
Definition Admin.h:3856
std::shared_ptr< ObjectObserver > ObjectObserverPtr
A shared pointer to an ObjectObserver.
Definition Admin.h:4193
std::vector< ServerDynamicInfo > ServerDynamicInfoSeq
A sequence of ServerDynamicInfo.
Definition Admin.h:107
std::vector< ObjectInfo > ObjectInfoSeq
A sequence of ObjectInfo.
Definition Admin.h:75
std::vector< ApplicationInfo > ApplicationInfoSeq
A sequence of ApplicationInfo.
Definition Admin.h:96
Deploy and manage Ice servers.
Definition Admin.h:34
std::shared_ptr< Communicator > CommunicatorPtr
A shared pointer to a Communicator.
const Context noExplicitContext
Marker value used to indicate that no explicit request context was passed to a proxy invocation.
int StreamHelperCategory
The stream helper category allows to select a StreamHelper specialization for a specific category of ...
std::vector< std::string > StringSeq
A sequence of strings.
constexpr StreamHelperCategory StreamHelperCategoryStruct
Generated struct types.
std::map< std::string, std::string, std::less<> > Context
Represents additional information carried by an Ice request.
Definition Context.h:28
The Ice RPC framework.
Definition SampleEvent.h:59
void ice_printFields(std::ostream &os) const
Outputs the name and value of each field of this instance to the stream.
std::tuple< const std::string &, const std::optional< Ice::ObjectPrx > & > ice_tuple() const
Creates a tuple with all the fields of this struct.
Definition Admin.h:3284
std::optional< Ice::ObjectPrx > proxy
The direct proxy containing the adapter endpoints. This proxy is never null.
Definition Admin.h:3280
std::string id
The id of the adapter.
Definition Admin.h:3277
Dynamic information about the state of an adapter.
Definition Admin.h:3275
std::string replicaGroupId
The replica group ID of the object adapter, or empty if the adapter doesn't belong to a replica group...
Definition Admin.h:2995
std::string id
The ID of the adapter.
Definition Admin.h:2989
std::tuple< const std::string &, const std::optional< Ice::ObjectPrx > &, const std::string & > ice_tuple() const
Creates a tuple with all the fields of this struct.
Definition Admin.h:2999
void ice_printFields(std::ostream &os) const
Outputs the name and value of each field of this instance to the stream.
std::optional< Ice::ObjectPrx > proxy
A dummy direct proxy that contains the adapter endpoints.
Definition Admin.h:2992
Information about an adapter registered with the IceGrid registry.
Definition Admin.h:2987
Describes an application.
std::int64_t updateTime
The last update time.
Definition Admin.h:3175
std::int64_t createTime
The creation time.
Definition Admin.h:3169
std::string updateUser
The user who updated the application.
Definition Admin.h:3178
std::string createUser
The user who created the application.
Definition Admin.h:3172
void ice_printFields(std::ostream &os) const
Outputs the name and value of each field of this instance to the stream.
::IceGrid::ApplicationDescriptor descriptor
The application descriptor.
Definition Admin.h:3184
std::tuple< const std::string &, const std::int64_t &, const std::string &, const std::int64_t &, const std::string &, const std::int32_t &, const ::IceGrid::ApplicationDescriptor & > ice_tuple() const
Creates a tuple with all the fields of this struct.
Definition Admin.h:3188
std::string uuid
Unique application identifier.
Definition Admin.h:3166
std::int32_t revision
The application revision number.
Definition Admin.h:3181
Information about an IceGrid application.
Definition Admin.h:3164
An application update descriptor to describe the updates to apply to a deployed application.
::IceGrid::ApplicationUpdateDescriptor descriptor
The update descriptor.
Definition Admin.h:3218
std::int32_t revision
The application revision number.
Definition Admin.h:3215
std::tuple< const std::int64_t &, const std::string &, const std::int32_t &, const ::IceGrid::ApplicationUpdateDescriptor & > ice_tuple() const
Creates a tuple with all the fields of this struct.
Definition Admin.h:3222
void ice_printFields(std::ostream &os) const
Outputs the name and value of each field of this instance to the stream.
std::int64_t updateTime
The update time.
Definition Admin.h:3209
std::string updateUser
The user who updated the application.
Definition Admin.h:3212
Information about updates to an IceGrid application.
Definition Admin.h:3207
float avg5
The load average over the past 5 minutes.
Definition Admin.h:3138
void ice_printFields(std::ostream &os) const
Outputs the name and value of each field of this instance to the stream.
std::tuple< const float &, const float &, const float & > ice_tuple() const
Creates a tuple with all the fields of this struct.
Definition Admin.h:3145
float avg15
The load average over the past 15 minutes.
Definition Admin.h:3141
float avg1
The load average over the past minute.
Definition Admin.h:3135
Information about the load of a node.
Definition Admin.h:3133
::IceGrid::NodeInfo info
Some static information about the node.
Definition Admin.h:3305
::IceGrid::AdapterDynamicInfoSeq adapters
The dynamic information of the adapters deployed on this node.
Definition Admin.h:3311
void ice_printFields(std::ostream &os) const
Outputs the name and value of each field of this instance to the stream.
std::tuple< const ::IceGrid::NodeInfo &, const ::IceGrid::ServerDynamicInfoSeq &, const ::IceGrid::AdapterDynamicInfoSeq & > ice_tuple() const
Creates a tuple with all the fields of this struct.
Definition Admin.h:3315
::IceGrid::ServerDynamicInfoSeq servers
The dynamic information of the servers deployed on this node.
Definition Admin.h:3308
Dynamic information about the state of a node.
Definition Admin.h:3303
std::string release
The operation system release level.
Definition Admin.h:3069
std::tuple< const std::string &, const std::string &, const std::string &, const std::string &, const std::string &, const std::string &, const std::int32_t &, const std::string & > ice_tuple() const
Creates a tuple with all the fields of this struct.
Definition Admin.h:3086
std::string machine
The machine hardware type.
Definition Admin.h:3075
std::string hostname
The network name of the host running this node.
Definition Admin.h:3066
void ice_printFields(std::ostream &os) const
Outputs the name and value of each field of this instance to the stream.
std::string os
The operating system name.
Definition Admin.h:3063
std::string version
The operation system version.
Definition Admin.h:3072
std::string name
The name of the node.
Definition Admin.h:3060
std::int32_t nProcessors
The number of processor threads on the node.
Definition Admin.h:3079
std::string dataDir
The path to the node data directory.
Definition Admin.h:3082
Information about an IceGrid node.
Definition Admin.h:3058
std::tuple< const std::optional< Ice::ObjectPrx > &, const std::string & > ice_tuple() const
Creates a tuple with all the fields of this struct.
Definition Admin.h:2968
void ice_printFields(std::ostream &os) const
Outputs the name and value of each field of this instance to the stream.
std::string type
The type of the object.
Definition Admin.h:2964
std::optional< Ice::ObjectPrx > proxy
The proxy of the object.
Definition Admin.h:2961
Information about an Ice well-known object.
Definition Admin.h:2959
void ice_printFields(std::ostream &os) const
Outputs the name and value of each field of this instance to the stream.
std::tuple< const std::string &, const std::string & > ice_tuple() const
Creates a tuple with all the fields of this struct.
Definition Admin.h:3114
std::string name
The name of the registry.
Definition Admin.h:3107
std::string hostname
The network name of the host running this registry.
Definition Admin.h:3110
Information about an IceGrid registry replica.
Definition Admin.h:3105
::IceGrid::ServerState state
The state of the server.
Definition Admin.h:3246
std::string id
The ID of the server.
Definition Admin.h:3243
std::int32_t pid
The process ID of the server.
Definition Admin.h:3249
std::tuple< const std::string &, const ::IceGrid::ServerState &, const std::int32_t &, const bool & > ice_tuple() const
Creates a tuple with all the fields of this struct.
Definition Admin.h:3256
bool enabled
Indicates whether the server is enabled.
Definition Admin.h:3252
void ice_printFields(std::ostream &os) const
Outputs the name and value of each field of this instance to the stream.
Dynamic information about the state of a server.
Definition Admin.h:3241
::IceGrid::ServerDescriptorPtr descriptor
The server descriptor.
Definition Admin.h:3032
std::string application
The application to which this server belongs.
Definition Admin.h:3020
std::string uuid
The application UUID.
Definition Admin.h:3023
void ice_printFields(std::ostream &os) const
Outputs the name and value of each field of this instance to the stream.
std::tuple< const std::string &, const std::string &, const std::int32_t &, const std::string &, const ::IceGrid::ServerDescriptorPtr &, const std::string & > ice_tuple() const
Creates a tuple with all the fields of this struct.
Definition Admin.h:3039
std::string sessionId
The ID of the session which allocated the server.
Definition Admin.h:3035
std::string node
The IceGrid node where this server is deployed.
Definition Admin.h:3029
std::int32_t revision
The application revision.
Definition Admin.h:3026
Information about a server managed by an IceGrid node.
Definition Admin.h:3018
Describes a template instantiation that creates a server.
Definition Descriptor.h:623
Provides information about an incoming request being dispatched.
Definition Current.h:18
Represents the identity of an Ice object.
Definition Identity.h:40