Closed kptfh closed 3 years ago
The "Read multi-op support added to read-only scans" point in the docs is incorrect. The server does not currently support any operation other than Operation.get(String binName)
for read-only scans.
If the server adds scan support for different read operations, the client is already positioned to support that. Example:
Statement stmt = new Statement();
stmt.setNamespace("test");
stmt.setSetName("set");
stmt.setOperations(new Operation[] {Operation.get("bin")}); // currently supported
// stmt.setOperations(new Operation[] {ListOperation.size("bin")}); not currently supported
RecordSet rs = client.query(null, stmt);
It doesn't look like scan API. Seems that query will load all data instead of iterating over it.
If Statement.setFilter() is not called (no filter/where clause) that query turns into a scan on the server. The query() apis are a superset of scans and can use both primary key and secondary index traversal.
Oh, I see. Not obvious.
So I can't use MapOperation.getByKeyRange
with client.query(null, stmt)
That is correct. Server functionality needs to be added to support other operations for read-only scans.
Is there any ETA for this?
No. I suggest using standard channels for server functionality requests.
Found that Aerospike starting from 4.9.0 version supports
Read moulti-op support added to read-only scans
feature. Didn't find how to use it via Java client. What is ETA of this feature support by Java client?aerospike.com/docs/guide/scan.html#version-4-9-0-changes