Skip to content

enisgurkann/ENLOCK

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

36 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

ENLOCK - EFCORE With(No Lock) Tool

GitHub GitHub Repo stars GitHub last commit Contributors Discussions Nuget version Nuget downloads

It is the plugin we made to simplify the 'transaction scope' event that we use to prevent the database lock event when using Entity Framework.

Methods

FirstOrDefault,Single,ToList,Any and Async

Efcore Provider Usage

PM> Install-Package ENLOCK
PM> Standart FirstOrDefault
        var customer = await _context
        .Customers
        .Where(x => x.Name == 'Enis' && x.Surname == 'Gürkan')
        .FirstOrDefaultkAsync();
 
PM> Using ToFirstOrDefaultWithNoLockAsync
        var customer = await _context
        .Customers
        .Where(x => x.Name == 'Enis' && x.Surname == 'Gürkan')
        .ToFirstOrDefaultWithNoLockAsync();
 
PM> Using other expressions
        var customers = await _context.NoLock(s => s.Customers.ToListAsync());
 
PM> Using other expressions
        var customers = await _context.Customers.WithNoLock().ToListAsync();
 

Packages

No packages published

Contributors 2

  •  
  •  

Languages