Board index » delphi » opening ADO connection spawns multiple threads

opening ADO connection spawns multiple threads

Hi I observed that  (in the process viewer utility that comes with visual
studio) when I open an ADO connection the application spawns off around six
more extra threads which are not closed  when I close the connection. The
threads are closed only when I terminate the application.
It is very easy to reproduce. All you have to do is drop and ADO connection
two buttons on a form - open the connection in one button and close in
another.
I hope someone can shed light on this.
regards
paras
 

Re:opening ADO connection spawns multiple threads


That's how ADO was designed to work. The reason for this
is not to block the main Application thread while processing
internal operations like fetching, local indexing and sorting,
cursor cloning etc. The extra threads that ADO creates are
not freed upon closing the connection for caching purposes.

HTH
--
V. Nazarov
IT Manager, Sofia Cable

Quote
"paras" <paras.kaf...@nospam.microbanker.org> wrote in message

news:3923867c@dnews...
Quote
> Hi I observed that  (in the process viewer utility that comes with visual
> studio) when I open an ADO connection the application spawns off around six
> more extra threads which are not closed  when I close the connection. The
> threads are closed only when I terminate the application.
> It is very easy to reproduce. All you have to do is drop and ADO connection
> two buttons on a form - open the connection in one button and close in
> another.
> I hope someone can shed light on this.
> regards
> paras

Re:opening ADO connection spawns multiple threads


TNX

Other Threads