node: Enable logging via systemd journal
The radicle-systemd crate is split into two modules, one for socket activation, and one for logging.
Both are behind feature flags.
radicle-node continues to depend on radicle-systemd.
Logging initialization code was removed from radicle, as it is a library crate.
17 files changed
+310
-146
7a9d4512
→
d7b48b9e
modified Cargo.lock
@@ -327,7 +327,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
|
|
|
|
| - | |
| + | |
|
|
|
|
|
@@ -809,6 +809,27 @@ dependencies = [
|
|
|
|
|
|
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
|
|
|
|
|
@@ -853,8 +874,8 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
|
|
|
|
| - | |
| - | |
| + | |
| + | |
|
|
|
|
|
@@ -1841,7 +1862,7 @@ dependencies = [
|
|
|
|
|
|
| - | |
| + | |
|
|
|
|
|
@@ -1957,6 +1978,15 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
|
|
|
|
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
|
|
|
|
|
@@ -2082,6 +2112,16 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
|
|
|
|
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
|
|
|
|
|
@@ -2197,6 +2237,12 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
|
|
|
|
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
|
|
|
|
|
@@ -2301,6 +2347,12 @@ dependencies = [
|
|
|
|
|
|
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
|
|
|
|
|
@@ -2687,6 +2739,7 @@ dependencies = [
|
|
|
|
|
|
| + | |
|
|
|
|
|
@@ -2719,6 +2772,7 @@ dependencies = [
|
|
|
|
|
|
| + | |
|
|
|
|
|
@@ -2782,6 +2836,10 @@ dependencies = [
|
|
|
|
|
|
| + | |
| + | |
| + | |
| + | |
|
|
|
|
|
@@ -2883,8 +2941,17 @@ checksum = "b544ef1b4eac5dc2db33ea63606ae9ffcfac26c1416a2806ae0bf5f56b201191"
|
|
|
|
|
|
| - | |
| - | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
|
|
|
|
|
@@ -2895,11 +2962,17 @@ checksum = "809e8dc61f6de73b46c85f4c96486310fe304c434cfa43669d7b40f711150908"
|
|
|
|
|
|
| - | |
| + | |
|
|
|
|
|
|
|
|
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
|
|
|
|
|
@@ -3142,6 +3215,15 @@ dependencies = [
|
|
|
|
|
|
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
|
|
|
|
|
@@ -3431,6 +3513,16 @@ dependencies = [
|
|
|
|
|
|
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
|
|
|
|
|
@@ -3454,6 +3546,28 @@ dependencies = [
|
|
|
|
|
|
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
|
|
|
|
|
@@ -3494,6 +3608,15 @@ dependencies = [
|
|
|
|
|
|
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
|
|
|
|
|
@@ -3525,6 +3648,54 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
|
|
|
|
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
|
|
|
|
|
@@ -3532,7 +3703,7 @@ checksum = "b67baf55e7e1b6806063b1e51041069c90afff16afcbbccd278d899f9d84bca4"
|
|
|
|
|
|
| - | |
| + | |
|
|
|
|
|
@@ -3781,6 +3952,12 @@ dependencies = [
|
|
|
|
|
|
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
|
|
|
|
|
modified crates/radicle-cli-test/src/lib.rs
@@ -207,9 +207,13 @@ impl TestFormula {
|
|
|
|
|
|
| - | |
| + | |
|
|
| - | |
| + | |
| + | |
| + | |
| + | |
| + | |
|
|
|
|
|
modified crates/radicle-cli/src/main.rs
@@ -30,7 +30,9 @@ enum Command {
|
|
|
|
|
|
| - | |
| + | |
| + | |
| + | |
|
|
|
|
|
modified crates/radicle-cli/tests/commands.rs
@@ -744,7 +744,6 @@ fn rad_node_connect() {
|
|
|
|
|
|
| - | |
|
|
|
|
|
@@ -922,7 +921,6 @@ fn rad_patch_ahead_behind() {
|
|
|
|
|
|
| - | |
|
|
|
|
|
@@ -1229,8 +1227,6 @@ fn rad_clone_partial_fail() {
|
|
|
|
|
|
| - | |
| - | |
|
|
|
|
|
@@ -1990,8 +1986,6 @@ fn rad_patch_pull_update() {
|
|
|
|
|
|
| - | |
| - | |
|
|
|
|
|
modified crates/radicle-node/Cargo.toml
@@ -55,3 +55,4 @@ qcheck-macros = { workspace = true }
|
|
|
|
|
|
| + | |
|
modified crates/radicle-node/src/main.rs
@@ -4,7 +4,6 @@ use std::{env, fs, net, path::PathBuf, process};
|
|
|
|
|
|
| - | |
|
|
|
|
|
@@ -91,7 +90,24 @@ fn execute() -> anyhow::Result<()> {
|
|
|
|
|
|
| - | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
|
|
|
|
|
modified crates/radicle-node/src/runtime.rs
@@ -341,7 +341,7 @@ impl Runtime {
|
|
|
|
|
|
| - | |
| + | |
|
|
|
|
|
modified crates/radicle-node/src/tests.rs
@@ -846,8 +846,6 @@ fn test_refs_announcement_relay_private() {
|
|
|
|
|
|
| - | |
| - | |
|
|
|
|
|
@@ -892,8 +890,6 @@ fn test_refs_announcement_fetch_trusted_no_inventory() {
|
|
|
|
|
|
| - | |
| - | |
|
|
|
|
|
@@ -1068,8 +1064,6 @@ fn test_refs_announcement_offline() {
|
|
|
|
|
|
| - | |
| - | |
|
|
|
|
|
@@ -1486,8 +1480,6 @@ fn test_queued_fetch_max_capacity() {
|
|
|
|
|
|
| - | |
| - | |
|
|
|
|
|
@@ -1608,8 +1600,6 @@ fn test_queued_fetch_from_command_same_rid() {
|
|
|
|
|
|
| - | |
| - | |
|
|
|
|
|
modified crates/radicle-node/src/tests/e2e.rs
@@ -1,5 +1,7 @@
|
|
|
|
| + | |
| + | |
|
|
|
|
|
@@ -16,7 +18,6 @@ use crate::node::config::Limits;
|
|
|
|
|
|
| - | |
|
|
|
|
|
@@ -48,8 +49,6 @@ mod config {
|
|
|
|
|
|
| - | |
| - | |
|
|
|
|
|
@@ -72,8 +71,6 @@ fn test_inventory_sync_basic() {
|
|
|
|
|
|
| - | |
| - | |
|
|
|
|
|
@@ -102,8 +99,6 @@ fn test_inventory_sync_bridge() {
|
|
|
|
|
|
| - | |
| - | |
|
|
|
|
|
@@ -139,8 +134,6 @@ fn test_inventory_sync_ring() {
|
|
|
|
|
|
| - | |
| - | |
|
|
|
|
|
@@ -172,8 +165,6 @@ fn test_inventory_sync_star() {
|
|
|
|
|
|
| - | |
| - | |
|
|
|
|
|
@@ -247,8 +238,6 @@ fn test_replication() {
|
|
|
|
|
|
| - | |
| - | |
|
|
|
|
|
@@ -341,8 +330,6 @@ fn test_replication_invalid() {
|
|
|
|
|
|
| - | |
| - | |
|
|
|
|
|
@@ -394,8 +381,6 @@ fn test_migrated_clone() {
|
|
|
|
|
|
| - | |
| - | |
|
|
|
|
|
@@ -421,8 +406,6 @@ fn test_dont_fetch_owned_refs() {
|
|
|
|
|
|
| - | |
| - | |
|
|
|
|
|
@@ -476,8 +459,6 @@ fn test_fetch_followed_remotes() {
|
|
|
|
|
|
| - | |
| - | |
|
|
|
|
|
@@ -505,8 +486,6 @@ fn test_missing_remote() {
|
|
|
|
|
|
| - | |
| - | |
|
|
|
|
|
@@ -551,8 +530,6 @@ fn test_fetch_preserve_owned_refs() {
|
|
|
|
|
|
| - | |
| - | |
|
|
|
|
|
@@ -609,8 +586,6 @@ fn test_clone() {
|
|
|
|
|
|
| - | |
| - | |
|
|
|
|
|
@@ -638,8 +613,6 @@ fn test_fetch_up_to_date() {
|
|
|
|
|
|
| - | |
| - | |
|
|
|
|
|
@@ -667,8 +640,6 @@ fn test_fetch_unseeded() {
|
|
|
|
|
|
| - | |
| - | |
|
|
|
|
|
@@ -703,8 +674,6 @@ fn test_large_fetch() {
|
|
|
|
|
|
| - | |
| - | |
|
|
|
|
|
@@ -810,8 +779,6 @@ fn test_concurrent_fetches() {
|
|
|
|
|
|
| - | |
| - | |
|
|
|
|
|
@@ -877,8 +844,6 @@ fn test_connection_crossing() {
|
|
|
|
|
|
| - | |
| - | |
|
|
|
|
|
@@ -985,8 +950,6 @@ fn test_non_fastforward_sigrefs() {
|
|
|
|
|
|
| - | |
| - | |
|
|
|
|
|
@@ -1081,8 +1044,6 @@ fn test_outdated_sigrefs() {
|
|
|
|
|
|
| - | |
| - | |
|
|
|
|
|
@@ -1169,8 +1130,6 @@ fn test_outdated_delegate_sigrefs() {
|
|
|
|
|
|
| - | |
| - | |
|
|
|
|
|
@@ -1227,9 +1186,6 @@ fn missing_delegate_default_branch() {
|
|
|
|
|
|
| - | |
| - | |
| - | |
|
|
|
|
|
@@ -1350,8 +1306,6 @@ fn missing_delegate_default_branch() {
|
|
|
|
|
|
| - | |
| - | |
|
|
|
|
|
@@ -1439,8 +1393,6 @@ fn test_background_foreground_fetch() {
|
|
|
|
|
|
| - | |
| - | |
|
|
|
|
|
@@ -1477,8 +1429,6 @@ fn test_catchup_on_refs_announcements() {
|
|
|
|
|
|
| - | |
| - | |
|
|
|
|
|
@@ -1505,8 +1455,6 @@ fn test_multiple_offline_inits() {
|
|
|
|
|
|
| - | |
| - | |
|
|
|
|
|
modified crates/radicle-remote-helper/Cargo.toml
@@ -14,6 +14,7 @@ name = "git-remote-rad"
|
|
|
|
|
|
| + | |
|
|
|
|
|
modified crates/radicle-remote-helper/src/git-remote-rad.rs
@@ -14,7 +14,10 @@ fn main() {
|
|
|
|
|
|
| - | |
| + | |
| + | |
| + | |
| + | |
|
|
|
|
|
modified crates/radicle-systemd/Cargo.toml
@@ -7,3 +7,12 @@ license.workspace = true
|
|
|
|
|
|
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
|
added crates/radicle-systemd/src/journal.rs
@@ -0,0 +1,23 @@
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
modified crates/radicle-systemd/src/lib.rs
@@ -1,41 +1,7 @@
|
|
|
|
| - | |
| - | |
| - | |
| + | |
| + | |
|
|
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| + | |
| + | |
added crates/radicle-systemd/src/listen.rs
@@ -0,0 +1,39 @@
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
modified crates/radicle/src/logger.rs
@@ -10,13 +10,19 @@ use std::io::Write;
|
|
|
|
|
|
| - | |
| + | |
|
|
|
|
|
|
|
|
|
|
|
|
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
|
|
|
|
|
@@ -84,19 +90,6 @@ impl Log for StderrLogger {
|
|
|
|
|
|
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
|
|
|
|
|
modified crates/radicle/src/logger/test.rs
@@ -1,10 +1,16 @@
|
|
|
|
|
|
| - | |
| + | |
|
|
|
|
|
|
| + | |
| + | |
| + | |
| + | |
| + | |
| + | |
|
|
|
|
|
@@ -57,11 +63,3 @@ impl Log for Logger {
|
|
|
|
|
|
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |
| - | |