crossplane / crossplane/upjet

Async resources skip Observe when async job is running

Open
#662 0 comments 0 reactions 0 assignees View on GitHub
bug
Dominant language
Go
Stars
481
Forks
131
Avg merge
2d 1h
Merged PRs (30d)
11

Description

### What happened?
Resources that are marked as Async skip the Observe step when an async job is running. This results in no ongoing status updates for resources that take a long time to create or update, such as EKS Cluster and Nodegroups. The AWS API returns the correct status but since the Observe step is skipped when the async job is running the Crossplane resource does not reflect the actual state of the resource.

### How can we reproduce it?
Deploy an EKS Cluster and trigger a kubernetes update. The Crossplane Cluster resource status remains "ACTIVE" while the actual resource status is "UPDATING". This makes it impossible to report the actual cluster status and requires Operations to use the AWS API to get resource status instead of relying on the Crossplane resource status.

[This](https://github.com/crossplane/upjet/blob/main/pkg/controller/external_async_tfpluginsdk.go#L119) line in the `Observe()` code is the root cause.

Is there a reason that we cannot run the resource `Observe()` function and then return the results, leaving the async job running?

Contributor guide

Open the contributing guide

Research direction

Start at pkg/controller/external_async_tfpluginsdk.go:119 and trace how Observe handles a running async job. Reproduce the behavior with an EKS Cluster during a Kubernetes update, then verify that Crossplane status reflects the AWS resource status while the async job remains active.

Written by the indexing model from the issue text.

Assessment

Tech stack
aws, go
Domain
backend, cloud
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
65/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.