File tree Expand file tree Collapse file tree 2 files changed +14
-0
lines changed Expand file tree Collapse file tree 2 files changed +14
-0
lines changed Original file line number Diff line number Diff line change @@ -69,6 +69,8 @@ code paths:
69
69
* convert_tags_post_to_ack_tags
70
70
* convert_tags_pre_from_ack_tags
71
71
* convert_tags_post_from_ack_tags
72
+ * pre_set_resource_identifiers
73
+ * post_set_resource_identifiers
72
74
73
75
The "pre_build_request" hooks are called BEFORE the call to construct
74
76
the Input shape that is used in the API operation and therefore BEFORE
@@ -143,6 +145,12 @@ tags into K8s resource tags
143
145
144
146
The "convert_tags_post_from_ack_tags" are called after converting the ACK
145
147
tags into K8s resource tags
148
+
149
+ The "pre_set_resource_identifiers" hook is called before the generated code
150
+ that sets the resource identifiers to uniquely identify a resource
151
+
152
+ The "post_set_resource_identifiers" hook is called after the generated code
153
+ that sets the resource identifiers to uniquely identify a resource
146
154
*/
147
155
148
156
// ResourceHookCode returns a string with custom callback code for a resource
Original file line number Diff line number Diff line change @@ -72,7 +72,13 @@ func (r *resource) SetStatus(desired acktypes.AWSResource) {
72
72
// SetIdentifiers sets the Spec or Status field that is referenced as the unique
73
73
// resource identifier
74
74
func (r *resource) SetIdentifiers(identifier *ackv1alpha1.AWSIdentifiers) error {
75
+ {{- if $hookCode := Hook .CRD " pre_set_resource_identifiers" } }
76
+ { { $hookCode } }
77
+ { {- end } }
75
78
{ {- GoCodeSetResourceIdentifiers .CRD " identifier" " r.ko" 1} }
79
+ { {- if $hookCode := Hook .CRD " post_set_resource_identifiers" } }
80
+ { { $hookCode } }
81
+ { {- end } }
76
82
return nil
77
83
}
78
84
You can’t perform that action at this time.
0 commit comments