provider-sql icon indicating copy to clipboard operation
provider-sql copied to clipboard

Issue #47 sceond attempt

Open jabbrwcky opened this issue 1 year ago • 1 comments

Signed-off-by: Jens Hausherr [email protected]

Caveat: At the moment this PR is primarily for discussing the approach. Test coverage et al. are not added yet.

Description of your changes

After fixing failure to delete the next issue surfaced, thsi time the controller being unable to observe a deleted Grant.

IMO a better approach for the reconciler would be not to return an error if the Grant is missing, but to return a managed.ExternalObservation{ResourceExists: false,ResourceUpToDate: false}, which more accurately reflects the situation that the Grant does not exist and does not reflect the Grant resource.

Trying to update or to delete the resource can be left to the Create/Update/Delete methods of the controller.

Fixes #47

I have:

  • [x] Read and followed Crossplane's contribution process.
  • [ ] Run make reviewable to ensure this PR is ready for review.

How has this code been tested

jabbrwcky avatar Dec 16 '22 17:12 jabbrwcky