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

   Relates to [CAMEL-23647](https://issues.apache.org/jira/browse/CAMEL-23647). 
Since the full Vert.x 5 upgrade is not planned until Camel 4.24, this change 
makes some Vert.x API  usage compatible with both Vert.x 4 and 5. It will help 
Camel Quarkus move forwards with Quarkus 4 migration in advance of the Camel 
4.24 release.
   
   The scope of the changes are _**deliberately limited**_ to areas that only 
affect Camel Quarkus. The full cleanup of the Vert.x components for Vert.x will 
happen for Camel 4.24.
   
   Some noteworthy changes:
   
   **camel-vertx — vertxFactory uses the public VertxBuilder (API change, 
upgrade guide entry)**
   The component used the internal io.vertx.core.impl.VertxBuilder, which does 
not exist in Vert.x 5. It now uses the public io.vertx.core.VertxBuilder from 
Vertx.builder(), which has with(VertxOptions), build() and buildClustered() in 
both versions. The vertxFactory option changes type accordingly; a user who 
sets it must create the builder with Vertx.builder(). The generated configurer, 
component JSON, catalog and component DSL are regenerated.
   
   **camel-vertx-websocket — Camel-owned path normalisation**
   
   `VertxWebsocketHelper` used` 
io.vertx.core.http.impl.HttpUtils.normalizePath`, which moved to an internal 
package in Vert.x 5 with no location common to both versions. It is replaced by 
a private implementation with the Vert.x 4 behaviour: leading slash guaranteed, 
percent-encoded unreserved characters decoded, dot segments removed per RFC 
3986 §5.2.4, // collapsed. It was checked against the Vert.x 4.5.34 
implementation with a differential run of 3 million generated paths (zero 
mismatches, including the exception messages). `VertxWebsocketHelperTest` gains 
cases for dot segments, encoded dot segments, encoded unreserved and reserved 
characters, a missing leading slash, repeated slashes and an invalid escape.
   
   **camel-vertx-common — KeyManagerFactoryOptions.keyManagerFactoryMapper**
   
   In Vert.x 5 `KeyCertOptions.keyManagerMapper` is gone and 
`keyManagerFactoryMapper` is abstract, so TLS setup with this class failed with 
`AbstractMethodError` whenever `sslContextParameters` supplied key material. 
The class now overrides `keyManagerFactoryMapper` to map every server name to 
null, which makes Vert.x fall back to `getKeyManagerFactory`(Vertx) — the same 
thing Vert.x's own `KeyManagerFactoryOptions` does. The key material presented 
is unchanged, since the class holds a single KeyManagerFactory. On Vert.x 4 
this replaces the default that built a separate SSL context per client-supplied 
SNI name (and NPE'd if the first key manager was not an X509KeyManager). 
`VertxWebsocketSSLTest` gains a test with SNI enabled on the server and a 
client that indicates a server name; it is the only test that fails if the 
mapper is broken.
   
   _Claude Code on behalf of @jamesnetherton_
   
   🤖 Generated with [Claude Code](https://claude.com/claude-code)


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