public void ProcessCue(CueRequest req)
        {
            Resolver        resolver;
            ResolverRequest request;

            lock (__lockObj)
            {
                SignalDbRecord signalDbRecord = DbEngine.Get <SignalDbRecord>(req.Id);
                Cue            cue            = req.Cue;
                ActionType     action         = new ActionType
                {
                    CueId   = cue.CueId,
                    Status  = StatusType.New,
                    IsValid = true,
                    Time    = DateTime.UtcNow
                };

                action.Variables = cue.Variables;

                if (signalDbRecord.Actions == null)
                {
                    signalDbRecord.Actions = new System.Collections.Generic.Dictionary <string, ActionType>();
                }

                resolver = signalDbRecord.Signal.Cues[cue.CueId].Resolver;
                request  = new ResolverRequest();

                try
                {
                    ValidateCue(signalDbRecord, cue);

                    request.Id       = cue.Id;
                    request.ActionId = req.ActionId;
                    request.CueId    = cue.CueId;

                    signalDbRecord.Status = StatusType.Received;
                }
                catch (Exception e)
                {
                    // TODO : Check for "Terminal" Status As Well.
                    if (signalDbRecord.Status != StatusType.Received)
                    {
                        signalDbRecord.Status = StatusType.Invalid;
                    }
                    action.Status        = StatusType.Error;
                    action.StatusMessage = e.Message;
                }

                signalDbRecord.Actions.Add(req.ActionId, action);
                signalDbRecord  = DbEngine.Update <SignalDbRecord>(signalDbRecord, true);
                request.Signal  = signalDbRecord.Signal;
                request.Actions = signalDbRecord.Actions;
                request.Trace   = signalDbRecord.Trace;
            }

            Logger.Info($"Sending To Resolver [{resolver.Name}].  {JsonTools.Serialize(request)}");
            SendToResolver(resolver, request);
        }
        public virtual void SendToResolver(Resolver resolver, ResolverRequest request)
        {
            IResolver res    = AssemblyLoader.Load <IResolver>(resolver.Name);
            Status    status = new Status();

            if (res != null)
            {
                status = res.ProcessRequest(request);
                status.SendToChannels = resolver.Notify;
            }
            else
            {
                status.Id             = request.Id;
                status.ActionId       = request.ActionId;
                status.NewStatus      = StatusType.Error;
                status.Message        = $"Resolver [{resolver.Name}] Does Not Exist.";
                status.SendToChannels = resolver.Notify;
            }

            ProcessStatus(status);
        }