Skip to content

Commit d7085f3

Browse files
renemadsenclaude
andcommitted
fix(plugins): pool per-plugin DbContext
Switch AddDbContext<T> to AddDbContextPool<T> to amortize DbContext allocation and connection acquisition across requests. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
1 parent a13e3c9 commit d7085f3

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

eFormAPI/Plugins/OuterInnerResource.Pn/OuterInnerResource.Pn/EformOuterInnerResourcePlugin.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -149,7 +149,7 @@ public void ConfigureDbContext(IServiceCollection services, string connectionStr
149149
});
150150
}
151151
_connectionString = connectionString;
152-
services.AddDbContext<OuterInnerResourcePnDbContext>(o =>
152+
services.AddDbContextPool<OuterInnerResourcePnDbContext>(o =>
153153
o.UseMySql(connectionString, new MariaDbServerVersion(
154154
new Version(10, 4, 0)), mySqlOptionsAction: builder =>
155155
{

0 commit comments

Comments
 (0)