Skip to content

DynamoDB backend calls CreateTable API for an existed table raise AWS cost #7710

Closed as not planned

Description

@lyajedi

Checklist

  • I have checked the issues list
    for similar or identical enhancement to an existing feature.
  • I have checked the pull requests list
    for existing proposed enhancements.
  • I have checked the commit log
    to find out if the if the same enhancement was already implemented in the
    master branch.
  • I have included all related issues and possible duplicate issues in this issue
    (If there are none, check this box anyway).

Related Issues and Possible Duplicates

Related Issues

Possible Duplicates

  • None

Brief Summary

https://github.com/celery/celery/blob/v5.2.7/celery/backends/dynamodb.py#L204
This always calls CreatTable even the table existed already.
Each call will have an AWS CloudTrail management event for CreateTable API call with ResourceInUseException error.
Each CouldTrail management event cost 0.00002 USD in AWS US West (Oregon) region.
I have 10M+ tasks everyday and they produce 10M+ such events, and AWS charges me for 200+ USD.

Design

Architectural Considerations

None

Proposed Behavior

Just like what proposed in #6622, check existence of table with another boto3 call first instead of just calling create table

Proposed UI/UX

Diagrams

N/A

Alternatives

None

Activity

  1. open-collective-bot commented on Aug 16, 2022

    @open-collective-bot

    Hey @lyajedi 👋,
    Thank you for opening an issue. We will get back to you as soon as we can.
    Also, check out our Open Collective and consider backing us - every little helps!

    We also offer priority support for our sponsors.
    If you require immediate assistance please consider sponsoring us.

  2. auvipy commented on Aug 16, 2022

    @auvipy
    Member

    I am going to close this as duplicate, let continue discussion there? can you try to contribute the fix?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions