Is version 5 of MyDac thread-safe ?

Discussion of open issues, suggestions and bugs regarding MyDAC (Data Access Components for MySQL) for Delphi, C++Builder, Lazarus (and FPC)
Post Reply
CFaiga
Posts: 14
Joined: Sun 12 Feb 2006 09:28

Is version 5 of MyDac thread-safe ?

Post by CFaiga » Tue 04 Dec 2007 21:24

My System is using Mydac version 4 with Midas and a has a TMyConnection per thread
Antaeus wrote:> As the MyDac isn't thread-safe ...
MyDAC can work in multithreaded applications, so it is thread safe. But the restriction is that you cannot use one component for more than one thread simultaneously.
> are rthey compatible with Midas ?
Yes, MyDAC is compatible with Midas. Please see Midas demo for example.
> what must be done to make them thread safe ?
In your case using one instanse of TMyConnection per thread must be helpful.

Does version 5 have the same problem ?

using one connection per thread my applation can use up to 16 connections per user - and that is a problem

Do you have any ideas on how I can share 1 connection to many RDMs in a Midas application ?

Antaeus
Posts: 2098
Joined: Tue 14 Feb 2006 10:14

Post by Antaeus » Wed 05 Dec 2007 08:44

MyDAC 5 also requires that each TMyConnection object is used from a single thread at the same time.

CFaiga
Posts: 14
Joined: Sun 12 Feb 2006 09:28

Post by CFaiga » Wed 05 Dec 2007 11:13

Are there any plans to fix this in version 6

Antaeus
Posts: 2098
Joined: Tue 14 Feb 2006 10:14

Post by Antaeus » Wed 05 Dec 2007 13:38

We will consider possibility to add this improvement.

Post Reply