elastic / apm-agent-php

Apache License 2.0
252 stars 69 forks source link

PHP CLI process hangs on the PeriodicTaskExecutor destructor's thread_.join() call #1209

Closed kisprof closed 2 weeks ago

kisprof commented 4 weeks ago

Describe the bug In our setup a main PHP CLI process triggered by cron is creating sub PHP processes to do work parallelly. We have observed that after some time, there are multiple child processes that are stuck. Their unit of work is completed, but they are not terminating. Upon further investigating these processes, we have seen that they are waiting for a lock to be released. After reproducing the issue locally we have seen in the traces that the PHP CLI process hangs on the PeriodicTaskExecutor class destructor's thread_.join() call.

To Reproduce Running the following setup reproduces the situation consistently for me:

Expected behavior PHP process should not stuck upon terminating when APM extension is enabled.

intuibase commented 1 week ago

Hey @kisprof

Could you please verify if latest (1.14) release fixed issue for you?

Thanks