473,499 Members | 1,903 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

FileSystemWatcher and Connection Pooling

Hello all. I've noticed something curious when using a filesystem watcher and was wondering if anybody had experienced thesame thing. All of my web applications manage their sessionthrough SQL Server and an assembly I built that I published inthe GAC. It's a service component and runs as a ServerApplication in Component Services under a particular identityinstead of the identity of the application that is calling it. I use the object construction string to get my connection stringto my session database. When we use the Session componentthroughout our web apps and other things it works fine great. However, I set up a FileSystemWatcher and have experienced atotally different thing. In the file system watcher I have amethod that handles the fileCreated event fired when a new fileis added to my watch folder. The Event Handler creates asession in my Session database using the Session Assembly in theGAC. This is the same assembly used by ALL THE OTHERapplications that need session information. My FSW does this sothat I can use that session to track information on what the FSWis doing.
Now, in all the other applications, I usually get 1 to 5 databaseconnections to the SQL Server through the session component nomatter how many different applications are hitting theSession.dll. When the FSW fileCreated event fires, I add 4items to the session database using the same methods of theSession.dll that the other applications use. But when theSession assembly is called from the FSW, it creates a NEW SQLConnection every single time that I make the call toAddVariable! After about 5 min, I've got about 100 connectionsto my Session database and it's starts rejecting further calls. It acts as though there is no using a connection from a pool,but only to create a new one and THEN put it in a pool to neverbe used again. Has anyone got any experience with anything likethis?

--------------------------------
From: Clifford Tillman

-----------------------
Posted by a user from .NET 247 (http://www.dotnet247.com/)

<Id>5ZJ4/O+X2ECeCkRMWw0ENg==</Id>
Nov 22 '05 #1
0 1226

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
332
by: Clifford Tillman via .NET 247 | last post by:
Hello all. I've noticed something curious when using a filesystem watcher and was wondering if anybody had experienced thesame thing. All of my web applications manage their sessionthrough SQL...
18
3204
by: Rob Nicholson | last post by:
We're getting an occasional occurrence of the following error when two users try and open the same record in our ASP.NET app: "There is already an open DataReader associated with this Connection...
1
5704
by: Lenny Shprekher | last post by:
Hi, I am getting issues that Oracle collecting opened sessions (connections) from my webservice using regular System.Data.OleDb.OleDbConnection object. I am guessing that this is connection...
7
2196
by: Mrinal Kamboj | last post by:
Hi , I am using OracleConnection object from Oracle ODP.net provider and following is the behaviour which i am finding bit strange : To start with my argument is based on followings facts : ...
3
10270
by: Martin B | last post by:
Hallo! I'm working with C# .NET 2.0, implementing Client/Server Applications which are connecting via Network to SQL-Server or Oracle Databases. To stay independent from the underlaying Database...
2
2328
by: JimLad | last post by:
Hi, In an existing ASP/ASP.NET 1.1 app running on IIS 6, I need to RELIABLY pass the logged in username through to the SQL Server 2000 database for auditing purposes. The current method is...
16
2842
by: crbd98 | last post by:
Hello All, Some time ago, I implemented a data access layer that included a simple connectin pool. At the time, I did it all by myself: I created N connections, each connection associated with...
20
3239
by: fniles | last post by:
I am using VS2003 and connecting to MS Access database. When using a connection pooling (every time I open the OLEDBCONNECTION I use the exact matching connection string), 1. how can I know how...
3
4875
by: fniles | last post by:
In the Windows application (using VB.NET 2005) I use connection pooling like the following: In the main form load I open a connection using a connection string that I stored in a global variable...
0
6574
viswarajan
by: viswarajan | last post by:
Introduction This article is to go in deep in dome key features in the ADO.NET 2 which was shipped with VS 2005. In this article I will go trough one of the key features which is the Connection...
0
7134
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
7225
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
7392
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
5479
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
4605
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
3101
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
1429
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...
1
667
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
0
307
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.