11import asyncio
2- import time
32from typing import TYPE_CHECKING , Any , Dict , List , Optional , Tuple
43from uuid import UUID
54
@@ -218,15 +217,11 @@ async def run(self):
218217
219218 while True :
220219 try :
221- # 1. Read batch from stream (idle blocks return empty, never tick)
222- read_started = time .perf_counter ()
220+ # 1. Read batch from stream
223221 batch = await self .read_batch ()
224222 if not batch :
225223 continue
226224
227- read_ms = (time .perf_counter () - read_started ) * 1000
228- started = time .perf_counter ()
229-
230225 # 2. Process batch
231226 ingested , processed_ids , batches = await self .process_batch (batch )
232227
@@ -245,10 +240,6 @@ async def run(self):
245240 "[EVENTS] Skipping ACK/DEL due to webhook dispatch failure" ,
246241 batch_size = len (batch ),
247242 )
248- log .tick (
249- f"{ self .metric_stream } .errors" ,
250- dims = {"stream" : self .metric_stream },
251- )
252243 continue
253244 else :
254245 log .info (
@@ -264,16 +255,6 @@ async def run(self):
264255 batch_size = len (batch ),
265256 ingested = ingested ,
266257 )
267- log .tick (
268- f"{ self .metric_stream } .processed" ,
269- count = len (processed_ids ),
270- duration_ms = (time .perf_counter () - started ) * 1000 ,
271- read_ms = read_ms ,
272- dims = {"stream" : self .metric_stream },
273- )
274258 except Exception :
275259 log .error ("[EVENTS] Worker loop error" , exc_info = True )
276- log .tick (
277- f"{ self .metric_stream } .errors" , dims = {"stream" : self .metric_stream }
278- )
279260 await asyncio .sleep (1 )
0 commit comments