public override async ValueTask <TagReadIntegrationEventReply> HandleRpcAsync(TagReadIntegrationEvent @event, CancellationToken cancellationToken = default)
        {
            ;
            var tagValue = await _biz.GetTagValueAsync(@event.GroupName, @event.Name).ConfigureAwait(false);

            return(new TagReadIntegrationEventReply(@event.GroupName + ".automation.read", @event.GroupName, @event.Name, @event.CreationDate, tagValue));
        }
        public override async ValueTask <TagReadIntegrationEventReply> HandleRpcAsync(TagReadIntegrationEvent @event, CancellationToken cancellationToken = default)
        {
            //Logger.LogTrace("TagReadRpcServerHandler HandleRpcAsync... " + @event.RoutingKey + " " + @event.ReplyRoutingKey + " "
            //+ @event.GroupName + " " + @event.Name);
            //;
            var tagValue = await _biz.GetTagValueAsync(@event.GroupName, @event.Name).ConfigureAwait(false);

            //Logger.LogTrace("HandleRpcAsync: " + tagValue);
            return(new TagReadIntegrationEventReply(@event.ReplyRoutingKey, @event.GroupName, @event.Name, @event.CreationDate, tagValue));
        }
        public async ValueTask <KSociety.Com.App.Dto.Res.Biz.GetTagValue> ExecuteAsync(GetTagValue request, CancellationToken cancellationToken = default)
        {
            var output = new KSociety.Com.App.Dto.Res.Biz.GetTagValue();

            //_logger.Trace("GetTagValue Execute: " + request.GroupName + " - " + request.TagName + " - " + _startup.SystemGroups.Count);
            try
            {
                //_startup.GetTagValue(new TagReadIntegrationEvent(request.GroupName + ".automation.readCmd", request.GroupName, request.TagName));

                var result = await _startup.GetTagValueAsync(new TagReadIntegrationEvent(request.GroupName + ".automation.read.server", request.GroupName + ".automation.read.client.com", request.GroupName, request.TagName)).ConfigureAwait(false);

                output.GroupName = result.GroupName;
                output.TagName   = result.TagName;
                output.Value     = result.TagValue;
            }
            catch (Exception ex)
            {
                _logger.LogError("GetTagValue Execute:  " + ex.Message + " - " + ex.StackTrace);
            }
            return(output);
        }