Skip to content

Commit da70de9

Browse files
committed
client POST - do not requeue messages if response code is 400
Signed-off-by: Lance-Drane <[email protected]>
1 parent 869ea6d commit da70de9

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

proxy-http-client/src/poster.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,8 @@ impl HttpBroadcast for Poster {
3636
Ok(bytes) => tracing::debug!("{:?}", bytes),
3737
Err(err) => tracing::debug!("ERROR: {}", err.to_string()),
3838
}
39-
status < 400
39+
// if we get a client error, drop the message entirely; if we get a server error, requeue the message for later
40+
status < 500
4041
} else {
4142
let result = result.unwrap_err();
4243
tracing::error!("response is error {}", result.to_string());

0 commit comments

Comments
 (0)