Skip to content

v2.0.0

Latest
Compare
Choose a tag to compare
@sangelovic sangelovic released this 24 Apr 19:05
· 11 commits to master since this release

A new major version with revamped API, bringing numerous new features, simplifications, fixes and breaking changes improving not only API consistency, safety and expressiveness, but also performance. The complete list of breaking API/ABI/behavior changes can be found in the Using sdbus-c++ document, section Migrating to sdbus-c++ v2. This version is based on C++20 standard (but its API is backwards-compatible with C++17, skipping C++20 features if used in a C++17-based project).

  • Add strong types to public API for higher API safety
  • Add support for string_view as a D-Bus type representation
  • Enable compile-time D-Bus signature generation (saving run-time string manipulation)
  • Redesign Object vtable registration API
  • Improve Proxy signal subscription API
  • Refactor object manager API for consistency
  • Introduce native sd-event integration
  • Let callbacks take message objects by value
  • Simplify async D-Bus connection handling
  • Simplify async call state flag
  • Use std::optional for passing potential call errors
  • Make Variant constructor explicit
  • Rename and re-organize CMake options
  • Rename connection creation methods
  • Have all async function names end with *Async for consistency
  • Implement more flexible searching for sd-bus libs
  • Add new SDBUSCPP_SDBUS_LIB CMake configuration variable determining which sd-bus library shall be picked
  • Make Variant conversion operator explicit
  • Use sd-bus API to get the current message
  • Use sd_bus_match_signal() for signal registration
  • Provide also const char* overloads for high-level functions for efficiency
  • Disable move in generated adaptor and proxy classes
  • Improve and make more efficient some Message API
  • Add Slot-returning overloads of async method calls
  • Remove floating_slot_t tag and use return_slot_t instead
  • Add [[nodiscard]] to many relevant API functions
  • Add proper fix for timeout handling
  • Fix for external event loops in which the event loop thread ID was not correctly initialized (now fixed and simplified by not needing the thread ID anymore)
  • Remove deprecated stuff
  • Add SDBUSCPP_ prefix to CMake configuration variables to avoid conflicts with downstream projects
  • Require systemd of at least v238
  • Many other fixes and updates in code, tests, build system, CI, and documentation