Files
qhmes/yy-admin-master/YY.Admin.Services/Service/Jeecg/JeecgUserMirrorPullHandler.cs

25 lines
774 B
C#
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
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);
}
}