Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 4 additions & 3 deletions bottlecap/src/bin/bottlecap/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1134,9 +1134,10 @@ fn start_trace_agent(
obfuscation_redis_remove_all_args: false,
};

let trace_processor = Arc::new(trace_processor::ServerlessTraceProcessor {
obfuscation_config: Arc::new(obfuscation_config),
});
let trace_processor = Arc::new(trace_processor::ServerlessTraceProcessor::new(
config.as_ref(),
obfuscation_config,
));

let (span_dedup_service, span_dedup_handle) = span_dedup_service::DedupService::new();
tokio::spawn(span_dedup_service.run());
Expand Down
4 changes: 2 additions & 2 deletions bottlecap/src/config/env.rs
Original file line number Diff line number Diff line change
Expand Up @@ -226,7 +226,7 @@ pub struct EnvConfig {
/// @env `DD_APM_FILTER_TAGS_REQUIRE`
///
/// Space-separated list of key:value tag pairs that spans must match to be kept.
/// Only spans matching at least one of these tags will be sent to Datadog.
/// Only spans matching all of these tags will be sent to Datadog.
/// Example: "env:production service:api-gateway"
#[serde(deserialize_with = "deserialize_apm_filter_tags")]
pub apm_filter_tags_require: Option<Vec<String>>,
Expand All @@ -240,7 +240,7 @@ pub struct EnvConfig {
/// @env `DD_APM_FILTER_TAGS_REGEX_REQUIRE`
///
/// Space-separated list of key:value tag pairs with regex values that spans must match to be kept.
/// Only spans matching at least one of these regex patterns will be sent to Datadog.
/// Only spans matching all of these regex patterns will be sent to Datadog.
/// Example: "env:^prod.*$ service:^api-.*$"
#[serde(deserialize_with = "deserialize_apm_filter_tags")]
pub apm_filter_tags_regex_require: Option<Vec<String>>,
Expand Down
26 changes: 13 additions & 13 deletions bottlecap/src/lifecycle/invocation/processor.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1671,9 +1671,11 @@ mod tests {
// Create trace sender
let trace_sender = Arc::new(SendingTraceProcessor {
appsec: None,
processor: Arc::new(trace_processor::ServerlessTraceProcessor {
obfuscation_config: Arc::new(ObfuscationConfig::new().expect("Failed to create ObfuscationConfig")),
}),
processor: Arc::new(trace_processor::ServerlessTraceProcessor::new(
config.as_ref(),
ObfuscationConfig::new()
.expect("Failed to create ObfuscationConfig"),
)),
trace_tx: tokio::sync::mpsc::channel(1).0,
stats_generator: Arc::new(StatsGenerator::new(stats_concentrator_handle)),
});
Expand Down Expand Up @@ -1779,11 +1781,10 @@ mod tests {
tokio::spawn(stats_concentrator_service.run());
let trace_sender = Arc::new(SendingTraceProcessor {
appsec: None,
processor: Arc::new(trace_processor::ServerlessTraceProcessor {
obfuscation_config: Arc::new(
ObfuscationConfig::new().expect("Failed to create ObfuscationConfig"),
),
}),
processor: Arc::new(trace_processor::ServerlessTraceProcessor::new(
config.as_ref(),
ObfuscationConfig::new().expect("Failed to create ObfuscationConfig"),
)),
trace_tx: tokio::sync::mpsc::channel(1).0,
stats_generator: Arc::new(StatsGenerator::new(stats_concentrator_handle)),
});
Expand Down Expand Up @@ -2174,11 +2175,10 @@ mod tests {
tokio::spawn(stats_concentrator_service.run());
let trace_sender = Arc::new(SendingTraceProcessor {
appsec: None,
processor: Arc::new(trace_processor::ServerlessTraceProcessor {
obfuscation_config: Arc::new(
ObfuscationConfig::new().expect("Failed to create ObfuscationConfig"),
),
}),
processor: Arc::new(trace_processor::ServerlessTraceProcessor::new(
config.as_ref(),
ObfuscationConfig::new().expect("Failed to create ObfuscationConfig"),
)),
trace_tx,
stats_generator: Arc::new(StatsGenerator::new(stats_concentrator_handle)),
});
Expand Down
Loading
Loading