tvalentyn commented on code in PR #35391:
URL: https://github.com/apache/beam/pull/35391#discussion_r2305246397
##########
sdks/python/apache_beam/runners/worker/worker_status.py:
##########
@@ -252,22 +257,26 @@ def _log_lull_in_bundle_processor(self,
bundle_process_cache):
self._log_lull_sampler_info(info, instruction)
def _log_lull_sampler_info(self, sampler_info, instruction):
- if not self._passed_lull_timeout_since_last_log():
+ if (not sampler_info or not sampler_info.time_since_transition):
return
- if (sampler_info and sampler_info.time_since_transition and
- sampler_info.time_since_transition > self.log_lull_timeout_ns):
- lull_seconds = sampler_info.time_since_transition / 1e9
- step_name = sampler_info.state_name.step_name
- state_name = sampler_info.state_name.name
- if step_name and state_name:
- step_name_log = (
- ' for PTransform{name=%s, state=%s}' % (step_name, state_name))
- else:
- step_name_log = ''
+ log_lull = self._passed_lull_timeout_since_last_log(
+ ) and sampler_info.time_since_transition > self.log_lull_timeout_ns
+ timeout_exceeded = self._element_processing_timeout_ns and
sampler_info.time_since_transition > self._element_processing_timeout_ns
+ if (not log_lull or not timeout_exceeded):
Review Comment:
> if (not log_lull or not timeout_exceeded):
should be
if not (log_lull or timeout_exceeded):
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]