Skip to content

CAMEL-20061: SMPP interface version can now be configured#11930

Merged
davsclaus merged 3 commits intoapache:mainfrom
brunoriemenschneider:CAMEL-20061
Nov 9, 2023
Merged

CAMEL-20061: SMPP interface version can now be configured#11930
davsclaus merged 3 commits intoapache:mainfrom
brunoriemenschneider:CAMEL-20061

Conversation

@brunoriemenschneider
Copy link
Contributor

Interface Version functionality as supported by jSMPP is adopted with @UriParam configuration parameter. The default value (interface version 3.4) remains unchanged.

The configuration value is parsed as String and converted to hex byte (which is used at protocol level) at a later stage when passed to jSMPP, as Camel does not support hexadecimal byte parsing from config values at this point. (I think the issue is in the Camel support component: the PropertyConfigurerSupport.class does not implement this case)

Description

JIRA Ticket CAMEL-20061
The interface version of the SMPP protocol binding can now be specified via configuration parameter. The configuration paramter is simply passed to the underlying library jSMPP as input to the wrapper class BindParameter, which is used for the bind message to establish a connection to an SMSC.

The prior default value of SMPP v3.4 is retained as default value.

The SMPP protocol defines the bind parameter interface_version as hexadecimal byte. This implementation reads the 0xXX byte value as String, and converts it to byte when passed to jSMPP. This has been done because AFAIK the current implementation in the Camel support component the ProprtyConfigurerSupport.class seems not to support hexadecimal byte configurators.

Target

  • I checked that the commit is targeting the correct branch (note that Camel 3 uses camel-3.x, whereas Camel 4 uses the main branch)

Tracking

  • If this is a large change, bug fix, or code improvement, I checked there is a JIRA issue filed for the change (usually before you start working on it).

Apache Camel coding standards and style

  • I checked that each commit in the pull request has a meaningful subject line and body.
  • I have run mvn clean install -DskipTests locally and I have committed all auto-generated changes

Interface Version functionality as supported by jSMPP is adopted with @UriParam configuration parameter. The default value (interface version 3.4) remains unchanged.

The configuration value is parsed as String and converted to hex byte (which is used at protocol level) at a later stage when passed to jSMPP, as Camel does not support hexadecimal byte parsing from config values at this point. (I think the issue is in the Camel support component: the PropertyConfigurerSupport.class does not implement this case)
@github-actions
Copy link
Contributor

github-actions bot commented Nov 7, 2023

🌟 Thank you for your contribution to the Apache Camel project! 🌟

🤖 CI automation will test this PR automatically.

🐫 Apache Camel Committers, please review the following items:

  • First-time contributors require MANUAL approval for the GitHub Actions to run

  • You can use the command /component-test (camel-)component-name1 (camel-)component-name2.. to request a test from the test bot.

  • You can label PRs using build-all, build-dependents, skip-tests and test-dependents to fine-tune the checks executed by this PR.

  • Build and test logs are available in the Summary page. Only Apache Camel committers have access to the summary.

  • ⚠️ Be careful when sharing logs. Review their contents before sharing them publicly.

Copy link
Contributor

@oscerd oscerd left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Minor findings, the logic is fine. We could have some troubles with docs generation

- Deleted redundant .md
- Added short doc comment about the functionality
- altered syntax in doc-relevant comment in configuration file
@github-actions github-actions bot removed the docs label Nov 7, 2023
- replaced the SMPP protocol-level version codes 0x00, 0x33, 0x34, and 0x50 in the configuration String by "legacy", "3.3", "3.4", and "5.0", respectively
@davsclaus davsclaus merged commit 9d1cd99 into apache:main Nov 9, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants