I did web search for "site:stackoverflow.com yandex-tank Waiting for aggregator to finish" and found nothing that specific.
I start JMeter via Yandex-Tank (YT) and after JMeter finishes YT continues to write in log "Waiting for aggregator to finish" like forever. I've found some discussion here: https://gitter.im/yandex/yandex-tank?at=5ce2c4e36366992a94ef7826:
Покопал ещё, оказывается эти строки там были, но их убрали в коммите: 47623dd4b7a08e5383cbb4144eecc13edbdf3e96 Видимо закрытие reader нужно перенести по аналогии с Bfg в plugins/JMeter/plugin.py В функции end_test и is_test_finished
it is a discussion board in Russian, brief translation for non-russian speakers: "closing of reader should be moved to end_test & is_test_finished like it's done for BFG plugin".
However, as I see in code end_test
and is_test_finished
reader.close()
is already there yandextank/plugins/JMeter/plugin.py
:
def is_test_finished(self):
retcode = self.process.poll()
aggregator = self.core.job.aggregator
if not aggregator.reader.jmeter_finished and retcode is not None:
logger.info(
"JMeter process finished with exit code: %s, waiting for aggregator",
retcode)
self.retries = 0
aggregator.reader.jmeter_finished = True
return -1
elif aggregator.reader.jmeter_finished is True:
print("aggregator.reader.jmeter_finished is True")
if aggregator.reader.agg_finished:
self.reader.close()
return retcode
else:
logger.info("Waiting for aggregator to finish")
return -1
else:
return -1
def end_test(self, retcode):
if self.process:
gracefully_shutdown = self.__graceful_shutdown()
if not gracefully_shutdown:
self.__kill_jmeter()
if self.process_stderr:
self.process_stderr.close()
self.core.add_artifact_file(self.jmeter_log)
self.reader.close()
return retcode
How to fix that (to make YT finish cleanly after JM finish)?