public interface HttpClient {
+
+ // Future version
+ Future<HttpClientRequest> request(RequestOptions request);
+
+ // Callback version
+ void request(RequestOptions request, Handler<AsyncResult<HttpClientRequest>> callback);
+ ...
+}
+diff --git a/index.html b/index.html index 33e3189..fbbe32f 100644 --- a/index.html +++ b/index.html @@ -524,6 +524,8 @@
Vert.x 4 extended the 3.x callback asynchronous model to a future/callback hybrid model, to facilitate migration from Vert.x 3.
+Every callback method has a matching future method:
+public interface HttpClient {
+
+ // Future version
+ Future<HttpClientRequest> request(RequestOptions request);
+
+ // Callback version
+ void request(RequestOptions request, Handler<AsyncResult<HttpClientRequest>> callback);
+ ...
+}
+Vert.x 5 only retains the future model and thus the callback model is gone, instead you get:
+public interface HttpClient {
+
+ // Future version
+ Future<HttpClientRequest> request(RequestOptions request);
+ ...
+}
+Callback methods Vert.x 4.x are not deprecated methods, however after the release of Vert.x 5, the callback +methods shall be deprecated in order to facilitate the migration to Vert.x 5.
+A few components are sunsetting in 5, that means they are still supported for the lifetime of the 5.x series, +but we don’t encourage using them anymore since we provide replacements for them. Such components are scheduled +to go away in the next major release (Vert.x 6).
+Here is the list of components sunsetting in 5:
+Component | +Replacement | +
---|---|
gRPC Netty |
+Vert.x gRPC client and server |
+
JDBC API |
+SQL client API implementation for JDBC |
+
Service Discovery |
+Vert.x Service Resolver |
+
RxJava 2 |
+Mutiny or RxJava 3 |
+
OpenTracing |
+OpenTelemetry |
+
Vert.x Unit |
+Vert.x JUnit 5 |
+
Here is the list of components removed in 5, that were sunset in the 4.x series.
+Component | +Replacement | +
---|---|
Vert.x Sync |
+Vert.x virtual threads |
+
Service Factories |
+None |
+
Maven Service Factory |
+None |
+
HTTP Service Factory |
+None |
+