Beispiel #1
0
        public IEnumerable <string> GetQueues()
        {
            string sqlQuery = @"
SELECT DISTINCT ""queue"" 
FROM """ + _options.SchemaName + @""".""jobqueue"";
";

            return(_storage.UseConnection(connection => connection.Query(sqlQuery).Select(x => (string)x.queue).ToList()));
        }
Beispiel #2
0
        public void RemoveFromQueue()
        {
            _storage.UseConnection(connection => connection.Execute(
                                       @"
DELETE FROM """ + _options.SchemaName + @""".""jobqueue"" 
WHERE ""id"" = @id;
",
                                       new { id = Id }));

            _removedFromQueue = true;
        }