[Performance] Unnecessary conversions from []byte to map to []byte to struct while populating status.atProvider
Open
codegen
enhancement
is:triaged
v2
- Dominant language
- Go
- Stars
- 481
- Forks
- 131
- Avg merge
- 2d 1h
- Merged PRs (30d)
- 11
Description
### What problem are you facing?
In `controller.external.Observe` & `controller.external.Update`, looks like we are first converting a `jsoniter.RawMessage` (`[]byte`) first to `map[string]any` and then from `map[string]any` back to `[]byte`, and then from `[]byte` to `Status.AtProvider` struct.
### How could Upjet help solve your problem?
The extra marshaling/unmarshaling costs us CPU. Let's take a look if this is really necessary. Can we shorten the conversion path to `[]byte` -> `Status.AtProvider`?
Contributor guide
Assessment
This issue has not been assessed yet.