Skip to content

Conversation

@kazanzhy
Copy link
Contributor

@kazanzhy kazanzhy commented Jan 17, 2022

Added AWS RDS management operators.

Based on: #20642 and #22005

The main issue that I have is how to test it. There are several options to do that:

  • use unittest.mock, but as I understand Airflow is moving from unittest pytest
  • use pytest-mock library
  • use moto library. Unfortunately mock_rds2 doesn't support operations with clusters, exports, and event subscriptions.
    I've added these methods and they are available since version moto>=3.0.2
  • use Botocore's Stubber

@kazanzhy
Copy link
Contributor Author

Hi, @dstandish.
I need your help and suggestions again :)

@kazanzhy kazanzhy force-pushed the add_aws_rds_operators branch 10 times, most recently from c7888c5 to 9af1954 Compare January 30, 2022 21:34
@kazanzhy kazanzhy force-pushed the add_aws_rds_operators branch from 9af1954 to 1e1af84 Compare January 30, 2022 23:08
@kazanzhy kazanzhy mentioned this pull request Jan 30, 2022
@kazanzhy kazanzhy force-pushed the add_aws_rds_operators branch 5 times, most recently from 57ba57c to 42b0d0f Compare February 3, 2022 22:54
@dstandish
Copy link
Contributor

Hi, @dstandish. I need your help and suggestions again :)

Hi sorry for the delay I was out for a bit then catching up on stuff.

Anything in particular you need guidance on? Or just it's ready to go and needs review.

@kazanzhy
Copy link
Contributor Author

kazanzhy commented Feb 3, 2022

Thanks for helping, @dstandish. I think it's ready for review.
Also, I'll be very happy if share your suggestions for this PR and #21231.

Talking about RdsHook (#20642), there are some strange mypy errors that are not caused by my changes.

@kazanzhy kazanzhy force-pushed the add_aws_rds_operators branch 2 times, most recently from ccb7966 to 061da0e Compare February 4, 2022 20:49
@kazanzhy kazanzhy marked this pull request as ready for review February 4, 2022 20:51
@kazanzhy kazanzhy requested a review from mik-laj as a code owner February 4, 2022 20:51
@kazanzhy kazanzhy force-pushed the add_aws_rds_operators branch from 061da0e to c935747 Compare February 4, 2022 21:12
@kazanzhy kazanzhy force-pushed the add_aws_rds_operators branch 8 times, most recently from 022ea65 to e95b0bb Compare February 21, 2022 17:26
@kazanzhy
Copy link
Contributor Author

Methods that are used in tests were implemented by me and available since version moto>=3.0.3
So constraints need to be updated to pass checks

@kazanzhy kazanzhy force-pushed the add_aws_rds_operators branch 3 times, most recently from df40cc2 to 87c99f0 Compare February 28, 2022 14:45
@kazanzhy kazanzhy force-pushed the add_aws_rds_operators branch 3 times, most recently from 5fc7b80 to 1c64923 Compare March 4, 2022 23:12
@kazanzhy kazanzhy force-pushed the add_aws_rds_operators branch from 1c64923 to 7382ba5 Compare March 5, 2022 18:04
@kazanzhy
Copy link
Contributor Author

kazanzhy commented Mar 6, 2022

The RdsHook is already merged and moto library is upgraded.
Also, I removed code duplication here and in sensors PR (#21231)

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

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants