Commit 32c9216
authored
fix: use deterministic sort for identifier field (#93)
@kumargauravsharma noticed that when generating the User resource
package in the elasticache-controller, sometimes he saw the Identifier
field be User.Spec.UserID. Other times it was User.Spec.UserName. Turns
out in the `pkg/model.CRD:SpecIdentifierField()` method, we were looping
over the `CRD.SpecFields` map keys (which are not ordered) instead of a
sorted list of spec field names, which is returned by the
`CRD.SpecFieldNames()` method.
By submitting this pull request, I confirm that my contribution is made under the
terms of the Apache 2.0 license.1 parent 8e82f0a commit 32c9216
1 file changed
+1
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
435 | 435 | | |
436 | 436 | | |
437 | 437 | | |
438 | | - | |
| 438 | + | |
439 | 439 | | |
440 | 440 | | |
441 | 441 | | |
| |||
0 commit comments