Specifications
2-32
Cisco CRS-1 Series Carrier Routing System XML API Guide
OL-4596-02
Chapter 2 Cisco CRS-1 Series XML Router Configuration and Management
Configuration Operations
Commit Operation
Table 2-2 describes the four optional attributes that are specified with the <Commit> operation.
If the commit operation is successful, the response contains just the <Commit/> tag along with any
attributes specified in the request. if the commit operation fails, the failed configuration is returned in
the response.
The following example shows a request to commit the target configuration using the Atomic option and
specifies that any failed configuration be retained in the target buffer. This request corresponds to the
CLI command commit atomic.
Sample XML Client Request to Commit the Target Configuration Using the Atomic Option
<?xml version="1.0" encoding="UTF-8"?>
<Request MajorVersion="1" MinorVersion="0">
<Commit Mode=”Atomic” Label=”BGPUpdate1” Comment=”BGP config update”/>
</Request>
Table 2-2 Commit Operation Attributes
Name Description
Mode Use the Mode attribute in the request to specify whether the target
configuration should be committed on an Atomic or BestEffort basis. In the
case of a commit with the Atomic option, the entire configuration in the target
area is committed only if application of all the configuration in the target area
to the running configuration succeeds. If any errors occur, the commit
operation is rolled back and the errors are returned to the client application. In
the case of commit with the BestEffort option, the configuration is committed
even if some configuration items fail during the commit operation. In this case,
the errors are also returned to the client application. By default, the commit
operation is carried out on a BestEffort basis.
KeepFailedConfig Use this Boolean value to specify whether any configuration that fails during
the commit operation should remain in the target configuration buffer. The
default value for KeepFailedConfig is false. That is, by default the target
configuration buffer is cleared after each commit. If a commit operation is
performed with a KeepFailedConfig value of false, the user can then use the
<Load> operation to load the failed configuration back into the target
configuration buffer. The use of the KeepFailedConfig attribute makes sense
only for the BestEffort commit mode. In the case of an Atomic commit, if
something fails, the entire target configuration is kept intact (because nothing
was committed).
Label Use the Label attribute instead of the commit identifier wherever a commit
identifier is expected, such as in the <Rollback> operation. The Label attribute
is a unique user-specified label that is associated with the commit in the Cisco
CRS-1 Series commit database. If specified, the label must begin with an
alphabetic character and cannot match any existing label in the Cisco CRS-1
Series commit database.
Comment Use the Comment attribute as a user-specified comment to be associated with
the commit in the Cisco CRS-1 Series router commit database.