Skip to content

Commit

Permalink
Update migration guide, move documentation od dbus_native to cgroups
Browse files Browse the repository at this point in the history
Signed-off-by: Yashodhan Joshi <[email protected]>
  • Loading branch information
YJDoc2 committed Oct 5, 2023
1 parent a650514 commit 263e6b8
Show file tree
Hide file tree
Showing 4 changed files with 18 additions and 12 deletions.
7 changes: 6 additions & 1 deletion MirgationGuide.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,12 @@

This contains information for migrating library versions.

## V0.1.0 -> v0.2.0
## v0.2.0 -> v0.3.0

### libcgroups
- Switched from dbus-rs to a native dbus implementation see [#2208](https://github.com/containers/youki/issues/2208) for motivation behind this. This replaces the `dbus` module with `dbus_native` module. However, As this is not in public interface for the crate, the users of this crate should not need any code changes. As this removes the dependency on the `libdbus` system library, you can uninstall it if desired.

## v0.1.0 -> v0.2.0

### libcontainer

Expand Down
2 changes: 1 addition & 1 deletion crates/libcgroups/src/systemd/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ mod controller;
pub mod controller_type;
mod cpu;
mod cpuset;
pub mod dbus_native;
mod dbus_native;
pub mod manager;
mod memory;
mod pids;
Expand Down
11 changes: 11 additions & 0 deletions docs/src/developer/libcgroups.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,3 +28,14 @@ This crates exposes several functions and modules that can be used to work with
- Cgroups V2 module which deal with implementing a cgroup manager for systems which have cgroups v2

As youki currently depends on systemd as an init system, this crate also exposes module systemd, which provides interface for working with systemd related operations. [systemd resource control](https://www.freedesktop.org/software/systemd/man/systemd.resource-control.html) is a good place to read more about systemd and its involvement in resource control.

## Dbus Native

This module is the native implementation of dbus connection functionality used for connecting with systemd via dbus. Refer to [this issue discussion](https://github.com/containers/youki/issues/2208) following for the discussion regarding moving away from existing dbus-interfacing library.

Note that this implements the minimal required functionality for youki to use dbus, and thus does not have all the dbus features.

- Refer to see [dbus specification](https://dbus.freedesktop.org/doc/dbus-specification.html) and [header format](https://dbus.freedesktop.org/doc/api/html/structDBusHeader.html) for the individual specifications.

- For systemd interface and types, you can generate the following file and take help from the auto-generated functions
`dbus-codegen-rust -s -g -m None -d org.freedesktop.systemd1 -p /org/freedesktop/systemd1`, see https://github.com/diwic/dbus-rs
10 changes: 0 additions & 10 deletions docs/src/user/dbus-native.md

This file was deleted.

0 comments on commit 263e6b8

Please sign in to comment.