|
|
@ -28,7 +28,7 @@ public class DaprAbpDistributedLock : IAbpDistributedLock, ITransientDependency |
|
|
{ |
|
|
{ |
|
|
if (timeout == default) |
|
|
if (timeout == default) |
|
|
{ |
|
|
{ |
|
|
timeout = TimeSpan.FromSeconds(30); |
|
|
timeout = DistributedLockDaprOptions.DefaultTimeout; |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
var daprClient = await DaprClientFactory.CreateAsync(); |
|
|
var daprClient = await DaprClientFactory.CreateAsync(); |
|
|
@ -37,7 +37,7 @@ public class DaprAbpDistributedLock : IAbpDistributedLock, ITransientDependency |
|
|
DistributedLockDaprOptions.StoreName, |
|
|
DistributedLockDaprOptions.StoreName, |
|
|
name, |
|
|
name, |
|
|
DaprOptions.AppId, |
|
|
DaprOptions.AppId, |
|
|
timeout.Seconds, |
|
|
(int)timeout.TotalSeconds, |
|
|
cancellationToken); |
|
|
cancellationToken); |
|
|
|
|
|
|
|
|
if (lockResponse == null || !lockResponse.Success) |
|
|
if (lockResponse == null || !lockResponse.Success) |
|
|
|