Access Violation exception & Pooling mode

Discussion of open issues, suggestions and bugs regarding SDAC (SQL Server Data Access Components) for Delphi, C++Builder, Lazarus (and FPC)
Post Reply
Robert Grzegorzewski
Posts: 3
Joined: Tue 21 Jun 2016 09:05

Access Violation exception & Pooling mode

Post by Robert Grzegorzewski » Tue 21 Jun 2016 09:12

I am developing a large application that use SDAC intensively. Now I need to use a DisconnectMode, because my customer will use the application in unstable network environment (wifi, mobile internet etc.). It generally works fine but the application is now very slow. So I decided to enable Pooling and set ConnectionLifetime to 60000 ms. Now application works very quickly but unfortunately it sometimes raises an exceptions (Access Violation). What can be a reason of such behaviour? Is something more (relative to documentation) that I should set to use the Pooling Mode successfully? The important information is that I use DirectMode. I hope it is not a problem. My application is large and complex so I can't prepare easily a test environment to reproduce this error. Or maybe there is a possibility to use something like ConnectionLifetime together with DisconnectMode, but without using a Pooling Mode? It would be a great solution for me.

ViktorV
Devart Team
Posts: 2299
Joined: Wed 30 Jul 2014 07:16

Re: Access Violation exception & Pooling mode

Post by ViktorV » Tue 21 Jun 2016 10:48

Unfortunately, we can't reproduce this problem. To investigate this behavior of SDAC, please compose a small sample demonstrating the problem and send it to us, including database objects creating scripts.

Robert Grzegorzewski
Posts: 3
Joined: Tue 21 Jun 2016 09:05

Re: Access Violation exception & Pooling mode

Post by Robert Grzegorzewski » Tue 21 Jun 2016 10:55

Ok, I will try to prepare such a sample.

Could you answer my question?
Is there a possibility to use something like ConnectionLifetime together with DisconnectMode, but without using a Pooling Mode? Maybe it would be enough. I need to disconnect connection after some time of inactivity.

Robert

ViktorV
Devart Team
Posts: 2299
Joined: Wed 30 Jul 2014 07:16

Re: Access Violation exception & Pooling mode

Post by ViktorV » Tue 21 Jun 2016 11:20

Only using Pooling mode allows to use the specified behavior.

Robert Grzegorzewski
Posts: 3
Joined: Tue 21 Jun 2016 09:05

Re: Access Violation exception & Pooling mode

Post by Robert Grzegorzewski » Tue 21 Jun 2016 20:52

I noticed that this error occurs when I use DirectMode only. In NativeClient Mode everything works properly with DisconnectMode & Pooling.

Robert

ViktorV
Devart Team
Posts: 2299
Joined: Wed 30 Jul 2014 07:16

Re: Access Violation exception & Pooling mode

Post by ViktorV » Fri 24 Jun 2016 08:37

As we wrote earlier, we couldn't reproduce the issue. Most likely, it occurs due to some specific conditions, that we don't know. Therefore, we ask you to compose a sample demonstrating the issue and send it to viktorv*devart*com , in order to investigate it.

Post Reply