[backport camel-4.14.x] CAMEL-23578: camel-web3j - align Exchange header constant names with Camel naming convention#23570
Merged
oscerd merged 1 commit intoMay 28, 2026
Conversation
davsclaus
approved these changes
May 27, 2026
8fb097b to
65d2287
Compare
…Camel naming convention (apache#23435) Renames the Exchange header string values in Web3jConstants from non-Camel prefixed values (OPERATION, FROM_ADDRESS, TO_ADDRESS, VALUE, SIGNED_TRANSACTION_DATA, SHA3_HASH_OF_DATA_TO_SIGN, ETH_HASHRATE, GAS_PRICE, GAS_LIMIT, ...) to CamelWeb3j<Name>, following the convention used across the rest of the Camel component catalog and matching the pattern established in CAMEL-23526 (camel-cxf), CAMEL-23522 (camel-mail), CAMEL-23461 (camel-aws-bedrock), CAMEL-23532 (camel-vertx-websocket / camel-atmosphere-websocket / camel-iggy), and CAMEL-23576 (camel-jira). The Java field names (OPERATION, FROM_ADDRESS, ...) are unchanged so routes referencing the constants symbolically continue to work; routes using the literal string values must be updated (documented in the 4.21 upgrade guide). The producer-side dispatch operation identifiers (WEB3_CLIENT_VERSION, ETH_GAS_PRICE, ETH_SEND_TRANSACTION, ...) keep their previous string values because they are operation enum values rather than Exchange header names; only ETH_HASHRATE is dual-purpose (both an operation identifier and an input header) and is therefore renamed alongside the other header names. The OPERATION constant gains an @metadata annotation so it now appears in the catalog as the producer dispatch header. The generated Endpoint DSL header accessors on Web3jHeaderNameBuilder have been renamed accordingly (fromAddress() -> web3jFromAddress(), toAddress() -> web3jToAddress(), ethHashrate() -> web3jEthHashrate(), iD() -> web3jId(), ...). Updates the tests that used Web3jConstants.OPERATION.toLowerCase() as the endpoint URI parameter name to use the literal "operation" parameter (the URI parameter controls the configuration.operation field and is unrelated to the header rename). Tracker: CAMEL-23577 Reported by Claude Code on behalf of Andrea Cosentino Signed-off-by: Andrea Cosentino <ancosen@gmail.com>
65d2287 to
06dd946
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Backports #23435 to
camel-4.14.x. Standard 4_21 → 4_14 guide-file adaptation. ~38@Metadata-annotated header values renamed toCamelWeb3j*prefix; producer operation-enum identifiers kept;OPERATIONconstant gains@Metadata. Tests updated for the URI-param-vs-header distinction (10 tests). mvn test passes on 4.14.x.Tracker: CAMEL-23577
Reported by Claude Code on behalf of Andrea Cosentino