Commit b49da34
authored
RDS: Add support for create DBInstanceReadReplica (#92)
Fixes aws-controllers-k8s/community#893
**Description of changes:**
It's from a old pr. #84
This pr is adding ability to allow create DBInstanceReadReplica, api call: https://docs.aws.amazon.com/AmazonRDS/latest/APIReference/API_CreateDBInstanceReadReplica.html
Some small bug fix:
1. copy over newCreateDBInstanceReadReplicaInput instead asking template generate it, so we can set `PerformanceInsightsEnabled` directly instead of using `EnablePerformanceInsights`
2. add extra nil check here https://github.com/aws-controllers-k8s/rds-controller/blob/d72e06ba7e1fc24eed5f02a36b367fc4c4bf9354/pkg/resource/db_instance/hooks.go#L207
3. update status to spec for cluster's allocated storage . https://github.com/aws-controllers-k8s/rds-controller/blob/d72e06ba7e1fc24eed5f02a36b367fc4c4bf9354/pkg/resource/db_cluster/custom_update.go#L108
**Testing part:**
Tested with successful creation of
- same region + encrypted source instance
- same region + unencrypted source instance
- cross region + encrypted source instance
- cross region + unencrypted source instance
**Notes:**
I don't have e2e test for this case yet which is because I'm blocked on this issue. aws-controllers-k8s/community#1325
Will add e2e tests after 1325 issue is resolved.
Also this pr has a dependency pr: aws-controllers-k8s/code-generator#339
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.1 parent d72e06b commit b49da34
File tree
14 files changed
+1311
-55
lines changed- apis/v1alpha1
- config/crd/bases
- helm/crds
- pkg/resource
- db_cluster
- db_instance
- templates/hooks/db_instance
14 files changed
+1311
-55
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | | - | |
| 2 | + | |
3 | 3 | | |
4 | 4 | | |
5 | 5 | | |
6 | | - | |
| 6 | + | |
7 | 7 | | |
8 | 8 | | |
9 | 9 | | |
10 | | - | |
| 10 | + | |
11 | 11 | | |
12 | 12 | | |
13 | 13 | | |
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
175 | 175 | | |
176 | 176 | | |
177 | 177 | | |
| 178 | + | |
178 | 179 | | |
179 | 180 | | |
180 | 181 | | |
| |||
183 | 184 | | |
184 | 185 | | |
185 | 186 | | |
| 187 | + | |
| 188 | + | |
| 189 | + | |
| 190 | + | |
| 191 | + | |
| 192 | + | |
| 193 | + | |
| 194 | + | |
| 195 | + | |
| 196 | + | |
| 197 | + | |
| 198 | + | |
| 199 | + | |
| 200 | + | |
| 201 | + | |
| 202 | + | |
| 203 | + | |
| 204 | + | |
| 205 | + | |
| 206 | + | |
| 207 | + | |
186 | 208 | | |
187 | 209 | | |
188 | 210 | | |
| |||
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
0 commit comments