Tasks/Commands for Dealing with Configuration Checkpoints
=========================================================
.. index:: checkpoint
.. _checkpoint:
``checkpoint``
--------------
The ``checkpoint`` task creates a configuration checkpoint with the given name. It is equivalent to using the "Administration/Configuration/Configuration Checkpoint" screen of WebGUI. If the checkpoint with the provided name already exists, it is automatically deleted (this is different from WebGUI's behavior). Note that DataPower can accommodate only a limited number of checkpoints in a domain.
If the checkpoint's name contains dots, they will be replaced with underscores. This makes it easier to accommodate version numbers in the checkpoint name.
Attributes/Options
^^^^^^^^^^^^^^^^^^
.. list-table::
:widths: 20 80 8
:header-rows: 1
* - Name
- Description
- Required
* - name
- Name of the checkpoint.
- Yes
* - timestamp
- If set to ``true``, append timestamp to the checkpoint name. Use with caution as this could quickly create a large number of checkpoints. The timestamp has the format "yyyyMMdd_HHmmss".
Defaults to ``false``.
- No
Examples
^^^^^^^^
.. code-block:: bat
dpbuddy checkpoint -name release-1.0.1 -save
.. code-block:: xml
.. index:: rollback
.. _rollback:
``rollback``
------------
This tasks reverts the domain configuration to the specified checkpoint or to the latest checkpoint. Note that the content of the local file system will also be restored using the files that resided on the ``local:/`` at the time of the checkpoint.
Attributes/Options
^^^^^^^^^^^^^^^^^^
.. list-table::
:widths: 20 80 8
:header-rows: 1
* - Name
- Description
- Required
* - name
- Name of the checkpoint to which to rollback.
Defaults to the latest checkpoint in the domain. If the domain does not have any checkpoints, an exception will be raised.
- No
Examples
^^^^^^^^
.. code-block:: bat
dpbuddy rollback -save
.. code-block:: xml
.. index: delCheckpoint
.. _delCheckpoint:
``delCheckpoint``
-----------------
This task deletes configuration checkpoints. Since DataPower can accommodate only a limited number of checkpoints, it may be necessary to delete old checkpoints from time to time.
The default number of checkpoints for a domain is 3. You can increase this limit from the domain configuration screen in WebGUI.
Attributes/Options
^^^^^^^^^^^^^^^^^^
.. list-table::
:widths: 20 80 8
:header-rows: 1
* - Name
- Description
- Required
* - name
- Name of the checkpoint to remove.
- Yes, unless ``namePattern`` was provided.
* - namePattern
- Regular expression pattern defining checkpoints to remove. Use ``.*`` to delete all checkpoints.
- Yes, unless ``name`` was provided.
* - matchRequired
- If set to ``true``, fail if no checkpoints matched the pattern specified in ``namePattern``.
Defaults to ``true``.
- No
Examples
^^^^^^^^
.. code-block:: bat
dpbuddy delCheckpoint -namePattern ".*1_0_1" -matchRequired false
.. code-block:: xml