We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents 156ffe6 + 7bf821f commit 5ce2a27Copy full SHA for 5ce2a27
crates/ct_worker/src/batcher_do.rs
@@ -145,12 +145,10 @@ impl DurableObject for Batcher {
145
}
146
147
async fn alarm(&mut self) -> Result<Response> {
148
- if !self.initialized {
+ if !self.initialized || self.batch.pending_leaves.is_empty() {
149
return Response::empty();
150
151
- if !self.batch.pending_leaves.is_empty()
152
- && self.last_batch_millis + MAX_BATCH_TIMEOUT_MILLIS < util::now_millis()
153
- {
+ if self.last_batch_millis + MAX_BATCH_TIMEOUT_MILLIS < util::now_millis() {
154
if let Err(e) = self.submit_batch().await {
155
log::warn!("failed to submit batch: {e}");
156
0 commit comments