When using gremlin npm package with exact version 3.6.2
with a brand new Neptune cluster with engine version 1.2.1.0 simple queries hangs even after default timeout from Neptune (2 minutes).
How to reproduce:
Having a lambda within the same vpc and doing the following code in a brand new Neptune cluster with engine 1.2.1.0 (tested instance type was db.r6g.large) running the following code:
const { DriverRemoteConnection } = gremlin.driver;
const { traversal } = gremlin.process.AnonymousTraversalSource;
const dc = new DriverRemoteConnection(GREMLIN_ENDPOINT, {});
const g = traversal().withRemote(dc);
console.log(`First toList()`);
const arr1 = await g.V().toList();
console.log(`First Result`, arr1);
console.log(`Second toList()`);
const arr2 = await g.E().toList();
console.log(`Second Result`, arr2);
Even though it's an empty cluster both traversals will not work hanging forever (until lambdas time is out) even though timeout is configured to 2 minutes in the query level within neptune_query_timeout.
The same code running against a Neptune cluster with engine 1.2.0.2 works normally.
It was indeed related to the slow query log that was not working as expected in the 1.2.0.2.