jessestimpson commented on PR #56:
URL: https://github.com/apache/couchdb-erlfdb/pull/56#issuecomment-3678351239

   @qzhuyan Thanks for reporting this issue. It helped me debug the issue in my 
fork of erlfdb (linked below). A couple key differences though:
   
   1. I was not able to reproduce a segfault.
   2. I believe the fix for the deadlock is to move the call to 
`fdb_future_cancel` out of the mutex section. Checking the thread type in the 
callback seems insufficient because multiple Erlang scheduler threads could be 
accessing the future at the same time. In that scenario, the thread type check 
isn't specific enough. Instead, all the `fdb_future_*` functions themselves are 
thread-safe, so there should be no need to use the future lock when calling 
`fdb_future_cancel`.
   
   https://github.com/foundationdb-beam/erlfdb/pull/60
   
   Is there anything more you can share about the segfault you were seeing? I 
wonder if I missed something.


-- 
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]

Reply via email to