AUTOMATING TASKS USING SIMPLE AGENTS


Triggering an agent on a schedule
At the Basics tab of the Agent Properties box, click On Schedule.

1. At the pull-down list next to the Schedule button, choose one of the following schedules. Note that the Web does not support scheduled invocation of agents; however, an agent on the Web can be triggered in other ways, such as through Tools/Macros or from the URL.
Schedule for agentWhen to use
More Than Once a DayFor high-priority applications, such as those critical to a business process, and for applications that replicate several times a day, such as workflow applications that route documents for approval.

Be aware that if you schedule very frequent runs (for example, every 5 minutes), the server’s performance could be affected.

DailyFor activities that are important but that will not cause a delay if they are only generated once a day. Examples include mailing news articles or generating low-priority assignments.
WeeklyFor routine tasks. Examples include generating summary reports and sending reminders.
MonthlyFor low-priority maintenance tasks. Examples include archiving documents and distributing company newsletters.
NeverFor agents that you do not want to run in particular circumstances. For example, use this run option for agents that do run on the Web or for agents that are called by other agents.
2. Once you make a choice from the pull-down menu, click the Schedule button to display the Schedule dialog box. You can add more detail on exactly when you want the agent to run. For example:

3. At the same Schedule dialog box, you also specify the servers on which you want the agent to run. You can choose from the Run on pull-down list. Alternatively, you can have users choose the server.
Server agent runs on:When to use:
LocalThe agent runs only on the client. Use this option to schedule agents to run in the background on the local Notes client. The application containing the agent must be local The agent will run with the rights of the current Notes ID.

Note that for scheduled agents to run on the local Notes client, the user must first check the "Enable scheduled local agents" box at the Basics tab of the User Preferences dialog box (File > Preferences > User Preferences).

Any serverThe agent runs on any server that the agent is available on. When agents run on multiple servers and they are changing documents in applications that are replicated, you should specify the servers they run on to prevent replication conflicts. Then, set up the applications' replication schedules so they don’t interfere with the agents’ scheduled runs.

Note that this option does not cause problems if you are using copies (instead of replicas) of the application.

Specific serverThe agent runs only on the single server you select from the list of available servers.
Choose when agent is enabledChecking this option prompts users to select a server when the agent is enabled. This option is useful for distributing agents in ready-to-use applications.
4. From the Target pull-down list, select the documents in the application the agent will run on. You have two choices:
When you schedule an agent, remember the following: When agents that run on multiple servers change documents in applications that are replicated, you should specify the servers they run on to prevent replication conflicts. Then, set up the applications' replication schedules so they don’t interfere with the agents’ scheduled runs. Note that agents are scheduled according to the interval you set up, not the exact time of day. For example, if you schedule an agent to run hourly, it runs about one hour after the last time it ran.

See Also