Skip to content

Commit 2f38582

Browse files
committed
put back some renaming
1 parent b8e51de commit 2f38582

File tree

2 files changed

+8
-8
lines changed

2 files changed

+8
-8
lines changed

bottlecap/src/lifecycle/invocation/processor.rs

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -310,11 +310,11 @@ impl Processor {
310310
// - metrics tags (for asm)
311311

312312
if let Some(tracer_span) = &context.tracer_span {
313-
self.span.meta.extend(tracer_span.meta.clone());
314-
self.span
313+
self.aws_lambda_span.meta.extend(tracer_span.meta.clone());
314+
self.aws_lambda_span
315315
.meta_struct
316316
.extend(tracer_span.meta_struct.clone());
317-
self.span.metrics.extend(tracer_span.metrics.clone());
317+
self.aws_lambda_span.metrics.extend(tracer_span.metrics.clone());
318318
}
319319

320320
if let Some(offsets) = &context.enhanced_metric_data {
@@ -435,7 +435,7 @@ impl Processor {
435435
/// If this method is called, it means that we are operating in a Universally Instrumented
436436
/// runtime. Therefore, we need to set the `tracer_detected` flag to `true`.
437437
///
438-
pub fn on_invocation_start(&mut self, headers: HashMap<String, String>, payload: Vec<u8>) {
438+
pub fn universal_instrumentation_start(&mut self, headers: HashMap<String, String>, payload: Vec<u8>) {
439439
self.tracer_detected = true;
440440

441441
let payload_value = serde_json::from_slice::<Value>(&payload).unwrap_or_else(|_| json!({}));
@@ -514,7 +514,7 @@ impl Processor {
514514

515515
/// Given trace context information, set it to the current span.
516516
///
517-
pub fn on_invocation_end(&mut self, headers: HashMap<String, String>, payload: Vec<u8>) {
517+
pub fn universal_instrumentation_end(&mut self, headers: HashMap<String, String>, payload: Vec<u8>) {
518518
let payload_value = serde_json::from_slice::<Value>(&payload).unwrap_or_else(|_| json!({}));
519519

520520
// Tag the invocation span with the request payload
@@ -862,7 +862,7 @@ mod tests {
862862
}
863863
"#;
864864

865-
p.on_invocation_end(HashMap::new(), response.as_bytes().to_vec());
865+
p.universal_instrumentation_end(HashMap::new(), response.as_bytes().to_vec());
866866

867867
assert_eq!(
868868
p.aws_lambda_span

bottlecap/src/lifecycle/listener.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,7 @@ impl Listener {
100100

101101
let headers = Self::headers_to_map(headers);
102102

103-
processor.on_invocation_start(headers, body);
103+
processor.universal_instrumentation_start(headers, body);
104104

105105
let mut response = Response::builder().status(200);
106106

@@ -151,7 +151,7 @@ impl Listener {
151151
let mut processor = invocation_processor.lock().await;
152152

153153
let headers = Self::headers_to_map(headers);
154-
processor.on_invocation_end(headers, body);
154+
processor.universal_instrumentation_end(headers, body);
155155
drop(processor);
156156

157157
Response::builder()

0 commit comments

Comments
 (0)