[tarantool-patches] Re[2]: [tarantool-patches] Fwd: [patches] [log 2/2] say: Fix log_rotate

Ilya Markov imarkov at tarantool.org
Thu Mar 29 14:17:59 MSK 2018


>On Wednesday, March 28, 2018 11:06:10 AM MSK Ilya Markov wrote:
>> -if (log->type != SAY_LOGGER_FILE) {
>> +if (pm_atomic_load(&log->type) != SAY_LOGGER_FILE)
>>  return 0;
>I am not sure you really need to use atomic. What the case you are  trying to 
>fix?

I use this variable as flag indicating whether it's allowed to start rotating.
I need here atomic because it is used in concurrent threads(tx thread in log_destroy and eio-worker thread in log_rotate).

-- 
Thank you,
Ilya Markov


More information about the Tarantool-patches mailing list