Skip to content
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
12 changes: 6 additions & 6 deletions apis/v1alpha1/ack-generate-metadata.yaml
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
ack_generate_info:
build_date: "2021-07-01T01:00:26Z"
build_hash: 9fec5f08628d5dcc3af38d517ea014930b1ae39d
build_date: "2021-07-16T03:54:07Z"
build_hash: 7832e9aa4a48565302cd440f4cdf2267f04adfed
go_version: go1.15.2 darwin/amd64
version: v0.3.1
api_directory_checksum: a0e397840365dfef9f86900d211b96e5040cf6a9
version: v0.5.0
api_directory_checksum: 04701e412e7e4597466c1d56571be2c5de2b1e27
api_version: v1alpha1
aws_sdk_go_version: ""
generator_config_info:
file_checksum: fa5597fbe4affa148d62ff2079b8d12ac1e07098
file_checksum: cc29e8be7c6f65ef2f8db75fc3752adbf18590df
original_file_name: generator.yaml
last_modification:
reason: API generation
timestamp: 2021-07-01 01:00:35.012299 +0000 UTC
timestamp: 2021-07-16 03:54:15.20368 +0000 UTC
13 changes: 13 additions & 0 deletions apis/v1alpha1/generator.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -55,13 +55,20 @@ resources:
path: Events
AuthToken:
is_secret: true
LogDeliveryConfigurations:
is_read_only: true
from:
operation: CreateReplicationGroup
path: ReplicationGroup.LogDeliveryConfigurations
hooks:
sdk_read_many_post_set_output:
code: "rm.updateSpecFields(ctx, resp.ReplicationGroups[0], &resource{ko})"
sdk_delete_pre_build_request:
template_path: hooks/sdk_delete_pre_build_request.go.tpl
sdk_delete_post_request:
template_path: hooks/sdk_delete_post_request.go.tpl
sdk_update_post_build_request:
template_path: hooks/sdk_update_post_build_request.go.tpl
Snapshot:
update_conditions_custom_method_name: CustomUpdateConditions
exceptions:
Expand Down Expand Up @@ -203,3 +210,9 @@ ignore:
- ModifyReplicationGroupInput.SecurityGroupIds
- ModifyReplicationGroupInput.EngineVersion
- CreateReplicationGroupInput.GlobalReplicationGroupId
- CreateSnapshotInput.Tags
- CreateCacheParameterGroupInput.Tags
- CreateCacheSubnetGroupInput.Tags
- CreateReplicationGroupInput.Tags
- CreateUserInput.Tags
- CreateUserGroupInput.Tags
29 changes: 28 additions & 1 deletion cmd/controller/main.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ module github.com/aws-controllers-k8s/elasticache-controller
go 1.14

require (
github.com/aws-controllers-k8s/runtime v0.2.3
github.com/aws-controllers-k8s/runtime v0.6.0
github.com/aws/aws-sdk-go v1.38.52
github.com/ghodss/yaml v1.0.0
github.com/go-logr/logr v0.1.0
Expand Down
4 changes: 2 additions & 2 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,8 @@ github.com/andreyvit/diff v0.0.0-20170406064948-c7f18ee00883/go.mod h1:rCTlJbsFo
github.com/armon/consul-api v0.0.0-20180202201655-eb2c6b5be1b6/go.mod h1:grANhF5doyWs3UAsr3K4I6qtAmlQcZDesFNEHPZAzj8=
github.com/asaskevich/govalidator v0.0.0-20180720115003-f9ffefc3facf/go.mod h1:lB+ZfQJz7igIIfQNfa7Ml4HSf2uFQQRzpGGRXenZAgY=
github.com/asaskevich/govalidator v0.0.0-20190424111038-f61b66f89f4a/go.mod h1:lB+ZfQJz7igIIfQNfa7Ml4HSf2uFQQRzpGGRXenZAgY=
github.com/aws-controllers-k8s/runtime v0.2.3 h1:pDDSXOJj5QLlC9OcgnGujeocQEg5U1oqQw3kUSDefLU=
github.com/aws-controllers-k8s/runtime v0.2.3/go.mod h1:xA2F18PJerBHaqrS4de1lpP7skeSMeStkmh+3x5sWvw=
github.com/aws-controllers-k8s/runtime v0.6.0 h1:Up9pn9FfItYiItiSdT+FOfHQNKO8oSb5GU8pKH9JF8E=
github.com/aws-controllers-k8s/runtime v0.6.0/go.mod h1:xA2F18PJerBHaqrS4de1lpP7skeSMeStkmh+3x5sWvw=
github.com/aws/aws-sdk-go v1.37.4/go.mod h1:hcU610XS61/+aQV88ixoOzUoG7v3b31pl2zKMmprdro=
github.com/aws/aws-sdk-go v1.38.52 h1:7NKcUyTG/CyDX835kq04DDNe8vXaJhbGW8ThemHb18A=
github.com/aws/aws-sdk-go v1.38.52/go.mod h1:hcU610XS61/+aQV88ixoOzUoG7v3b31pl2zKMmprdro=
Expand Down
5 changes: 3 additions & 2 deletions pkg/resource/cache_parameter_group/manager.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 3 additions & 2 deletions pkg/resource/cache_parameter_group/resource.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

10 changes: 6 additions & 4 deletions pkg/resource/cache_parameter_group/sdk.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 3 additions & 2 deletions pkg/resource/cache_subnet_group/manager.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 3 additions & 2 deletions pkg/resource/cache_subnet_group/resource.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

10 changes: 6 additions & 4 deletions pkg/resource/cache_subnet_group/sdk.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 3 additions & 2 deletions pkg/resource/replication_group/manager.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 3 additions & 2 deletions pkg/resource/replication_group/resource.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

22 changes: 11 additions & 11 deletions pkg/resource/replication_group/sdk.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

15 changes: 4 additions & 11 deletions pkg/resource/replication_group/testdata/test_suite.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -122,9 +122,8 @@ tests:
code: ReplicationGroupNotFoundFault
message: "ReplicationGroup rg-cmd not found"
invoke: Delete
expect: # for the delete case we don't expect a new latest state or a non-nil error
latest_state: nil
error: nil
expect:
error: "Delete is in progress."
- name: "DeleteInitiated"
description: "Delete cluster mode-disabled RG. RG moves from available to deleting state."
given:
Expand All @@ -134,22 +133,16 @@ tests:
output_fixture: "replication_group/delete/rg_cmd_delete_initiated.json"
- operation: DescribeReplicationGroupsWithContext
output_fixture: "replication_group/read_one/rg_cmd_delete_initiated.json"
- operation: ListAllowedNodeTypeModifications
output_fixture: "allowed_node_types/read_many/rg_cmd_allowed_node_types.json"
- operation: DescribeEventsWithContext
output_fixture: "events/read_many/rg_cmd_events.json"
invoke: Delete
expect: # for the delete case we don't expect a new latest state or a non-nil error
latest_state: nil
expect:
Copy link
Contributor

Choose a reason for hiding this comment

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

As there is no call to sdkFind() inside sdkDelete(), there is no need to mock DescribeReplicationGroupsWithContext, ListAllowedNodeTypeModifications and ListAllowedNodeTypeModifications service APIs.

error: "Delete is in progress."
- name: "Deleting"
description: "Delete cluster mode-disabled RG. Retry scenario, RG is in deleting state."
given:
desired_state: "replication_group/cr/rg_cmd_delete_initiated.yaml"
svc_api:
invoke: Delete
expect: # for the delete case we don't expect a new latest state or a non-nil error
latest_state: nil
expect:
error: "Delete is in progress."
- name: Cluster mode enabled replication group
description: Cluster mode enabled replication group CRUD tests
Expand Down
5 changes: 3 additions & 2 deletions pkg/resource/snapshot/manager.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 3 additions & 2 deletions pkg/resource/snapshot/resource.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

10 changes: 6 additions & 4 deletions pkg/resource/snapshot/sdk.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading