forked from aws/aws-sdk-go
-
Notifications
You must be signed in to change notification settings - Fork 0
/
api.go
6452 lines (5342 loc) · 206 KB
/
api.go
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
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
// THIS FILE IS AUTOMATICALLY GENERATED. DO NOT EDIT.
// Package storagegateway provides a client for AWS Storage Gateway.
package storagegateway
import (
"fmt"
"time"
"github.com/aws/aws-sdk-go/aws/awsutil"
"github.com/aws/aws-sdk-go/aws/request"
)
const opActivateGateway = "ActivateGateway"
// ActivateGatewayRequest generates a request for the ActivateGateway operation.
func (c *StorageGateway) ActivateGatewayRequest(input *ActivateGatewayInput) (req *request.Request, output *ActivateGatewayOutput) {
op := &request.Operation{
Name: opActivateGateway,
HTTPMethod: "POST",
HTTPPath: "/",
}
if input == nil {
input = &ActivateGatewayInput{}
}
req = c.newRequest(op, input, output)
output = &ActivateGatewayOutput{}
req.Data = output
return
}
// Activates the gateway you previously deployed on your host. For more information,
// see Activate the AWS Storage Gateway (http://docs.aws.amazon.com/storagegateway/latest/userguide/GettingStartedActivateGateway-common.html).
// In the activation process, you specify information such as the you want to
// use for storing snapshots, the time zone for scheduled snapshots the gateway
// snapshot schedule window, an activation key, and a name for your gateway.
// The activation process also associates your gateway with your account; for
// more information, see UpdateGatewayInformation.
//
// You must turn on the gateway VM before you can activate your gateway.
func (c *StorageGateway) ActivateGateway(input *ActivateGatewayInput) (*ActivateGatewayOutput, error) {
req, out := c.ActivateGatewayRequest(input)
err := req.Send()
return out, err
}
const opAddCache = "AddCache"
// AddCacheRequest generates a request for the AddCache operation.
func (c *StorageGateway) AddCacheRequest(input *AddCacheInput) (req *request.Request, output *AddCacheOutput) {
op := &request.Operation{
Name: opAddCache,
HTTPMethod: "POST",
HTTPPath: "/",
}
if input == nil {
input = &AddCacheInput{}
}
req = c.newRequest(op, input, output)
output = &AddCacheOutput{}
req.Data = output
return
}
// Configures one or more gateway local disks as cache for a cached-volume gateway.
// This operation is supported only for the gateway-cached volume architecture
// (see Storage Gateway Concepts (http://docs.aws.amazon.com/storagegateway/latest/userguide/StorageGatewayConcepts.html)).
//
// In the request, you specify the gateway Amazon Resource Name (ARN) to which
// you want to add cache, and one or more disk IDs that you want to configure
// as cache.
func (c *StorageGateway) AddCache(input *AddCacheInput) (*AddCacheOutput, error) {
req, out := c.AddCacheRequest(input)
err := req.Send()
return out, err
}
const opAddTagsToResource = "AddTagsToResource"
// AddTagsToResourceRequest generates a request for the AddTagsToResource operation.
func (c *StorageGateway) AddTagsToResourceRequest(input *AddTagsToResourceInput) (req *request.Request, output *AddTagsToResourceOutput) {
op := &request.Operation{
Name: opAddTagsToResource,
HTTPMethod: "POST",
HTTPPath: "/",
}
if input == nil {
input = &AddTagsToResourceInput{}
}
req = c.newRequest(op, input, output)
output = &AddTagsToResourceOutput{}
req.Data = output
return
}
// Adds one or more tags to the specified resource. You use tags to add metadata
// to resources, which you can use to categorize these resources. For example,
// you can categorize resources by purpose, owner, environment, or team. Each
// tag consists of a key and a value, which you define. You can add tags to
// the following AWS Storage Gateway resources:
//
// Storage gateways of all types
//
// Storage Volumes
//
// Virtual Tapes
//
// You can create a maximum of 10 tags for each resource. Virtual tapes and
// storage volumes that are recovered to a new gateway maintain their tags.
func (c *StorageGateway) AddTagsToResource(input *AddTagsToResourceInput) (*AddTagsToResourceOutput, error) {
req, out := c.AddTagsToResourceRequest(input)
err := req.Send()
return out, err
}
const opAddUploadBuffer = "AddUploadBuffer"
// AddUploadBufferRequest generates a request for the AddUploadBuffer operation.
func (c *StorageGateway) AddUploadBufferRequest(input *AddUploadBufferInput) (req *request.Request, output *AddUploadBufferOutput) {
op := &request.Operation{
Name: opAddUploadBuffer,
HTTPMethod: "POST",
HTTPPath: "/",
}
if input == nil {
input = &AddUploadBufferInput{}
}
req = c.newRequest(op, input, output)
output = &AddUploadBufferOutput{}
req.Data = output
return
}
// Configures one or more gateway local disks as upload buffer for a specified
// gateway. This operation is supported for both the gateway-stored and gateway-cached
// volume architectures.
//
// In the request, you specify the gateway Amazon Resource Name (ARN) to which
// you want to add upload buffer, and one or more disk IDs that you want to
// configure as upload buffer.
func (c *StorageGateway) AddUploadBuffer(input *AddUploadBufferInput) (*AddUploadBufferOutput, error) {
req, out := c.AddUploadBufferRequest(input)
err := req.Send()
return out, err
}
const opAddWorkingStorage = "AddWorkingStorage"
// AddWorkingStorageRequest generates a request for the AddWorkingStorage operation.
func (c *StorageGateway) AddWorkingStorageRequest(input *AddWorkingStorageInput) (req *request.Request, output *AddWorkingStorageOutput) {
op := &request.Operation{
Name: opAddWorkingStorage,
HTTPMethod: "POST",
HTTPPath: "/",
}
if input == nil {
input = &AddWorkingStorageInput{}
}
req = c.newRequest(op, input, output)
output = &AddWorkingStorageOutput{}
req.Data = output
return
}
// Configures one or more gateway local disks as working storage for a gateway.
// This operation is supported only for the gateway-stored volume architecture.
// This operation is deprecated in cached-volumes API version 20120630. Use
// AddUploadBuffer instead.
//
// Working storage is also referred to as upload buffer. You can also use
// the AddUploadBuffer operation to add upload buffer to a stored-volume gateway.
//
// In the request, you specify the gateway Amazon Resource Name (ARN) to which
// you want to add working storage, and one or more disk IDs that you want to
// configure as working storage.
func (c *StorageGateway) AddWorkingStorage(input *AddWorkingStorageInput) (*AddWorkingStorageOutput, error) {
req, out := c.AddWorkingStorageRequest(input)
err := req.Send()
return out, err
}
const opCancelArchival = "CancelArchival"
// CancelArchivalRequest generates a request for the CancelArchival operation.
func (c *StorageGateway) CancelArchivalRequest(input *CancelArchivalInput) (req *request.Request, output *CancelArchivalOutput) {
op := &request.Operation{
Name: opCancelArchival,
HTTPMethod: "POST",
HTTPPath: "/",
}
if input == nil {
input = &CancelArchivalInput{}
}
req = c.newRequest(op, input, output)
output = &CancelArchivalOutput{}
req.Data = output
return
}
// Cancels archiving of a virtual tape to the virtual tape shelf (VTS) after
// the archiving process is initiated.
func (c *StorageGateway) CancelArchival(input *CancelArchivalInput) (*CancelArchivalOutput, error) {
req, out := c.CancelArchivalRequest(input)
err := req.Send()
return out, err
}
const opCancelRetrieval = "CancelRetrieval"
// CancelRetrievalRequest generates a request for the CancelRetrieval operation.
func (c *StorageGateway) CancelRetrievalRequest(input *CancelRetrievalInput) (req *request.Request, output *CancelRetrievalOutput) {
op := &request.Operation{
Name: opCancelRetrieval,
HTTPMethod: "POST",
HTTPPath: "/",
}
if input == nil {
input = &CancelRetrievalInput{}
}
req = c.newRequest(op, input, output)
output = &CancelRetrievalOutput{}
req.Data = output
return
}
// Cancels retrieval of a virtual tape from the virtual tape shelf (VTS) to
// a gateway after the retrieval process is initiated. The virtual tape is returned
// to the VTS.
func (c *StorageGateway) CancelRetrieval(input *CancelRetrievalInput) (*CancelRetrievalOutput, error) {
req, out := c.CancelRetrievalRequest(input)
err := req.Send()
return out, err
}
const opCreateCachediSCSIVolume = "CreateCachediSCSIVolume"
// CreateCachediSCSIVolumeRequest generates a request for the CreateCachediSCSIVolume operation.
func (c *StorageGateway) CreateCachediSCSIVolumeRequest(input *CreateCachediSCSIVolumeInput) (req *request.Request, output *CreateCachediSCSIVolumeOutput) {
op := &request.Operation{
Name: opCreateCachediSCSIVolume,
HTTPMethod: "POST",
HTTPPath: "/",
}
if input == nil {
input = &CreateCachediSCSIVolumeInput{}
}
req = c.newRequest(op, input, output)
output = &CreateCachediSCSIVolumeOutput{}
req.Data = output
return
}
// Creates a cached volume on a specified cached gateway. This operation is
// supported only for the gateway-cached volume architecture.
//
// Cache storage must be allocated to the gateway before you can create a cached
// volume. Use the AddCache operation to add cache storage to a gateway.
//
// In the request, you must specify the gateway, size of the volume in bytes,
// the iSCSI target name, an IP address on which to expose the target, and a
// unique client token. In response, AWS Storage Gateway creates the volume
// and returns information about it such as the volume Amazon Resource Name
// (ARN), its size, and the iSCSI target ARN that initiators can use to connect
// to the volume target.
func (c *StorageGateway) CreateCachediSCSIVolume(input *CreateCachediSCSIVolumeInput) (*CreateCachediSCSIVolumeOutput, error) {
req, out := c.CreateCachediSCSIVolumeRequest(input)
err := req.Send()
return out, err
}
const opCreateSnapshot = "CreateSnapshot"
// CreateSnapshotRequest generates a request for the CreateSnapshot operation.
func (c *StorageGateway) CreateSnapshotRequest(input *CreateSnapshotInput) (req *request.Request, output *CreateSnapshotOutput) {
op := &request.Operation{
Name: opCreateSnapshot,
HTTPMethod: "POST",
HTTPPath: "/",
}
if input == nil {
input = &CreateSnapshotInput{}
}
req = c.newRequest(op, input, output)
output = &CreateSnapshotOutput{}
req.Data = output
return
}
// Initiates a snapshot of a volume.
//
// AWS Storage Gateway provides the ability to back up point-in-time snapshots
// of your data to Amazon Simple Storage (S3) for durable off-site recovery,
// as well as import the data to an Amazon Elastic Block Store (EBS) volume
// in Amazon Elastic Compute Cloud (EC2). You can take snapshots of your gateway
// volume on a scheduled or ad-hoc basis. This API enables you to take ad-hoc
// snapshot. For more information, see Working With Snapshots in the AWS Storage
// Gateway Console (http://docs.aws.amazon.com/storagegateway/latest/userguide/WorkingWithSnapshots.html).
//
// In the CreateSnapshot request you identify the volume by providing its Amazon
// Resource Name (ARN). You must also provide description for the snapshot.
// When AWS Storage Gateway takes the snapshot of specified volume, the snapshot
// and description appears in the AWS Storage Gateway Console. In response,
// AWS Storage Gateway returns you a snapshot ID. You can use this snapshot
// ID to check the snapshot progress or later use it when you want to create
// a volume from a snapshot.
//
// To list or delete a snapshot, you must use the Amazon EC2 API. For more
// information, see DescribeSnapshots or DeleteSnapshot in the EC2 API reference
// (http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_Operations.html).
//
// Volume and snapshot IDs are changing to a longer length ID format. For
// more information, see the important note on the Welcome (http://docs.aws.amazon.com/storagegateway/latest/APIReference/Welcome.html)
// page.
func (c *StorageGateway) CreateSnapshot(input *CreateSnapshotInput) (*CreateSnapshotOutput, error) {
req, out := c.CreateSnapshotRequest(input)
err := req.Send()
return out, err
}
const opCreateSnapshotFromVolumeRecoveryPoint = "CreateSnapshotFromVolumeRecoveryPoint"
// CreateSnapshotFromVolumeRecoveryPointRequest generates a request for the CreateSnapshotFromVolumeRecoveryPoint operation.
func (c *StorageGateway) CreateSnapshotFromVolumeRecoveryPointRequest(input *CreateSnapshotFromVolumeRecoveryPointInput) (req *request.Request, output *CreateSnapshotFromVolumeRecoveryPointOutput) {
op := &request.Operation{
Name: opCreateSnapshotFromVolumeRecoveryPoint,
HTTPMethod: "POST",
HTTPPath: "/",
}
if input == nil {
input = &CreateSnapshotFromVolumeRecoveryPointInput{}
}
req = c.newRequest(op, input, output)
output = &CreateSnapshotFromVolumeRecoveryPointOutput{}
req.Data = output
return
}
// Initiates a snapshot of a gateway from a volume recovery point. This operation
// is supported only for the gateway-cached volume architecture.
//
// A volume recovery point is a point in time at which all data of the volume
// is consistent and from which you can create a snapshot. To get a list of
// volume recovery point for gateway-cached volumes, use ListVolumeRecoveryPoints.
//
// In the CreateSnapshotFromVolumeRecoveryPoint request, you identify the volume
// by providing its Amazon Resource Name (ARN). You must also provide a description
// for the snapshot. When AWS Storage Gateway takes a snapshot of the specified
// volume, the snapshot and its description appear in the AWS Storage Gateway
// console. In response, AWS Storage Gateway returns you a snapshot ID. You
// can use this snapshot ID to check the snapshot progress or later use it when
// you want to create a volume from a snapshot.
//
// To list or delete a snapshot, you must use the Amazon EC2 API. For more
// information, in Amazon Elastic Compute Cloud API Reference.
func (c *StorageGateway) CreateSnapshotFromVolumeRecoveryPoint(input *CreateSnapshotFromVolumeRecoveryPointInput) (*CreateSnapshotFromVolumeRecoveryPointOutput, error) {
req, out := c.CreateSnapshotFromVolumeRecoveryPointRequest(input)
err := req.Send()
return out, err
}
const opCreateStorediSCSIVolume = "CreateStorediSCSIVolume"
// CreateStorediSCSIVolumeRequest generates a request for the CreateStorediSCSIVolume operation.
func (c *StorageGateway) CreateStorediSCSIVolumeRequest(input *CreateStorediSCSIVolumeInput) (req *request.Request, output *CreateStorediSCSIVolumeOutput) {
op := &request.Operation{
Name: opCreateStorediSCSIVolume,
HTTPMethod: "POST",
HTTPPath: "/",
}
if input == nil {
input = &CreateStorediSCSIVolumeInput{}
}
req = c.newRequest(op, input, output)
output = &CreateStorediSCSIVolumeOutput{}
req.Data = output
return
}
// Creates a volume on a specified gateway. This operation is supported only
// for the gateway-stored volume architecture.
//
// The size of the volume to create is inferred from the disk size. You can
// choose to preserve existing data on the disk, create volume from an existing
// snapshot, or create an empty volume. If you choose to create an empty gateway
// volume, then any existing data on the disk is erased.
//
// In the request you must specify the gateway and the disk information on
// which you are creating the volume. In response, AWS Storage Gateway creates
// the volume and returns volume information such as the volume Amazon Resource
// Name (ARN), its size, and the iSCSI target ARN that initiators can use to
// connect to the volume target.
func (c *StorageGateway) CreateStorediSCSIVolume(input *CreateStorediSCSIVolumeInput) (*CreateStorediSCSIVolumeOutput, error) {
req, out := c.CreateStorediSCSIVolumeRequest(input)
err := req.Send()
return out, err
}
const opCreateTapeWithBarcode = "CreateTapeWithBarcode"
// CreateTapeWithBarcodeRequest generates a request for the CreateTapeWithBarcode operation.
func (c *StorageGateway) CreateTapeWithBarcodeRequest(input *CreateTapeWithBarcodeInput) (req *request.Request, output *CreateTapeWithBarcodeOutput) {
op := &request.Operation{
Name: opCreateTapeWithBarcode,
HTTPMethod: "POST",
HTTPPath: "/",
}
if input == nil {
input = &CreateTapeWithBarcodeInput{}
}
req = c.newRequest(op, input, output)
output = &CreateTapeWithBarcodeOutput{}
req.Data = output
return
}
// Creates a virtual tape by using your own barcode. You write data to the virtual
// tape and then archive the tape.
//
// Cache storage must be allocated to the gateway before you can create a virtual
// tape. Use the AddCache operation to add cache storage to a gateway.
func (c *StorageGateway) CreateTapeWithBarcode(input *CreateTapeWithBarcodeInput) (*CreateTapeWithBarcodeOutput, error) {
req, out := c.CreateTapeWithBarcodeRequest(input)
err := req.Send()
return out, err
}
const opCreateTapes = "CreateTapes"
// CreateTapesRequest generates a request for the CreateTapes operation.
func (c *StorageGateway) CreateTapesRequest(input *CreateTapesInput) (req *request.Request, output *CreateTapesOutput) {
op := &request.Operation{
Name: opCreateTapes,
HTTPMethod: "POST",
HTTPPath: "/",
}
if input == nil {
input = &CreateTapesInput{}
}
req = c.newRequest(op, input, output)
output = &CreateTapesOutput{}
req.Data = output
return
}
// Creates one or more virtual tapes. You write data to the virtual tapes and
// then archive the tapes.
//
// Cache storage must be allocated to the gateway before you can create virtual
// tapes. Use the AddCache operation to add cache storage to a gateway.
func (c *StorageGateway) CreateTapes(input *CreateTapesInput) (*CreateTapesOutput, error) {
req, out := c.CreateTapesRequest(input)
err := req.Send()
return out, err
}
const opDeleteBandwidthRateLimit = "DeleteBandwidthRateLimit"
// DeleteBandwidthRateLimitRequest generates a request for the DeleteBandwidthRateLimit operation.
func (c *StorageGateway) DeleteBandwidthRateLimitRequest(input *DeleteBandwidthRateLimitInput) (req *request.Request, output *DeleteBandwidthRateLimitOutput) {
op := &request.Operation{
Name: opDeleteBandwidthRateLimit,
HTTPMethod: "POST",
HTTPPath: "/",
}
if input == nil {
input = &DeleteBandwidthRateLimitInput{}
}
req = c.newRequest(op, input, output)
output = &DeleteBandwidthRateLimitOutput{}
req.Data = output
return
}
// Deletes the bandwidth rate limits of a gateway. You can delete either the
// upload and download bandwidth rate limit, or you can delete both. If you
// delete only one of the limits, the other limit remains unchanged. To specify
// which gateway to work with, use the Amazon Resource Name (ARN) of the gateway
// in your request.
func (c *StorageGateway) DeleteBandwidthRateLimit(input *DeleteBandwidthRateLimitInput) (*DeleteBandwidthRateLimitOutput, error) {
req, out := c.DeleteBandwidthRateLimitRequest(input)
err := req.Send()
return out, err
}
const opDeleteChapCredentials = "DeleteChapCredentials"
// DeleteChapCredentialsRequest generates a request for the DeleteChapCredentials operation.
func (c *StorageGateway) DeleteChapCredentialsRequest(input *DeleteChapCredentialsInput) (req *request.Request, output *DeleteChapCredentialsOutput) {
op := &request.Operation{
Name: opDeleteChapCredentials,
HTTPMethod: "POST",
HTTPPath: "/",
}
if input == nil {
input = &DeleteChapCredentialsInput{}
}
req = c.newRequest(op, input, output)
output = &DeleteChapCredentialsOutput{}
req.Data = output
return
}
// Deletes Challenge-Handshake Authentication Protocol (CHAP) credentials for
// a specified iSCSI target and initiator pair.
func (c *StorageGateway) DeleteChapCredentials(input *DeleteChapCredentialsInput) (*DeleteChapCredentialsOutput, error) {
req, out := c.DeleteChapCredentialsRequest(input)
err := req.Send()
return out, err
}
const opDeleteGateway = "DeleteGateway"
// DeleteGatewayRequest generates a request for the DeleteGateway operation.
func (c *StorageGateway) DeleteGatewayRequest(input *DeleteGatewayInput) (req *request.Request, output *DeleteGatewayOutput) {
op := &request.Operation{
Name: opDeleteGateway,
HTTPMethod: "POST",
HTTPPath: "/",
}
if input == nil {
input = &DeleteGatewayInput{}
}
req = c.newRequest(op, input, output)
output = &DeleteGatewayOutput{}
req.Data = output
return
}
// Deletes a gateway. To specify which gateway to delete, use the Amazon Resource
// Name (ARN) of the gateway in your request. The operation deletes the gateway;
// however, it does not delete the gateway virtual machine (VM) from your host
// computer.
//
// After you delete a gateway, you cannot reactivate it. Completed snapshots
// of the gateway volumes are not deleted upon deleting the gateway, however,
// pending snapshots will not complete. After you delete a gateway, your next
// step is to remove it from your environment.
//
// You no longer pay software charges after the gateway is deleted; however,
// your existing Amazon EBS snapshots persist and you will continue to be billed
// for these snapshots. You can choose to remove all remaining Amazon EBS snapshots
// by canceling your Amazon EC2 subscription. If you prefer not to cancel your
// Amazon EC2 subscription, you can delete your snapshots using the Amazon EC2
// console. For more information, see the AWS Storage Gateway Detail Page (http://aws.amazon.com/storagegateway).
func (c *StorageGateway) DeleteGateway(input *DeleteGatewayInput) (*DeleteGatewayOutput, error) {
req, out := c.DeleteGatewayRequest(input)
err := req.Send()
return out, err
}
const opDeleteSnapshotSchedule = "DeleteSnapshotSchedule"
// DeleteSnapshotScheduleRequest generates a request for the DeleteSnapshotSchedule operation.
func (c *StorageGateway) DeleteSnapshotScheduleRequest(input *DeleteSnapshotScheduleInput) (req *request.Request, output *DeleteSnapshotScheduleOutput) {
op := &request.Operation{
Name: opDeleteSnapshotSchedule,
HTTPMethod: "POST",
HTTPPath: "/",
}
if input == nil {
input = &DeleteSnapshotScheduleInput{}
}
req = c.newRequest(op, input, output)
output = &DeleteSnapshotScheduleOutput{}
req.Data = output
return
}
// Deletes a snapshot of a volume.
//
// You can take snapshots of your gateway volumes on a scheduled or ad hoc
// basis. This API action enables you to delete a snapshot schedule for a volume.
// For more information, see Working with Snapshots (http://docs.aws.amazon.com/storagegateway/latest/userguide/WorkingWithSnapshots.html).
// In the DeleteSnapshotSchedule request, you identify the volume by providing
// its Amazon Resource Name (ARN).
//
// To list or delete a snapshot, you must use the Amazon EC2 API. in Amazon
// Elastic Compute Cloud API Reference.
func (c *StorageGateway) DeleteSnapshotSchedule(input *DeleteSnapshotScheduleInput) (*DeleteSnapshotScheduleOutput, error) {
req, out := c.DeleteSnapshotScheduleRequest(input)
err := req.Send()
return out, err
}
const opDeleteTape = "DeleteTape"
// DeleteTapeRequest generates a request for the DeleteTape operation.
func (c *StorageGateway) DeleteTapeRequest(input *DeleteTapeInput) (req *request.Request, output *DeleteTapeOutput) {
op := &request.Operation{
Name: opDeleteTape,
HTTPMethod: "POST",
HTTPPath: "/",
}
if input == nil {
input = &DeleteTapeInput{}
}
req = c.newRequest(op, input, output)
output = &DeleteTapeOutput{}
req.Data = output
return
}
// Deletes the specified virtual tape.
func (c *StorageGateway) DeleteTape(input *DeleteTapeInput) (*DeleteTapeOutput, error) {
req, out := c.DeleteTapeRequest(input)
err := req.Send()
return out, err
}
const opDeleteTapeArchive = "DeleteTapeArchive"
// DeleteTapeArchiveRequest generates a request for the DeleteTapeArchive operation.
func (c *StorageGateway) DeleteTapeArchiveRequest(input *DeleteTapeArchiveInput) (req *request.Request, output *DeleteTapeArchiveOutput) {
op := &request.Operation{
Name: opDeleteTapeArchive,
HTTPMethod: "POST",
HTTPPath: "/",
}
if input == nil {
input = &DeleteTapeArchiveInput{}
}
req = c.newRequest(op, input, output)
output = &DeleteTapeArchiveOutput{}
req.Data = output
return
}
// Deletes the specified virtual tape from the virtual tape shelf (VTS).
func (c *StorageGateway) DeleteTapeArchive(input *DeleteTapeArchiveInput) (*DeleteTapeArchiveOutput, error) {
req, out := c.DeleteTapeArchiveRequest(input)
err := req.Send()
return out, err
}
const opDeleteVolume = "DeleteVolume"
// DeleteVolumeRequest generates a request for the DeleteVolume operation.
func (c *StorageGateway) DeleteVolumeRequest(input *DeleteVolumeInput) (req *request.Request, output *DeleteVolumeOutput) {
op := &request.Operation{
Name: opDeleteVolume,
HTTPMethod: "POST",
HTTPPath: "/",
}
if input == nil {
input = &DeleteVolumeInput{}
}
req = c.newRequest(op, input, output)
output = &DeleteVolumeOutput{}
req.Data = output
return
}
// Deletes the specified gateway volume that you previously created using the
// CreateCachediSCSIVolume or CreateStorediSCSIVolume API. For gateway-stored
// volumes, the local disk that was configured as the storage volume is not
// deleted. You can reuse the local disk to create another storage volume.
//
// Before you delete a gateway volume, make sure there are no iSCSI connections
// to the volume you are deleting. You should also make sure there is no snapshot
// in progress. You can use the Amazon Elastic Compute Cloud (Amazon EC2) API
// to query snapshots on the volume you are deleting and check the snapshot
// status. For more information, go to DescribeSnapshots (http://docs.aws.amazon.com/AWSEC2/latest/APIReference/ApiReference-query-DescribeSnapshots.html)
// in the Amazon Elastic Compute Cloud API Reference.
//
// In the request, you must provide the Amazon Resource Name (ARN) of the storage
// volume you want to delete.
func (c *StorageGateway) DeleteVolume(input *DeleteVolumeInput) (*DeleteVolumeOutput, error) {
req, out := c.DeleteVolumeRequest(input)
err := req.Send()
return out, err
}
const opDescribeBandwidthRateLimit = "DescribeBandwidthRateLimit"
// DescribeBandwidthRateLimitRequest generates a request for the DescribeBandwidthRateLimit operation.
func (c *StorageGateway) DescribeBandwidthRateLimitRequest(input *DescribeBandwidthRateLimitInput) (req *request.Request, output *DescribeBandwidthRateLimitOutput) {
op := &request.Operation{
Name: opDescribeBandwidthRateLimit,
HTTPMethod: "POST",
HTTPPath: "/",
}
if input == nil {
input = &DescribeBandwidthRateLimitInput{}
}
req = c.newRequest(op, input, output)
output = &DescribeBandwidthRateLimitOutput{}
req.Data = output
return
}
// Returns the bandwidth rate limits of a gateway. By default, these limits
// are not set, which means no bandwidth rate limiting is in effect.
//
// This operation only returns a value for a bandwidth rate limit only if the
// limit is set. If no limits are set for the gateway, then this operation returns
// only the gateway ARN in the response body. To specify which gateway to describe,
// use the Amazon Resource Name (ARN) of the gateway in your request.
func (c *StorageGateway) DescribeBandwidthRateLimit(input *DescribeBandwidthRateLimitInput) (*DescribeBandwidthRateLimitOutput, error) {
req, out := c.DescribeBandwidthRateLimitRequest(input)
err := req.Send()
return out, err
}
const opDescribeCache = "DescribeCache"
// DescribeCacheRequest generates a request for the DescribeCache operation.
func (c *StorageGateway) DescribeCacheRequest(input *DescribeCacheInput) (req *request.Request, output *DescribeCacheOutput) {
op := &request.Operation{
Name: opDescribeCache,
HTTPMethod: "POST",
HTTPPath: "/",
}
if input == nil {
input = &DescribeCacheInput{}
}
req = c.newRequest(op, input, output)
output = &DescribeCacheOutput{}
req.Data = output
return
}
// Returns information about the cache of a gateway. This operation is supported
// only for the gateway-cached volume architecture.
//
// The response includes disk IDs that are configured as cache, and it includes
// the amount of cache allocated and used.
func (c *StorageGateway) DescribeCache(input *DescribeCacheInput) (*DescribeCacheOutput, error) {
req, out := c.DescribeCacheRequest(input)
err := req.Send()
return out, err
}
const opDescribeCachediSCSIVolumes = "DescribeCachediSCSIVolumes"
// DescribeCachediSCSIVolumesRequest generates a request for the DescribeCachediSCSIVolumes operation.
func (c *StorageGateway) DescribeCachediSCSIVolumesRequest(input *DescribeCachediSCSIVolumesInput) (req *request.Request, output *DescribeCachediSCSIVolumesOutput) {
op := &request.Operation{
Name: opDescribeCachediSCSIVolumes,
HTTPMethod: "POST",
HTTPPath: "/",
}
if input == nil {
input = &DescribeCachediSCSIVolumesInput{}
}
req = c.newRequest(op, input, output)
output = &DescribeCachediSCSIVolumesOutput{}
req.Data = output
return
}
// Returns a description of the gateway volumes specified in the request. This
// operation is supported only for the gateway-cached volume architecture.
//
// The list of gateway volumes in the request must be from one gateway. In
// the response Amazon Storage Gateway returns volume information sorted by
// volume Amazon Resource Name (ARN).
func (c *StorageGateway) DescribeCachediSCSIVolumes(input *DescribeCachediSCSIVolumesInput) (*DescribeCachediSCSIVolumesOutput, error) {
req, out := c.DescribeCachediSCSIVolumesRequest(input)
err := req.Send()
return out, err
}
const opDescribeChapCredentials = "DescribeChapCredentials"
// DescribeChapCredentialsRequest generates a request for the DescribeChapCredentials operation.
func (c *StorageGateway) DescribeChapCredentialsRequest(input *DescribeChapCredentialsInput) (req *request.Request, output *DescribeChapCredentialsOutput) {
op := &request.Operation{
Name: opDescribeChapCredentials,
HTTPMethod: "POST",
HTTPPath: "/",
}
if input == nil {
input = &DescribeChapCredentialsInput{}
}
req = c.newRequest(op, input, output)
output = &DescribeChapCredentialsOutput{}
req.Data = output
return
}
// Returns an array of Challenge-Handshake Authentication Protocol (CHAP) credentials
// information for a specified iSCSI target, one for each target-initiator pair.
func (c *StorageGateway) DescribeChapCredentials(input *DescribeChapCredentialsInput) (*DescribeChapCredentialsOutput, error) {
req, out := c.DescribeChapCredentialsRequest(input)
err := req.Send()
return out, err
}
const opDescribeGatewayInformation = "DescribeGatewayInformation"
// DescribeGatewayInformationRequest generates a request for the DescribeGatewayInformation operation.
func (c *StorageGateway) DescribeGatewayInformationRequest(input *DescribeGatewayInformationInput) (req *request.Request, output *DescribeGatewayInformationOutput) {
op := &request.Operation{
Name: opDescribeGatewayInformation,
HTTPMethod: "POST",
HTTPPath: "/",
}
if input == nil {
input = &DescribeGatewayInformationInput{}
}
req = c.newRequest(op, input, output)
output = &DescribeGatewayInformationOutput{}
req.Data = output
return
}
// Returns metadata about a gateway such as its name, network interfaces, configured
// time zone, and the state (whether the gateway is running or not). To specify
// which gateway to describe, use the Amazon Resource Name (ARN) of the gateway
// in your request.
func (c *StorageGateway) DescribeGatewayInformation(input *DescribeGatewayInformationInput) (*DescribeGatewayInformationOutput, error) {
req, out := c.DescribeGatewayInformationRequest(input)
err := req.Send()
return out, err
}
const opDescribeMaintenanceStartTime = "DescribeMaintenanceStartTime"
// DescribeMaintenanceStartTimeRequest generates a request for the DescribeMaintenanceStartTime operation.
func (c *StorageGateway) DescribeMaintenanceStartTimeRequest(input *DescribeMaintenanceStartTimeInput) (req *request.Request, output *DescribeMaintenanceStartTimeOutput) {
op := &request.Operation{
Name: opDescribeMaintenanceStartTime,
HTTPMethod: "POST",
HTTPPath: "/",
}
if input == nil {
input = &DescribeMaintenanceStartTimeInput{}
}
req = c.newRequest(op, input, output)
output = &DescribeMaintenanceStartTimeOutput{}
req.Data = output
return
}
// Returns your gateway's weekly maintenance start time including the day and
// time of the week. Note that values are in terms of the gateway's time zone.
func (c *StorageGateway) DescribeMaintenanceStartTime(input *DescribeMaintenanceStartTimeInput) (*DescribeMaintenanceStartTimeOutput, error) {
req, out := c.DescribeMaintenanceStartTimeRequest(input)
err := req.Send()
return out, err
}
const opDescribeSnapshotSchedule = "DescribeSnapshotSchedule"
// DescribeSnapshotScheduleRequest generates a request for the DescribeSnapshotSchedule operation.
func (c *StorageGateway) DescribeSnapshotScheduleRequest(input *DescribeSnapshotScheduleInput) (req *request.Request, output *DescribeSnapshotScheduleOutput) {
op := &request.Operation{
Name: opDescribeSnapshotSchedule,
HTTPMethod: "POST",
HTTPPath: "/",
}
if input == nil {
input = &DescribeSnapshotScheduleInput{}
}
req = c.newRequest(op, input, output)
output = &DescribeSnapshotScheduleOutput{}
req.Data = output
return
}
// Describes the snapshot schedule for the specified gateway volume. The snapshot
// schedule information includes intervals at which snapshots are automatically
// initiated on the volume.
func (c *StorageGateway) DescribeSnapshotSchedule(input *DescribeSnapshotScheduleInput) (*DescribeSnapshotScheduleOutput, error) {
req, out := c.DescribeSnapshotScheduleRequest(input)
err := req.Send()
return out, err
}
const opDescribeStorediSCSIVolumes = "DescribeStorediSCSIVolumes"
// DescribeStorediSCSIVolumesRequest generates a request for the DescribeStorediSCSIVolumes operation.
func (c *StorageGateway) DescribeStorediSCSIVolumesRequest(input *DescribeStorediSCSIVolumesInput) (req *request.Request, output *DescribeStorediSCSIVolumesOutput) {
op := &request.Operation{
Name: opDescribeStorediSCSIVolumes,
HTTPMethod: "POST",
HTTPPath: "/",
}
if input == nil {
input = &DescribeStorediSCSIVolumesInput{}
}
req = c.newRequest(op, input, output)
output = &DescribeStorediSCSIVolumesOutput{}
req.Data = output
return
}
// Returns the description of the gateway volumes specified in the request.
// The list of gateway volumes in the request must be from one gateway. In the
// response Amazon Storage Gateway returns volume information sorted by volume
// ARNs.
func (c *StorageGateway) DescribeStorediSCSIVolumes(input *DescribeStorediSCSIVolumesInput) (*DescribeStorediSCSIVolumesOutput, error) {
req, out := c.DescribeStorediSCSIVolumesRequest(input)
err := req.Send()
return out, err
}
const opDescribeTapeArchives = "DescribeTapeArchives"
// DescribeTapeArchivesRequest generates a request for the DescribeTapeArchives operation.
func (c *StorageGateway) DescribeTapeArchivesRequest(input *DescribeTapeArchivesInput) (req *request.Request, output *DescribeTapeArchivesOutput) {
op := &request.Operation{
Name: opDescribeTapeArchives,
HTTPMethod: "POST",
HTTPPath: "/",
Paginator: &request.Paginator{
InputTokens: []string{"Marker"},
OutputTokens: []string{"Marker"},
LimitToken: "Limit",
TruncationToken: "",
},
}
if input == nil {
input = &DescribeTapeArchivesInput{}
}
req = c.newRequest(op, input, output)
output = &DescribeTapeArchivesOutput{}
req.Data = output
return
}
// Returns a description of specified virtual tapes in the virtual tape shelf
// (VTS).
//
// If a specific TapeARN is not specified, AWS Storage Gateway returns a description
// of all virtual tapes found in the VTS associated with your account.
func (c *StorageGateway) DescribeTapeArchives(input *DescribeTapeArchivesInput) (*DescribeTapeArchivesOutput, error) {
req, out := c.DescribeTapeArchivesRequest(input)
err := req.Send()
return out, err
}
func (c *StorageGateway) DescribeTapeArchivesPages(input *DescribeTapeArchivesInput, fn func(p *DescribeTapeArchivesOutput, lastPage bool) (shouldContinue bool)) error {
page, _ := c.DescribeTapeArchivesRequest(input)
page.Handlers.Build.PushBack(request.MakeAddToUserAgentFreeFormHandler("Paginator"))
return page.EachPage(func(p interface{}, lastPage bool) bool {
return fn(p.(*DescribeTapeArchivesOutput), lastPage)
})
}
const opDescribeTapeRecoveryPoints = "DescribeTapeRecoveryPoints"