Files
MaxScale/server/core
Markus Mäkelä efd953c434 MXS-1929: Store service active state atomically
When a session is closed, it releases a reference on the service and
checks if it was the last session for a destroyed service. The state of
the service was loaded after the reference count was decremented.  This
behavior introduced a race condition where it was possible for a service
to be freed twice, first by the thread that marked the service as
destroyed and again by the last session for that service. By always
loading the service state before decrementing the reference count, we
avoid this race condition.

Currently, the memory ordering used for the reference counting is too
strict and could be relaxed. By default, all atomic operations use
sequentially consistent memory ordering. This guarantees correct behavior
but imposes a performance penalty. Incrementing the reference counts could
be done with a relaxed memory order as long as as we know the reference
we're incrementing is valid. Releasing a reference must use an
acquire-release order to guarantee the read-modify-write operation is
successful.
2018-07-31 09:41:12 +03:00
..
2018-07-26 11:27:09 +03:00
2018-06-25 10:07:52 +03:00
2018-06-25 10:07:52 +03:00
2018-06-25 10:07:52 +03:00
2018-06-25 10:07:52 +03:00
2018-07-26 11:27:09 +03:00
2018-06-22 13:59:57 +03:00
2018-07-17 11:52:23 +03:00
2018-07-31 09:41:06 +03:00
2018-06-25 10:07:52 +03:00
2018-06-25 10:07:52 +03:00
2018-06-25 10:07:52 +03:00
2018-06-25 10:07:52 +03:00
2018-06-25 10:07:52 +03:00
2018-06-25 10:07:52 +03:00
2018-06-25 10:07:52 +03:00
2018-06-25 10:07:52 +03:00
2018-07-31 09:41:06 +03:00
2018-06-25 10:07:52 +03:00
2018-06-25 10:07:52 +03:00
2018-06-25 10:07:52 +03:00
2018-06-25 10:07:52 +03:00
2018-06-25 10:07:52 +03:00
2018-06-26 09:19:46 +03:00
2018-06-25 10:07:52 +03:00
2018-06-25 10:07:52 +03:00
2018-07-26 11:27:09 +03:00
2018-06-25 10:07:52 +03:00
2018-06-25 10:07:52 +03:00
2018-06-25 10:07:52 +03:00
2018-06-25 10:07:52 +03:00
2018-06-25 10:07:52 +03:00
2018-06-25 10:07:52 +03:00
2018-07-09 12:10:36 +03:00
2018-06-25 10:07:52 +03:00
2018-06-25 10:07:52 +03:00
2018-06-25 10:07:52 +03:00
2018-06-25 10:07:52 +03:00
2018-06-25 10:07:52 +03:00
2018-06-25 10:07:52 +03:00
2018-06-25 10:07:52 +03:00
2018-06-25 10:07:52 +03:00