Skip to content

Commit 660bbd7

Browse files
committed
Remove daemonize feature
1 parent 7e15c74 commit 660bbd7

File tree

4 files changed

+4
-38
lines changed

4 files changed

+4
-38
lines changed

Cargo.lock

Lines changed: 2 additions & 13 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,8 +25,8 @@ keywords = ["uProtocol", "uSubscription"]
2525
license = "Apache-2.0"
2626
readme = "README.md"
2727
repository = "https://github.com/eclipse-uprotocol/up-subscription-rust"
28-
rust-version = "1.82"
29-
version = "0.3.0"
28+
rust-version = "1.87"
29+
version = "0.4.0"
3030

3131
[workspace.dependencies]
3232
async-trait = { version = "0.1" }

up-subscription-cli/Cargo.toml

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,3 @@ up-rust = { workspace = true }
4343
up-subscription = { workspace = true }
4444
up-transport-mqtt5 = { version = "0.4.0", optional = true }
4545
up-transport-zenoh = { version = "0.9.0", optional = true }
46-
47-
[target.'cfg(unix)'.dependencies]
48-
daemonize2 = { version = "0.6" }

up-subscription-cli/src/main.rs

Lines changed: 0 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -20,9 +20,6 @@ use tokio::signal;
2020
use up_rust::{LocalUriProvider, UTransport};
2121
use up_subscription::{ConfigurationError, USubscriptionConfiguration, USubscriptionService};
2222

23-
#[cfg(unix)]
24-
use daemonize2::Daemonize;
25-
2623
#[cfg(feature = "mqtt5")]
2724
use up_transport_mqtt5::Mqtt5TransportOptions;
2825

@@ -85,11 +82,6 @@ pub(crate) struct Args {
8582
#[arg(short, long, env)]
8683
authority: String,
8784

88-
/// Run as a daemon (in the background)
89-
#[cfg(unix)]
90-
#[arg(short, long, default_value_t = false)]
91-
daemon: bool,
92-
9385
/// The transport implementation to use
9486
#[arg(short, long, env)]
9587
transport: Transport,
@@ -189,18 +181,6 @@ async fn main() {
189181
_config.get_source_uri()
190182
);
191183

192-
// Daemonize or wait for shutdown signal
193-
#[cfg(unix)]
194-
if args.daemon {
195-
let daemonize = Daemonize::new();
196-
match unsafe { daemonize.start() } {
197-
Ok(_) => {
198-
debug!("Success, running daemonized");
199-
}
200-
Err(e) => error!("Error, {e}"),
201-
}
202-
}
203-
204184
signal::ctrl_c().await.expect("failed to listen for event");
205185
info!("Stopping usubscription service");
206186
ustop.stop().await;

0 commit comments

Comments
 (0)