hxxxi-malog opened a new pull request, #6807:
URL: https://github.com/apache/camel-k/pull/6807
Fixes #6805
Removes the `logging`, `master` and `telemetry` traits, deprecated since
2.9.0, following the same removal pattern used for the Jolokia trait (#6764).
## What is removed
* Trait implementations, registrations and unit tests
(`pkg/trait/logging.go`, `master.go`, `telemetry.go`)
* Jaeger discovery support (`pkg/trait/discovery/`), only used by the
telemetry trait
* Master RBAC embedded templates (`resources/addons/master/*.tmpl`) — this
also removes an automatic RBAC creation path from the operator, in line with
the security guidance to keep RBAC under explicit deployer control
* Trait documentation pages, nav entries and autogenerated CRD/API/doc
artifacts (regenerated)
## What is kept (compatibility)
* `spec.traits` fields remain as deprecated Go fields (`DeprecatedLogging`,
`DeprecatedMaster`, `DeprecatedTelemetry`) with their original JSON names
(`logging`, `master`, `telemetry`), so existing Integrations and Pipes keep
serializing unchanged
* Configurations targeting the removed traits in `spec.traits` are ignored
with a WARN log
* Legacy trait annotations
(`trait.camel.apache.org/{logging,master,telemetry}.*`) are ignored and cleaned
up during migration, while any other unknown trait annotation still fails
validation (typo protection)
* The exported `resources.TemplateResource` API is preserved: it was only
consumed by the master trait, but it is a general-purpose public API
## Migration
* **logging** → Quarkus logging properties: `traits.logging.level=DEBUG` →
`-p quarkus.log.level=DEBUG`
* **telemetry** → Quarkus OpenTelemetry properties: `--trait
telemetry.endpoint=http://jaeger:4317` → `-p
quarkus.otel.exporter.otlp.traces.endpoint=http://jaeger:4317`
* **master** → create the required Role/RoleBinding manually, then configure:
`-p quarkus.camel.cluster.kubernetes.resource-name=<integration>-lock`
`-p quarkus.camel.cluster.kubernetes.resource-type=Lease`
`-p
quarkus.camel.cluster.kubernetes.labels."camel.apache.org/integration"=<integration-name>`
(for existing Integrations, create the manual RBAC **before** removing the
trait configuration)
## Tests
* Table-driven unit tests for all three removed traits (catalog ignores
config, trait absent from catalog)
* Legacy JSON field names round-trip and `Traits.Merge` compatibility
* Legacy annotation paths covered for Integration, IntegrationKit and Pipe
conversion
* `TestTemplateResource` restored with a neutral test fixture
* E2E usages migrated to Quarkus properties (`pipe_test.go`,
`cron_test.go`); master/telemetry e2e suites had already been migrated to
manual RBAC/properties when the traits were deprecated
## Verification
* Affected package unit tests pass (`pkg/trait`, `pkg/resources`,
`pkg/controller/pipe`, `pkg/apis/camel/v1`)
* `go vet`, `gofmt` and golangci-lint clean
* Generated artifacts verified drift-free against the pinned toolchain
(controller-gen v0.20.0); deepcopy regenerated to match CI output style;
client/CRD/Helm/docs regeneration produces no further changes
---
_Generated with assistance from Codex, then reviewed and completed by
@hxxxi-malog._
--
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]