Skip to content

Commit

Permalink
chore: enhance cargo workspace and release build (#680)
Browse files Browse the repository at this point in the history
* chore: enhance cargo workspace and release build

---------

Co-authored-by: Henil Dedania <dedaniahenil@gmail.com>
  • Loading branch information
carlocorradini and henil authored Aug 17, 2023
1 parent 74ca53e commit b7c3086
Show file tree
Hide file tree
Showing 7 changed files with 39 additions and 18 deletions.
16 changes: 15 additions & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,8 +1,22 @@
[workspace]

members = [
"rumqttc",
"rumqttd",
"benchmarks",
"benchmarks/simplerouter",
]

[workspace.package]
rust-version = "1.70.0"
edition = "2021"
repository = "https://github.com/bytebeamio/rumqtt"
license = "Apache-2.0"
authors = ["tekjar <raviteja@bytebeam.io>"]

[profile.dev.build-override]
debug = true

[profile.release]
codegen-units = 1
lto = true
strip = true
9 changes: 6 additions & 3 deletions benchmarks/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,9 +1,12 @@
[package]
name = "benchmarks"
version = "0.4.0"
authors = ["tekjar <raviteja@bytebeam.io>"]
edition = "2018"
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
publish = false
rust-version.workspace = true
edition.workspace = true
repository.workspace = true
license.workspace = true
authors.workspace = true

[dependencies]
bytes = "1"
Expand Down
8 changes: 6 additions & 2 deletions benchmarks/simplerouter/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,8 +1,12 @@
[package]
name = "simplerouter"
version = "0.1.0"
edition = "2021"
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
publish = false
rust-version.workspace = true
edition.workspace = true
repository.workspace = true
license.workspace = true
authors.workspace = true

[dependencies]
bytes = "1"
Expand Down
10 changes: 6 additions & 4 deletions rumqttc/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,13 +1,15 @@
[package]
name = "rumqttc"
version = "0.22.0"
publish = true
description = "An efficient and robust mqtt client for your connected devices"
license = "Apache-2.0"
repository = "https://github.com/bytebeamio/rumqtt"
authors = ["tekjar"]
edition = "2018"
keywords = ["mqtt", "iot", "coap", "http"]
categories = ["network-programming"]
rust-version.workspace = true
edition.workspace = true
repository.workspace = true
license.workspace = true
authors.workspace = true

[package.metadata.docs.rs]
all-features = true
Expand Down
2 changes: 0 additions & 2 deletions rumqttc/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -528,8 +528,6 @@ impl MqttOptions {
/// options.set_transport(Transport::tls_with_config(client_config.into()));
/// ```
pub fn parse_url<S: Into<String>>(url: S) -> Result<MqttOptions, OptionError> {
use std::convert::TryFrom;

let url = url::Url::parse(&url.into())?;
let options = MqttOptions::try_from(url)?;

Expand Down
2 changes: 0 additions & 2 deletions rumqttc/src/v5/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -178,8 +178,6 @@ impl MqttOptions {
/// options.set_transport(Transport::tls_with_config(client_config.into()));
/// ```
pub fn parse_url<S: Into<String>>(url: S) -> Result<MqttOptions, OptionError> {
use std::convert::TryFrom;

let url = url::Url::parse(&url.into())?;
let options = MqttOptions::try_from(url)?;

Expand Down
10 changes: 6 additions & 4 deletions rumqttd/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,13 +1,15 @@
[package]
name = "rumqttd"
version = "0.17.0"
license = "Apache-2.0"
publish = true
description = "rumqttd is a high performance MQTT broker written in Rust which is light weight and embeddable"
authors = ["tekjar <raviteja@bytebeam.io>"]
edition = "2021"
keywords = ["mqtt", "broker", "iot", "kafka", "nats"]
categories = ["network-programming"]
repository = "https://github.com/bytebeamio/rumqtt/"
rust-version.workspace = true
edition.workspace = true
repository.workspace = true
license.workspace = true
authors.workspace = true

[dependencies]
tokio = { version = "1.0", features = ["rt", "time", "net", "io-util", "macros"]}
Expand Down

0 comments on commit b7c3086

Please sign in to comment.