1
+ --
2
+ :api: upgrade
3
+ :request: IndexUpgradeRequest
4
+ :response: BulkByScrollResponse
5
+ :submit_response: IndexUpgradeSubmissionResponse
6
+ :doc-tests-file: {doc-tests}/MigrationClientDocumentationIT.java
7
+ --
8
+
1
9
[[java-rest-high-migration-upgrade]]
2
10
=== Migration Upgrade
3
11
4
12
[[java-rest-high-migraton-upgrade-request]]
5
13
==== Index Upgrade Request
6
14
7
- An `IndexUpgradeRequest` requires an index argument. Only one index at the time should be upgraded:
15
+ An +{request}+ requires an index argument. Only one index at the time should be upgraded:
8
16
9
17
["source","java",subs="attributes,callouts,macros"]
10
18
--------------------------------------------------
11
- include-tagged::{doc-tests}/MigrationClientDocumentationIT.java[upgrade -request]
19
+ include-tagged::{doc-tests-file}[{api} -request]
12
20
--------------------------------------------------
13
21
<1> Create a new request instance
14
22
@@ -17,39 +25,37 @@ include-tagged::{doc-tests}/MigrationClientDocumentationIT.java[upgrade-request]
17
25
18
26
["source","java",subs="attributes,callouts,macros"]
19
27
--------------------------------------------------
20
- include-tagged::{doc-tests}/MigrationClientDocumentationIT.java[upgrade -execute]
28
+ include-tagged::{doc-tests-file}[{api} -execute]
21
29
--------------------------------------------------
22
30
23
31
[[java-rest-high-migration-upgrade-response]]
24
32
==== Response
25
- The returned `BulkByScrollResponse` contains information about the executed operation
33
+ The returned +{response}+ contains information about the executed operation
26
34
27
35
28
36
[[java-rest-high-migraton-async-upgrade-request]]
29
37
==== Asynchronous Execution
30
38
31
- The asynchronous execution of a upgrade request requires both the `IndexUpgradeRequest`
39
+ The asynchronous execution of an upgrade request requires both the +{request}+
32
40
instance and an `ActionListener` instance to be passed to the asynchronous
33
41
method:
34
42
35
- A typical listener for `BulkResponse` looks like:
36
-
37
43
["source","java",subs="attributes,callouts,macros"]
38
44
--------------------------------------------------
39
- include-tagged::{doc-tests}/MigrationClientDocumentationIT.java[upgrade -async-listener]
45
+ include-tagged::{doc-tests-file}[{api} -async-listener]
40
46
--------------------------------------------------
41
47
<1> Called when the execution is successfully completed. The response is
42
48
provided as an argument and contains a list of individual results for each
43
49
operation that was executed. Note that one or more operations might have
44
50
failed while the others have been successfully executed.
45
- <2> Called when the whole `IndexUpgradeRequest` fails. In this case the raised
51
+ <2> Called when the whole +{request}+ fails. In this case the raised
46
52
exception is provided as an argument and no operation has been executed.
47
53
48
54
["source","java",subs="attributes,callouts,macros"]
49
55
--------------------------------------------------
50
- include-tagged::{doc-tests}/MigrationClientDocumentationIT.java[upgrade -async-execute]
56
+ include-tagged::{doc-tests-file}[{api} -async-execute]
51
57
--------------------------------------------------
52
- <1> The `IndexUpgradeRequest` to execute and the `ActionListener` to use when
58
+ <1> The +{request}+ to execute and the `ActionListener` to use when
53
59
the execution completes
54
60
55
61
The asynchronous method does not block and returns immediately. Once it is
@@ -59,11 +65,11 @@ it failed.
59
65
60
66
61
67
=== Migration Upgrade with Task API
62
- Submission of upgrade request task will requires the `IndexUpgradeRequest` and will return
63
- `IndexUpgradeSubmissionResponse` . The `IndexUpgradeSubmissionResponse` can later be use to fetch
68
+ Submission of upgrade request task will requires the +{request}+ and will return
69
+ +{submit_response}+ . The +{submit_response}+ can later be use to fetch
64
70
TaskId and query the Task API for results.
65
71
66
72
["source","java",subs="attributes,callouts,macros"]
67
73
--------------------------------------------------
68
- include-tagged::{doc-tests}/MigrationClientDocumentationIT.java[upgrade -task-api]
74
+ include-tagged::{doc-tests-file}[{api} -task-api]
69
75
--------------------------------------------------
0 commit comments