Пример #1
0
 public bool Run(TaskInfo info, Message msg)
 {
     _action();
     return true;
 }
Пример #2
0
        public void PutMessage(string queueName, Message message, TimeSpan timeToLive)
        {
            var msg = new Data.Message();
            msg.Queue = queueName;
            if (message.Content != null)
                msg.Content = message.Content;

            using (var dc = new Data.MessageDataContext())
            {
                dc.Messages.InsertOnSubmit(msg);
                dc.SubmitChanges();
            }
        }