server(alarms): watch-list resolver merging GR discovery + config override
This commit is contained in:
@@ -0,0 +1,28 @@
|
||||
using ZB.MOM.WW.MxGateway.Contracts.Proto;
|
||||
using ZB.MOM.WW.MxGateway.Server.Configuration;
|
||||
|
||||
namespace ZB.MOM.WW.MxGateway.Server.Alarms;
|
||||
|
||||
/// <summary>
|
||||
/// Resolves the subtag watch-list the gateway sends to the worker when the
|
||||
/// central alarm monitor operates in subtag-polling fallback mode. Merges
|
||||
/// Galaxy Repository alarm-attribute discovery with the configured
|
||||
/// include/exclude overrides and composes the per-attribute subtag item
|
||||
/// addresses from the configured subtag names.
|
||||
/// </summary>
|
||||
public interface IAlarmWatchListResolver
|
||||
{
|
||||
/// <summary>
|
||||
/// Builds the subtag watch-list for the supplied alarm configuration.
|
||||
/// </summary>
|
||||
/// <param name="options">Alarm configuration carrying discovery and subtag-name settings.</param>
|
||||
/// <param name="cancellationToken">Token to cancel the asynchronous operation.</param>
|
||||
/// <returns>
|
||||
/// The resolved <see cref="AlarmSubtagTarget"/> watch-list, possibly empty.
|
||||
/// Discovery being unavailable never throws; the caller decides what to do
|
||||
/// with an empty list.
|
||||
/// </returns>
|
||||
Task<IReadOnlyList<AlarmSubtagTarget>> ResolveAsync(
|
||||
AlarmsOptions options,
|
||||
CancellationToken cancellationToken = default);
|
||||
}
|
||||
Reference in New Issue
Block a user