-
Notifications
You must be signed in to change notification settings - Fork 18
SQL Server
Furkan Güngör edited this page Mar 27, 2022
·
4 revisions
Install EasyProfiler.SQLServer
from Nuget Package
Initilaze EasyProfilerDbContext
in Program.cs
to save the results.
builder.Services.AddEasyProfilerDbContext(options =>
{
options.UseSqlServer(Configuration.GetConnectionString("DefaultConnection"));
}, options=>
{
options.Resulation = Resulation.HIGH;
});
or
builder.Services.AddEasyProfilerDbContext(options =>
{
options.UseSqlServer(Configuration.GetConnectionString("DefaultConnection"));
}, options=>
{
options.UseCronExpression = true;
options.CronExpression = "* 1 * * *";
});
and EasyProfilerInterceptor
extensions add for own DbContext
.
builder.Services.AddDbContext<OwnDbContext>(options =>
{
options.UseSqlServer(Configuration.GetConnectionString("DefaultConnection"))
.AddEasyProfiler(services);
});
Use the MigrateEasyProfiler
extension method for pending migrations.
var app = builder.Build();
app.MigrateEasyProfiler();
Welcome to the EasyProfiler wiki!
Topics:
-
Getting Started
-
Databases
-
Advanced Queries
-
Other