What happened?
The Usage creation logic does not check to ensure that the metadata.name field is populated and can generate Usage resources with empty resourceRef.name fields for of or by or both.
How can we reproduce it?
This is mostly a problem in testing with crossplane render where the observed list of resources may be generated and could be missing the metadata.name field.
Using a set of observed resources without the metadata.name field set, run crossplane render on a composition and observe that the resourceRef.name fields are set to '""'
What environment did it happen in?
Function version: v0.5.0
What happened?
The
Usagecreation logic does not check to ensure that themetadata.namefield is populated and can generateUsageresources with emptyresourceRef.namefields foroforbyor both.How can we reproduce it?
This is mostly a problem in testing with
crossplane renderwhere the observed list of resources may be generated and could be missing themetadata.namefield.Using a set of observed resources without the
metadata.namefield set, runcrossplane renderon a composition and observe that theresourceRef.namefields are set to '""'What environment did it happen in?
Function version: v0.5.0