Skip to content

Conversation

@tlrx
Copy link
Member

@tlrx tlrx commented Mar 23, 2021

This commit adds some missing documentation about the Clone Snapshot Java API.

Relates #63863

@tlrx tlrx added >docs General docs changes :Distributed Coordination/Snapshot/Restore Anything directly related to the `_snapshot/*` APIs v8.0.0 v7.13.0 v7.12.1 labels Mar 23, 2021
@elasticmachine elasticmachine added Team:Docs Meta label for docs team Team:Distributed (Obsolete) Meta label for distributed team (obsolete). Replaced by Distributed Indexing/Coordination. labels Mar 23, 2021
@elasticmachine
Copy link
Collaborator

Pinging @elastic/es-docs (Team:Docs)

@elasticmachine
Copy link
Collaborator

Pinging @elastic/es-distributed (Team:Distributed)

@tlrx
Copy link
Member Author

tlrx commented Mar 23, 2021

Tests failed for unrelated failure tracked reported in #70746:

@elasticmachine run elasticsearch-ci/2

@tlrx tlrx requested a review from ywelsch March 24, 2021 09:07
Copy link
Contributor

@ywelsch ywelsch left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've left one comment, o.w. looks good. Adding @jrodewig as a reviewer here as well for an extra pair of eyes.

==== Indices to Clone

The `indices` property is used to provide the list of
indices that should be included in the snapshot:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

provide the list of indices from the source snapshot to be included in the snapshot clone

@ywelsch ywelsch requested a review from jrodewig March 24, 2021 09:20
Copy link
Contributor

@jrodewig jrodewig left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM with @ywelsch's edit. I left a few suggestions, but they're all non-blocking nits. Feel free to ignore them if wanted.

Thanks @tlrx!

[[java-rest-high-snapshot-clone-snapshot]]
=== Clone Snapshot API

The Clone Snapshot API allows to clone part or all of a snapshot into a new snapshot.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
The Clone Snapshot API allows to clone part or all of a snapshot into a new snapshot.
The Clone Snapshot API clones part or all of a snapshot into a new snapshot.

The Clone Snapshot API allows to clone part or all of a snapshot into a new snapshot.

[[java-rest-high-snapshot-clone-snapshot-request]]
==== Clone Snapshot Request
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit

Suggested change
==== Clone Snapshot Request
==== Request

<2> Called in case of a failure. The raised exception is provided as an argument.

[[java-rest-high-cluster-clone-snapshot-response]]
==== Clone Snapshot Response
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit

Suggested change
==== Clone Snapshot Response
==== Response

Comment on lines 18 to 19
The `indices` property is used to provide the list of
indices that should be included in the snapshot:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
The `indices` property is used to provide the list of
indices that should be included in the snapshot:
Use `indices` to specify a list of indices from the source snapshot to include
in the snapshot clone:

--------------------------------------------------
include-tagged::{doc-tests}/SnapshotClientDocumentationIT.java[clone-snapshot-request-indices]
--------------------------------------------------
<1> Request that Elasticsearch only includes "test_index" from the source snapshot.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
<1> Request that Elasticsearch only includes "test_index" from the source snapshot.
<1> Include only `test_index` from the source snapshot.


==== Further Arguments

The following arguments can optionally be provided:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
The following arguments can optionally be provided:
You can also provide the following optional arguments:

--------------------------------------------------
include-tagged::{doc-tests}/SnapshotClientDocumentationIT.java[clone-snapshot-response]
--------------------------------------------------
<1> A boolean value of `true` if the clone successfully completed, `false` otherwise.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nit

Suggested change
<1> A boolean value of `true` if the clone successfully completed, `false` otherwise.
<1> A boolean value of `true` if the clone successfully completed. Otherwise, the value is `false`.

Comment on lines 89 to 90
The returned `AcknowledgedResponse` contains a value on whether or not the request
was received:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
The returned `AcknowledgedResponse` contains a value on whether or not the request
was received:
`AcknowledgedResponse` indicates whether the request was received:

@tlrx tlrx merged commit 222f2a0 into elastic:master Mar 24, 2021
@tlrx
Copy link
Member Author

tlrx commented Mar 24, 2021

Thanks both!

@jrodewig I initially borrowed most of the content of this change from the other create/delete/restore Java APIs docs, so I think many of your comments are also applicable there.

@tlrx tlrx deleted the hlrc-clone-api-java-documentation branch March 24, 2021 14:34
tlrx added a commit to tlrx/elasticsearch that referenced this pull request Mar 24, 2021
This commit adds some missing documentation about 
the Clone Snapshot Java API.

Relates elastic#63863
tlrx added a commit to tlrx/elasticsearch that referenced this pull request Mar 24, 2021
This commit adds some missing documentation about 
the Clone Snapshot Java API.

Relates elastic#63863
tlrx added a commit that referenced this pull request Mar 24, 2021
This commit adds some missing documentation about 
the Clone Snapshot Java API.

Relates #63863
tlrx added a commit that referenced this pull request Mar 24, 2021
This commit adds some missing documentation about 
the Clone Snapshot Java API.

Relates #63863
@jakelandis jakelandis removed the v8.0.0 label Jul 26, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

:Distributed Coordination/Snapshot/Restore Anything directly related to the `_snapshot/*` APIs >docs General docs changes Team:Distributed (Obsolete) Meta label for distributed team (obsolete). Replaced by Distributed Indexing/Coordination. Team:Docs Meta label for docs team v7.12.1 v7.13.0 v8.0.0-alpha1

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants