mirror of
https://github.com/apache/arrow.git
synced 2026-10-29 00:56:31 +08:00
fix java client
This commit is contained in:
1 parent
9da2cd38b9
commit
be92e90851
1 file changed
-23
@@ -81,34 +81,11 @@ public class PlasmaClient implements ObjectStoreLink {
|
||||
return ret;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<byte[]> wait(byte[][] objectIds, int timeoutMs, int numReturns) {
|
||||
byte[][] readys = PlasmaClientJNI.wait(conn, objectIds, timeoutMs, numReturns);
|
||||
|
||||
List<byte[]> ret = new ArrayList<>();
|
||||
for (byte[] ready : readys) {
|
||||
for (byte[] id : objectIds) {
|
||||
if (Arrays.equals(ready, id)) {
|
||||
ret.add(id);
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
assert (ret.size() == readys.length);
|
||||
return ret;
|
||||
}
|
||||
|
||||
@Override
|
||||
public byte[] hash(byte[] objectId) {
|
||||
return PlasmaClientJNI.hash(conn, objectId);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void fetch(byte[][] objectIds) {
|
||||
PlasmaClientJNI.fetch(conn, objectIds);
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<ObjectStoreData> get(byte[][] objectIds, int timeoutMs) {
|
||||
ByteBuffer[][] bufs = PlasmaClientJNI.get(conn, objectIds, timeoutMs);
|
||||
|
||||
Reference in new issue
Block a user