Closed ieuan-richards closed 10 months ago
@ieuan-richards Can you please provide a code snippet to reproduce the issue?
ArangoDB arangoDB = new ArangoDB.Builder()
.host("localhost", 8529)
.user("user")
.password("pword")
.build();
ArangoDatabase db = arangoDB.db("db");
// Should have more than 2 results to see issue
try(ArangoCursor<BaseDocument> cursor = db.query("for doc in Collection return doc",
new AqlQueryOptions().batchSize(2), BaseDocument.class)){
while (cursor.hasNext()){
BaseDocument next = cursor.next();
System.out.println(next);
}
}
I can execute the snippet above without getting any exception! Can you enable debug level logging for com.arangodb
and report here the logs related to requests and responses?
I should have mentioned that we are on v3.6.13 of ArangoDB server. I will provide the debug logs shortly.
Closing as not reproducible, please reopen if still relevant.
In versions 6.18.0+ I see an exception is thrown whenever the cursors tries to return the second batch of results from a query.
We've downgraded to v6.17.0 of the driver in the meantime.
To replicate:
This is the exception:
Exception in thread "main" com.arangodb.ArangoDBException: Response: 400, Error: 400 - expecting POST /_api/cursor at com.arangodb.internal.util.ResponseUtils.checkError(ResponseUtils.java:55) at com.arangodb.internal.velocystream.VstCommunication.checkError(VstCommunication.java:157) at com.arangodb.internal.velocystream.VstCommunicationSync.execute(VstCommunicationSync.java:144) at com.arangodb.internal.velocystream.VstCommunicationSync.execute(VstCommunicationSync.java:45) at com.arangodb.internal.velocystream.VstCommunication.execute(VstCommunication.java:149) at com.arangodb.internal.velocystream.VstCommunication.execute(VstCommunication.java:144) at com.arangodb.internal.velocystream.VstProtocol.execute(VstProtocol.java:46) at com.arangodb.internal.ArangoExecutorSync.execute(ArangoExecutorSync.java:71) at com.arangodb.internal.ArangoExecutorSync.execute(ArangoExecutorSync.java:57) at com.arangodb.internal.ArangoDatabaseImpl$1.next(ArangoDatabaseImpl.java:211) at com.arangodb.internal.cursor.ArangoCursorIterator.next(ArangoCursorIterator.java:69) at com.arangodb.internal.cursor.ArangoCursorImpl.next(ArangoCursorImpl.java:111)