Skip to content

Commit

Permalink
Add backupStats func to docs (#358)
Browse files Browse the repository at this point in the history
  • Loading branch information
DeepikaDixit authored and mergify[bot] committed Oct 14, 2019
1 parent 01666ce commit 9f896b4
Showing 1 changed file with 57 additions and 0 deletions.
57 changes: 57 additions & 0 deletions docs/functions.rst
Original file line number Diff line number Diff line change
Expand Up @@ -829,6 +829,63 @@ Example:
namespace: "{{ .Deployment.Namespace }}"
snapshots: "{{ .ArtifactsIn.backupInfo.KeyValue.manifest }}"
BackupDataStats
---------------

This function get stats for the backed up data from the object store location

.. note::
It is important that the application includes a ``kanister-tools``
sidecar container. This sidecar is necessary to run the
tools that get the information from the object store.

Arguments:

.. csv-table::
:header: "Argument", "Required", "Type", "Description"
:align: left
:widths: 5,5,5,15

`namespace`, Yes, `string`, namespace in which to execute
`backupArtifactPrefix`, Yes, `string`, path to the object store location
`backupID`, Yes, `string`, unique snapshot id generated during backup
`mode`, No, `string`, mode in which stats are expected
`encryptionKey`, No, `string`, encryption key to be used for backups

Outputs:

.. csv-table::
:header: "Output", "Type", "Description"
:align: left
:widths: 5,5,15

`mode`,`string`, mode of the output stats
`fileCount`,`string`, number of files in backup
`size`, `string`, size of the number of files in backup

Example:

.. code-block:: yaml
:linenos:
actions:
backupStats:
type: Deployment
outputArtifacts:
backupStats:
keyValue:
mode: "{{ .Phases.backupDataStatsFromObjectStore.Output.BackupDataStatsOutputMode }}"
fileCount "{{ .Phases.backupDataStatsFromObjectStore.Output.BackupDataStatsOutputFileCount }}"
size: "{{ .Phases.backupDataStatsFromObjectStore.Output.BackupDataStatsOutputSize }}"
phases:
- func: BackupData
name: BackupToObjectStore
args:
namespace: "{{ .Deployment.Namespace }}"
backupArtifactPrefix: s3-bucket/path/artifactPrefix
mode: restore-size
backupID: "{{ .ArtifactsIn.snapshot.KeyValue.backupIdentifier }}"
Registering Functions
---------------------
Expand Down

0 comments on commit 9f896b4

Please sign in to comment.