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

fix(delete): Remove Deletion Polling #2

Closed
wants to merge 2 commits into from

Conversation

jessedoyle
Copy link

Hi there! We noticed an issue deleting Lex bot resources when using this custom resource due to the polling/async behaviour in the crhelper library.

I've tested the changes in the PR against our own larger bot definition and they seem to correctly delete the resource with the polling strategy removed.

Issue #, if available:

resolves: #1

Description of changes:

  • There is an 8KB limit to AWS::Events::Rule resources that are
    created by the crhelper library to implement a polling
    strategy for the custom resource.
  • The polling strategies for update and create were previously
    removed in commit ad497ce, but
    the poll_delete function was not removed.
  • For larger bot definitions (ie. > 8KB), the custom resource
    correctly creates and updates the bot resource, but it will
    fail on deletion with an error message of:
'targets.1.member.input' failed to satisfy constraint:

Member must have length less than or equal to 8192
  • To resolve this issue, simply remove the poll_delete function
    and update the delete_resource function to wait for the bot
    and the bot alias to be fully deleted.

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

Jesse Doyle added 2 commits September 24, 2021 11:53
* There is an 8KB limit to `AWS::Events::Rule` resources that are
  created by the  `crhelper` library to implement a polling
  strategy for the custom resource.
* The polling strategies for `update` and `create` were previously
  removed in commit ad497ce, but
  the `poll_delete` function was not removed.
* For larger bot definitions (ie. > 8KB), the custom resource
  correctly creates and updates the bot resource, but it will
  fail on deletion with an error message of:

```
'targets.1.member.input' failed to satisfy constraint:

Member must have length less than or equal to 8192
```
* To resolve this issue, simply remove the `poll_delete` function
  and update the `delete_resource` function to wait for the bot
  and the bot alias to be fully deleted.

resolves: aws-samples#1
* Resolve lint violations that were flagged when running the
  `lint` make target.
@jessedoyle
Copy link
Author

jessedoyle commented Sep 24, 2021

Pinging @atoa - it looks like you have created all the commits in this repo.

Please let me know what you think of the change, I'm happy to make any modifications!

@jessedoyle jessedoyle closed this Sep 13, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

poll_delete - Breaks with Large Bot Definitions
1 participant