25 lines
774 B
C#
25 lines
774 B
C#
using YY.Admin.Core;
|
||
using YY.Admin.Core.Services;
|
||
using YY.Admin.Services.Service.Auth;
|
||
|
||
namespace YY.Admin.Services.Service.Jeecg;
|
||
|
||
/// <summary>
|
||
/// Outbox 消费端:执行 SCADA 全量拉取并写入 jeecg_sys_user(与设备模块 HTTP 幂等上报并列的第二条 REST 能力)。
|
||
/// </summary>
|
||
public class JeecgUserMirrorPullHandler : IJeecgUserMirrorPullHandler, ISingletonDependency
|
||
{
|
||
private readonly ISysAuthService _authService;
|
||
|
||
public JeecgUserMirrorPullHandler(ISysAuthService authService)
|
||
{
|
||
_authService = authService;
|
||
}
|
||
|
||
/// <inheritdoc />
|
||
public Task<bool> ExecutePullAsync(CancellationToken cancellationToken = default)
|
||
{
|
||
return _authService.TryBackgroundSyncJeecgUsersAsync(cancellationToken);
|
||
}
|
||
}
|