Documentation
¶
Overview ¶
Package amp provides the API client, operations, and parameter types for Amazon Prometheus Service.
Amazon Managed Service for Prometheus
Index ¶
- Constants
- func NewDefaultEndpointResolver() *internalendpoints.Resolver
- func WithAPIOptions(optFns ...func(*middleware.Stack) error) func(*Options)
- func WithEndpointResolver(v EndpointResolver) func(*Options)
- type Client
- func (c *Client) CreateWorkspace(ctx context.Context, params *CreateWorkspaceInput, optFns ...func(*Options)) (*CreateWorkspaceOutput, error)
- func (c *Client) DeleteWorkspace(ctx context.Context, params *DeleteWorkspaceInput, optFns ...func(*Options)) (*DeleteWorkspaceOutput, error)
- func (c *Client) DescribeWorkspace(ctx context.Context, params *DescribeWorkspaceInput, optFns ...func(*Options)) (*DescribeWorkspaceOutput, error)
- func (c *Client) ListWorkspaces(ctx context.Context, params *ListWorkspacesInput, optFns ...func(*Options)) (*ListWorkspacesOutput, error)
- func (c *Client) UpdateWorkspaceAlias(ctx context.Context, params *UpdateWorkspaceAliasInput, ...) (*UpdateWorkspaceAliasOutput, error)
- type CreateWorkspaceInput
- type CreateWorkspaceOutput
- type DeleteWorkspaceInput
- type DeleteWorkspaceOutput
- type DescribeWorkspaceInput
- type DescribeWorkspaceOutput
- type EndpointResolver
- type EndpointResolverFunc
- type EndpointResolverOptions
- type HTTPClient
- type HTTPSignerV4
- type ListWorkspacesAPIClient
- type ListWorkspacesInput
- type ListWorkspacesOutput
- type ListWorkspacesPaginator
- type ListWorkspacesPaginatorOptions
- type Options
- type ResolveEndpoint
- type UpdateWorkspaceAliasInput
- type UpdateWorkspaceAliasOutput
Constants ¶
const ServiceAPIVersion = "2020-08-01"
const ServiceID = "amp"
Variables ¶
This section is empty.
Functions ¶
func NewDefaultEndpointResolver ¶
func NewDefaultEndpointResolver() *internalendpoints.Resolver
NewDefaultEndpointResolver constructs a new service endpoint resolver
func WithAPIOptions ¶
func WithAPIOptions(optFns ...func(*middleware.Stack) error) func(*Options)
WithAPIOptions returns a functional option for setting the Client's APIOptions option.
func WithEndpointResolver ¶
func WithEndpointResolver(v EndpointResolver) func(*Options)
WithEndpointResolver returns a functional option for setting the Client's EndpointResolver option.
Types ¶
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
Client provides the API client to make operations call for Amazon Prometheus Service.
func New ¶
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 ¶
NewFromConfig returns a new client from the provided config.
func (*Client) CreateWorkspace ¶
func (c *Client) CreateWorkspace(ctx context.Context, params *CreateWorkspaceInput, optFns ...func(*Options)) (*CreateWorkspaceOutput, error)
Creates a new AMP workspace.
func (*Client) DeleteWorkspace ¶
func (c *Client) DeleteWorkspace(ctx context.Context, params *DeleteWorkspaceInput, optFns ...func(*Options)) (*DeleteWorkspaceOutput, error)
Deletes an AMP workspace.
func (*Client) DescribeWorkspace ¶
func (c *Client) DescribeWorkspace(ctx context.Context, params *DescribeWorkspaceInput, optFns ...func(*Options)) (*DescribeWorkspaceOutput, error)
Describes an existing AMP workspace.
func (*Client) ListWorkspaces ¶
func (c *Client) ListWorkspaces(ctx context.Context, params *ListWorkspacesInput, optFns ...func(*Options)) (*ListWorkspacesOutput, error)
Lists all AMP workspaces, including workspaces being created or deleted.
func (*Client) UpdateWorkspaceAlias ¶
func (c *Client) UpdateWorkspaceAlias(ctx context.Context, params *UpdateWorkspaceAliasInput, optFns ...func(*Options)) (*UpdateWorkspaceAliasOutput, error)
Updates an AMP workspace alias.
type CreateWorkspaceInput ¶
type CreateWorkspaceInput struct { // An optional user-assigned alias for this workspace. This alias is for user // reference and does not need to be unique. Alias *string // Optional, unique, case-sensitive, user-provided identifier to ensure the // idempotency of the request. ClientToken *string // contains filtered or unexported fields }
Represents the input of a CreateWorkspace operation.
type CreateWorkspaceOutput ¶
type CreateWorkspaceOutput struct { // The ARN of the workspace that was just created. // // This member is required. Arn *string // The status of the workspace that was just created (usually CREATING). // // This member is required. Status *types.WorkspaceStatus // The generated ID of the workspace that was just created. // // This member is required. WorkspaceId *string // Metadata pertaining to the operation's result. ResultMetadata middleware.Metadata // contains filtered or unexported fields }
Represents the output of a CreateWorkspace operation.
type DeleteWorkspaceInput ¶
type DeleteWorkspaceInput struct { // The ID of the workspace to delete. // // This member is required. WorkspaceId *string // Optional, unique, case-sensitive, user-provided identifier to ensure the // idempotency of the request. ClientToken *string // contains filtered or unexported fields }
Represents the input of a DeleteWorkspace operation.
type DeleteWorkspaceOutput ¶
type DeleteWorkspaceOutput struct { // Metadata pertaining to the operation's result. ResultMetadata middleware.Metadata // contains filtered or unexported fields }
type DescribeWorkspaceInput ¶
type DescribeWorkspaceInput struct { // The ID of the workspace to describe. // // This member is required. WorkspaceId *string // contains filtered or unexported fields }
Represents the input of a DescribeWorkspace operation.
type DescribeWorkspaceOutput ¶
type DescribeWorkspaceOutput struct { // The properties of the selected workspace. // // This member is required. Workspace *types.WorkspaceDescription // Metadata pertaining to the operation's result. ResultMetadata middleware.Metadata // contains filtered or unexported fields }
Represents the output of a DescribeWorkspace operation.
type EndpointResolver ¶
type EndpointResolver interface {
ResolveEndpoint(region string, options EndpointResolverOptions) (aws.Endpoint, error)
}
EndpointResolver interface for resolving service endpoints.
func EndpointResolverFromURL ¶
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 ¶
type EndpointResolverOptions = internalendpoints.Options
EndpointResolverOptions is the service endpoint resolver options
type HTTPSignerV4 ¶
type ListWorkspacesAPIClient ¶
type ListWorkspacesAPIClient interface {
ListWorkspaces(context.Context, *ListWorkspacesInput, ...func(*Options)) (*ListWorkspacesOutput, error)
}
ListWorkspacesAPIClient is a client that implements the ListWorkspaces operation.
type ListWorkspacesInput ¶
type ListWorkspacesInput struct { // Optional filter for workspace alias. Only the workspaces with aliases that begin // with this value will be returned. Alias *string // Maximum results to return in response (default=100, maximum=1000). MaxResults *int32 // Pagination token to request the next page in a paginated list. This token is // obtained from the output of the previous ListWorkspaces request. NextToken *string // contains filtered or unexported fields }
Represents the input of a ListWorkspaces operation.
type ListWorkspacesOutput ¶
type ListWorkspacesOutput struct { // The list of existing workspaces, including those undergoing creation or // deletion. // // This member is required. Workspaces []types.WorkspaceSummary // Pagination token to use when requesting the next page in this list. NextToken *string // Metadata pertaining to the operation's result. ResultMetadata middleware.Metadata // contains filtered or unexported fields }
Represents the output of a ListWorkspaces operation.
type ListWorkspacesPaginator ¶
type ListWorkspacesPaginator struct {
// contains filtered or unexported fields
}
ListWorkspacesPaginator is a paginator for ListWorkspaces
func NewListWorkspacesPaginator ¶
func NewListWorkspacesPaginator(client ListWorkspacesAPIClient, params *ListWorkspacesInput, optFns ...func(*ListWorkspacesPaginatorOptions)) *ListWorkspacesPaginator
NewListWorkspacesPaginator returns a new ListWorkspacesPaginator
func (*ListWorkspacesPaginator) HasMorePages ¶
func (p *ListWorkspacesPaginator) HasMorePages() bool
HasMorePages returns a boolean indicating whether more pages are available
func (*ListWorkspacesPaginator) NextPage ¶
func (p *ListWorkspacesPaginator) NextPage(ctx context.Context, optFns ...func(*Options)) (*ListWorkspacesOutput, error)
NextPage retrieves the next ListWorkspaces page.
type ListWorkspacesPaginatorOptions ¶
type ListWorkspacesPaginatorOptions struct { // Maximum results to return in response (default=100, maximum=1000). 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 }
ListWorkspacesPaginatorOptions is the paginator options for ListWorkspaces
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 // 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 endpoint options to be used when attempting to resolve an endpoint. EndpointOptions EndpointResolverOptions // The service endpoint resolver. EndpointResolver EndpointResolver // Signature Version 4 (SigV4) Signer HTTPSignerV4 HTTPSignerV4 // The logger writer interface to write logging messages to. Logger logging.Logger // The region to send requests to. (Required) Region string // Retryer guides how HTTP requests should be retried in case of recoverable // failures. When nil the API client will use a default retryer. Retryer aws.Retryer // The HTTP client to invoke API calls with. Defaults to client's default HTTP // implementation if nil. HTTPClient HTTPClient }
type ResolveEndpoint ¶
type ResolveEndpoint struct { Resolver EndpointResolver Options EndpointResolverOptions }
func (*ResolveEndpoint) HandleSerialize ¶
func (m *ResolveEndpoint) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) ( out middleware.SerializeOutput, metadata middleware.Metadata, err error, )
func (*ResolveEndpoint) ID ¶
func (*ResolveEndpoint) ID() string
type UpdateWorkspaceAliasInput ¶
type UpdateWorkspaceAliasInput struct { // The ID of the workspace being updated. // // This member is required. WorkspaceId *string // The new alias of the workspace. Alias *string // Optional, unique, case-sensitive, user-provided identifier to ensure the // idempotency of the request. ClientToken *string // contains filtered or unexported fields }
Represents the input of an UpdateWorkspaceAlias operation.
type UpdateWorkspaceAliasOutput ¶
type UpdateWorkspaceAliasOutput struct { // Metadata pertaining to the operation's result. ResultMetadata middleware.Metadata // contains filtered or unexported fields }