13#ifndef IOX2_CONFIG_HPP
14#define IOX2_CONFIG_HPP
74 explicit Node(iox2_config_h* config);
76 iox2_config_h* m_config =
nullptr;
115 explicit Service(iox2_config_h* config);
117 iox2_config_h* m_config =
nullptr;
144 friend class ::iox2::Config;
145 explicit Global(iox2_config_h* config);
147 iox2_config_h* m_config =
nullptr;
207 iox2_config_h* m_config =
nullptr;
252 explicit Event(iox2_config_h* config);
254 iox2_config_h* m_config =
nullptr;
371 iox2_config_h* m_config =
nullptr;
392 iox2_config_h* m_config =
nullptr;
409 friend class ::iox2::Config;
410 explicit Defaults(iox2_config_h* config);
412 iox2_config_h* m_config =
nullptr;
437 iox2_config_ptr m_ptr =
nullptr;
478 template <ServiceType>
481 explicit Config(iox2_config_h handle);
484 iox2_config_h m_handle =
nullptr;
Non-owning view of a [Config].
auto to_owned() const -> Config
Creates a copy of the corresponding [Config] and returns it.
ConfigView(const ConfigView &)=default
auto operator=(ConfigView &&) -> ConfigView &=default
ConfigView(ConfigView &&)=default
auto operator=(const ConfigView &) -> ConfigView &=default
auto operator=(const Config &rhs) -> Config &
auto defaults() -> config::Defaults
Returns the [config::Defaults] part of the config.
auto global() -> config::Global
Returns the [config::Global] part of the config.
auto operator=(Config &&rhs) noexcept -> Config &
static auto setup_global_config_from_file(const iox2::bb::FilePath &file) -> iox2::bb::Expected< ConfigView, ConfigCreationError >
Config(Config &&rhs) noexcept
Config(const Config &rhs)
static auto from_file(const iox2::bb::FilePath &file) -> iox2::bb::Expected< Config, ConfigCreationError >
auto view() -> ConfigView
Returns the [ConfigView] to this [Config].
static auto global_config() -> ConfigView
Returns a [ConfigView] to the current global config.
Contains all details of a [Node] that is dead.
Represents a single file name. It is not allowed to contain any path elements like "....
Represents a path to a file. It is not allowed to end with a path separator since this would then be ...
Represents a path to a file or a directory.
void set_max_readers(size_t value) &&
Set the maximum amount of supported [Reader]s.
void set_max_nodes(size_t value) &&
Set the maximum amount of supported [Node]s.
auto max_readers() &&-> size_t
The maximum amount of supported [Reader]s.
auto max_nodes() &&-> size_t
auto blackboard() &&-> Blackboard
Returns the blackboard part of the default settings.
auto publish_subscribe() &&-> PublishSubscribe
Returns the publish_subscribe part of the default settings.
auto event() &&-> Event
Returns the event part of the default settings.
auto request_response() &&-> RequestResponse
Returns the request_response part of the default settings.
void set_notifier_dead_event(bb::Optional< size_t > value) &&
Sets the event id value that is emitted if a notifier was identified as dead.
void set_max_notifiers(size_t value) &&
Set the maximum amount of supported [Notifier].
void set_deadline(bb::Optional< iox2::bb::Duration > deadline) &&
Sets the deadline of the event service.
auto max_listeners() &&-> size_t
The maximum amount of supported [Listener].
void set_notifier_dropped_event(bb::Optional< size_t > value) &&
Sets the event id value that is emitted before a new notifier is dropped.
auto notifier_dead_event() &&-> bb::Optional< size_t >
Defines the event id value that is emitted if a notifier was identified as dead.
auto deadline() &&-> bb::Optional< iox2::bb::Duration >
auto notifier_dropped_event() &&-> bb::Optional< size_t >
Defines the event id value that is emitted before a new notifier is dropped.
void set_max_listeners(size_t value) &&
Set the maximum amount of supported [Listener].
void set_max_nodes(size_t value) &&
Set the maximum amount of supported [Node]s.
void set_event_id_max_value(size_t value) &&
Set the largest event id supported by the event service.
auto max_notifiers() &&-> size_t
The maximum amount of supported [Notifier].
void set_notifier_created_event(bb::Optional< size_t > value) &&
Sets the event id value that is emitted after a new notifier was created.
auto event_id_max_value() &&-> size_t
The largest event id supported by the event service.
auto max_nodes() &&-> size_t
auto notifier_created_event() &&-> bb::Optional< size_t >
Defines the event id value that is emitted after a new notifier was created.
auto service() -> Service
Returns the service part of the global configuration.
auto node() -> Node
Returns the node part of the global configuration.
auto root_path() &&-> const char *
The path under which all other directories or files will be created.
void set_prefix(const iox2::bb::FileName &value) &&
Set the prefix used for all files created during runtime.
auto creation_timeout() &&-> iox2::bb::Duration
void set_root_path(const iox2::bb::Path &value) &&
Defines the path under which all other directories or files will be created.
auto prefix() &&-> const char *
Prefix used for all files created during runtime.
void set_creation_timeout(const iox2::bb::Duration &value) &&
Set the creation timeout.
All configurable settings of a [Node].
void set_static_config_suffix(const iox2::bb::FileName &value) &&
Set the suffix of the files where the node configuration is stored.
void set_service_tag_suffix(const iox2::bb::FileName &value) &&
Set the suffix of the service tags.
auto monitor_suffix() &&-> const char *
The suffix of the monitor token.
void set_port_tag_suffix(const iox2::bb::FileName &value) &&
Set the suffix of the service tags.
void set_monitor_suffix(const iox2::bb::FileName &value) &&
Set the suffix of the monitor token.
void set_global_mgmt_suffix(const iox2::bb::FileName &value) &&
Set the suffix of the files where the node configuration is stored.
auto directory() &&-> const char *
The directory in which all node files are stored.
auto cleanup_dead_nodes_on_destruction() &&-> bool
void set_directory(const iox2::bb::Path &value) &&
Set the directory in which all node files are stored.
auto service_tag_suffix() &&-> const char *
The suffix of the service tags.
void set_cleanup_dead_nodes_on_destruction(bool value) &&
Enable/disable the cleanup dead nodes on destruction.
auto port_tag_suffix() &&-> const char *
The suffix of the service tags.
void set_cleanup_dead_nodes_on_creation(bool value) &&
Enable/disable the cleanup dead nodes on creation.
auto global_mgmt_suffix() &&-> const char *
The suffix of the files where the node configuration is stored.
auto cleanup_dead_nodes_on_creation() &&-> bool
auto static_config_suffix() &&-> const char *
The suffix of the files where the node configuration is stored.
void set_enable_safe_overflow(bool value) &&
Enables/disables safe overflow.
auto subscriber_expired_connection_buffer() &&-> size_t
void set_publisher_history_size(size_t value) &&
Set the maximum history size a [Subscriber] can request from a [Publisher].
void set_max_publishers(size_t value) &&
Set the maximum amount of supported [Publisher]s.
void set_max_subscribers(size_t value) &&
Set the maximum amount of supported [Subscriber]s.
void set_max_nodes(size_t value) &&
Set the maximum amount of supported [Node]s.
void set_subscriber_max_borrowed_samples(size_t value) &&
Set the maximum amount of [Sample]s a [Subscriber] can hold at the same time.
auto max_subscribers() &&-> size_t
The maximum amount of supported [Subscriber]s.
void set_backpressure_strategy(BackpressureStrategy value) &&
Define the backpressure strategy.
auto backpressure_strategy() &&-> BackpressureStrategy
auto enable_safe_overflow() &&-> bool
void set_publisher_max_loaned_samples(size_t value) &&
The maximum amount of [SampleMut]s a [Publisher] can loan at the same time.
auto publisher_max_loaned_samples() &&-> size_t
The maximum amount of [SampleMut]s a [Publisher] can loan at the same time.
void set_subscriber_expired_connection_buffer(size_t value) &&
Set the expired connection buffer size.
auto subscriber_max_buffer_size() &&-> size_t
The maximum buffer size a [Subscriber] can have.
auto max_nodes() &&-> size_t
auto max_publishers() &&-> size_t
The maximum amount of supported [Publisher]s.
auto publisher_history_size() &&-> size_t
The maximum history size a [Subscriber] can request from a [Publisher].
void set_subscriber_max_buffer_size(size_t value) &&
Set the maximum buffer size a [Subscriber] can have.
auto subscriber_max_borrowed_samples() &&-> size_t
The maximum amount of [Sample]s a [Subscriber] can hold at the same time.
auto enable_safe_overflow_for_requests() &&-> bool
Defines if the request buffer of the [Service] safely overflows.
void set_max_loaned_requests(size_t value) &&
void set_max_response_buffer_size(size_t value) &&
auto server_backpressure_strategy() &&-> BackpressureStrategy
void set_server_backpressure_strategy(BackpressureStrategy value) &&
void set_client_expired_connection_buffer(size_t value) &&
void set_max_clients(size_t value) &&
Set the maximum amount of supported [crate::port::client::Client].
void set_enable_safe_overflow_for_responses(bool value) &&
Enables/disables safe overflow for the response buffer.
auto max_servers() &&-> size_t
The maximum amount of supported [crate::port::server::Server].
auto max_active_requests_per_client() &&-> size_t
auto client_expired_connection_buffer() &&-> size_t
void set_client_backpressure_strategy(BackpressureStrategy value) &&
void set_enable_fire_and_forget_requests(bool value) &&
Set if fire-and-forget feature is enabled.
void set_max_borrowed_responses_per_pending_response(size_t value) &&
void set_server_expired_connection_buffer(size_t value) &&
auto max_borrowed_responses_per_pending_response() &&-> size_t
auto enable_safe_overflow_for_responses() &&-> bool
Defines if the response buffer of the [Service] safely overflows.
void set_max_nodes(size_t value) &&
auto max_response_buffer_size() &&-> size_t
void set_max_servers(size_t value) &&
Set the maximum amount of supported [crate::port::server::Server].
void set_max_active_requests_per_client(size_t value) &&
auto max_nodes() &&-> size_t
void set_server_max_loaned_responses_per_request(size_t value) &&
auto max_loaned_requests() &&-> size_t
auto server_max_loaned_responses_per_request() &&-> size_t
auto max_clients() &&-> size_t
The maximum amount of supported [crate::port::client::Client].
auto server_expired_connection_buffer() &&-> size_t
auto client_backpressure_strategy() &&-> BackpressureStrategy
void set_enable_safe_overflow_for_requests(bool value) &&
Enables/disables safe overflow for the request buffer.
auto enable_fire_and_forget_requests() &&-> bool
All configurable settings of a [Service].
auto directory() &&-> const char *
The directory in which all service files are stored.
void set_directory(const iox2::bb::Path &value) &&
Set the directory in which all service files are stored.
auto data_segment_suffix() &&-> const char *
The suffix of the ports data segment.
void set_event_connection_suffix(const iox2::bb::FileName &value) &&
Set the suffix of a one-to-one connection.
auto connection_suffix() &&-> const char *
The suffix of a one-to-one connection.
auto dynamic_config_storage_suffix() &&-> const char *
The suffix of the dynamic config file.
auto static_config_storage_suffix() &&-> const char *
The suffix of the static config file.
auto event_connection_suffix() &&-> const char *
The suffix of a one-to-one connection.
void set_data_segment_suffix(const iox2::bb::FileName &value) &&
Set the suffix of the ports data segment.
void set_connection_suffix(const iox2::bb::FileName &value) &&
Set the suffix of a one-to-one connection.
void set_static_config_storage_suffix(const iox2::bb::FileName &value) &&
Set the suffix of the static config file.
void set_dynamic_config_storage_suffix(const iox2::bb::FileName &value) &&
Set the suffix of the dynamic config file.
auto cleanup_dead_nodes_on_open() &&-> bool
void set_cleanup_dead_nodes_on_open(bool value) &&
iox2::bb::variation::Optional< T > Optional
iox2::bb::variation::Expected< T, E > Expected