Share via


Schedules

For the latest version of Commerce Server 2007 Help, see the Microsoft Web site.

Schedules are used to automate replication of a Commerce Server Staging (CSS) project. The CReplicationSchedule object controls the schedule of when and how frequently replications are run. This object works with the Windows Task Scheduler to create nonrecurring, run one time only schedules or recurring schedules that run weekly.

Schedule Types

There are two types of schedules:

  • Replication. Sets the date and time for initiating project replication on a source staging server.

  • Apply time. Sets the date and time for when an Apply command is to be issued to complete content replication on an endpoint server. This option is only valid for Web content projects and is used in association with the enable timed release.

The schedule type is set by using the CReplicationSchedule.ScheduledAction property.

The Apply time option is useful when you want content to be available to all users at a specific time, regardless of the time zone. For the Apply time option to work, it must be used together with a scheduled deployment, and the project on the endpoint servers must have the Enable timed release option selected. For more information about timed release replications, see How to Initiate Timed Release of a Web Content Project.

Schedule Frequency

There are two types of schedule frequencies:

  • Nonrecurring. Sets the date and time for a project to run one time by using the RunOnce property. When this property is set, the IsRunOnce property is set to True.

  • Recurring. Sets the time and one or more days for a project to run weekly. The Days, Hour, and Minute properties are used to set a recurring schedule. For example, you can set a schedule that initiates project replication every Monday, Wednesday, and Friday at 3:00 AM.

After a schedule is defined for a project, it will run the project when the scheduled date(s) occur. You use the CReplicationProject.AddSchedule and CReplicationSchedule.Remove methods to add and remove a schedule to/from a project, respectively.

Defining a Schedule

For each schedule that you want to define, follow these steps:

  1. Open the project for which the schedule will be added. For information about how to open projects, see How to Create and Modify a Staging Project.

  2. Add the schedule to the project.

    • Add replication schedules to the source staging server.

    • Add apply time schedules to an endpoint server.

    For information about how to add a schedule, see How to Manage Staging Schedules.

Retrieving Schedule Information

To retrieve the schedules that are defined for a server, you use the CReplicationProject.EnumSchedules. This method returns a CReplicationSchedule object for each schedule that is defined for the project. One object each is returned until all schedules have been enumerated.

See Also

Other Resources

How to Initiate Timed Release of a Web Content Project

How to Create and Modify a Staging Project

How to Manage Staging Schedules

CReplicationSchedule Class

What are the Staging API Concepts?