Reservations for multi threads

dariesto

Client
Регистрация
03.11.2011
Сообщения
124
Благодарностей
9
Баллы
18
Hi Guys,

My proposal for consideration is to implement some kind of reservation when table/list is fully synchronised, so one thread can block access for others until it finishes operations. For example one thread is reading line and processing that data and/or making some changes in the line a then unlocking access to file for other threads.

Such feature could be solution for multithreaded access to file without need to deleting the line and writing it at any failure in the template.

The second way to improve avoiding to process the same data by many threads could be global table in project (used only for reservations) with queued and lockable access, where threads can write data which are reserved for them along with having possibility to search for reserved data by others.

Any comments are welcome.
 

Drew

Client
Регистрация
29.07.2012
Сообщения
70
Благодарностей
14
Баллы
8
I hate to bump this because it's old but why has no one else brought up the idea of global lists or tables.

Do really really have to deal with disk writes as the only way to deal with multi threading and large lists?
 

Кто просматривает тему: (Всего: 1, Пользователи: 0, Гости: 1)