----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: https://reviews.apache.org/r/65305/#review196143 -----------------------------------------------------------
3rdparty/libprocess/src/process.cpp Lines 506 (patched) <https://reviews.apache.org/r/65305/#comment275647> Any specific reason why this is not a value, i.e., ``` static std::mutex authorization_callbacks_mutex; ``` - Alexander Rukletsov On Jan. 24, 2018, 12:54 a.m., Benjamin Mahler wrote: > > ----------------------------------------------------------- > This is an automatically generated e-mail. To reply, visit: > https://reviews.apache.org/r/65305/ > ----------------------------------------------------------- > > (Updated Jan. 24, 2018, 12:54 a.m.) > > > Review request for mesos, Alexander Rukletsov, Alexander Rojas, and Joseph Wu. > > > Bugs: MESOS-8453 > https://issues.apache.org/jira/browse/MESOS-8453 > > > Repository: mesos > > > Description > ------- > > The authorization callbacks are not mutated in a thread-safe manner: > a `Process` may be calling a callback while the callbacks are being > deleted by another thread. > > The fix here for now is to make the mutation and access synchronized > under a mutex. The mutex is non-recursive, which means that the > callbacks must not be cleared or re-set from within a callback. This > is already a requirement, since a callback calling in to clear or > re-set the callbacks is thereby deleting itself! > > Some TODOs were left for performance improvements. Since the HTTP > likely has much more significant bottlenecks, I left these as TODOs. > > > Diffs > ----- > > 3rdparty/libprocess/src/process.cpp > 2126c272a69bfa53b4b3cbbb1a55a3f81a5da8ad > > > Diff: https://reviews.apache.org/r/65305/diff/1/ > > > Testing > ------- > > make check > > > Thanks, > > Benjamin Mahler > >
