-
Notifications
You must be signed in to change notification settings - Fork 579
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(client-ec2): This release adds new functionality that allows cus…
…tomers to provision IPv6 CIDR blocks through Amazon VPC IP Address Manager (IPAM) as well as allowing customers to utilize IPAM Resource Discovery APIs.
- Loading branch information
awstools
committed
Jan 25, 2023
1 parent
bf7623f
commit 8973fbd
Showing
68 changed files
with
18,546 additions
and
12,807 deletions.
There are no files selected for viewing
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
122 changes: 122 additions & 0 deletions
122
clients/client-ec2/src/commands/AssociateIpamResourceDiscoveryCommand.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,122 @@ | ||
// smithy-typescript generated code | ||
import { EndpointParameterInstructions, getEndpointPlugin } from "@aws-sdk/middleware-endpoint"; | ||
import { getSerdePlugin } from "@aws-sdk/middleware-serde"; | ||
import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http"; | ||
import { Command as $Command } from "@aws-sdk/smithy-client"; | ||
import { | ||
FinalizeHandlerArguments, | ||
Handler, | ||
HandlerExecutionContext, | ||
HttpHandlerOptions as __HttpHandlerOptions, | ||
MetadataBearer as __MetadataBearer, | ||
MiddlewareStack, | ||
SerdeContext as __SerdeContext, | ||
} from "@aws-sdk/types"; | ||
|
||
import { EC2ClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../EC2Client"; | ||
import { | ||
AssociateIpamResourceDiscoveryRequest, | ||
AssociateIpamResourceDiscoveryRequestFilterSensitiveLog, | ||
AssociateIpamResourceDiscoveryResult, | ||
AssociateIpamResourceDiscoveryResultFilterSensitiveLog, | ||
} from "../models/models_0"; | ||
import { | ||
deserializeAws_ec2AssociateIpamResourceDiscoveryCommand, | ||
serializeAws_ec2AssociateIpamResourceDiscoveryCommand, | ||
} from "../protocols/Aws_ec2"; | ||
|
||
export interface AssociateIpamResourceDiscoveryCommandInput extends AssociateIpamResourceDiscoveryRequest {} | ||
export interface AssociateIpamResourceDiscoveryCommandOutput | ||
extends AssociateIpamResourceDiscoveryResult, | ||
__MetadataBearer {} | ||
|
||
/** | ||
* <p>Associates an IPAM resource discovery with an Amazon VPC IPAM. A resource discovery is an IPAM component that enables IPAM Service to manage and monitor resources that belong to the owning account.</p> | ||
* @example | ||
* Use a bare-bones client and the command you need to make an API call. | ||
* ```javascript | ||
* import { EC2Client, AssociateIpamResourceDiscoveryCommand } from "@aws-sdk/client-ec2"; // ES Modules import | ||
* // const { EC2Client, AssociateIpamResourceDiscoveryCommand } = require("@aws-sdk/client-ec2"); // CommonJS import | ||
* const client = new EC2Client(config); | ||
* const command = new AssociateIpamResourceDiscoveryCommand(input); | ||
* const response = await client.send(command); | ||
* ``` | ||
* | ||
* @see {@link AssociateIpamResourceDiscoveryCommandInput} for command's `input` shape. | ||
* @see {@link AssociateIpamResourceDiscoveryCommandOutput} for command's `response` shape. | ||
* @see {@link EC2ClientResolvedConfig | config} for EC2Client's `config` shape. | ||
* | ||
*/ | ||
export class AssociateIpamResourceDiscoveryCommand extends $Command< | ||
AssociateIpamResourceDiscoveryCommandInput, | ||
AssociateIpamResourceDiscoveryCommandOutput, | ||
EC2ClientResolvedConfig | ||
> { | ||
// Start section: command_properties | ||
// End section: command_properties | ||
|
||
public static getEndpointParameterInstructions(): EndpointParameterInstructions { | ||
return { | ||
UseFIPS: { type: "builtInParams", name: "useFipsEndpoint" }, | ||
Endpoint: { type: "builtInParams", name: "endpoint" }, | ||
Region: { type: "builtInParams", name: "region" }, | ||
UseDualStack: { type: "builtInParams", name: "useDualstackEndpoint" }, | ||
}; | ||
} | ||
|
||
constructor(readonly input: AssociateIpamResourceDiscoveryCommandInput) { | ||
// Start section: command_constructor | ||
super(); | ||
// End section: command_constructor | ||
} | ||
|
||
/** | ||
* @internal | ||
*/ | ||
resolveMiddleware( | ||
clientStack: MiddlewareStack<ServiceInputTypes, ServiceOutputTypes>, | ||
configuration: EC2ClientResolvedConfig, | ||
options?: __HttpHandlerOptions | ||
): Handler<AssociateIpamResourceDiscoveryCommandInput, AssociateIpamResourceDiscoveryCommandOutput> { | ||
this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize)); | ||
this.middlewareStack.use( | ||
getEndpointPlugin(configuration, AssociateIpamResourceDiscoveryCommand.getEndpointParameterInstructions()) | ||
); | ||
|
||
const stack = clientStack.concat(this.middlewareStack); | ||
|
||
const { logger } = configuration; | ||
const clientName = "EC2Client"; | ||
const commandName = "AssociateIpamResourceDiscoveryCommand"; | ||
const handlerExecutionContext: HandlerExecutionContext = { | ||
logger, | ||
clientName, | ||
commandName, | ||
inputFilterSensitiveLog: AssociateIpamResourceDiscoveryRequestFilterSensitiveLog, | ||
outputFilterSensitiveLog: AssociateIpamResourceDiscoveryResultFilterSensitiveLog, | ||
}; | ||
const { requestHandler } = configuration; | ||
return stack.resolve( | ||
(request: FinalizeHandlerArguments<any>) => | ||
requestHandler.handle(request.request as __HttpRequest, options || {}), | ||
handlerExecutionContext | ||
); | ||
} | ||
|
||
private serialize( | ||
input: AssociateIpamResourceDiscoveryCommandInput, | ||
context: __SerdeContext | ||
): Promise<__HttpRequest> { | ||
return serializeAws_ec2AssociateIpamResourceDiscoveryCommand(input, context); | ||
} | ||
|
||
private deserialize( | ||
output: __HttpResponse, | ||
context: __SerdeContext | ||
): Promise<AssociateIpamResourceDiscoveryCommandOutput> { | ||
return deserializeAws_ec2AssociateIpamResourceDiscoveryCommand(output, context); | ||
} | ||
|
||
// Start section: command_body_extra | ||
// End section: command_body_extra | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.