ebs

package module
v1.23.4 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 29, 2024 License: Apache-2.0 Imports: 41 Imported by: 6

Documentation

Overview

Package ebs provides the API client, operations, and parameter types for Amazon Elastic Block Store.

You can use the Amazon Elastic Block Store (Amazon EBS) direct APIs to create Amazon EBS snapshots, write data directly to your snapshots, read data on your snapshots, and identify the differences or changes between two snapshots. If you’re an independent software vendor (ISV) who offers backup services for Amazon EBS, the EBS direct APIs make it more efficient and cost-effective to track incremental changes on your Amazon EBS volumes through snapshots. This can be done without having to create new volumes from snapshots, and then use Amazon Elastic Compute Cloud (Amazon EC2) instances to compare the differences. You can create incremental snapshots directly from data on-premises into volumes and the cloud to use for quick disaster recovery. With the ability to write and read snapshots, you can write your on-premises data to an snapshot during a disaster. Then after recovery, you can restore it back to Amazon Web Services or on-premises from the snapshot. You no longer need to build and maintain complex mechanisms to copy data to and from Amazon EBS. This API reference provides detailed information about the actions, data types, parameters, and errors of the EBS direct APIs. For more information about the elements that make up the EBS direct APIs, and examples of how to use them effectively, see Accessing the Contents of an Amazon EBS Snapshot (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ebs-accessing-snapshot.html) in the Amazon Elastic Compute Cloud User Guide. For more information about the supported Amazon Web Services Regions, endpoints, and service quotas for the EBS direct APIs, see Amazon Elastic Block Store Endpoints and Quotas (https://docs.aws.amazon.com/general/latest/gr/ebs-service.html) in the Amazon Web Services General Reference.

Index

Constants

View Source
const ServiceAPIVersion = "2019-11-02"
View Source
const ServiceID = "EBS"

Variables

This section is empty.

Functions

func NewDefaultEndpointResolver

func NewDefaultEndpointResolver() *internalendpoints.Resolver

NewDefaultEndpointResolver constructs a new service endpoint resolver

func WithAPIOptions added in v1.0.0

func WithAPIOptions(optFns ...func(*middleware.Stack) error) func(*Options)

WithAPIOptions returns a functional option for setting the Client's APIOptions option.

func WithEndpointResolver deprecated

func WithEndpointResolver(v EndpointResolver) func(*Options)

Deprecated: EndpointResolver and WithEndpointResolver. Providing a value for this field will likely prevent you from using any endpoint-related service features released after the introduction of EndpointResolverV2 and BaseEndpoint. To migrate an EndpointResolver implementation that uses a custom endpoint, set the client option BaseEndpoint instead.

func WithEndpointResolverV2 added in v1.18.0

func WithEndpointResolverV2(v EndpointResolverV2) func(*Options)

WithEndpointResolverV2 returns a functional option for setting the Client's EndpointResolverV2 option.

func WithSigV4SigningName added in v1.20.2

func WithSigV4SigningName(name string) func(*Options)

WithSigV4SigningName applies an override to the authentication workflow to use the given signing name for SigV4-authenticated operations.

This is an advanced setting. The value here is FINAL, taking precedence over the resolved signing name from both auth scheme resolution and endpoint resolution.

func WithSigV4SigningRegion added in v1.20.2

func WithSigV4SigningRegion(region string) func(*Options)

WithSigV4SigningRegion applies an override to the authentication workflow to use the given signing region for SigV4-authenticated operations.

This is an advanced setting. The value here is FINAL, taking precedence over the resolved signing region from both auth scheme resolution and endpoint resolution.

Types

type AuthResolverParameters added in v1.20.2

type AuthResolverParameters struct {
	// The name of the operation being invoked.
	Operation string

	// The region in which the operation is being invoked.
	Region string
}

AuthResolverParameters contains the set of inputs necessary for auth scheme resolution.

type AuthSchemeResolver added in v1.20.2

type AuthSchemeResolver interface {
	ResolveAuthSchemes(context.Context, *AuthResolverParameters) ([]*smithyauth.Option, error)
}

AuthSchemeResolver returns a set of possible authentication options for an operation.

type Client

type Client struct {
	// contains filtered or unexported fields
}

Client provides the API client to make operations call for Amazon Elastic Block Store.

func New

func New(options Options, optFns ...func(*Options)) *Client

New returns an initialized Client based on the functional options. Provide additional functional options to further configure the behavior of the client, such as changing the client's endpoint or adding custom middleware behavior.

func NewFromConfig

func NewFromConfig(cfg aws.Config, optFns ...func(*Options)) *Client

NewFromConfig returns a new client from the provided config.

func (*Client) CompleteSnapshot

func (c *Client) CompleteSnapshot(ctx context.Context, params *CompleteSnapshotInput, optFns ...func(*Options)) (*CompleteSnapshotOutput, error)

Seals and completes the snapshot after all of the required blocks of data have been written to it. Completing the snapshot changes the status to completed . You cannot write new blocks to a snapshot after it has been completed. You should always retry requests that receive server ( 5xx ) error responses, and ThrottlingException and RequestThrottledException client error responses. For more information see Error retries (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/error-retries.html) in the Amazon Elastic Compute Cloud User Guide.

func (*Client) GetSnapshotBlock

func (c *Client) GetSnapshotBlock(ctx context.Context, params *GetSnapshotBlockInput, optFns ...func(*Options)) (*GetSnapshotBlockOutput, error)

Returns the data in a block in an Amazon Elastic Block Store snapshot. You should always retry requests that receive server ( 5xx ) error responses, and ThrottlingException and RequestThrottledException client error responses. For more information see Error retries (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/error-retries.html) in the Amazon Elastic Compute Cloud User Guide.

func (*Client) ListChangedBlocks

func (c *Client) ListChangedBlocks(ctx context.Context, params *ListChangedBlocksInput, optFns ...func(*Options)) (*ListChangedBlocksOutput, error)

Returns information about the blocks that are different between two Amazon Elastic Block Store snapshots of the same volume/snapshot lineage. You should always retry requests that receive server ( 5xx ) error responses, and ThrottlingException and RequestThrottledException client error responses. For more information see Error retries (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/error-retries.html) in the Amazon Elastic Compute Cloud User Guide.

func (*Client) ListSnapshotBlocks

func (c *Client) ListSnapshotBlocks(ctx context.Context, params *ListSnapshotBlocksInput, optFns ...func(*Options)) (*ListSnapshotBlocksOutput, error)

Returns information about the blocks in an Amazon Elastic Block Store snapshot. You should always retry requests that receive server ( 5xx ) error responses, and ThrottlingException and RequestThrottledException client error responses. For more information see Error retries (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/error-retries.html) in the Amazon Elastic Compute Cloud User Guide.

func (*Client) Options added in v1.21.0

func (c *Client) Options() Options

Options returns a copy of the client configuration.

Callers SHOULD NOT perform mutations on any inner structures within client config. Config overrides should instead be made on a per-operation basis through functional options.

func (*Client) PutSnapshotBlock

func (c *Client) PutSnapshotBlock(ctx context.Context, params *PutSnapshotBlockInput, optFns ...func(*Options)) (*PutSnapshotBlockOutput, error)

Writes a block of data to a snapshot. If the specified block contains data, the existing data is overwritten. The target snapshot must be in the pending state. Data written to a snapshot must be aligned with 512-KiB sectors. You should always retry requests that receive server ( 5xx ) error responses, and ThrottlingException and RequestThrottledException client error responses. For more information see Error retries (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/error-retries.html) in the Amazon Elastic Compute Cloud User Guide.

func (*Client) StartSnapshot

func (c *Client) StartSnapshot(ctx context.Context, params *StartSnapshotInput, optFns ...func(*Options)) (*StartSnapshotOutput, error)

Creates a new Amazon EBS snapshot. The new snapshot enters the pending state after the request completes. After creating the snapshot, use PutSnapshotBlock (https://docs.aws.amazon.com/ebs/latest/APIReference/API_PutSnapshotBlock.html) to write blocks of data to the snapshot. You should always retry requests that receive server ( 5xx ) error responses, and ThrottlingException and RequestThrottledException client error responses. For more information see Error retries (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/error-retries.html) in the Amazon Elastic Compute Cloud User Guide.

type CompleteSnapshotInput

type CompleteSnapshotInput struct {

	// The number of blocks that were written to the snapshot.
	//
	// This member is required.
	ChangedBlocksCount *int32

	// The ID of the snapshot.
	//
	// This member is required.
	SnapshotId *string

	// An aggregated Base-64 SHA256 checksum based on the checksums of each written
	// block. To generate the aggregated checksum using the linear aggregation method,
	// arrange the checksums for each written block in ascending order of their block
	// index, concatenate them to form a single string, and then generate the checksum
	// on the entire string using the SHA256 algorithm.
	Checksum *string

	// The aggregation method used to generate the checksum. Currently, the only
	// supported aggregation method is LINEAR .
	ChecksumAggregationMethod types.ChecksumAggregationMethod

	// The algorithm used to generate the checksum. Currently, the only supported
	// algorithm is SHA256 .
	ChecksumAlgorithm types.ChecksumAlgorithm
	// contains filtered or unexported fields
}

type CompleteSnapshotOutput

type CompleteSnapshotOutput struct {

	// The status of the snapshot.
	Status types.Status

	// Metadata pertaining to the operation's result.
	ResultMetadata middleware.Metadata
	// contains filtered or unexported fields
}

type EndpointParameters added in v1.18.0

type EndpointParameters struct {
	// The AWS region used to dispatch the request.
	//
	// Parameter is
	// required.
	//
	// AWS::Region
	Region *string

	// When true, use the dual-stack endpoint. If the configured endpoint does not
	// support dual-stack, dispatching the request MAY return an error.
	//
	// Defaults to
	// false if no value is provided.
	//
	// AWS::UseDualStack
	UseDualStack *bool

	// When true, send this request to the FIPS-compliant regional endpoint. If the
	// configured endpoint does not have a FIPS compliant endpoint, dispatching the
	// request will return an error.
	//
	// Defaults to false if no value is
	// provided.
	//
	// AWS::UseFIPS
	UseFIPS *bool

	// Override the endpoint used to send this request
	//
	// Parameter is
	// required.
	//
	// SDK::Endpoint
	Endpoint *string
}

EndpointParameters provides the parameters that influence how endpoints are resolved.

func (EndpointParameters) ValidateRequired added in v1.18.0

func (p EndpointParameters) ValidateRequired() error

ValidateRequired validates required parameters are set.

func (EndpointParameters) WithDefaults added in v1.18.0

func (p EndpointParameters) WithDefaults() EndpointParameters

WithDefaults returns a shallow copy of EndpointParameterswith default values applied to members where applicable.

type EndpointResolver

type EndpointResolver interface {
	ResolveEndpoint(region string, options EndpointResolverOptions) (aws.Endpoint, error)
}

EndpointResolver interface for resolving service endpoints.

func EndpointResolverFromURL added in v1.1.0

func EndpointResolverFromURL(url string, optFns ...func(*aws.Endpoint)) EndpointResolver

EndpointResolverFromURL returns an EndpointResolver configured using the provided endpoint url. By default, the resolved endpoint resolver uses the client region as signing region, and the endpoint source is set to EndpointSourceCustom.You can provide functional options to configure endpoint values for the resolved endpoint.

type EndpointResolverFunc

type EndpointResolverFunc func(region string, options EndpointResolverOptions) (aws.Endpoint, error)

EndpointResolverFunc is a helper utility that wraps a function so it satisfies the EndpointResolver interface. This is useful when you want to add additional endpoint resolving logic, or stub out specific endpoints with custom values.

func (EndpointResolverFunc) ResolveEndpoint

func (fn EndpointResolverFunc) ResolveEndpoint(region string, options EndpointResolverOptions) (endpoint aws.Endpoint, err error)

type EndpointResolverOptions added in v0.29.0

type EndpointResolverOptions = internalendpoints.Options

EndpointResolverOptions is the service endpoint resolver options

type EndpointResolverV2 added in v1.18.0

type EndpointResolverV2 interface {
	// ResolveEndpoint attempts to resolve the endpoint with the provided options,
	// returning the endpoint if found. Otherwise an error is returned.
	ResolveEndpoint(ctx context.Context, params EndpointParameters) (
		smithyendpoints.Endpoint, error,
	)
}

EndpointResolverV2 provides the interface for resolving service endpoints.

func NewDefaultEndpointResolverV2 added in v1.18.0

func NewDefaultEndpointResolverV2() EndpointResolverV2

type GetSnapshotBlockInput

type GetSnapshotBlockInput struct {

	// The block index of the block in which to read the data. A block index is a
	// logical index in units of 512 KiB blocks. To identify the block index, divide
	// the logical offset of the data in the logical volume by the block size (logical
	// offset of data/ 524288 ). The logical offset of the data must be 512 KiB
	// aligned.
	//
	// This member is required.
	BlockIndex *int32

	// The block token of the block from which to get data. You can obtain the
	// BlockToken by running the ListChangedBlocks or ListSnapshotBlocks operations.
	//
	// This member is required.
	BlockToken *string

	// The ID of the snapshot containing the block from which to get data. If the
	// specified snapshot is encrypted, you must have permission to use the KMS key
	// that was used to encrypt the snapshot. For more information, see Using
	// encryption (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ebsapis-using-encryption.html)
	// in the Amazon Elastic Compute Cloud User Guide.
	//
	// This member is required.
	SnapshotId *string
	// contains filtered or unexported fields
}

type GetSnapshotBlockOutput

type GetSnapshotBlockOutput struct {

	// The data content of the block.
	BlockData io.ReadCloser

	// The checksum generated for the block, which is Base64 encoded.
	Checksum *string

	// The algorithm used to generate the checksum for the block, such as SHA256.
	ChecksumAlgorithm types.ChecksumAlgorithm

	// The size of the data in the block.
	DataLength *int32

	// Metadata pertaining to the operation's result.
	ResultMetadata middleware.Metadata
	// contains filtered or unexported fields
}

type HTTPClient

type HTTPClient interface {
	Do(*http.Request) (*http.Response, error)
}

type HTTPSignerV4

type HTTPSignerV4 interface {
	SignHTTP(ctx context.Context, credentials aws.Credentials, r *http.Request, payloadHash string, service string, region string, signingTime time.Time, optFns ...func(*v4.SignerOptions)) error
}

type IdempotencyTokenProvider

type IdempotencyTokenProvider interface {
	GetIdempotencyToken() (string, error)
}

IdempotencyTokenProvider interface for providing idempotency token

type ListChangedBlocksAPIClient added in v0.30.0

type ListChangedBlocksAPIClient interface {
	ListChangedBlocks(context.Context, *ListChangedBlocksInput, ...func(*Options)) (*ListChangedBlocksOutput, error)
}

ListChangedBlocksAPIClient is a client that implements the ListChangedBlocks operation.

type ListChangedBlocksInput

type ListChangedBlocksInput struct {

	// The ID of the second snapshot to use for the comparison. The SecondSnapshotId
	// parameter must be specified with a FirstSnapshotID parameter; otherwise, an
	// error occurs.
	//
	// This member is required.
	SecondSnapshotId *string

	// The ID of the first snapshot to use for the comparison. The FirstSnapshotID
	// parameter must be specified with a SecondSnapshotId parameter; otherwise, an
	// error occurs.
	FirstSnapshotId *string

	// The maximum number of blocks to be returned by the request. Even if additional
	// blocks can be retrieved from the snapshot, the request can return less blocks
	// than MaxResults or an empty array of blocks. To retrieve the next set of blocks
	// from the snapshot, make another request with the returned NextToken value. The
	// value of NextToken is null when there are no more blocks to return.
	MaxResults *int32

	// The token to request the next page of results. If you specify NextToken, then
	// StartingBlockIndex is ignored.
	NextToken *string

	// The block index from which the comparison should start. The list in the
	// response will start from this block index or the next valid block index in the
	// snapshots. If you specify NextToken, then StartingBlockIndex is ignored.
	StartingBlockIndex *int32
	// contains filtered or unexported fields
}

type ListChangedBlocksOutput

type ListChangedBlocksOutput struct {

	// The size of the blocks in the snapshot, in bytes.
	BlockSize *int32

	// An array of objects containing information about the changed blocks.
	ChangedBlocks []types.ChangedBlock

	// The time when the BlockToken expires.
	ExpiryTime *time.Time

	// The token to use to retrieve the next page of results. This value is null when
	// there are no more results to return.
	NextToken *string

	// The size of the volume in GB.
	VolumeSize *int64

	// Metadata pertaining to the operation's result.
	ResultMetadata middleware.Metadata
	// contains filtered or unexported fields
}

type ListChangedBlocksPaginator added in v0.30.0

type ListChangedBlocksPaginator struct {
	// contains filtered or unexported fields
}

ListChangedBlocksPaginator is a paginator for ListChangedBlocks

func NewListChangedBlocksPaginator added in v0.30.0

func NewListChangedBlocksPaginator(client ListChangedBlocksAPIClient, params *ListChangedBlocksInput, optFns ...func(*ListChangedBlocksPaginatorOptions)) *ListChangedBlocksPaginator

NewListChangedBlocksPaginator returns a new ListChangedBlocksPaginator

func (*ListChangedBlocksPaginator) HasMorePages added in v0.30.0

func (p *ListChangedBlocksPaginator) HasMorePages() bool

HasMorePages returns a boolean indicating whether more pages are available

func (*ListChangedBlocksPaginator) NextPage added in v0.30.0

func (p *ListChangedBlocksPaginator) NextPage(ctx context.Context, optFns ...func(*Options)) (*ListChangedBlocksOutput, error)

NextPage retrieves the next ListChangedBlocks page.

type ListChangedBlocksPaginatorOptions added in v0.30.0

type ListChangedBlocksPaginatorOptions struct {
	// The maximum number of blocks to be returned by the request. Even if additional
	// blocks can be retrieved from the snapshot, the request can return less blocks
	// than MaxResults or an empty array of blocks. To retrieve the next set of blocks
	// from the snapshot, make another request with the returned NextToken value. The
	// value of NextToken is null when there are no more blocks to return.
	Limit int32

	// Set to true if pagination should stop if the service returns a pagination token
	// that matches the most recent token provided to the service.
	StopOnDuplicateToken bool
}

ListChangedBlocksPaginatorOptions is the paginator options for ListChangedBlocks

type ListSnapshotBlocksAPIClient added in v0.30.0

type ListSnapshotBlocksAPIClient interface {
	ListSnapshotBlocks(context.Context, *ListSnapshotBlocksInput, ...func(*Options)) (*ListSnapshotBlocksOutput, error)
}

ListSnapshotBlocksAPIClient is a client that implements the ListSnapshotBlocks operation.

type ListSnapshotBlocksInput

type ListSnapshotBlocksInput struct {

	// The ID of the snapshot from which to get block indexes and block tokens.
	//
	// This member is required.
	SnapshotId *string

	// The maximum number of blocks to be returned by the request. Even if additional
	// blocks can be retrieved from the snapshot, the request can return less blocks
	// than MaxResults or an empty array of blocks. To retrieve the next set of blocks
	// from the snapshot, make another request with the returned NextToken value. The
	// value of NextToken is null when there are no more blocks to return.
	MaxResults *int32

	// The token to request the next page of results. If you specify NextToken, then
	// StartingBlockIndex is ignored.
	NextToken *string

	// The block index from which the list should start. The list in the response will
	// start from this block index or the next valid block index in the snapshot. If
	// you specify NextToken, then StartingBlockIndex is ignored.
	StartingBlockIndex *int32
	// contains filtered or unexported fields
}

type ListSnapshotBlocksOutput

type ListSnapshotBlocksOutput struct {

	// The size of the blocks in the snapshot, in bytes.
	BlockSize *int32

	// An array of objects containing information about the blocks.
	Blocks []types.Block

	// The time when the BlockToken expires.
	ExpiryTime *time.Time

	// The token to use to retrieve the next page of results. This value is null when
	// there are no more results to return.
	NextToken *string

	// The size of the volume in GB.
	VolumeSize *int64

	// Metadata pertaining to the operation's result.
	ResultMetadata middleware.Metadata
	// contains filtered or unexported fields
}

type ListSnapshotBlocksPaginator added in v0.30.0

type ListSnapshotBlocksPaginator struct {
	// contains filtered or unexported fields
}

ListSnapshotBlocksPaginator is a paginator for ListSnapshotBlocks

func NewListSnapshotBlocksPaginator added in v0.30.0

func NewListSnapshotBlocksPaginator(client ListSnapshotBlocksAPIClient, params *ListSnapshotBlocksInput, optFns ...func(*ListSnapshotBlocksPaginatorOptions)) *ListSnapshotBlocksPaginator

NewListSnapshotBlocksPaginator returns a new ListSnapshotBlocksPaginator

func (*ListSnapshotBlocksPaginator) HasMorePages added in v0.30.0

func (p *ListSnapshotBlocksPaginator) HasMorePages() bool

HasMorePages returns a boolean indicating whether more pages are available

func (*ListSnapshotBlocksPaginator) NextPage added in v0.30.0

func (p *ListSnapshotBlocksPaginator) NextPage(ctx context.Context, optFns ...func(*Options)) (*ListSnapshotBlocksOutput, error)

NextPage retrieves the next ListSnapshotBlocks page.

type ListSnapshotBlocksPaginatorOptions added in v0.30.0

type ListSnapshotBlocksPaginatorOptions struct {
	// The maximum number of blocks to be returned by the request. Even if additional
	// blocks can be retrieved from the snapshot, the request can return less blocks
	// than MaxResults or an empty array of blocks. To retrieve the next set of blocks
	// from the snapshot, make another request with the returned NextToken value. The
	// value of NextToken is null when there are no more blocks to return.
	Limit int32

	// Set to true if pagination should stop if the service returns a pagination token
	// that matches the most recent token provided to the service.
	StopOnDuplicateToken bool
}

ListSnapshotBlocksPaginatorOptions is the paginator options for ListSnapshotBlocks

type Options

type Options struct {
	// Set of options to modify how an operation is invoked. These apply to all
	// operations invoked for this client. Use functional options on operation call to
	// modify this list for per operation behavior.
	APIOptions []func(*middleware.Stack) error

	// The optional application specific identifier appended to the User-Agent header.
	AppID string

	// This endpoint will be given as input to an EndpointResolverV2. It is used for
	// providing a custom base endpoint that is subject to modifications by the
	// processing EndpointResolverV2.
	BaseEndpoint *string

	// Configures the events that will be sent to the configured logger.
	ClientLogMode aws.ClientLogMode

	// The credentials object to use when signing requests.
	Credentials aws.CredentialsProvider

	// The configuration DefaultsMode that the SDK should use when constructing the
	// clients initial default settings.
	DefaultsMode aws.DefaultsMode

	// The endpoint options to be used when attempting to resolve an endpoint.
	EndpointOptions EndpointResolverOptions

	// The service endpoint resolver.
	//
	// Deprecated: Deprecated: EndpointResolver and WithEndpointResolver. Providing a
	// value for this field will likely prevent you from using any endpoint-related
	// service features released after the introduction of EndpointResolverV2 and
	// BaseEndpoint. To migrate an EndpointResolver implementation that uses a custom
	// endpoint, set the client option BaseEndpoint instead.
	EndpointResolver EndpointResolver

	// Resolves the endpoint used for a particular service operation. This should be
	// used over the deprecated EndpointResolver.
	EndpointResolverV2 EndpointResolverV2

	// Signature Version 4 (SigV4) Signer
	HTTPSignerV4 HTTPSignerV4

	// Provides idempotency tokens values that will be automatically populated into
	// idempotent API operations.
	IdempotencyTokenProvider IdempotencyTokenProvider

	// The logger writer interface to write logging messages to.
	Logger logging.Logger

	// The region to send requests to. (Required)
	Region string

	// RetryMaxAttempts specifies the maximum number attempts an API client will call
	// an operation that fails with a retryable error. A value of 0 is ignored, and
	// will not be used to configure the API client created default retryer, or modify
	// per operation call's retry max attempts. If specified in an operation call's
	// functional options with a value that is different than the constructed client's
	// Options, the Client's Retryer will be wrapped to use the operation's specific
	// RetryMaxAttempts value.
	RetryMaxAttempts int

	// RetryMode specifies the retry mode the API client will be created with, if
	// Retryer option is not also specified. When creating a new API Clients this
	// member will only be used if the Retryer Options member is nil. This value will
	// be ignored if Retryer is not nil. Currently does not support per operation call
	// overrides, may in the future.
	RetryMode aws.RetryMode

	// Retryer guides how HTTP requests should be retried in case of recoverable
	// failures. When nil the API client will use a default retryer. The kind of
	// default retry created by the API client can be changed with the RetryMode
	// option.
	Retryer aws.Retryer

	// The RuntimeEnvironment configuration, only populated if the DefaultsMode is set
	// to DefaultsModeAuto and is initialized using config.LoadDefaultConfig . You
	// should not populate this structure programmatically, or rely on the values here
	// within your applications.
	RuntimeEnvironment aws.RuntimeEnvironment

	// The HTTP client to invoke API calls with. Defaults to client's default HTTP
	// implementation if nil.
	HTTPClient HTTPClient

	// The auth scheme resolver which determines how to authenticate for each
	// operation.
	AuthSchemeResolver AuthSchemeResolver

	// The list of auth schemes supported by the client.
	AuthSchemes []smithyhttp.AuthScheme
	// contains filtered or unexported fields
}

func (Options) Copy

func (o Options) Copy() Options

Copy creates a clone where the APIOptions list is deep copied.

func (Options) GetIdentityResolver added in v1.20.2

func (o Options) GetIdentityResolver(schemeID string) smithyauth.IdentityResolver

type PutSnapshotBlockInput

type PutSnapshotBlockInput struct {

	// The data to write to the block. The block data is not signed as part of the
	// Signature Version 4 signing process. As a result, you must generate and provide
	// a Base64-encoded SHA256 checksum for the block data using the x-amz-Checksum
	// header. Also, you must specify the checksum algorithm using the
	// x-amz-Checksum-Algorithm header. The checksum that you provide is part of the
	// Signature Version 4 signing process. It is validated against a checksum
	// generated by Amazon EBS to ensure the validity and authenticity of the data. If
	// the checksums do not correspond, the request fails. For more information, see
	// Using checksums with the EBS direct APIs (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ebs-accessing-snapshot.html#ebsapis-using-checksums)
	// in the Amazon Elastic Compute Cloud User Guide.
	//
	// This member is required.
	BlockData io.Reader

	// The block index of the block in which to write the data. A block index is a
	// logical index in units of 512 KiB blocks. To identify the block index, divide
	// the logical offset of the data in the logical volume by the block size (logical
	// offset of data/ 524288 ). The logical offset of the data must be 512 KiB
	// aligned.
	//
	// This member is required.
	BlockIndex *int32

	// A Base64-encoded SHA256 checksum of the data. Only SHA256 checksums are
	// supported.
	//
	// This member is required.
	Checksum *string

	// The algorithm used to generate the checksum. Currently, the only supported
	// algorithm is SHA256 .
	//
	// This member is required.
	ChecksumAlgorithm types.ChecksumAlgorithm

	// The size of the data to write to the block, in bytes. Currently, the only
	// supported size is 524288 bytes. Valid values: 524288
	//
	// This member is required.
	DataLength *int32

	// The ID of the snapshot. If the specified snapshot is encrypted, you must have
	// permission to use the KMS key that was used to encrypt the snapshot. For more
	// information, see Using encryption (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ebsapis-using-encryption.html)
	// in the Amazon Elastic Compute Cloud User Guide..
	//
	// This member is required.
	SnapshotId *string

	// The progress of the write process, as a percentage.
	Progress *int32
	// contains filtered or unexported fields
}

type PutSnapshotBlockOutput

type PutSnapshotBlockOutput struct {

	// The SHA256 checksum generated for the block data by Amazon EBS.
	Checksum *string

	// The algorithm used by Amazon EBS to generate the checksum.
	ChecksumAlgorithm types.ChecksumAlgorithm

	// Metadata pertaining to the operation's result.
	ResultMetadata middleware.Metadata
	// contains filtered or unexported fields
}

type ResolveEndpoint

type ResolveEndpoint struct {
	Resolver EndpointResolver
	Options  EndpointResolverOptions
}

func (*ResolveEndpoint) HandleSerialize

func (*ResolveEndpoint) ID

func (*ResolveEndpoint) ID() string

type StartSnapshotInput

type StartSnapshotInput struct {

	// The size of the volume, in GiB. The maximum size is 65536 GiB (64 TiB).
	//
	// This member is required.
	VolumeSize *int64

	// A unique, case-sensitive identifier that you provide to ensure the idempotency
	// of the request. Idempotency ensures that an API request completes only once.
	// With an idempotent request, if the original request completes successfully. The
	// subsequent retries with the same client token return the result from the
	// original successful request and they have no additional effect. If you do not
	// specify a client token, one is automatically generated by the Amazon Web
	// Services SDK. For more information, see Idempotency for StartSnapshot API (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ebs-direct-api-idempotency.html)
	// in the Amazon Elastic Compute Cloud User Guide.
	ClientToken *string

	// A description for the snapshot.
	Description *string

	// Indicates whether to encrypt the snapshot. You can't specify Encrypted and
	// ParentSnapshotId in the same request. If you specify both parameters, the
	// request fails with ValidationException . The encryption status of the snapshot
	// depends on the values that you specify for Encrypted, KmsKeyArn, and
	// ParentSnapshotId, and whether your Amazon Web Services account is enabled for
	// encryption by default (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/EBSEncryption.html#encryption-by-default)
	// . For more information, see Using encryption (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ebsapis-using-encryption.html)
	// in the Amazon Elastic Compute Cloud User Guide. To create an encrypted snapshot,
	// you must have permission to use the KMS key. For more information, see
	// Permissions to use Key Management Service keys (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ebsapi-permissions.html#ebsapi-kms-permissions)
	// in the Amazon Elastic Compute Cloud User Guide.
	Encrypted *bool

	// The Amazon Resource Name (ARN) of the Key Management Service (KMS) key to be
	// used to encrypt the snapshot. The encryption status of the snapshot depends on
	// the values that you specify for Encrypted, KmsKeyArn, and ParentSnapshotId, and
	// whether your Amazon Web Services account is enabled for encryption by default (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/EBSEncryption.html#encryption-by-default)
	// . For more information, see Using encryption (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ebsapis-using-encryption.html)
	// in the Amazon Elastic Compute Cloud User Guide. To create an encrypted snapshot,
	// you must have permission to use the KMS key. For more information, see
	// Permissions to use Key Management Service keys (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ebsapi-permissions.html#ebsapi-kms-permissions)
	// in the Amazon Elastic Compute Cloud User Guide.
	KmsKeyArn *string

	// The ID of the parent snapshot. If there is no parent snapshot, or if you are
	// creating the first snapshot for an on-premises volume, omit this parameter. You
	// can't specify ParentSnapshotId and Encrypted in the same request. If you specify
	// both parameters, the request fails with ValidationException . The encryption
	// status of the snapshot depends on the values that you specify for Encrypted,
	// KmsKeyArn, and ParentSnapshotId, and whether your Amazon Web Services account is
	// enabled for encryption by default (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/EBSEncryption.html#encryption-by-default)
	// . For more information, see Using encryption (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ebsapis-using-encryption.html)
	// in the Amazon Elastic Compute Cloud User Guide. If you specify an encrypted
	// parent snapshot, you must have permission to use the KMS key that was used to
	// encrypt the parent snapshot. For more information, see Permissions to use Key
	// Management Service keys (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ebsapi-permissions.html#ebsapi-kms-permissions)
	// in the Amazon Elastic Compute Cloud User Guide.
	ParentSnapshotId *string

	// The tags to apply to the snapshot.
	Tags []types.Tag

	// The amount of time (in minutes) after which the snapshot is automatically
	// cancelled if:
	//   - No blocks are written to the snapshot.
	//   - The snapshot is not completed after writing the last block of data.
	// If no value is specified, the timeout defaults to 60 minutes.
	Timeout *int32
	// contains filtered or unexported fields
}

type StartSnapshotOutput

type StartSnapshotOutput struct {

	// The size of the blocks in the snapshot, in bytes.
	BlockSize *int32

	// The description of the snapshot.
	Description *string

	// The Amazon Resource Name (ARN) of the Key Management Service (KMS) key used to
	// encrypt the snapshot.
	KmsKeyArn *string

	// The Amazon Web Services account ID of the snapshot owner.
	OwnerId *string

	// The ID of the parent snapshot.
	ParentSnapshotId *string

	// The ID of the snapshot.
	SnapshotId *string

	// Reserved for future use.
	SseType types.SSEType

	// The timestamp when the snapshot was created.
	StartTime *time.Time

	// The status of the snapshot.
	Status types.Status

	// The tags applied to the snapshot. You can specify up to 50 tags per snapshot.
	// For more information, see Tagging your Amazon EC2 resources (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/Using_Tags.html)
	// in the Amazon Elastic Compute Cloud User Guide.
	Tags []types.Tag

	// The size of the volume, in GiB.
	VolumeSize *int64

	// Metadata pertaining to the operation's result.
	ResultMetadata middleware.Metadata
	// contains filtered or unexported fields
}

Directories

Path Synopsis
internal

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL