C# Класс RedisQueue.Net.ServiceProvider.Old.QueueMonitor

Показать файл Открыть проект Примеры использования класса

Открытые методы

Метод Описание
QueueMonitor ( ) : System

Ctor. Creates and consumes a new {RedisQueueClient} instance.

QueueMonitor ( QueueClient queue ) : System

Ctor. Requires a {RedisQueueClient} instance.

SignalNewTasksArrived ( ) : void

Lets the main process know that more tasks are available.

Start ( ) : void

The main work method, signalling the monitor to start observing the queue defined in configuration.

Stop ( ) : void

Защищенные методы

Метод Описание
Run ( ) : void

The main monitor run method. What it does is try to reserve a task and dispatch it in a separate application domain. A couple of notes follow: AppDomain load / unload policy The current policy is pretty straightforward. As long as the monitor finds tasks in the queue, it will re-use the application domain. As soon as the queue is empty, it will attempt to unload the application domain. Stuck tasks ...will currently hang the service. Probable TODO: Monitor the AppDomain and kill / fail stuck tasks.

Приватные методы

Метод Описание
initAppDomain ( ) : void
releaseAppDomain ( ) : bool
resolvePath ( string workerAssemblyPath ) : string

Описание методов

QueueMonitor() публичный Метод

Ctor. Creates and consumes a new {RedisQueueClient} instance.
public QueueMonitor ( ) : System
Результат System

QueueMonitor() публичный Метод

Ctor. Requires a {RedisQueueClient} instance.
public QueueMonitor ( QueueClient queue ) : System
queue RedisQueue.Net.Clients.QueueClient
Результат System

Run() защищенный Метод

The main monitor run method. What it does is try to reserve a task and dispatch it in a separate application domain. A couple of notes follow: AppDomain load / unload policy The current policy is pretty straightforward. As long as the monitor finds tasks in the queue, it will re-use the application domain. As soon as the queue is empty, it will attempt to unload the application domain. Stuck tasks ...will currently hang the service. Probable TODO: Monitor the AppDomain and kill / fail stuck tasks.
protected Run ( ) : void
Результат void

SignalNewTasksArrived() публичный Метод

Lets the main process know that more tasks are available.
public SignalNewTasksArrived ( ) : void
Результат void

Start() публичный Метод

The main work method, signalling the monitor to start observing the queue defined in configuration.
public Start ( ) : void
Результат void

Stop() публичный Метод

public Stop ( ) : void
Результат void