Amp
Service object for interacting with AWS Amp service.
public struct Amp: AWSService
Amazon Managed Service for Prometheus
Inheritance
AWSService
Initializers
init(client:region:partition:endpoint:timeout:byteBufferAllocator:options:)
Initialize the Amp client
public init(
client: AWSClient,
region: SotoCore.Region? = nil,
partition: AWSPartition = .aws,
endpoint: String? = nil,
timeout: TimeAmount? = nil,
byteBufferAllocator: ByteBufferAllocator = ByteBufferAllocator(),
options: AWSServiceConfig.Options = []
)
Parameters
- client: AWSClient used to process requests
- region: Region of server you want to communicate with. This will override the partition parameter.
- partition: AWS partition where service resides, standard (.aws), china (.awscn), government (.awsusgov).
- endpoint: Custom endpoint URL to use instead of standard AWS servers
- timeout: Timeout value for HTTP requests
init(from:patch:)
Initializer required by AWSService.with(middlewares:timeout:byteBufferAllocator:options)
. You are not able to use this initializer directly as there are no public initializers for AWSServiceConfig.Patch
. Please use AWSService.with(middlewares:timeout:byteBufferAllocator:options)
instead.
public init(from: Amp, patch: AWSServiceConfig.Patch)
Properties
client
Client used for communication with AWS
public let client: AWSClient
config
Service configuration
public let config: AWSServiceConfig
Methods
createAlertManagerDefinition(_:logger:on:)
Create an alert manager definition.
public func createAlertManagerDefinition(_ input: CreateAlertManagerDefinitionRequest, logger: Logger = AWSClient.loggingDisabled, on eventLoop: EventLoop? = nil) -> EventLoopFuture<CreateAlertManagerDefinitionResponse>
createRuleGroupsNamespace(_:logger:on:)
Create a rule group namespace.
public func createRuleGroupsNamespace(_ input: CreateRuleGroupsNamespaceRequest, logger: Logger = AWSClient.loggingDisabled, on eventLoop: EventLoop? = nil) -> EventLoopFuture<CreateRuleGroupsNamespaceResponse>
createWorkspace(_:logger:on:)
Creates a new AMP workspace.
public func createWorkspace(_ input: CreateWorkspaceRequest, logger: Logger = AWSClient.loggingDisabled, on eventLoop: EventLoop? = nil) -> EventLoopFuture<CreateWorkspaceResponse>
deleteAlertManagerDefinition(_:logger:on:)
Deletes an alert manager definition.
@discardableResult public func deleteAlertManagerDefinition(_ input: DeleteAlertManagerDefinitionRequest, logger: Logger = AWSClient.loggingDisabled, on eventLoop: EventLoop? = nil) -> EventLoopFuture<Void>
deleteRuleGroupsNamespace(_:logger:on:)
Delete a rule groups namespace.
@discardableResult public func deleteRuleGroupsNamespace(_ input: DeleteRuleGroupsNamespaceRequest, logger: Logger = AWSClient.loggingDisabled, on eventLoop: EventLoop? = nil) -> EventLoopFuture<Void>
deleteWorkspace(_:logger:on:)
Deletes an AMP workspace.
@discardableResult public func deleteWorkspace(_ input: DeleteWorkspaceRequest, logger: Logger = AWSClient.loggingDisabled, on eventLoop: EventLoop? = nil) -> EventLoopFuture<Void>
describeAlertManagerDefinition(_:logger:on:)
Describes an alert manager definition.
public func describeAlertManagerDefinition(_ input: DescribeAlertManagerDefinitionRequest, logger: Logger = AWSClient.loggingDisabled, on eventLoop: EventLoop? = nil) -> EventLoopFuture<DescribeAlertManagerDefinitionResponse>
describeRuleGroupsNamespace(_:logger:on:)
Describe a rule groups namespace.
public func describeRuleGroupsNamespace(_ input: DescribeRuleGroupsNamespaceRequest, logger: Logger = AWSClient.loggingDisabled, on eventLoop: EventLoop? = nil) -> EventLoopFuture<DescribeRuleGroupsNamespaceResponse>
describeWorkspace(_:logger:on:)
Describes an existing AMP workspace.
public func describeWorkspace(_ input: DescribeWorkspaceRequest, logger: Logger = AWSClient.loggingDisabled, on eventLoop: EventLoop? = nil) -> EventLoopFuture<DescribeWorkspaceResponse>
listRuleGroupsNamespaces(_:logger:on:)
Lists rule groups namespaces.
public func listRuleGroupsNamespaces(_ input: ListRuleGroupsNamespacesRequest, logger: Logger = AWSClient.loggingDisabled, on eventLoop: EventLoop? = nil) -> EventLoopFuture<ListRuleGroupsNamespacesResponse>
listTagsForResource(_:logger:on:)
Lists the tags you have assigned to the resource.
public func listTagsForResource(_ input: ListTagsForResourceRequest, logger: Logger = AWSClient.loggingDisabled, on eventLoop: EventLoop? = nil) -> EventLoopFuture<ListTagsForResourceResponse>
listWorkspaces(_:logger:on:)
Lists all AMP workspaces, including workspaces being created or deleted.
public func listWorkspaces(_ input: ListWorkspacesRequest, logger: Logger = AWSClient.loggingDisabled, on eventLoop: EventLoop? = nil) -> EventLoopFuture<ListWorkspacesResponse>
putAlertManagerDefinition(_:logger:on:)
Update an alert manager definition.
public func putAlertManagerDefinition(_ input: PutAlertManagerDefinitionRequest, logger: Logger = AWSClient.loggingDisabled, on eventLoop: EventLoop? = nil) -> EventLoopFuture<PutAlertManagerDefinitionResponse>
putRuleGroupsNamespace(_:logger:on:)
Update a rule groups namespace.
public func putRuleGroupsNamespace(_ input: PutRuleGroupsNamespaceRequest, logger: Logger = AWSClient.loggingDisabled, on eventLoop: EventLoop? = nil) -> EventLoopFuture<PutRuleGroupsNamespaceResponse>
tagResource(_:logger:on:)
Creates tags for the specified resource.
public func tagResource(_ input: TagResourceRequest, logger: Logger = AWSClient.loggingDisabled, on eventLoop: EventLoop? = nil) -> EventLoopFuture<TagResourceResponse>
untagResource(_:logger:on:)
Deletes tags from the specified resource.
public func untagResource(_ input: UntagResourceRequest, logger: Logger = AWSClient.loggingDisabled, on eventLoop: EventLoop? = nil) -> EventLoopFuture<UntagResourceResponse>
updateWorkspaceAlias(_:logger:on:)
Updates an AMP workspace alias.
@discardableResult public func updateWorkspaceAlias(_ input: UpdateWorkspaceAliasRequest, logger: Logger = AWSClient.loggingDisabled, on eventLoop: EventLoop? = nil) -> EventLoopFuture<Void>
listRuleGroupsNamespacesPaginator(_:logger:on:)
compiler(>=5.5.2) && canImport(_Concurrency)
-
Lists rule groups namespaces.
Return PaginatorSequence for operation.
public func listRuleGroupsNamespacesPaginator( _ input: ListRuleGroupsNamespacesRequest, logger: Logger = AWSClient.loggingDisabled, on eventLoop: EventLoop? = nil ) -> AWSClient.PaginatorSequence<ListRuleGroupsNamespacesRequest, ListRuleGroupsNamespacesResponse>
Parameters
- input: Input for request - logger: Logger used flot logging - eventLoop: EventLoop to run this process on
listWorkspacesPaginator(_:logger:on:)
compiler(>=5.5.2) && canImport(_Concurrency)
-
Lists all AMP workspaces, including workspaces being created or deleted.
Return PaginatorSequence for operation.
public func listWorkspacesPaginator( _ input: ListWorkspacesRequest, logger: Logger = AWSClient.loggingDisabled, on eventLoop: EventLoop? = nil ) -> AWSClient.PaginatorSequence<ListWorkspacesRequest, ListWorkspacesResponse>
Parameters
- input: Input for request - logger: Logger used flot logging - eventLoop: EventLoop to run this process on
listRuleGroupsNamespacesPaginator(_:_:logger:on:onPage:)
Lists rule groups namespaces.
public func listRuleGroupsNamespacesPaginator<Result>(
_ input: ListRuleGroupsNamespacesRequest,
_ initialValue: Result,
logger: Logger = AWSClient.loggingDisabled,
on eventLoop: EventLoop? = nil,
onPage: @escaping (Result, ListRuleGroupsNamespacesResponse, EventLoop) -> EventLoopFuture<(Bool, Result)>
) -> EventLoopFuture<Result>
Provide paginated results to closure onPage
for it to combine them into one result. This works in a similar manner to Array.reduce<Result>(_:_:) -> Result
.
Parameters:
- input: Input for request
- initialValue: The value to use as the initial accumulating value.
initialValue
is passed toonPage
the first time it is called.
- logger: Logger used flot logging
- eventLoop: EventLoop to run this process on
- onPage: closure called with each paginated response. It combines an accumulating result with the contents of response. This combined result is then returned along with a boolean indicating if the paginate operation should continue.
listRuleGroupsNamespacesPaginator(_:logger:on:onPage:)
Provide paginated results to closure onPage
.
public func listRuleGroupsNamespacesPaginator(
_ input: ListRuleGroupsNamespacesRequest,
logger: Logger = AWSClient.loggingDisabled,
on eventLoop: EventLoop? = nil,
onPage: @escaping (ListRuleGroupsNamespacesResponse, EventLoop) -> EventLoopFuture<Bool>
) -> EventLoopFuture<Void>
Parameters
- input: Input for request
- logger: Logger used flot logging
- eventLoop: EventLoop to run this process on
- onPage: closure called with each block of entries. Returns boolean indicating whether we should continue.
listWorkspacesPaginator(_:_:logger:on:onPage:)
Lists all AMP workspaces, including workspaces being created or deleted.
public func listWorkspacesPaginator<Result>(
_ input: ListWorkspacesRequest,
_ initialValue: Result,
logger: Logger = AWSClient.loggingDisabled,
on eventLoop: EventLoop? = nil,
onPage: @escaping (Result, ListWorkspacesResponse, EventLoop) -> EventLoopFuture<(Bool, Result)>
) -> EventLoopFuture<Result>
Provide paginated results to closure onPage
for it to combine them into one result. This works in a similar manner to Array.reduce<Result>(_:_:) -> Result
.
Parameters:
- input: Input for request
- initialValue: The value to use as the initial accumulating value.
initialValue
is passed toonPage
the first time it is called.
- logger: Logger used flot logging
- eventLoop: EventLoop to run this process on
- onPage: closure called with each paginated response. It combines an accumulating result with the contents of response. This combined result is then returned along with a boolean indicating if the paginate operation should continue.
listWorkspacesPaginator(_:logger:on:onPage:)
Provide paginated results to closure onPage
.
public func listWorkspacesPaginator(
_ input: ListWorkspacesRequest,
logger: Logger = AWSClient.loggingDisabled,
on eventLoop: EventLoop? = nil,
onPage: @escaping (ListWorkspacesResponse, EventLoop) -> EventLoopFuture<Bool>
) -> EventLoopFuture<Void>
Parameters
- input: Input for request
- logger: Logger used flot logging
- eventLoop: EventLoop to run this process on
- onPage: closure called with each block of entries. Returns boolean indicating whether we should continue.
waitUntilWorkspaceActive(_:maxWaitTime:logger:on:)
Wait until a workspace reaches ACTIVE status
public func waitUntilWorkspaceActive(
_ input: DescribeWorkspaceRequest,
maxWaitTime: TimeAmount? = nil,
logger: Logger = AWSClient.loggingDisabled,
on eventLoop: EventLoop? = nil
) -> EventLoopFuture<Void>
waitUntilWorkspaceDeleted(_:maxWaitTime:logger:on:)
Wait until a workspace reaches DELETED status
public func waitUntilWorkspaceDeleted(
_ input: DescribeWorkspaceRequest,
maxWaitTime: TimeAmount? = nil,
logger: Logger = AWSClient.loggingDisabled,
on eventLoop: EventLoop? = nil
) -> EventLoopFuture<Void>