Skip to content

Commit e9b9621

Browse files
authored
Add support to configure EventInvokeConfig for Version (#115)
Issue #, if available: Description of changes: By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
1 parent 7708bfa commit e9b9621

14 files changed

+527
-5
lines changed

apis/v1alpha1/ack-generate-metadata.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ api_directory_checksum: 72bea0d84787d3f6fcaf7bbbc7f576a6d78b4609
77
api_version: v1alpha1
88
aws_sdk_go_version: v1.44.181
99
generator_config_info:
10-
file_checksum: 0f86b7a7f2adfe243a9aa055853514f6b4c16645
10+
file_checksum: ad8dfe3985ccc54cbe75614e8bf1381b9212bfee
1111
original_file_name: generator.yaml
1212
last_modification:
1313
reason: API generation

apis/v1alpha1/generator.yaml

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -226,15 +226,25 @@ resources:
226226
from:
227227
operation: GetFunctionConfiguration
228228
path: Version
229+
FunctionEventInvokeConfig:
230+
from:
231+
operation: PutFunctionEventInvokeConfig
232+
path: .
229233
tags:
230234
ignore: true
235+
update_operation:
236+
custom_method_name: customUpdateVersion
231237
hooks:
232238
sdk_read_one_pre_build_request:
233239
template_path: hooks/version/sdk_read_one_pre_build_request.go.tpl
234240
sdk_create_pre_build_request:
235241
template_path: hooks/version/sdk_create_pre_build_request.go.tpl
236242
sdk_create_pre_set_output:
237243
template_path: hooks/version/sdk_create_pre_set_output.go.tpl
244+
sdk_read_one_post_set_output:
245+
template_path: hooks/version/sdk_read_one_post_set_output.go.tpl
246+
sdk_create_post_set_output:
247+
template_path: hooks/version/sdk_create_post_set_output.go.tpl
238248
renames:
239249
operations:
240250
DeleteFunction:

apis/v1alpha1/version.go

Lines changed: 2 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

apis/v1alpha1/zz_generated.deepcopy.go

Lines changed: 5 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

config/crd/bases/lambda.services.k8s.aws_versions.yaml

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,37 @@ spec:
4545
description: A description for the version to override the description
4646
in the function configuration.
4747
type: string
48+
functionEventInvokeConfig:
49+
properties:
50+
destinationConfig:
51+
description: A configuration object that specifies the destination
52+
of an event after Lambda processes it.
53+
properties:
54+
onFailure:
55+
description: A destination for events that failed processing.
56+
properties:
57+
destination:
58+
type: string
59+
type: object
60+
onSuccess:
61+
description: A destination for events that were processed
62+
successfully.
63+
properties:
64+
destination:
65+
type: string
66+
type: object
67+
type: object
68+
functionName:
69+
type: string
70+
maximumEventAgeInSeconds:
71+
format: int64
72+
type: integer
73+
maximumRetryAttempts:
74+
format: int64
75+
type: integer
76+
qualifier:
77+
type: string
78+
type: object
4879
functionName:
4980
description: "The name of the Lambda function. \n Name formats \n
5081
* Function name - MyFunction. \n * Function ARN - arn:aws:lambda:us-west-2:123456789012:function:MyFunction.

generator.yaml

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -226,15 +226,25 @@ resources:
226226
from:
227227
operation: GetFunctionConfiguration
228228
path: Version
229+
FunctionEventInvokeConfig:
230+
from:
231+
operation: PutFunctionEventInvokeConfig
232+
path: .
229233
tags:
230234
ignore: true
235+
update_operation:
236+
custom_method_name: customUpdateVersion
231237
hooks:
232238
sdk_read_one_pre_build_request:
233239
template_path: hooks/version/sdk_read_one_pre_build_request.go.tpl
234240
sdk_create_pre_build_request:
235241
template_path: hooks/version/sdk_create_pre_build_request.go.tpl
236242
sdk_create_pre_set_output:
237243
template_path: hooks/version/sdk_create_pre_set_output.go.tpl
244+
sdk_read_one_post_set_output:
245+
template_path: hooks/version/sdk_read_one_post_set_output.go.tpl
246+
sdk_create_post_set_output:
247+
template_path: hooks/version/sdk_create_post_set_output.go.tpl
238248
renames:
239249
operations:
240250
DeleteFunction:

helm/crds/lambda.services.k8s.aws_versions.yaml

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,37 @@ spec:
4545
description: A description for the version to override the description
4646
in the function configuration.
4747
type: string
48+
functionEventInvokeConfig:
49+
properties:
50+
destinationConfig:
51+
description: A configuration object that specifies the destination
52+
of an event after Lambda processes it.
53+
properties:
54+
onFailure:
55+
description: A destination for events that failed processing.
56+
properties:
57+
destination:
58+
type: string
59+
type: object
60+
onSuccess:
61+
description: A destination for events that were processed
62+
successfully.
63+
properties:
64+
destination:
65+
type: string
66+
type: object
67+
type: object
68+
functionName:
69+
type: string
70+
maximumEventAgeInSeconds:
71+
format: int64
72+
type: integer
73+
maximumRetryAttempts:
74+
format: int64
75+
type: integer
76+
qualifier:
77+
type: string
78+
type: object
4879
functionName:
4980
description: "The name of the Lambda function. \n Name formats \n
5081
- Function name - MyFunction. \n - Function ARN - arn:aws:lambda:us-west-2:123456789012:function:MyFunction.

pkg/resource/version/delta.go

Lines changed: 58 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)