On 10/04/2017 06:17, Mark Rotteveel wrote: > >> This code runs concurrently and find the same empty slot for >> simultaneous events being registered. > In the specific example, Jaybird uses a single connection to register > for events, and it takes a lock on the database handle, so there > wouldn't be concurrent que_events invocations on that connection. Is it > possible that a similar problem occurs when que_events call interleaves > with an even notification being posted back to the client? > > You are right, the Jaybird code syncs the op_que_event send/response.
However, server is reading/writing same data in multiple threads without using concurrency primitives. So they may not be accessing "simultaneously", but caching may have bad tricks in this condition. Adriano ------------------------------------------------------------------------------ Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot Firebird-Devel mailing list, web interface at https://lists.sourceforge.net/lists/listinfo/firebird-devel