Details
-
New Feature
-
Status: Closed (View Workflow)
-
P2
-
Resolution: Done
-
None
-
-
CP: sprint 108, CP: sprint 109
-
2
-
Core: Platform
Description
ClientGenerator.generateMethodMeta generates a
public void method([other args], Handler<AsyncResult<HttpResponse<Buffer>>> handler) {
method that calls
request.sendBuffer(buffer, responseHandler);
or
request.send(responseHandler);
Task:
Change the method to become
public Future<HttpResponse<Buffer>> method([other args]) {
that calls
return request.sendBuffer(buffer);
or
return request.send();
Wrap the code into a try-catch-clause that returns a failed future with the thrown Throwable.
Add
public void method([other args], Handler<AsyncResult<HttpResponse<Buffer>>> handler) {
method([other args]).onComplete(handler);
}