forked from aws/aws-sdk-java
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathAWSDataSync.java
More file actions
553 lines (520 loc) · 24.5 KB
/
AWSDataSync.java
File metadata and controls
553 lines (520 loc) · 24.5 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
/*
* Copyright 2014-2019 Amazon.com, Inc. or its affiliates. All Rights Reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License"). You may not use this file except in compliance with
* the License. A copy of the License is located at
*
* http://aws.amazon.com/apache2.0
*
* or in the "license" file accompanying this file. This file is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR
* CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions
* and limitations under the License.
*/
package com.amazonaws.services.datasync;
import javax.annotation.Generated;
import com.amazonaws.*;
import com.amazonaws.regions.*;
import com.amazonaws.services.datasync.model.*;
/**
* Interface for accessing DataSync.
* <p>
* <b>Note:</b> Do not directly implement this interface, new methods are added to it regularly. Extend from
* {@link com.amazonaws.services.datasync.AbstractAWSDataSync} instead.
* </p>
* <p>
* <fullname>AWS DataSync</fullname>
* <p>
* AWS DataSync is a managed data transfer service that makes it simpler for you to automate moving data between
* on-premises storage and Amazon Simple Storage Service (Amazon S3) or Amazon Elastic File System (Amazon EFS).
* </p>
* <p>
* This API interface reference for AWS DataSync contains documentation for a programming interface that you can use to
* manage AWS DataSync.
* </p>
*/
@Generated("com.amazonaws:aws-java-sdk-code-generator")
public interface AWSDataSync {
/**
* The region metadata service name for computing region endpoints. You can use this value to retrieve metadata
* (such as supported regions) of the service.
*
* @see RegionUtils#getRegionsForService(String)
*/
String ENDPOINT_PREFIX = "datasync";
/**
* <p>
* Cancels execution of a task.
* </p>
* <p>
* When you cancel a task execution, the transfer of some files are abruptly interrupted. The contents of files that
* are transferred to the destination might be incomplete or inconsistent with the source files. However, if you
* start a new task execution on the same task and you allow the task execution to complete, file content on the
* destination is complete and consistent. This applies to other unexpected failures that interrupt a task
* execution. In all of these cases, AWS DataSync successfully complete the transfer when you start the next task
* execution.
* </p>
*
* @param cancelTaskExecutionRequest
* CancelTaskExecutionRequest
* @return Result of the CancelTaskExecution operation returned by the service.
* @throws InvalidRequestException
* This exception is thrown when the client submits a malformed request.
* @sample AWSDataSync.CancelTaskExecution
* @see <a href="http://docs.aws.amazon.com/goto/WebAPI/datasync-2018-11-09/CancelTaskExecution" target="_top">AWS
* API Documentation</a>
*/
CancelTaskExecutionResult cancelTaskExecution(CancelTaskExecutionRequest cancelTaskExecutionRequest);
/**
* <p>
* Activates an AWS DataSync agent that you have deployed on your host. The activation process associates your agent
* with your account. In the activation process, you specify information such as the AWS Region that you want to
* activate the agent in. You activate the agent in the AWS Region where your target locations (in Amazon S3 or
* Amazon EFS) reside. Your tasks are created in this AWS Region.
* </p>
* <p>
* You can use an agent for more than one location. If a task uses multiple agents, all of them need to have status
* AVAILABLE for the task to run. If you use multiple agents for a source location, the status of all the agents
* must be AVAILABLE for the task to run. For more information, see <a href=
* "https://docs.aws.amazon.com/sync-service/latest/userguide/working-with-sync-agents.html#activating-sync-agent"
* >Activating a Sync Agent</a> in the <i>AWS DataSync User Guide.</i>
* </p>
* <p>
* Agents are automatically updated by AWS on a regular basis, using a mechanism that ensures minimal interruption
* to your tasks.
* </p>
* <p/>
*
* @param createAgentRequest
* CreateAgentRequest
* @return Result of the CreateAgent operation returned by the service.
* @throws InvalidRequestException
* This exception is thrown when the client submits a malformed request.
* @sample AWSDataSync.CreateAgent
* @see <a href="http://docs.aws.amazon.com/goto/WebAPI/datasync-2018-11-09/CreateAgent" target="_top">AWS API
* Documentation</a>
*/
CreateAgentResult createAgent(CreateAgentRequest createAgentRequest);
/**
* <p>
* Creates an endpoint for an Amazon EFS file system.
* </p>
*
* @param createLocationEfsRequest
* CreateLocationEfsRequest
* @return Result of the CreateLocationEfs operation returned by the service.
* @throws InvalidRequestException
* This exception is thrown when the client submits a malformed request.
* @sample AWSDataSync.CreateLocationEfs
* @see <a href="http://docs.aws.amazon.com/goto/WebAPI/datasync-2018-11-09/CreateLocationEfs" target="_top">AWS API
* Documentation</a>
*/
CreateLocationEfsResult createLocationEfs(CreateLocationEfsRequest createLocationEfsRequest);
/**
* <p>
* Creates an endpoint for a Network File System (NFS) file system.
* </p>
*
* @param createLocationNfsRequest
* CreateLocationNfsRequest
* @return Result of the CreateLocationNfs operation returned by the service.
* @throws InvalidRequestException
* This exception is thrown when the client submits a malformed request.
* @sample AWSDataSync.CreateLocationNfs
* @see <a href="http://docs.aws.amazon.com/goto/WebAPI/datasync-2018-11-09/CreateLocationNfs" target="_top">AWS API
* Documentation</a>
*/
CreateLocationNfsResult createLocationNfs(CreateLocationNfsRequest createLocationNfsRequest);
/**
* <p>
* Creates an endpoint for an Amazon S3 bucket.
* </p>
* <p>
* For AWS DataSync to access a destination S3 bucket, it needs an AWS Identity and Access Management (IAM) role
* that has the required permissions. You can set up the required permissions by creating an IAM policy that grants
* the required permissions and attaching the policy to the role. An example of such a policy is shown in the
* examples section. For more information, see <a
* href="https://docs.aws.amazon.com/sync-service/latest/userguide/configuring-s3-locations.html">Configuring Amazon
* S3 Location Settings</a> in the <i>AWS DataSync User Guide</i>.
* </p>
*
* @param createLocationS3Request
* CreateLocationS3Request
* @return Result of the CreateLocationS3 operation returned by the service.
* @throws InvalidRequestException
* This exception is thrown when the client submits a malformed request.
* @sample AWSDataSync.CreateLocationS3
* @see <a href="http://docs.aws.amazon.com/goto/WebAPI/datasync-2018-11-09/CreateLocationS3" target="_top">AWS API
* Documentation</a>
*/
CreateLocationS3Result createLocationS3(CreateLocationS3Request createLocationS3Request);
/**
* <p>
* Creates a task. A task is a set of two locations (source and destination) and a set of default
* <code>OverrideOptions</code> that you use to control the behavior of a task. If you don't specify default values
* for <code>Options</code> when you create a task, AWS DataSync populates them with safe service defaults.
* </p>
* <p>
* When you initially create a task, it enters the INITIALIZING status and then the CREATING status. In CREATING
* status, AWS DataSync attempts to mount the source Network File System (NFS) location. The task transitions to the
* AVAILABLE status without waiting for the destination location to mount. Instead, AWS DataSync mounts a
* destination before every task execution and then unmounts it after every task execution.
* </p>
* <p>
* If an agent that is associated with a source (NFS) location goes offline, the task transitions to the UNAVAILABLE
* status. If the status of the task remains in the CREATING status for more than a few minutes, it means that your
* agent might be having trouble mounting the source NFS file system. Check the task's <code>ErrorCode</code> and
* <code>ErrorDetail</code>. Mount issues are often caused by either a misconfigured firewall or a mistyped NFS
* server host name.
* </p>
*
* @param createTaskRequest
* CreateTaskRequest
* @return Result of the CreateTask operation returned by the service.
* @throws InvalidRequestException
* This exception is thrown when the client submits a malformed request.
* @sample AWSDataSync.CreateTask
* @see <a href="http://docs.aws.amazon.com/goto/WebAPI/datasync-2018-11-09/CreateTask" target="_top">AWS API
* Documentation</a>
*/
CreateTaskResult createTask(CreateTaskRequest createTaskRequest);
/**
* <p>
* Deletes an agent. To specify which agent to delete, use the Amazon Resource Name (ARN) of the agent in your
* request. The operation disassociates the agent from your AWS account. However, it doesn't delete the agent
* virtual machine (VM) from your on-premises environment.
* </p>
* <note>
* <p>
* After you delete an agent, you can't reactivate it and you longer pay software charges for it.
* </p>
* </note>
*
* @param deleteAgentRequest
* DeleteAgentRequest
* @return Result of the DeleteAgent operation returned by the service.
* @throws InvalidRequestException
* This exception is thrown when the client submits a malformed request.
* @sample AWSDataSync.DeleteAgent
* @see <a href="http://docs.aws.amazon.com/goto/WebAPI/datasync-2018-11-09/DeleteAgent" target="_top">AWS API
* Documentation</a>
*/
DeleteAgentResult deleteAgent(DeleteAgentRequest deleteAgentRequest);
/**
* <p>
* Deletes the configuration of a location used by AWS DataSync.
* </p>
*
* @param deleteLocationRequest
* DeleteLocation
* @return Result of the DeleteLocation operation returned by the service.
* @throws InvalidRequestException
* This exception is thrown when the client submits a malformed request.
* @sample AWSDataSync.DeleteLocation
* @see <a href="http://docs.aws.amazon.com/goto/WebAPI/datasync-2018-11-09/DeleteLocation" target="_top">AWS API
* Documentation</a>
*/
DeleteLocationResult deleteLocation(DeleteLocationRequest deleteLocationRequest);
/**
* <p>
* Deletes a task.
* </p>
*
* @param deleteTaskRequest
* DeleteTask
* @return Result of the DeleteTask operation returned by the service.
* @throws InvalidRequestException
* This exception is thrown when the client submits a malformed request.
* @sample AWSDataSync.DeleteTask
* @see <a href="http://docs.aws.amazon.com/goto/WebAPI/datasync-2018-11-09/DeleteTask" target="_top">AWS API
* Documentation</a>
*/
DeleteTaskResult deleteTask(DeleteTaskRequest deleteTaskRequest);
/**
* <p>
* Returns metadata such as the name, the network interfaces, and the status (that is, whether the agent is running
* or not) for an agent. To specify which agent to describe, use the Amazon Resource Name (ARN) of the agent in your
* request.
* </p>
*
* @param describeAgentRequest
* DescribeAgent
* @return Result of the DescribeAgent operation returned by the service.
* @throws InvalidRequestException
* This exception is thrown when the client submits a malformed request.
* @sample AWSDataSync.DescribeAgent
* @see <a href="http://docs.aws.amazon.com/goto/WebAPI/datasync-2018-11-09/DescribeAgent" target="_top">AWS API
* Documentation</a>
*/
DescribeAgentResult describeAgent(DescribeAgentRequest describeAgentRequest);
/**
* <p>
* Returns metadata, such as the path information about an Amazon EFS location.
* </p>
*
* @param describeLocationEfsRequest
* DescribeLocationEfsRequest
* @return Result of the DescribeLocationEfs operation returned by the service.
* @throws InvalidRequestException
* This exception is thrown when the client submits a malformed request.
* @sample AWSDataSync.DescribeLocationEfs
* @see <a href="http://docs.aws.amazon.com/goto/WebAPI/datasync-2018-11-09/DescribeLocationEfs" target="_top">AWS
* API Documentation</a>
*/
DescribeLocationEfsResult describeLocationEfs(DescribeLocationEfsRequest describeLocationEfsRequest);
/**
* <p>
* Returns metadata, such as the path information, about a NFS location.
* </p>
*
* @param describeLocationNfsRequest
* DescribeLocationNfsRequest
* @return Result of the DescribeLocationNfs operation returned by the service.
* @throws InvalidRequestException
* This exception is thrown when the client submits a malformed request.
* @sample AWSDataSync.DescribeLocationNfs
* @see <a href="http://docs.aws.amazon.com/goto/WebAPI/datasync-2018-11-09/DescribeLocationNfs" target="_top">AWS
* API Documentation</a>
*/
DescribeLocationNfsResult describeLocationNfs(DescribeLocationNfsRequest describeLocationNfsRequest);
/**
* <p>
* Returns metadata, such as bucket name, about an Amazon S3 bucket location.
* </p>
*
* @param describeLocationS3Request
* DescribeLocationS3Request
* @return Result of the DescribeLocationS3 operation returned by the service.
* @throws InvalidRequestException
* This exception is thrown when the client submits a malformed request.
* @sample AWSDataSync.DescribeLocationS3
* @see <a href="http://docs.aws.amazon.com/goto/WebAPI/datasync-2018-11-09/DescribeLocationS3" target="_top">AWS
* API Documentation</a>
*/
DescribeLocationS3Result describeLocationS3(DescribeLocationS3Request describeLocationS3Request);
/**
* <p>
* Returns metadata about a task.
* </p>
*
* @param describeTaskRequest
* DescribeTaskRequest
* @return Result of the DescribeTask operation returned by the service.
* @throws InvalidRequestException
* This exception is thrown when the client submits a malformed request.
* @sample AWSDataSync.DescribeTask
* @see <a href="http://docs.aws.amazon.com/goto/WebAPI/datasync-2018-11-09/DescribeTask" target="_top">AWS API
* Documentation</a>
*/
DescribeTaskResult describeTask(DescribeTaskRequest describeTaskRequest);
/**
* <p>
* Returns detailed metadata about a task that is being executed.
* </p>
*
* @param describeTaskExecutionRequest
* DescribeTaskExecutionRequest
* @return Result of the DescribeTaskExecution operation returned by the service.
* @throws InvalidRequestException
* This exception is thrown when the client submits a malformed request.
* @sample AWSDataSync.DescribeTaskExecution
* @see <a href="http://docs.aws.amazon.com/goto/WebAPI/datasync-2018-11-09/DescribeTaskExecution" target="_top">AWS
* API Documentation</a>
*/
DescribeTaskExecutionResult describeTaskExecution(DescribeTaskExecutionRequest describeTaskExecutionRequest);
/**
* <p>
* Returns a list of agents owned by an AWS account in the AWS Region specified in the request. The returned list is
* ordered by agent Amazon Resource Name (ARN).
* </p>
* <p>
* By default, this operation returns a maximum of 100 agents. This operation supports pagination that enables you
* to optionally reduce the number of agents returned in a response.
* </p>
* <p>
* If you have more agents than are returned in a response (that is, the response returns only a truncated list of
* your agents), the response contains a marker that you can specify in your next request to fetch the next page of
* agents.
* </p>
*
* @param listAgentsRequest
* ListAgentsRequest
* @return Result of the ListAgents operation returned by the service.
* @throws InvalidRequestException
* This exception is thrown when the client submits a malformed request.
* @sample AWSDataSync.ListAgents
* @see <a href="http://docs.aws.amazon.com/goto/WebAPI/datasync-2018-11-09/ListAgents" target="_top">AWS API
* Documentation</a>
*/
ListAgentsResult listAgents(ListAgentsRequest listAgentsRequest);
/**
* <p>
* Returns a lists of source and destination locations.
* </p>
* <p>
* If you have more locations than are returned in a response (that is, the response returns only a truncated list
* of your agents), the response contains a token that you can specify in your next request to fetch the next page
* of locations.
* </p>
*
* @param listLocationsRequest
* ListLocationsRequest
* @return Result of the ListLocations operation returned by the service.
* @throws InvalidRequestException
* This exception is thrown when the client submits a malformed request.
* @sample AWSDataSync.ListLocations
* @see <a href="http://docs.aws.amazon.com/goto/WebAPI/datasync-2018-11-09/ListLocations" target="_top">AWS API
* Documentation</a>
*/
ListLocationsResult listLocations(ListLocationsRequest listLocationsRequest);
/**
* <p>
* Returns all the tags associated with a specified resources.
* </p>
*
* @param listTagsForResourceRequest
* ListTagsForResourceRequest
* @return Result of the ListTagsForResource operation returned by the service.
* @throws InvalidRequestException
* This exception is thrown when the client submits a malformed request.
* @sample AWSDataSync.ListTagsForResource
* @see <a href="http://docs.aws.amazon.com/goto/WebAPI/datasync-2018-11-09/ListTagsForResource" target="_top">AWS
* API Documentation</a>
*/
ListTagsForResourceResult listTagsForResource(ListTagsForResourceRequest listTagsForResourceRequest);
/**
* <p>
* Returns a list of executed tasks.
* </p>
*
* @param listTaskExecutionsRequest
* ListTaskExecutions
* @return Result of the ListTaskExecutions operation returned by the service.
* @throws InvalidRequestException
* This exception is thrown when the client submits a malformed request.
* @sample AWSDataSync.ListTaskExecutions
* @see <a href="http://docs.aws.amazon.com/goto/WebAPI/datasync-2018-11-09/ListTaskExecutions" target="_top">AWS
* API Documentation</a>
*/
ListTaskExecutionsResult listTaskExecutions(ListTaskExecutionsRequest listTaskExecutionsRequest);
/**
* <p>
* Returns a list of all the tasks.
* </p>
*
* @param listTasksRequest
* ListTasksRequest
* @return Result of the ListTasks operation returned by the service.
* @throws InvalidRequestException
* This exception is thrown when the client submits a malformed request.
* @sample AWSDataSync.ListTasks
* @see <a href="http://docs.aws.amazon.com/goto/WebAPI/datasync-2018-11-09/ListTasks" target="_top">AWS API
* Documentation</a>
*/
ListTasksResult listTasks(ListTasksRequest listTasksRequest);
/**
* <p>
* Starts a specific invocation of a task. A <code>TaskExecution</code> value represents an individual run of a
* task. Each task can have at most one <code>TaskExecution</code> at a time.
* </p>
* <p>
* <code>TaskExecution</code> has the following transition phases: INITIALIZING | PREPARING | TRANSFERRING |
* VERIFYING | SUCCESS/FAILURE.
* </p>
* <p>
* For detailed information, see <i>Task Execution</i> in <a
* href="https://docs.aws.amazon.com/sync-service/latest/userguide/how-awssync-works.html#terminology">Components
* and Terminology</a> in the <i>AWS DataSync User Guide</i>.
* </p>
*
* @param startTaskExecutionRequest
* StartTaskExecutionRequest
* @return Result of the StartTaskExecution operation returned by the service.
* @throws InvalidRequestException
* This exception is thrown when the client submits a malformed request.
* @sample AWSDataSync.StartTaskExecution
* @see <a href="http://docs.aws.amazon.com/goto/WebAPI/datasync-2018-11-09/StartTaskExecution" target="_top">AWS
* API Documentation</a>
*/
StartTaskExecutionResult startTaskExecution(StartTaskExecutionRequest startTaskExecutionRequest);
/**
* <p>
* Applies a key-value pair to an AWS resource.
* </p>
*
* @param tagResourceRequest
* TagResourceRequest
* @return Result of the TagResource operation returned by the service.
* @throws InvalidRequestException
* This exception is thrown when the client submits a malformed request.
* @sample AWSDataSync.TagResource
* @see <a href="http://docs.aws.amazon.com/goto/WebAPI/datasync-2018-11-09/TagResource" target="_top">AWS API
* Documentation</a>
*/
TagResourceResult tagResource(TagResourceRequest tagResourceRequest);
/**
* <p>
* Removes a tag from an AWS resource.
* </p>
*
* @param untagResourceRequest
* UntagResourceRequest
* @return Result of the UntagResource operation returned by the service.
* @throws InvalidRequestException
* This exception is thrown when the client submits a malformed request.
* @sample AWSDataSync.UntagResource
* @see <a href="http://docs.aws.amazon.com/goto/WebAPI/datasync-2018-11-09/UntagResource" target="_top">AWS API
* Documentation</a>
*/
UntagResourceResult untagResource(UntagResourceRequest untagResourceRequest);
/**
* <p>
* Updates the name of an agent.
* </p>
*
* @param updateAgentRequest
* UpdateAgentRequest
* @return Result of the UpdateAgent operation returned by the service.
* @throws InvalidRequestException
* This exception is thrown when the client submits a malformed request.
* @sample AWSDataSync.UpdateAgent
* @see <a href="http://docs.aws.amazon.com/goto/WebAPI/datasync-2018-11-09/UpdateAgent" target="_top">AWS API
* Documentation</a>
*/
UpdateAgentResult updateAgent(UpdateAgentRequest updateAgentRequest);
/**
* <p>
* Updates the metadata associated with a task.
* </p>
*
* @param updateTaskRequest
* UpdateTaskResponse
* @return Result of the UpdateTask operation returned by the service.
* @throws InvalidRequestException
* This exception is thrown when the client submits a malformed request.
* @sample AWSDataSync.UpdateTask
* @see <a href="http://docs.aws.amazon.com/goto/WebAPI/datasync-2018-11-09/UpdateTask" target="_top">AWS API
* Documentation</a>
*/
UpdateTaskResult updateTask(UpdateTaskRequest updateTaskRequest);
/**
* Shuts down this client object, releasing any resources that might be held open. This is an optional method, and
* callers are not expected to call it, but can if they want to explicitly release any open resources. Once a client
* has been shutdown, it should not be used to make any more requests.
*/
void shutdown();
/**
* Returns additional metadata for a previously executed successful request, typically used for debugging issues
* where a service isn't acting as expected. This data isn't considered part of the result data returned by an
* operation, so it's available through this separate, diagnostic interface.
* <p>
* Response metadata is only cached for a limited period of time, so if you need to access this extra diagnostic
* information for an executed request, you should use this method to retrieve it as soon as possible after
* executing a request.
*
* @param request
* The originally executed request.
*
* @return The response metadata for the specified request, or null if none is available.
*/
ResponseMetadata getCachedResponseMetadata(AmazonWebServiceRequest request);
}