oscerd opened a new pull request, #23629:
URL: https://github.com/apache/camel/pull/23629

   Backport of #23602 (CAMEL-23584) to the `camel-4.18.x` maintenance branch.
   
   ## Summary
   
   Renames the Exchange header string values in `KafkaConstants` from the 
non-Camel-prefixed `kafka.*` namespace to the project-wide `CamelKafka*` 
PascalCase convention, completing the camel-kafka sub-task under the 
[CAMEL-23577](https://issues.apache.org/jira/browse/CAMEL-23577) umbrella 
header-naming-convention sweep.
   
   | Constant | Previous value | New value |
   |----------|---------------|-----------|
   | `PARTITION_KEY` | `kafka.PARTITION_KEY` | `CamelKafkaPartitionKey` |
   | `PARTITION` | `kafka.PARTITION` | `CamelKafkaPartition` |
   | `KEY` | `kafka.KEY` | `CamelKafkaKey` |
   | `TOPIC` | `kafka.TOPIC` | `CamelKafkaTopic` |
   | `OVERRIDE_TOPIC` | `kafka.OVERRIDE_TOPIC` | `CamelKafkaOverrideTopic` |
   | `OFFSET` | `kafka.OFFSET` | `CamelKafkaOffset` |
   | `HEADERS` | `kafka.HEADERS` | `CamelKafkaHeaders` |
   | `LAST_RECORD_BEFORE_COMMIT` | `kafka.LAST_RECORD_BEFORE_COMMIT` | 
`CamelKafkaLastRecordBeforeCommit` |
   | `LAST_POLL_RECORD` | `kafka.LAST_POLL_RECORD` | `CamelKafkaLastPollRecord` 
|
   | `TIMESTAMP` | `kafka.TIMESTAMP` | `CamelKafkaTimestamp` |
   | `OVERRIDE_TIMESTAMP` | `kafka.OVERRIDE_TIMESTAMP` | 
`CamelKafkaOverrideTimestamp` |
   | `KAFKA_RECORD_META` | `kafka.RECORD_META` | `CamelKafkaRecordMeta` |
   
   ## Backwards-compatibility
   
   - Java field names are unchanged → routes using the symbolic constants are 
unaffected.
   - Routes hard-coding the literal `kafka.*` header strings must move to the 
new `CamelKafka*` values.
   - The Endpoint DSL header accessor **method names** (`kafkaOverrideTopic()`, 
etc.) are unchanged; only the returned string value reflects the new convention.
   
   ## Notes for this backport
   
   - The version-specific upgrade-guide entry is added on the **main** branch 
(per the backport upgrade-guide policy), **not** on this maintenance branch.
   - Keeps the bundled transform classes, `KafkaHeaderDeserializer`, the 
`camel-tracing` / `camel-telemetry` `KafkaSpanDecorator` copies, and the 
`camel-opentelemetry2` mock Kafka producer / `SpanKindTest` in sync. 
Regenerates the catalog, endpoint DSL, and important-headers artifacts.
   
   ## Test plan
   
   - [x] camel-kafka unit tests (`KafkaProducerTest`, `RegexRouterTest`, 
transform tests, `KafkaHeaderDeserializerTest`) — pass
   - [x] `camel-opentelemetry2` `SpanKindTest` (exercises the inherited 
camel-telemetry `KafkaSpanDecorator`) — pass
   - [x] Full reactor `mvn clean install -DskipTests` from root — passes, all 
downstream generators regenerate cleanly
   
   _Reported by Claude Code on behalf of Andrea Cosentino_


-- 
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]

Reply via email to