Troubleshooting — EricksonLopez.DistributedLock
L2StableNuGet: v1.0.0Local HEAD: v2.1.0AOT: Full
Frequent setup issues with EricksonLopez.DistributedLock (1.0.0).
No Root EricksonLopez.DistributedLock NuGet Package
Section titled “No Root EricksonLopez.DistributedLock NuGet Package”- Symptom:
NU1101: Unable to find package EricksonLopez.DistributedLock. - Fix: Install
EricksonLopez.DistributedLock.Abstractionsplus a dialect provider (.PostgreSql,.SqlServer,.Sqlite,.Redis, etc.).
Missing AddPostgresDistributedLock / AddSqliteDistributedLock Method
Section titled “Missing AddPostgresDistributedLock / AddSqliteDistributedLock Method”- Symptom: Compiler cannot find
AddSqliteDistributedLockeven after importingEricksonLopez.DistributedLock.Sqlite. - Fix: Add
using Microsoft.Extensions.DependencyInjection;(ImplicitUsings=disable), as all dialect DI extensions reside inMicrosoft.Extensions.DependencyInjection. Also ensureservices.AddLogging()is registered in standalone test/console containers.
EricksonLopez.DistributedLock.Redis sets IsAotCompatible=true, but runtime trimming behavior depends on the underlying StackExchange.Redis version in use.