MB-61438: Supporting Plan for Id Extraction from Value
Change-Id: I2d4fd57af4f71a3b8cf45ed708a1500436565e6e
Reviewed-on: https://asterix-gerrit.ics.uci.edu/c/asterixdb/+/18229
Integration-Tests: Jenkins <jenkins@fulliautomatix.ics.uci.edu>
Reviewed-by: Peeyush Gupta <peeyush.gupta@couchbase.com>
Tested-by: Murtadha Hubail <mhubail@apache.org>
diff --git a/hyracks-fullstack/hyracks/hyracks-data/hyracks-data-std/src/main/java/org/apache/hyracks/data/std/util/ByteArrayAccessibleInputStream.java b/hyracks-fullstack/hyracks/hyracks-data/hyracks-data-std/src/main/java/org/apache/hyracks/data/std/util/ByteArrayAccessibleInputStream.java
index 7f1d451..c1b4d9e 100644
--- a/hyracks-fullstack/hyracks/hyracks-data/hyracks-data-std/src/main/java/org/apache/hyracks/data/std/util/ByteArrayAccessibleInputStream.java
+++ b/hyracks-fullstack/hyracks/hyracks-data/hyracks-data-std/src/main/java/org/apache/hyracks/data/std/util/ByteArrayAccessibleInputStream.java
@@ -29,7 +29,7 @@
public void setContent(byte[] buf, int offset, int length) {
this.buf = buf;
this.pos = offset;
- this.count = Math.min(offset + length, buf.length);
+ this.count = Math.min(offset + length, buf == null ? 0 : buf.length);
this.mark = offset;
}
diff --git a/hyracks-fullstack/hyracks/hyracks-storage-am-lsm-common/src/main/java/org/apache/hyracks/storage/am/lsm/common/dataflow/LSMTreeIndexInsertUpdateDeleteOperatorDescriptor.java b/hyracks-fullstack/hyracks/hyracks-storage-am-lsm-common/src/main/java/org/apache/hyracks/storage/am/lsm/common/dataflow/LSMTreeIndexInsertUpdateDeleteOperatorDescriptor.java
index 26ce56a..9281319 100644
--- a/hyracks-fullstack/hyracks/hyracks-storage-am-lsm-common/src/main/java/org/apache/hyracks/storage/am/lsm/common/dataflow/LSMTreeIndexInsertUpdateDeleteOperatorDescriptor.java
+++ b/hyracks-fullstack/hyracks/hyracks-storage-am-lsm-common/src/main/java/org/apache/hyracks/storage/am/lsm/common/dataflow/LSMTreeIndexInsertUpdateDeleteOperatorDescriptor.java
@@ -67,4 +67,8 @@
recordDescProvider.getInputRecordDescriptor(getActivityId(), 0), op, modCallbackFactory,
tupleFilterFactory, tuplePartitionerFactory, partitionsMap);
}
+
+ public int[] getFieldPermutation() {
+ return fieldPermutation;
+ }
}