thedavidweng commented on PR #6667: URL: https://github.com/apache/camel-k/pull/6667#issuecomment-4664363912
Thanks for the review — you're right, my previous change was wrong. I now understand that `Status.Traits` must continue to record **executed** traits (GitOps export, platform/profile propagation, mount hot-reload all depend on it). The fix is to stop auto-inferred defaults from being written back into the serialized API trait fields. Revised approach (Option B): - **service**: `Configure()` uses a local `enabled` flag instead of `t.Enabled = new(exposeHTTPServices)` - **container**: auto `expose` goes to an unexported field; OpenShift `RunAsUser` is applied via a local variable (same pattern as `security_context` trait) without mutating `t.RunAsUser` - **trait.Apply**: restored the original merge of executed traits into `Status.Traits` Scope is limited to `container` + `service` as in #6663. Similar patterns in `knative-service`/`knative`/`cron`/`master` are noted for follow-up. Tests cover both cases: HTTP integration with no user traits → empty `Status.Traits`; explicit `container.port` → still appears in status. Ready for another look when you have time. _Claude on behalf of David Weng_ -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
