Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore(appconfig): fix some awslint errors, explicitly exempt others #28671

Merged
merged 6 commits into from
Jan 18, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
34 changes: 29 additions & 5 deletions packages/@aws-cdk/aws-appconfig-alpha/awslint.json
Original file line number Diff line number Diff line change
Expand Up @@ -25,10 +25,34 @@
"docs-public-apis:@aws-cdk/aws-appconfig-alpha.IConfiguration",
"docs-public-apis:@aws-cdk/aws-appconfig-alpha.IApplication",

"ref-via-interface:@aws-cdk/aws-appconfig-alpha.Application.addAgentToEcs.taskDef",
"events-in-interface",
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

How is this awslint error fixed in this PR?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"events-method-signature",
"events-generic",
"from-signature:@aws-cdk/aws-appconfig-alpha.DeploymentStrategy.fromDeploymentStrategyId.params[2]"
"from-signature:@aws-cdk/aws-appconfig-alpha.DeploymentStrategy.fromDeploymentStrategyId.params[2]",
"events-method-signature:@aws-cdk/aws-appconfig-alpha.Application.on",
"events-method-signature:@aws-cdk/aws-appconfig-alpha.Application.onDeploymentBaking*",
"events-method-signature:@aws-cdk/aws-appconfig-alpha.Application.onDeploymentComplete*",
"events-method-signature:@aws-cdk/aws-appconfig-alpha.Application.onDeploymentRolledBack*",
"events-method-signature:@aws-cdk/aws-appconfig-alpha.Application.onDeploymentStart*",
"events-method-signature:@aws-cdk/aws-appconfig-alpha.Application.onDeploymentStep*",
"events-method-signature:@aws-cdk/aws-appconfig-alpha.Environment.on",
"events-method-signature:@aws-cdk/aws-appconfig-alpha.Environment.onDeploymentBaking*",
"events-method-signature:@aws-cdk/aws-appconfig-alpha.Environment.onDeploymentComplete*",
"events-method-signature:@aws-cdk/aws-appconfig-alpha.Environment.onDeploymentRolledBack*",
"events-method-signature:@aws-cdk/aws-appconfig-alpha.Environment.onDeploymentStart*",
"events-method-signature:@aws-cdk/aws-appconfig-alpha.Environment.onDeploymentStep*",
"events-method-signature:@aws-cdk/aws-appconfig-alpha.HostedConfiguration.on",
"events-method-signature:@aws-cdk/aws-appconfig-alpha.HostedConfiguration.onDeploymentBaking*",
"events-method-signature:@aws-cdk/aws-appconfig-alpha.HostedConfiguration.onDeploymentComplete*",
"events-method-signature:@aws-cdk/aws-appconfig-alpha.HostedConfiguration.onDeploymentRolledBack*",
"events-method-signature:@aws-cdk/aws-appconfig-alpha.HostedConfiguration.onDeploymentStart*",
"events-method-signature:@aws-cdk/aws-appconfig-alpha.HostedConfiguration.onDeploymentStep*",
"events-method-signature:@aws-cdk/aws-appconfig-alpha.SourcedConfiguration.on",
"events-method-signature:@aws-cdk/aws-appconfig-alpha.SourcedConfiguration.onDeploymentBaking*",
"events-method-signature:@aws-cdk/aws-appconfig-alpha.SourcedConfiguration.onDeploymentComplete*",
"events-method-signature:@aws-cdk/aws-appconfig-alpha.SourcedConfiguration.onDeploymentRolledBack*",
"events-method-signature:@aws-cdk/aws-appconfig-alpha.SourcedConfiguration.onDeploymentStart*",
"events-method-signature:@aws-cdk/aws-appconfig-alpha.SourcedConfiguration.onDeploymentStep*",
"events-generic:@aws-cdk/aws-appconfig-alpha.Application",
"events-generic:@aws-cdk/aws-appconfig-alpha.Environment",
"events-generic:@aws-cdk/aws-appconfig-alpha.HostedConfiguration",
"events-generic:@aws-cdk/aws-appconfig-alpha.SourcedConfiguration"
]
}
81 changes: 80 additions & 1 deletion packages/@aws-cdk/aws-appconfig-alpha/lib/application.ts
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,85 @@ export interface IApplication extends cdk.IResource {
* Returns the list of associated environments.
*/
get environments(): IEnvironment[];

/**
* Adds an extension defined by the action point and event destination
* and also creates an extension association to an application.
*
* @param actionPoint The action point which triggers the event
* @param eventDestination The event that occurs during the extension
* @param options Options for the extension
*/
on(actionPoint: ActionPoint, eventDestination: IEventDestination, options?: ExtensionOptions): void;

/**
* Adds a PRE_CREATE_HOSTED_CONFIGURATION_VERSION extension with the
* provided event destination and also creates an extension association to an application.
*
* @param eventDestination The event that occurs during the extension
* @param options Options for the extension
*/
preCreateHostedConfigurationVersion(eventDestination: IEventDestination, options?: ExtensionOptions): void;

/**
* Adds a PRE_START_DEPLOYMENT extension with the provided event destination and
* also creates an extension association to an application.
*
* @param eventDestination The event that occurs during the extension
* @param options Options for the extension
*/
preStartDeployment(eventDestination: IEventDestination, options?: ExtensionOptions): void;
/**
* Adds an ON_DEPLOYMENT_START extension with the provided event destination and
* also creates an extension association to an application.
*
* @param eventDestination The event that occurs during the extension
* @param options Options for the extension
*/
onDeploymentStart(eventDestination: IEventDestination, options?: ExtensionOptions): void;

/**
* Adds an ON_DEPLOYMENT_STEP extension with the provided event destination and
* also creates an extension association to an application.
*
* @param eventDestination The event that occurs during the extension
* @param options Options for the extension
*/
onDeploymentStep(eventDestination: IEventDestination, options?: ExtensionOptions): void;

/**
* Adds an ON_DEPLOYMENT_BAKING extension with the provided event destination and
* also creates an extension association to an application.
*
* @param eventDestination The event that occurs during the extension
* @param options Options for the extension
*/
onDeploymentBaking(eventDestination: IEventDestination, options?: ExtensionOptions): void;

/**
* Adds an ON_DEPLOYMENT_COMPLETE extension with the provided event destination and
* also creates an extension association to an application.
*
* @param eventDestination The event that occurs during the extension
* @param options Options for the extension
*/
onDeploymentComplete(eventDestination: IEventDestination, options?: ExtensionOptions): void;

/**
* Adds an ON_DEPLOYMENT_ROLLED_BACK extension with the provided event destination and
* also creates an extension association to an application.
*
* @param eventDestination The event that occurs during the extension
* @param options Options for the extension
*/
onDeploymentRolledBack(eventDestination: IEventDestination, options?: ExtensionOptions): void;

/**
* Adds an extension association to the application.
*
* @param extension The extension to create an association for
*/
addExtension(extension: IExtension): void;
}

/**
Expand Down Expand Up @@ -296,7 +375,7 @@ export class Application extends ApplicationBase {
/**
* Adds the AWS AppConfig Agent as a container to the provided ECS task definition.
*
* @param taskDef The ECS task definition
* @param taskDef The ECS task definition [disable-awslint:ref-via-interface]
kaizencc marked this conversation as resolved.
Show resolved Hide resolved
*/
public static addAgentToEcs(taskDef: ecs.TaskDefinition) {
taskDef.addContainer('AppConfigAgentContainer', {
Expand Down