Skip to content

Commit

Permalink
Update README.md
Browse files Browse the repository at this point in the history
  • Loading branch information
furkandeveloper authored Oct 27, 2020
1 parent 9f5b013 commit c259802
Showing 1 changed file with 39 additions and 0 deletions.
39 changes: 39 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,45 @@ public void Configure(IApplicationBuilder app, IWebHostEnvironment env, Profiler

Run your application and check your db. Must be created `Profiler` entity.

### Sample for MariaDb
Install `EasyProfiler.MariaDb` from [Nuget Package](https://www.nuget.org/packages/EasyProfiler.MariaDb/)

Initilaze `EasyProfilerDbContext` in `Startup.cs` to save the results.
#### Sample
```csharp
services.AddEasyProfilerDbContext(options =>
{
options.UseMySql(Configuration.GetConnectionString("DefaultConnection"));
});
```

and `EasyProfilerInterceptor` extensions add for own `DbContext`.

#### Sample
```csharp
services.AddDbContext<SampleDbContext>(options =>
{
options.UseMySql(Configuration.GetConnectionString("DefaultConnection"))
.AddEasyProfiler(services);
});
```

### Migrations
Use the `ApplyEasyProfilerMariaDb` extension method for pending migrations.

#### Sample

```csharp
public void Configure(IApplicationBuilder app, IWebHostEnvironment env, ProfilerDbContext profilerDbContext)
{
app.ApplyEasyProfilerMariaDb(profilerDbContext);
}
```

<hr/>

Run your application and check your db. Must be created `Profiler` entity.

## Watch Queries with AdvancedFilter

#### Usage
Expand Down

0 comments on commit c259802

Please sign in to comment.