This commit is contained in:
parent
2ef12c37f5
commit
256102042b
|
@ -215,20 +215,48 @@ PUT /_slm/policy/daily-snapshots
|
||||||
|
|
||||||
|
|
||||||
[[slm-api-get]]
|
[[slm-api-get]]
|
||||||
=== Get Snapshot Lifecycle Policy API
|
=== Get snapshot lifecycle policy API
|
||||||
|
++++
|
||||||
|
<titleabbrev>Get snapshot lifecycle policy</titleabbrev>
|
||||||
|
++++
|
||||||
|
|
||||||
Once a policy is in place, you can retrieve one or more of the policies using
|
Returns information
|
||||||
the get snapshot lifecycle policy API. This also includes information about the
|
about one or more snapshot lifecycle policies.
|
||||||
latest successful and failed invocation that the automatic snapshots have taken.
|
|
||||||
|
|
||||||
==== Path Parameters
|
|
||||||
|
|
||||||
`policy_ids` (optional)::
|
[[slm-api-get-request]]
|
||||||
(string) Comma-separated ids of policies to retrieve.
|
==== {api-request-title}
|
||||||
|
|
||||||
==== Examples
|
`GET /_slm/policy/<snapshot-lifecycle-policy-id>`
|
||||||
|
|
||||||
To retrieve a policy, perform a `GET` with the policy's id
|
`GET /_slm/policy/`
|
||||||
|
|
||||||
|
|
||||||
|
[[slm-api-get-desc]]
|
||||||
|
==== {api-description-title}
|
||||||
|
|
||||||
|
Use the snapshot lifecycle policy API
|
||||||
|
to retrieve information
|
||||||
|
about one or more snapshot lifecycle policies.
|
||||||
|
The API response also includes information
|
||||||
|
about the latest successful and failed attempts
|
||||||
|
to create automatic snapshots.
|
||||||
|
|
||||||
|
[[slm-api-get-path-params]]
|
||||||
|
==== {api-path-parms-title}
|
||||||
|
|
||||||
|
`<snapshot-lifecycle-policy-id>`::
|
||||||
|
(Optional, string)
|
||||||
|
Comma-separated list of snapshot lifecycle policy IDs
|
||||||
|
to retrieve.
|
||||||
|
|
||||||
|
|
||||||
|
[[slm-api-get-example]]
|
||||||
|
==== {api-examples-title}
|
||||||
|
|
||||||
|
|
||||||
|
[[slm-api-get-specific-ex]]
|
||||||
|
===== Get a specific policy
|
||||||
|
|
||||||
[source,console]
|
[source,console]
|
||||||
--------------------------------------------------
|
--------------------------------------------------
|
||||||
|
@ -236,7 +264,7 @@ GET /_slm/policy/daily-snapshots?human
|
||||||
--------------------------------------------------
|
--------------------------------------------------
|
||||||
// TEST[continued]
|
// TEST[continued]
|
||||||
|
|
||||||
The output looks similar to the following:
|
The API returns the following response:
|
||||||
|
|
||||||
[source,console-result]
|
[source,console-result]
|
||||||
--------------------------------------------------
|
--------------------------------------------------
|
||||||
|
@ -274,10 +302,12 @@ The output looks similar to the following:
|
||||||
--------------------------------------------------
|
--------------------------------------------------
|
||||||
// TESTRESPONSE[s/"modified_date": "2019-04-23T01:30:00.000Z"/"modified_date": $body.daily-snapshots.modified_date/ s/"modified_date_millis": 1556048137314/"modified_date_millis": $body.daily-snapshots.modified_date_millis/ s/"next_execution": "2019-04-24T01:30:00.000Z"/"next_execution": $body.daily-snapshots.next_execution/ s/"next_execution_millis": 1556048160000/"next_execution_millis": $body.daily-snapshots.next_execution_millis/]
|
// TESTRESPONSE[s/"modified_date": "2019-04-23T01:30:00.000Z"/"modified_date": $body.daily-snapshots.modified_date/ s/"modified_date_millis": 1556048137314/"modified_date_millis": $body.daily-snapshots.modified_date_millis/ s/"next_execution": "2019-04-24T01:30:00.000Z"/"next_execution": $body.daily-snapshots.next_execution/ s/"next_execution_millis": 1556048160000/"next_execution_millis": $body.daily-snapshots.next_execution_millis/]
|
||||||
<1> The version of the snapshot policy, only the latest verison is stored and incremented when the policy is updated
|
<1> The version of the snapshot policy, only the latest verison is stored and incremented when the policy is updated
|
||||||
<2> The last time this policy was modified
|
<2> The last time this policy was modified.
|
||||||
<3> The next time this policy will be executed
|
<3> The next time this policy will be executed.
|
||||||
|
|
||||||
Or, to retrieve all policies:
|
|
||||||
|
[[slm-api-get-all-ex]]
|
||||||
|
===== Get all policies
|
||||||
|
|
||||||
[source,console]
|
[source,console]
|
||||||
--------------------------------------------------
|
--------------------------------------------------
|
||||||
|
@ -285,6 +315,7 @@ GET /_slm/policy
|
||||||
--------------------------------------------------
|
--------------------------------------------------
|
||||||
// TEST[continued]
|
// TEST[continued]
|
||||||
|
|
||||||
|
|
||||||
[[slm-api-execute]]
|
[[slm-api-execute]]
|
||||||
=== Execute Snapshot Lifecycle Policy API
|
=== Execute Snapshot Lifecycle Policy API
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue