Skip to content

[backport camel-4.18.x] CAMEL-23508: camel-elasticsearch-rest-client - align Exchange header constant names with Camel naming convention#23244

Merged
oscerd merged 1 commit into
apache:camel-4.18.xfrom
oscerd:backport/23212-to-camel-4.18.x
May 15, 2026
Merged

[backport camel-4.18.x] CAMEL-23508: camel-elasticsearch-rest-client - align Exchange header constant names with Camel naming convention#23244
oscerd merged 1 commit into
apache:camel-4.18.xfrom
oscerd:backport/23212-to-camel-4.18.x

Conversation

@oscerd
Copy link
Copy Markdown
Contributor

@oscerd oscerd commented May 15, 2026

Backport of #23212

Cherry-pick of #23212 onto camel-4.18.x.

Original PR: #23212CAMEL-23508: camel-elasticsearch-rest-client - align Exchange header constant names with Camel naming convention
Original author: @oscerd
Target branch: camel-4.18.x
Fix versions: 4.14.8, 4.18.3, 4.21.0

What this changes

Renames the Exchange header string values in ElasticSearchRestClientConstant
to the Camel naming convention. The Java field names are unchanged, so
routes referencing the constants symbolically continue to work without
changes. Routes that use the literal string value must be updated.

Constant Previous value New value
ElasticSearchRestClientConstant.ID ID CamelElasticsearchId
ElasticSearchRestClientConstant.SEARCH_QUERY SEARCH_QUERY CamelElasticsearchSearchQuery
ElasticSearchRestClientConstant.INDEX_SETTINGS INDEX_SETTINGS CamelElasticsearchIndexSettings
ElasticSearchRestClientConstant.INDEX_NAME INDEX_NAME CamelElasticsearchIndexName
ElasticSearchRestClientConstant.OPERATION OPERATION CamelElasticsearchOperation

Cherry-pick notes

The original commit also modified camel-4x-upgrade-guide-4_21.adoc.
That file does not exist on camel-4.18.x (it is canonical on main
across all releases), so it was dropped from this backport. A separate
doc-sync PR against main adds the matching
camel-4x-upgrade-guide-4_18.adoc entry for this rename.

Test plan

  • Full reactor mvn clean install -DskipTests succeeds on camel-4.18.x after the cherry-pick.

Claude Code on behalf of Andrea Cosentino

…constant names with Camel naming convention

Rename the Exchange header string values in ElasticSearchRestClientConstant
from raw uppercase (ID, SEARCH_QUERY, INDEX_SETTINGS, INDEX_NAME, OPERATION)
to the Camel naming convention (CamelElasticsearchId,
CamelElasticsearchSearchQuery, CamelElasticsearchIndexSettings,
CamelElasticsearchIndexName, CamelElasticsearchOperation). The Java field
names are unchanged so routes referencing the constants symbolically
continue to work. Routes using the literal string value must be updated.

Adds an entry to the 4.21 upgrade guide and regenerates the affected
component metadata, catalog, and endpoint DSL.

Closes apache#23212
@oscerd oscerd merged commit ff88400 into apache:camel-4.18.x May 15, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant