You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Jan 5, 2022. It is now read-only.
When PHP Daemon tears itself down for an automatic reboot it invokes its own destruct method explicitly. The destruct method loops through worker and plugin aliases, invoking each of their teardown methods and removing the objects
foreach(array_merge($this->workers, $this->plugins) as $object) {
$this->{$object}->teardown();
unset($this->{$object});
}
However, the aliases are maintained in the arrays. I'm noticing that occasionally the PHP interpreter is invoking the destruct method again. In the second iteration, the workers and plugins are already unset so it attempts to call a method on an undefined property. The error that is raised causes PHP Daemon to attempt to restart itself.... Which calls the destruct method again and the whole party continues.
Because the original restart was actually successful in spawning a new instance of the daemon, you end up with one correctly functioning daemon and a few endless looping walking dead daemons.
I'm using version 2.1.1. Also, thanks for the library and the great documentation! Overall, this has been working great for me.
The text was updated successfully, but these errors were encountered:
Sign up for freeto subscribe to this conversation on GitHub.
Already have an account?
Sign in.
This is possibly related to #57.
When PHP Daemon tears itself down for an automatic reboot it invokes its own destruct method explicitly. The destruct method loops through worker and plugin aliases, invoking each of their teardown methods and removing the objects
However, the aliases are maintained in the arrays. I'm noticing that occasionally the PHP interpreter is invoking the destruct method again. In the second iteration, the workers and plugins are already unset so it attempts to call a method on an undefined property. The error that is raised causes PHP Daemon to attempt to restart itself.... Which calls the destruct method again and the whole party continues.
Because the original restart was actually successful in spawning a new instance of the daemon, you end up with one correctly functioning daemon and a few endless looping walking dead daemons.
I'm using version 2.1.1. Also, thanks for the library and the great documentation! Overall, this has been working great for me.
The text was updated successfully, but these errors were encountered: