MENU

The LiSA Task Daemon

Starting with version 6.6 LiSA includes a Task Daemon which is used to execute asynchronous task at specific intervals in the system.  Advanced users and developers can write their own task implementations and have them run by the Task Daemon.

Some of the systems built into LiSA use the Task Daemon to perform certain tasks:

  • Mailing List - Uses the Task Daemon to deliver messages.  A task for each delivery is automatically created, using the role "MailDelivery".  NOTE: In a clustered environment (with multiple servers running the site), make sure that this role is only set on one machine.  For information, see below.

  • External Datasources - If you create an asynchronous data source, a new task is automatically created in the Task Daemon which runs at the specified interval to automatically fetch and refresh the data source.  Those tasks are created using the role "DataHarvest".  NOTE: In a clustered environment (with multiple servers running the site), make sure that this role is only set on one machine.  For information, see below.

  • Cache Notifications - This is a low level functionality in LiSA, which ensures that any changes made to cached content properly invalidates the cache accross all web servers in a cluster/farm setup, to make sure the latest content is always visible on the website.

  • LiSA Search - The Search Crawler which crawls and indexes the website is a task which is run by the Task Daemon.  Since this task is manually set up by the user as a part of the search setup, the user can specify who runs the task, either by specifying a role such as "SearchCrawler" or simply by typing in the name of the web server.
    NOTE: In a clustered environment (with multiple servers running the site), make sure that this role is only set on one machine.  For information, see below.

Understanding the TaskDaemonRoles

Some websites are run on multiple servers.  Under such circumstances, it must be possible to define which server runs each task.  If the task is specific to each server, then it's probably OK if it runs on each and every server.  Some other tasks, like delivering e-mails in the mailing list and crawling/indexing the website for search should only be performed on one web server.  This is where the TaskDaemonRoles setting comes in.

Each task has an assigned worker - that is, which machine should run the task.  When a task is registered manually in the Task Daemon, the user is given the opportunity to specify who should run the task.  The user can type in the name of the web server which should run the task, or he can type in a predefined "Role" (or select from a list of roles which have been set).

The built in systems which use the Task Daemon internally, like the Mailing List and the External Datasources, use the roles "MailDelivery" and "DataHarvest" respectively.

There's a key in the appSettings section in the web.config (or appsettings.config) file on the root of the website where the available roles are defined.
<add key="TaskDaemonRoles" value="DataHarvest,MailDelivery,SearchCrawler"/>
In this case, the webserver is a part of the DataHarvest, MailDelivery and SearchCrawler roles.  That means that if tasks are registered which use any of those roles, they will be run by this webserver.  When a single web.config/appsettings.config file is being used for multiple servers, each server can be given it's own set of roles by prepending the machine name to the TaskDemonRoles key, like below:
<add key="TaskDaemonRoles" value="DataHarvest,MailDelivery,SearchCrawler"/>
<add key="TFW86954:TaskDaemonRoles" value="DataHarvest"/>
In this case, the server "TFW86954" will be in the "DataHarvest" role, any other servers running this config file will be in all three roles.

Running tasks on headless servers (or without IIS present)


A Windows service application is available which can run certain Tasks in LiSA.  If you have a dedicated machine which you wish to use to run certain tasks, like delivering messages in the Mailing List or crawling the website, you can use this service.

The service only requires the appropriate .NET framework to be installed and it needs to be able to connect to the LiSA database to read task information.

For more information about this service, please contact Advania.

Search

Index

Mailing list

Get notified when new versions of LiSA are released!

Check the box next to the list you wish to register to.