-
Notifications
You must be signed in to change notification settings - Fork 7
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
raphf - is thread not safe #25
Comments
tag @bwoebi, any chance you could take a look at this? ext/raphf is used by pecl/http and pecl/pq for resource persistence, since this is not (afaik) a problem generally, I'm guessing this is something to do with the way it is interacting with pecl/uv. I'm sure @m6w6 can give you more info on the rationale behind, and inner workings of raphf if required. @uasan I'm confident that the first thing Bob will ask you for is a core dump, so it would be a good idea to make one available online somewhere and link it here if you can. |
At a quick glance into the raphf src, I see no true globals being used, making it thread safe. I don't think raphf itself is causing that crash, but rather something else … I'm wondering what |
Run php-zts.ini:
uv_queue_work.php: <?php
$loop = uv_default_loop();
$thread = function()
{
echo "THREAD-CALL\n";
};
$after = function()
{
echo "THREAD-CALL-AFTER\n";
};
uv_queue_work($loop, $thread, $after);
uv_queue_work($loop, $thread, $after);
$timer = uv_timer_init($loop);
uv_timer_start($timer, 1000, 1000, function() use($timer)
{
uv_close($timer);
echo "STOP\n";
});
uv_run($loop); Out:
|
Ugh, does |
It is… sigh. |
Thanks, closing then. |
Hello.
If delete
raphf.so
inphp.ini
then everything works well.How to compile the
pq
withoutraff
?We use
pq
inphp-cli
as daemon process, persistent connection do not need it.Thank.
The text was updated successfully, but these errors were encountered: