Skip to content

Conversation

@a-hilaly
Copy link
Member

@a-hilaly a-hilaly commented Nov 4, 2022

Currently the generated sdk code throws a simple error when sdkUpdate
is not implemented. This is only observable in the controller logs and
users are not able to read this information from their resource's
status/conditions.

This patch forces sdkUpdate to return a terminal error instead of a
normal error.
Fixes aws-controllers-k8s/community#1521

By submitting this pull request, I confirm that my contribution is made
under the terms of the Apache 2.0 license.

@a-hilaly
Copy link
Member Author

a-hilaly commented Nov 4, 2022

This is expected to break some e2e tests in some controllers.
/hold

@ack-bot ack-bot added the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Nov 4, 2022
@a-hilaly a-hilaly force-pushed the update/terminal-condition branch from 1eb464c to 5abe4e2 Compare November 4, 2022 16:08
@a-hilaly
Copy link
Member Author

a-hilaly commented Nov 4, 2022

/test unit-test

@a-hilaly
Copy link
Member Author

a-hilaly commented Nov 4, 2022

/retest

1 similar comment
@a-hilaly
Copy link
Member Author

/retest

@RedbackThomson
Copy link
Contributor

/approve

Let me know if you would like me to merge this

@jaypipes
Copy link
Collaborator

@RedbackThomson yes, let's merge this.

Copy link
Collaborator

@jaypipes jaypipes left a comment

Choose a reason for hiding this comment

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

👍

latest *resource,
delta *ackcompare.Delta,
) (*resource, error) {
// TODO(jaypipes): Figure this out...
Copy link
Collaborator

Choose a reason for hiding this comment

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

You might even want to remove this comment now.

Currently the generated sdk code throws a simple error when `sdkUpdate`
is not implemented. This is only observable in the controller logs and
users are not able to read this information from their resource's
status/conditions.

This patch forces `sdkUpdate` to return a terminal error instead of a
normal error.

Fixes aws-controllers-k8s/community#1521

Signed-off-by: Amine Hilaly <hilalyamine@gmail.com>
@a-hilaly a-hilaly force-pushed the update/terminal-condition branch from 5abe4e2 to 2e58e5c Compare January 19, 2023 16:07
@a-hilaly
Copy link
Member Author

/unhold

@a-hilaly
Copy link
Member Author

/hold cancel

@ack-bot ack-bot removed the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Jan 19, 2023
@a-hilaly
Copy link
Member Author

@RedbackThomson @jaypipes i'm not sure but this PR can break few e2e tests for controllers relying on condition assertions.. we'll see..

@a-hilaly a-hilaly requested review from jljaco and removed request for brycahta January 19, 2023 16:11
@a-hilaly
Copy link
Member Author

/retest

@RedbackThomson
Copy link
Contributor

/lgtm
Let's get this baby out there!

@ack-bot ack-bot added the lgtm Indicates that a PR is ready to be merged. label Jan 25, 2023
@ack-bot
Copy link
Collaborator

ack-bot commented Jan 25, 2023

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: A-Hilaly, jaypipes, RedbackThomson

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:
  • OWNERS [A-Hilaly,RedbackThomson]

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@ack-bot ack-bot merged commit fd06571 into aws-controllers-k8s:main Jan 25, 2023
@embano1
Copy link
Member

embano1 commented Jan 26, 2023

Nice, thx!

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

Labels

approved lgtm Indicates that a PR is ready to be merged.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Inform users about NotImplemented features using conditions

5 participants