aws-sdk-ebs 1.4.0 → 1.9.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: '0409f53a6aee215d8b93786bd4cb550b35746632b39fbf30db2a94518aeba819'
4
- data.tar.gz: 9ca32894ab8e35c2fc39ea65a16f4f2240346a005f1de1db1c4e03991fa860a4
3
+ metadata.gz: ddba9a0efe683f000f117556552564b9fe383fbb5f47094bafda97aeded53b38
4
+ data.tar.gz: 350c2159ee3fe84554f374dc658b44d12bd3b17e94e50b67bcb03ba525c6f798
5
5
  SHA512:
6
- metadata.gz: 7bf80eaa9ab0178601b11de4a315a341f93de27e8d13abd8a63a2d633c61958411050f02c31481f435320cfc490f5b188368bbce11051fcefcbf9bcdf69f4dbc
7
- data.tar.gz: 42bf23a56719af77b94b7e9aaecfe70299a683273d0006bc17ae1fd777e8eb960dfa931f022191385377b03622bd4d53047ec4eccfd8c54fbcf8b16ce261e549
6
+ metadata.gz: 445c0c17cf2c729af53e4a4611d409313ece7c3435683d42f4edc2c20eae148daa1841670494be071ed33f14b7a54e7b6c2edf24d77a4c2fef9af0392bb912d6
7
+ data.tar.gz: c9e579ab4d01cd49bc5804356094300dc32d4b58627c7a6ddeaa05193502100ac36eb51df743c3a2e22ca2ea72620d3b7212e5ec5171f081267acc0cf71723d3
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  # WARNING ABOUT GENERATED CODE
2
4
  #
3
5
  # This file is generated. See the contributing guide for more information:
@@ -25,7 +27,7 @@ require_relative 'aws-sdk-ebs/customizations'
25
27
  # structure.
26
28
  #
27
29
  # ebs = Aws::EBS::Client.new
28
- # resp = ebs.get_snapshot_block(params)
30
+ # resp = ebs.complete_snapshot(params)
29
31
  #
30
32
  # See {Client} for more information.
31
33
  #
@@ -42,9 +44,9 @@ require_relative 'aws-sdk-ebs/customizations'
42
44
  #
43
45
  # See {Errors} for more information.
44
46
  #
45
- # @service
47
+ # @!group service
46
48
  module Aws::EBS
47
49
 
48
- GEM_VERSION = '1.4.0'
50
+ GEM_VERSION = '1.9.0'
49
51
 
50
52
  end
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  # WARNING ABOUT GENERATED CODE
2
4
  #
3
5
  # This file is generated. See the contributing guide for more information:
@@ -24,6 +26,7 @@ require 'aws-sdk-core/plugins/jsonvalue_converter.rb'
24
26
  require 'aws-sdk-core/plugins/client_metrics_plugin.rb'
25
27
  require 'aws-sdk-core/plugins/client_metrics_send_plugin.rb'
26
28
  require 'aws-sdk-core/plugins/transfer_encoding.rb'
29
+ require 'aws-sdk-core/plugins/http_checksum.rb'
27
30
  require 'aws-sdk-core/plugins/signature_v4.rb'
28
31
  require 'aws-sdk-core/plugins/protocols/rest_json.rb'
29
32
 
@@ -69,6 +72,7 @@ module Aws::EBS
69
72
  add_plugin(Aws::Plugins::ClientMetricsPlugin)
70
73
  add_plugin(Aws::Plugins::ClientMetricsSendPlugin)
71
74
  add_plugin(Aws::Plugins::TransferEncoding)
75
+ add_plugin(Aws::Plugins::HttpChecksum)
72
76
  add_plugin(Aws::Plugins::SignatureV4)
73
77
  add_plugin(Aws::Plugins::Protocols::RestJson)
74
78
 
@@ -81,13 +85,28 @@ module Aws::EBS
81
85
  # * `Aws::Credentials` - Used for configuring static, non-refreshing
82
86
  # credentials.
83
87
  #
88
+ # * `Aws::SharedCredentials` - Used for loading static credentials from a
89
+ # shared file, such as `~/.aws/config`.
90
+ #
91
+ # * `Aws::AssumeRoleCredentials` - Used when you need to assume a role.
92
+ #
93
+ # * `Aws::AssumeRoleWebIdentityCredentials` - Used when you need to
94
+ # assume a role after providing credentials via the web.
95
+ #
96
+ # * `Aws::SSOCredentials` - Used for loading credentials from AWS SSO using an
97
+ # access token generated from `aws login`.
98
+ #
99
+ # * `Aws::ProcessCredentials` - Used for loading credentials from a
100
+ # process that outputs to stdout.
101
+ #
84
102
  # * `Aws::InstanceProfileCredentials` - Used for loading credentials
85
103
  # from an EC2 IMDS on an EC2 instance.
86
104
  #
87
- # * `Aws::SharedCredentials` - Used for loading credentials from a
88
- # shared file, such as `~/.aws/config`.
105
+ # * `Aws::ECSCredentials` - Used for loading credentials from
106
+ # instances running in ECS.
89
107
  #
90
- # * `Aws::AssumeRoleCredentials` - Used when you need to assume a role.
108
+ # * `Aws::CognitoIdentityCredentials` - Used for loading credentials
109
+ # from the Cognito Identity service.
91
110
  #
92
111
  # When `:credentials` are not configured directly, the following
93
112
  # locations will be searched for credentials:
@@ -97,10 +116,10 @@ module Aws::EBS
97
116
  # * ENV['AWS_ACCESS_KEY_ID'], ENV['AWS_SECRET_ACCESS_KEY']
98
117
  # * `~/.aws/credentials`
99
118
  # * `~/.aws/config`
100
- # * EC2 IMDS instance profile - When used by default, the timeouts are
101
- # very aggressive. Construct and pass an instance of
102
- # `Aws::InstanceProfileCredentails` to enable retries and extended
103
- # timeouts.
119
+ # * EC2/ECS IMDS instance profile - When used by default, the timeouts
120
+ # are very aggressive. Construct and pass an instance of
121
+ # `Aws::InstanceProfileCredentails` or `Aws::ECSCredentials` to
122
+ # enable retries and extended timeouts.
104
123
  #
105
124
  # @option options [required, String] :region
106
125
  # The AWS region to connect to. The configured `:region` is
@@ -161,7 +180,7 @@ module Aws::EBS
161
180
  # @option options [String] :endpoint
162
181
  # The client endpoint is normally constructed from the `:region`
163
182
  # option. You should only configure an `:endpoint` when connecting
164
- # to test endpoints. This should be a valid HTTP(S) URI.
183
+ # to test or custom endpoints. This should be a valid HTTP(S) URI.
165
184
  #
166
185
  # @option options [Integer] :endpoint_cache_max_entries (1000)
167
186
  # Used for the maximum size limit of the LRU cache storing endpoints data
@@ -308,6 +327,62 @@ module Aws::EBS
308
327
 
309
328
  # @!group API Operations
310
329
 
330
+ # Seals and completes the snapshot after all of the required blocks of
331
+ # data have been written to it. Completing the snapshot changes the
332
+ # status to `completed`. You cannot write new blocks to a snapshot after
333
+ # it has been completed.
334
+ #
335
+ # @option params [required, String] :snapshot_id
336
+ # The ID of the snapshot.
337
+ #
338
+ # @option params [required, Integer] :changed_blocks_count
339
+ # The number of blocks that were written to the snapshot.
340
+ #
341
+ # @option params [String] :checksum
342
+ # An aggregated Base-64 SHA256 checksum based on the checksums of each
343
+ # written block.
344
+ #
345
+ # To generate the aggregated checksum using the linear aggregation
346
+ # method, arrange the checksums for each written block in ascending
347
+ # order of their block index, concatenate them to form a single string,
348
+ # and then generate the checksum on the entire string using the SHA256
349
+ # algorithm.
350
+ #
351
+ # @option params [String] :checksum_algorithm
352
+ # The algorithm used to generate the checksum. Currently, the only
353
+ # supported algorithm is `SHA256`.
354
+ #
355
+ # @option params [String] :checksum_aggregation_method
356
+ # The aggregation method used to generate the checksum. Currently, the
357
+ # only supported aggregation method is `LINEAR`.
358
+ #
359
+ # @return [Types::CompleteSnapshotResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
360
+ #
361
+ # * {Types::CompleteSnapshotResponse#status #status} => String
362
+ #
363
+ # @example Request syntax with placeholder values
364
+ #
365
+ # resp = client.complete_snapshot({
366
+ # snapshot_id: "SnapshotId", # required
367
+ # changed_blocks_count: 1, # required
368
+ # checksum: "Checksum",
369
+ # checksum_algorithm: "SHA256", # accepts SHA256
370
+ # checksum_aggregation_method: "LINEAR", # accepts LINEAR
371
+ # })
372
+ #
373
+ # @example Response structure
374
+ #
375
+ # resp.status #=> String, one of "completed", "pending", "error"
376
+ #
377
+ # @see http://docs.aws.amazon.com/goto/WebAPI/ebs-2019-11-02/CompleteSnapshot AWS API Documentation
378
+ #
379
+ # @overload complete_snapshot(params = {})
380
+ # @param [Hash] params ({})
381
+ def complete_snapshot(params = {}, options = {})
382
+ req = build_request(:complete_snapshot, params)
383
+ req.send_request(options)
384
+ end
385
+
311
386
  # Returns the data in a block in an Amazon Elastic Block Store snapshot.
312
387
  #
313
388
  # @option params [required, String] :snapshot_id
@@ -356,9 +431,9 @@ module Aws::EBS
356
431
  req.send_request(options, &block)
357
432
  end
358
433
 
359
- # Returns the block indexes and block tokens for blocks that are
360
- # different between two Amazon Elastic Block Store snapshots of the same
361
- # volume/snapshot lineage.
434
+ # Returns information about the blocks that are different between two
435
+ # Amazon Elastic Block Store snapshots of the same volume/snapshot
436
+ # lineage.
362
437
  #
363
438
  # @option params [String] :first_snapshot_id
364
439
  # The ID of the first snapshot to use for the comparison.
@@ -424,8 +499,8 @@ module Aws::EBS
424
499
  req.send_request(options)
425
500
  end
426
501
 
427
- # Returns the block indexes and block tokens for blocks in an Amazon
428
- # Elastic Block Store snapshot.
502
+ # Returns information about the blocks in an Amazon Elastic Block Store
503
+ # snapshot.
429
504
  #
430
505
  # @option params [required, String] :snapshot_id
431
506
  # The ID of the snapshot from which to get block indexes and block
@@ -480,6 +555,244 @@ module Aws::EBS
480
555
  req.send_request(options)
481
556
  end
482
557
 
558
+ # Writes a block of data to a snapshot. If the specified block contains
559
+ # data, the existing data is overwritten. The target snapshot must be in
560
+ # the `pending` state.
561
+ #
562
+ # Data written to a snapshot must be aligned with 512-byte sectors.
563
+ #
564
+ # @option params [required, String] :snapshot_id
565
+ # The ID of the snapshot.
566
+ #
567
+ # @option params [required, Integer] :block_index
568
+ # The block index of the block in which to write the data. A block index
569
+ # is a logical index in units of `512` KiB blocks. To identify the block
570
+ # index, divide the logical offset of the data in the logical volume by
571
+ # the block size (logical offset of data/`524288`). The logical offset
572
+ # of the data must be `512` KiB aligned.
573
+ #
574
+ # @option params [required, String, IO] :block_data
575
+ # The data to write to the block.
576
+ #
577
+ # The block data is not signed as part of the Signature Version 4
578
+ # signing process. As a result, you must generate and provide a
579
+ # Base64-encoded SHA256 checksum for the block data using the
580
+ # **x-amz-Checksum** header. Also, you must specify the checksum
581
+ # algorithm using the **x-amz-Checksum-Algorithm** header. The checksum
582
+ # that you provide is part of the Signature Version 4 signing process.
583
+ # It is validated against a checksum generated by Amazon EBS to ensure
584
+ # the validity and authenticity of the data. If the checksums do not
585
+ # correspond, the request fails. For more information, see [ Using
586
+ # checksums with the EBS direct APIs][1] in the *Amazon Elastic Compute
587
+ # Cloud User Guide*.
588
+ #
589
+ #
590
+ #
591
+ # [1]: https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ebs-accessing-snapshot.html#ebsapis-using-checksums
592
+ #
593
+ # @option params [required, Integer] :data_length
594
+ # The size of the data to write to the block, in bytes. Currently, the
595
+ # only supported size is `524288`.
596
+ #
597
+ # Valid values: `524288`
598
+ #
599
+ # @option params [Integer] :progress
600
+ # The progress of the write process, as a percentage.
601
+ #
602
+ # @option params [required, String] :checksum
603
+ # A Base64-encoded SHA256 checksum of the data. Only SHA256 checksums
604
+ # are supported.
605
+ #
606
+ # @option params [required, String] :checksum_algorithm
607
+ # The algorithm used to generate the checksum. Currently, the only
608
+ # supported algorithm is `SHA256`.
609
+ #
610
+ # @return [Types::PutSnapshotBlockResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
611
+ #
612
+ # * {Types::PutSnapshotBlockResponse#checksum #checksum} => String
613
+ # * {Types::PutSnapshotBlockResponse#checksum_algorithm #checksum_algorithm} => String
614
+ #
615
+ # @example Request syntax with placeholder values
616
+ #
617
+ # resp = client.put_snapshot_block({
618
+ # snapshot_id: "SnapshotId", # required
619
+ # block_index: 1, # required
620
+ # block_data: "data", # required
621
+ # data_length: 1, # required
622
+ # progress: 1,
623
+ # checksum: "Checksum", # required
624
+ # checksum_algorithm: "SHA256", # required, accepts SHA256
625
+ # })
626
+ #
627
+ # @example Response structure
628
+ #
629
+ # resp.checksum #=> String
630
+ # resp.checksum_algorithm #=> String, one of "SHA256"
631
+ #
632
+ # @see http://docs.aws.amazon.com/goto/WebAPI/ebs-2019-11-02/PutSnapshotBlock AWS API Documentation
633
+ #
634
+ # @overload put_snapshot_block(params = {})
635
+ # @param [Hash] params ({})
636
+ def put_snapshot_block(params = {}, options = {})
637
+ req = build_request(:put_snapshot_block, params)
638
+ req.send_request(options)
639
+ end
640
+
641
+ # Creates a new Amazon EBS snapshot. The new snapshot enters the
642
+ # `pending` state after the request completes.
643
+ #
644
+ # After creating the snapshot, use [ PutSnapshotBlock][1] to write
645
+ # blocks of data to the snapshot.
646
+ #
647
+ #
648
+ #
649
+ # [1]: https://docs.aws.amazon.com/ebs/latest/APIReference/API_PutSnapshotBlock.html
650
+ #
651
+ # @option params [required, Integer] :volume_size
652
+ # The size of the volume, in GiB. The maximum size is `16384` GiB (16
653
+ # TiB).
654
+ #
655
+ # @option params [String] :parent_snapshot_id
656
+ # The ID of the parent snapshot. If there is no parent snapshot, or if
657
+ # you are creating the first snapshot for an on-premises volume, omit
658
+ # this parameter.
659
+ #
660
+ # If your account is enabled for encryption by default, you cannot use
661
+ # an unencrypted snapshot as a parent snapshot. You must first create an
662
+ # encrypted copy of the parent snapshot using [CopySnapshot][1].
663
+ #
664
+ #
665
+ #
666
+ # [1]: https://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_CopySnapshot.html
667
+ #
668
+ # @option params [Array<Types::Tag>] :tags
669
+ # The tags to apply to the snapshot.
670
+ #
671
+ # @option params [String] :description
672
+ # A description for the snapshot.
673
+ #
674
+ # @option params [String] :client_token
675
+ # A unique, case-sensitive identifier that you provide to ensure the
676
+ # idempotency of the request. Idempotency ensures that an API request
677
+ # completes only once. With an idempotent request, if the original
678
+ # request completes successfully. The subsequent retries with the same
679
+ # client token return the result from the original successful request
680
+ # and they have no additional effect.
681
+ #
682
+ # If you do not specify a client token, one is automatically generated
683
+ # by the AWS SDK.
684
+ #
685
+ # For more information, see [ Idempotency for StartSnapshot API][1] in
686
+ # the *Amazon Elastic Compute Cloud User Guide*.
687
+ #
688
+ # **A suitable default value is auto-generated.** You should normally
689
+ # not need to pass this option.**
690
+ #
691
+ #
692
+ #
693
+ # [1]: https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ebs-direct-api-idempotency.html
694
+ #
695
+ # @option params [Boolean] :encrypted
696
+ # Indicates whether to encrypt the snapshot. To create an encrypted
697
+ # snapshot, specify `true`. To create an unencrypted snapshot, omit this
698
+ # parameter.
699
+ #
700
+ # If you specify a value for **ParentSnapshotId**, omit this parameter.
701
+ #
702
+ # If you specify `true`, the snapshot is encrypted using the CMK
703
+ # specified using the **KmsKeyArn** parameter. If no value is specified
704
+ # for **KmsKeyArn**, the default CMK for your account is used. If no
705
+ # default CMK has been specified for your account, the AWS managed CMK
706
+ # is used. To set a default CMK for your account, use [
707
+ # ModifyEbsDefaultKmsKeyId][1].
708
+ #
709
+ # If your account is enabled for encryption by default, you cannot set
710
+ # this parameter to `false`. In this case, you can omit this parameter.
711
+ #
712
+ # For more information, see [ Using encryption][2] in the *Amazon
713
+ # Elastic Compute Cloud User Guide*.
714
+ #
715
+ #
716
+ #
717
+ # [1]: https://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_ModifyEbsDefaultKmsKeyId.html
718
+ # [2]: https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ebs-accessing-snapshot.html#ebsapis-using-encryption
719
+ #
720
+ # @option params [String] :kms_key_arn
721
+ # The Amazon Resource Name (ARN) of the AWS Key Management Service (AWS
722
+ # KMS) customer master key (CMK) to be used to encrypt the snapshot. If
723
+ # you do not specify a CMK, the default AWS managed CMK is used.
724
+ #
725
+ # If you specify a **ParentSnapshotId**, omit this parameter; the
726
+ # snapshot will be encrypted using the same CMK that was used to encrypt
727
+ # the parent snapshot.
728
+ #
729
+ # If **Encrypted** is set to `true`, you must specify a CMK ARN.
730
+ #
731
+ # @option params [Integer] :timeout
732
+ # The amount of time (in minutes) after which the snapshot is
733
+ # automatically cancelled if:
734
+ #
735
+ # * No blocks are written to the snapshot.
736
+ #
737
+ # * The snapshot is not completed after writing the last block of data.
738
+ #
739
+ # If no value is specified, the timeout defaults to `60` minutes.
740
+ #
741
+ # @return [Types::StartSnapshotResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
742
+ #
743
+ # * {Types::StartSnapshotResponse#description #description} => String
744
+ # * {Types::StartSnapshotResponse#snapshot_id #snapshot_id} => String
745
+ # * {Types::StartSnapshotResponse#owner_id #owner_id} => String
746
+ # * {Types::StartSnapshotResponse#status #status} => String
747
+ # * {Types::StartSnapshotResponse#start_time #start_time} => Time
748
+ # * {Types::StartSnapshotResponse#volume_size #volume_size} => Integer
749
+ # * {Types::StartSnapshotResponse#block_size #block_size} => Integer
750
+ # * {Types::StartSnapshotResponse#tags #tags} => Array&lt;Types::Tag&gt;
751
+ # * {Types::StartSnapshotResponse#parent_snapshot_id #parent_snapshot_id} => String
752
+ # * {Types::StartSnapshotResponse#kms_key_arn #kms_key_arn} => String
753
+ #
754
+ # @example Request syntax with placeholder values
755
+ #
756
+ # resp = client.start_snapshot({
757
+ # volume_size: 1, # required
758
+ # parent_snapshot_id: "SnapshotId",
759
+ # tags: [
760
+ # {
761
+ # key: "TagKey",
762
+ # value: "TagValue",
763
+ # },
764
+ # ],
765
+ # description: "Description",
766
+ # client_token: "IdempotencyToken",
767
+ # encrypted: false,
768
+ # kms_key_arn: "KmsKeyArn",
769
+ # timeout: 1,
770
+ # })
771
+ #
772
+ # @example Response structure
773
+ #
774
+ # resp.description #=> String
775
+ # resp.snapshot_id #=> String
776
+ # resp.owner_id #=> String
777
+ # resp.status #=> String, one of "completed", "pending", "error"
778
+ # resp.start_time #=> Time
779
+ # resp.volume_size #=> Integer
780
+ # resp.block_size #=> Integer
781
+ # resp.tags #=> Array
782
+ # resp.tags[0].key #=> String
783
+ # resp.tags[0].value #=> String
784
+ # resp.parent_snapshot_id #=> String
785
+ # resp.kms_key_arn #=> String
786
+ #
787
+ # @see http://docs.aws.amazon.com/goto/WebAPI/ebs-2019-11-02/StartSnapshot AWS API Documentation
788
+ #
789
+ # @overload start_snapshot(params = {})
790
+ # @param [Hash] params ({})
791
+ def start_snapshot(params = {}, options = {})
792
+ req = build_request(:start_snapshot, params)
793
+ req.send_request(options)
794
+ end
795
+
483
796
  # @!endgroup
484
797
 
485
798
  # @param params ({})
@@ -493,7 +806,7 @@ module Aws::EBS
493
806
  params: params,
494
807
  config: config)
495
808
  context[:gem_name] = 'aws-sdk-ebs'
496
- context[:gem_version] = '1.4.0'
809
+ context[:gem_version] = '1.9.0'
497
810
  Seahorse::Client::Request.new(handlers, context)
498
811
  end
499
812