51
51
* <ul>
52
52
* <li>Master calls {@link #initializeSnapshot(SnapshotId, List, org.elasticsearch.cluster.metadata.MetaData)}
53
53
* with list of indices that will be included into the snapshot</li>
54
- * <li>Data nodes call {@link Repository#snapshotShard(Store, MapperService, SnapshotId, IndexId, IndexCommit, IndexShardSnapshotStatus) }
54
+ * <li>Data nodes call {@link Repository#snapshotShard}
55
55
* for each shard</li>
56
56
* <li>When all shard calls return master calls {@link #finalizeSnapshot} with possible list of failures</li>
57
57
* </ul>
@@ -191,27 +191,6 @@ SnapshotInfo finalizeSnapshot(SnapshotId snapshotId, List<IndexId> indices, long
191
191
*/
192
192
boolean isReadOnly ();
193
193
194
- /**
195
- * Creates a snapshot of the shard based on the index commit point.
196
- * <p>
197
- * The index commit point can be obtained by using {@link org.elasticsearch.index.engine.Engine#acquireLastIndexCommit} method.
198
- * Repository implementations shouldn't release the snapshot index commit point. It is done by the method caller.
199
- * <p>
200
- * As snapshot process progresses, implementation of this method should update {@link IndexShardSnapshotStatus} object and check
201
- * {@link IndexShardSnapshotStatus#isAborted()} to see if the snapshot process should be aborted.
202
- * @param indexShard the shard to be snapshotted
203
- * @param snapshotId snapshot id
204
- * @param indexId id for the index being snapshotted
205
- * @param snapshotIndexCommit commit point
206
- * @param snapshotStatus snapshot status
207
- * @deprecated use {@link #snapshotShard(Store, MapperService, SnapshotId, IndexId, IndexCommit, IndexShardSnapshotStatus)} instead
208
- */
209
- @ Deprecated
210
- default void snapshotShard (IndexShard indexShard , SnapshotId snapshotId , IndexId indexId , IndexCommit snapshotIndexCommit ,
211
- IndexShardSnapshotStatus snapshotStatus ) {
212
- snapshotShard (indexShard .store (), indexShard .mapperService (), snapshotId , indexId , snapshotIndexCommit , snapshotStatus );
213
- }
214
-
215
194
/**
216
195
* Creates a snapshot of the shard based on the index commit point.
217
196
* <p>
@@ -226,9 +205,10 @@ default void snapshotShard(IndexShard indexShard, SnapshotId snapshotId, IndexId
226
205
* @param indexId id for the index being snapshotted
227
206
* @param snapshotIndexCommit commit point
228
207
* @param snapshotStatus snapshot status
208
+ * @param listener listener invoked on completion
229
209
*/
230
210
void snapshotShard (Store store , MapperService mapperService , SnapshotId snapshotId , IndexId indexId , IndexCommit snapshotIndexCommit ,
231
- IndexShardSnapshotStatus snapshotStatus );
211
+ IndexShardSnapshotStatus snapshotStatus , ActionListener < Void > listener );
232
212
233
213
/**
234
214
* Restores snapshot of the shard.
0 commit comments