Skip to content

Commit

Permalink
feat: add two setters on Dependency telemetry
Browse files Browse the repository at this point in the history
  • Loading branch information
vegardgs-ksat committed Jan 30, 2024
1 parent 1794ff2 commit b931888
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions appinsights/src/telemetry/remote_dependency.rs
Original file line number Diff line number Diff line change
Expand Up @@ -146,6 +146,16 @@ impl RemoteDependencyTelemetry {
pub fn set_id(&mut self, id: impl Into<String>) {
self.id = Some(id.into());
}

/// Set the `data` field of the dependency trace.
pub fn set_data(&mut self, data: impl Into<String>) {
self.data = Some(data.into());
}

/// Set the `tags` fields of the telemetry, replacing the existing one.
pub fn set_tags(&mut self, tags: ContextTags) {
self.tags = tags;
}
}

impl Telemetry for RemoteDependencyTelemetry {
Expand Down

0 comments on commit b931888

Please sign in to comment.