fix java client

This commit is contained in:
Philipp Moritz committed 2018-12-14 05:42:55 -08:00
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);