Previous page

Next page

Locate page in Contents

Print this page

add

Summary:

Adds a task to the scheduler.

Request specification:

Name

Min/Max

Type

Description

add

1..1

 

 

{

 

 

 

task

1..1

taskType

Task definition.

}

 

 

 

Returns:

Name

Min/Max

Type

Description

task

1..1

taskType

The ID that was assigned to the task.

Description:

See taskType for the descriptions and examples of how to schedule a task.

It is possible to set the maximum allowable number of simultaneously scheduled tasks, which is usually done in order to avoid scheduler overflow. The number is defined in the Agent configuration. The parameter name is max_tasks_count, which is located in the scheduler/configuration section.

Example:

Scheduling to perform a server backup on a daily basis. The backups will be performed at midnight on every day of the week, including weekdays and weekends. The backups will begin on March 03, 2007 and will end on May 05, 2007.

Input

<packet xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" version="4.0.0">

<target>scheduler</target>

<data>

<scheduler>

<add>

<task>

<title>Test-Backup</title>

<triggers>

<trigger xsi:type="daily_triggerType">

<start_time>2007-03-01T00:00:00-0500</start_time>

<end_time>2007-05-01T00:00:00-0500</end_time>

<days_interval>1</days_interval>

</trigger>

</triggers>

<packet>PHBhY2tldCB2ZXJzaW9uPSI0LjAuMCI+PHRhcmdldD5iYWNrdXBtPC90YXJnZXQ+PGRhdGE+PGJhY2t1cG0+PGJhY2t1cF9lbnY+PGVudl9saXN0PjxlaWQ+NTdjMmNkNmMtYzAyYi00NjQ1LWJkYjUtZTg4M2VhMDA1ODk2PC9laWQ+PC9lbnZfbGlzdD48YmFja3VwX29wdGlvbnM+PHR5cGU+MDwvdHlwZT48Y29tcHJlc3Npb24+MjwvY29tcHJlc3Npb24+PGRlc2NyaXB0aW9uPlJuVnNiQ0JpWVdOcmRYQWdNakF3Tnkwd01TMHhNZz09PC9kZXNjcmlwdGlvbj48L2JhY2t1cF9vcHRpb25zPjxnbG9iYWwvPjwvYmFja3VwX2Vudj48L2JhY2t1cG0+PC9kYXRhPjwvcGFja2V0Pg==</packet>

</task>

</add>

</scheduler>

</data>

</packet>

Output

The output contains the task ID.

<ns1:packet xmlns:ns2="http://www.swsoft.com/webservices/vzl/4.0.0/scheduler" xmlns:ns1="http://www.swsoft.com/webservices/vzl/4.0.0/protocol" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" id="26c45ed906at428br274" time="2007-03-04T14:55:22+0000" priority="0" version="4.0.0">

<ns1:origin>scheduler</ns1:origin>

<ns1:target>vzclient3</ns1:target>

<ns1:dst>

<ns1:director>gend</ns1:director>

</ns1:dst>

<ns1:data>

<ns2:scheduler>

<ns2:id>f40d0ba4-e561-4d4a-a1f4-01e0156a91f5</ns2:id>

</ns2:scheduler>

</ns1:data>

<ns1:src>

<ns1:director>gend</ns1:director>

</ns1:src>

</ns1:packet>

Please send us your feedback on this help page