Skip to content

Commit

Permalink
Update worker.rs
Browse files Browse the repository at this point in the history
  • Loading branch information
oliverb123 authored Aug 6, 2024
1 parent d8ce6c4 commit 804494d
Showing 1 changed file with 8 additions and 12 deletions.
20 changes: 8 additions & 12 deletions rust/hook-worker/src/worker.rs
Original file line number Diff line number Diff line change
Expand Up @@ -266,18 +266,14 @@ async fn process_batch<'a>(

let results = join_all(futures).await;

if hog_mode {
if (push_hoghook_results_to_kafka(
results,
metadata_vec,
kafka_producer,
cdp_function_callbacks_topic,
)
.await)
.is_err()
{
return;
}
if hog_mode && push_hoghook_results_to_kafka(
results,
metadata_vec,
kafka_producer,
cdp_function_callbacks_topic,
).await.is_err()
{
return;
}

let _ = batch.commit().await.map_err(|e| {
Expand Down

0 comments on commit 804494d

Please sign in to comment.