Skip to content

Commit

Permalink
Added env_info to connection
Browse files Browse the repository at this point in the history
  • Loading branch information
amigin committed Feb 20, 2025
1 parent 0b8139c commit 7e8fe4a
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion my-service-bus-tcp-client/src/new_connection_handler.rs
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,15 @@ pub async fn send_greeting(
app_version: &str,
client_version: &str,
) {
let mut name = format!("{}:{};{}", app_name, app_version, client_version);

if let Ok(value) = std::env::var("ENV_INFO") {
name.push(';');
name.push_str(&value);
}

let greeting = MySbTcpContract::Greeting {
name: format!("{}:{};{}", app_name, app_version, client_version),
name,
protocol_version: DEFAULT_TCP_PROTOCOL_VERSION,
};

Expand Down

0 comments on commit 7e8fe4a

Please sign in to comment.