Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

README.developer.md: update #521

Merged
merged 2 commits into from
Aug 31, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .markdownlint-cli2.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,4 @@ globs:
ignores:
- "doc/man/*.md"
- "subprojects/*/*.md"
- "README.developer.md"
54 changes: 54 additions & 0 deletions README.developer.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
- [Linting](#linting)
- [Build](#build)
- [Debug](#debug)
- [Busctl](#busctl)
- [Unit Tests](#unit-tests)
- [Integration Tests](#integration-tests)
- [Running](#running)
Expand Down Expand Up @@ -55,6 +56,59 @@ sudo dnf install \
Check the [installation guide](https://github.com/DavidAnson/markdownlint-cli2#install) and use the most appropriate way
of installation for your setup.

### busctl

**busctl** is a systemd tool to introspect and monitor the D-Bus bus. See below some examples using busctl with bluechi service.

**Instrospect org.eclipse.bluechi**:
```bash
# busctl introspect \
org.eclipse.bluechi \
/org/eclipse/bluechi

NAME TYPE SIGNATURE RESULT/VALUE FLAGS
org.eclipse.bluechi.Manager interface - - -
.CreateMonitor method - o -
.DisableMetrics method - - -
.EnableMetrics method - - -
.GetNode method s o -
.ListNodes method - a(sos) -
.ListUnits method - a(sssssssouso) -
.Ping method s s -
.SetLogLevel method s - -
.JobNew signal uo - -
.JobRemoved signal uosss - -
.NodeConnectionStateChanged signal ss - -
org.eclipse.bluechi.Shutdown interface - - -
.Shutdown method - - -
org.freedesktop.DBus.Introspectable interface - - -
.Introspect method - s -
org.freedesktop.DBus.Peer interface - - -
.GetMachineId method - s -
.Ping method - - -
org.freedesktop.DBus.Properties interface - - -
.Get method ss v -
.GetAll method s a{sv} -
.Set method ssv - -
.PropertiesChanged signal sa{sv}as - -
```

**Example calling ListNodes**:
```bash
export SERVICE="org.eclipse.bluechi"
export OBJECT="/org/eclipse/bluechi"
export INTERFACE="org.eclipse.bluechi.Manager"
export METHOD="ListNodes"

# busctl call \
"${SERVICE}" \
"${OBJECT}" \
"${INTERFACE}" \
"${METHOD}"

a(sos) 3 "control" "/org/eclipse/bluechi/node/control" "online" "node1" "/org/eclipse/bluechi/node/node1" "online" "qm-node1" "/org/eclipse/bluechi/node/qm_2dnode1" "online"
```

### Code Style

[clang-format](https://clang.llvm.org/docs/ClangFormat.html) is used to enforce a uniform code style. The formatting
Expand Down