Architecting a Decoupled Data Access Layer in VB.NET with ADO.NET
Learn how to build a secure, decoupled Data Access Layer in VB.NET using ADO.NET, focusing on the Repository pattern, parameterized queries, and connection management.
ReadMeFeed / Community knowledge
Real questions. Useful conversations. Find the people who know your stack.
Learn how to build a secure, decoupled Data Access Layer in VB.NET using ADO.NET, focusing on the Repository pattern, parameterized queries, and connection management.
When a Visual Basic .NET application uses SqlTransaction to wrap a schema change such as ALTER TABLE or DROP COLUMN , the goal is to determine whether the DDL can be rolled back if a later data manipulation step fails. The constraint is that SQL Server issues an implicit commit for most DDL commands, so the transaction started in VB.NET code does not encompa
Understanding when EF Core acquires and releases a physical database connection relative to DbContext lifetime and per-command execution is needed to reason about intermittent pool exhaustion. The documented interaction between DbContext connection management, SaveChanges and provider pooling is relevant, as is the effect of holding a DbContext instance acro
The goal is to identify why a connection pool intermittently runs out of available connections in an ADO.NET‑based application hosted on Glitch, while using a specific pooling feature such as Max Pool Size. The application exhibits sporadic time‑outs and exceptions despite seemingly normal traffic, making it unclear whether the exhaustion stems from unreturn
Integration Boundary VB.NET applications using System.Transactions.TransactionScope or explicit DbTransaction objects rely on ADO.NET's common abstraction layer to coordinate work across SQL Server, PostgreSQL, and Oracle. The abstraction promises a single Rollback() call that undoes all enlisted operations, but the underlying providers diverge sharply when
NHibernate delegates connection checkout and return to the underlying ADO.NET provider pool. The connection.release_mode setting determines when a checked-out connection is handed back, with options on_close, after_transaction, after_statement, and auto (default). When sessions engage in lazy loading outside an explicit transaction, the connection may be hel
ADO.NET utilizes connection pooling to minimize the overhead of establishing physical database connections. By default, the pool manages connections based on the exact connection string provided, and the Max Pool Size attribute defines the upper limit of physical connections allowed per pool. When an application reaches this limit and all connections are cur
In SQL Server environments using ADO.NET, SqlCommand.CommandTimeout allows a client to send an attention signal to the server to abort a running batch when a time limit is reached. While this stops the execution of the current statement, the behavior regarding the surrounding transaction remains a point of architectural uncertainty. When a timeout occurs dur
Design choice is between a fixed-size pre-warmed pool using Min Pool Size and a dynamic on-demand pool with Min Pool Size at zero for a workload with high-concurrency bursts followed by idle periods. Connection pooling is managed client-side by the ADO.NET provider, not by the SQL Server engine. Pool behavior is governed by Max Pool Size and Min Pool Size in