Closed Jurgen-Aquilina closed 2 years ago
The intent of the async API is to be executed asynchronously. So the result can be managed in the callback.
The callback covers the whole lifecycle, from when the query is executed, to each result to the closing. Also in case of error, you have a method for that.
Try this:
database.async().query("sql", "select from User", new AsyncResultsetCallback() {
@Override
public boolean onNext(Result result) {
System.out.println( "Email = " + result.getProperty("email"));
return true;
}
});
Check the docs about this (recently updated): https://docs.arcadedb.com/#asyncQueryPos
ArcadeDB Version: 22.1.2
JDK Version: Coretto 11
OS: Windows 10
Expected behavior
Running a query through the DatabaseAsyncExecutor method should return a result set, same as the query method on the Database interface.
Actual behavior
Running a query through the DatabaseAsyncExecutor returns void.
Steps to reproduce