Search in sources :

Example 1 with IVisitablePointable

use of org.apache.asterix.om.pointables.base.IVisitablePointable in project asterixdb by apache.

the class DeepEqualityDescriptor method createEvaluatorFactory.

@Override
public IScalarEvaluatorFactory createEvaluatorFactory(final IScalarEvaluatorFactory[] args) {
    final IScalarEvaluatorFactory evalFactoryLeft = args[0];
    final IScalarEvaluatorFactory evalFactoryRight = args[1];
    return new IScalarEvaluatorFactory() {

        private static final long serialVersionUID = 1L;

        @SuppressWarnings("unchecked")
        private final ISerializerDeserializer<ABoolean> boolSerde = SerializerDeserializerProvider.INSTANCE.getSerializerDeserializer(BuiltinType.ABOOLEAN);

        @Override
        public IScalarEvaluator createScalarEvaluator(IHyracksTaskContext ctx) throws HyracksDataException {
            final ArrayBackedValueStorage resultStorage = new ArrayBackedValueStorage();
            final DataOutput out = resultStorage.getDataOutput();
            final IScalarEvaluator evalLeft = evalFactoryLeft.createScalarEvaluator(ctx);
            final IScalarEvaluator evalRight = evalFactoryRight.createScalarEvaluator(ctx);
            return new IScalarEvaluator() {

                private final DeepEqualAssessor deepEqualAssessor = new DeepEqualAssessor();

                private final PointableAllocator allocator = new PointableAllocator();

                private final IVisitablePointable pointableLeft = allocator.allocateFieldValue(inputTypeLeft);

                private final IVisitablePointable pointableRight = allocator.allocateFieldValue(inputTypeRight);

                @Override
                public void evaluate(IFrameTupleReference tuple, IPointable result) throws HyracksDataException {
                    try {
                        evalLeft.evaluate(tuple, pointableLeft);
                        evalRight.evaluate(tuple, pointableRight);
                        // Using deep equality assessment to assess the equality of the two values
                        boolean isEqual = deepEqualAssessor.isEqual(pointableLeft, pointableRight);
                        ABoolean resultBit = isEqual ? ABoolean.TRUE : ABoolean.FALSE;
                        resultStorage.reset();
                        boolSerde.serialize(resultBit, out);
                        result.set(resultStorage);
                    } catch (Exception ioe) {
                        throw new HyracksDataException(ioe);
                    }
                }
            };
        }
    };
}
Also used : DataOutput(java.io.DataOutput) ABoolean(org.apache.asterix.om.base.ABoolean) IPointable(org.apache.hyracks.data.std.api.IPointable) IScalarEvaluator(org.apache.hyracks.algebricks.runtime.base.IScalarEvaluator) ISerializerDeserializer(org.apache.hyracks.api.dataflow.value.ISerializerDeserializer) HyracksDataException(org.apache.hyracks.api.exceptions.HyracksDataException) HyracksDataException(org.apache.hyracks.api.exceptions.HyracksDataException) IScalarEvaluatorFactory(org.apache.hyracks.algebricks.runtime.base.IScalarEvaluatorFactory) ArrayBackedValueStorage(org.apache.hyracks.data.std.util.ArrayBackedValueStorage) IVisitablePointable(org.apache.asterix.om.pointables.base.IVisitablePointable) IHyracksTaskContext(org.apache.hyracks.api.context.IHyracksTaskContext) IFrameTupleReference(org.apache.hyracks.dataflow.common.data.accessors.IFrameTupleReference) DeepEqualAssessor(org.apache.asterix.runtime.evaluators.comparisons.DeepEqualAssessor) PointableAllocator(org.apache.asterix.om.pointables.PointableAllocator)

Example 2 with IVisitablePointable

use of org.apache.asterix.om.pointables.base.IVisitablePointable in project asterixdb by apache.

the class RecordAddFieldsDescriptor method createEvaluatorFactory.

@Override
public IScalarEvaluatorFactory createEvaluatorFactory(final IScalarEvaluatorFactory[] args) {
    return new IScalarEvaluatorFactory() {

        private static final long serialVersionUID = 1L;

        @Override
        public IScalarEvaluator createScalarEvaluator(final IHyracksTaskContext ctx) throws HyracksDataException {
            final PointableAllocator allocator = new PointableAllocator();
            final IVisitablePointable vp0 = allocator.allocateRecordValue(inRecType);
            final IVisitablePointable vp1 = allocator.allocateListValue(inListType);
            final IPointable argPtr0 = new VoidPointable();
            final IPointable argPtr1 = new VoidPointable();
            final IScalarEvaluator eval0 = args[0].createScalarEvaluator(ctx);
            final IScalarEvaluator eval1 = args[1].createScalarEvaluator(ctx);
            final ArrayBackedValueStorage fieldNamePointable = new ArrayBackedValueStorage();
            final ArrayBackedValueStorage fieldValuePointer = new ArrayBackedValueStorage();
            final PointableHelper pointableHelper = new PointableHelper();
            try {
                pointableHelper.serializeString("field-name", fieldNamePointable, true);
                pointableHelper.serializeString("field-value", fieldValuePointer, true);
            } catch (AsterixException e) {
                throw new HyracksDataException(e);
            }
            return new IScalarEvaluator() {

                // the default 32k frame size
                public static final int TABLE_FRAME_SIZE = 32768;

                // the default 32k frame size
                public static final int TABLE_SIZE = 100;

                private final RecordBuilder recordBuilder = new RecordBuilder();

                private final RuntimeRecordTypeInfo requiredRecordTypeInfo = new RuntimeRecordTypeInfo();

                private final IBinaryHashFunction putHashFunc = ListItemBinaryHashFunctionFactory.INSTANCE.createBinaryHashFunction();

                private final IBinaryHashFunction getHashFunc = ListItemBinaryHashFunctionFactory.INSTANCE.createBinaryHashFunction();

                private final BinaryEntry keyEntry = new BinaryEntry();

                private final BinaryEntry valEntry = new BinaryEntry();

                private final IVisitablePointable tempValReference = allocator.allocateEmpty();

                private final IBinaryComparator cmp = ListItemBinaryComparatorFactory.INSTANCE.createBinaryComparator();

                private BinaryHashMap hashMap = new BinaryHashMap(TABLE_SIZE, TABLE_FRAME_SIZE, putHashFunc, getHashFunc, cmp);

                private ArrayBackedValueStorage resultStorage = new ArrayBackedValueStorage();

                private DataOutput out = resultStorage.getDataOutput();

                @Override
                public void evaluate(IFrameTupleReference tuple, IPointable result) throws HyracksDataException {
                    resultStorage.reset();
                    recordBuilder.reset(outRecType);
                    requiredRecordTypeInfo.reset(outRecType);
                    eval0.evaluate(tuple, argPtr0);
                    eval1.evaluate(tuple, argPtr1);
                    // Make sure we get a valid record
                    byte typeTag0 = argPtr0.getByteArray()[argPtr0.getStartOffset()];
                    if (typeTag0 != ATypeTag.SERIALIZED_RECORD_TYPE_TAG) {
                        throw new TypeMismatchException(getIdentifier(), 0, typeTag0, ATypeTag.SERIALIZED_RECORD_TYPE_TAG);
                    }
                    // Make sure we get a valid list
                    byte typeTag1 = argPtr1.getByteArray()[argPtr1.getStartOffset()];
                    if (typeTag1 != ATypeTag.SERIALIZED_ORDEREDLIST_TYPE_TAG) {
                        throw new TypeMismatchException(getIdentifier(), 1, typeTag1, ATypeTag.SERIALIZED_ORDEREDLIST_TYPE_TAG);
                    }
                    vp0.set(argPtr0);
                    vp1.set(argPtr1);
                    ARecordVisitablePointable recordPointable = (ARecordVisitablePointable) vp0;
                    AListVisitablePointable listPointable = (AListVisitablePointable) vp1;
                    // Initialize our hashmap
                    int tableSize = recordPointable.getFieldNames().size() + listPointable.getItems().size();
                    // Thus avoiding unnecessary object construction
                    if (hashMap == null || tableSize > TABLE_SIZE) {
                        hashMap = new BinaryHashMap(tableSize, TABLE_FRAME_SIZE, putHashFunc, getHashFunc, cmp);
                    } else {
                        hashMap.clear();
                    }
                    addFields(recordPointable, listPointable);
                    recordBuilder.write(out, true);
                    result.set(resultStorage);
                }

                private void addFields(ARecordVisitablePointable inputRecordPointer, AListVisitablePointable listPointable) throws HyracksDataException {
                    List<IVisitablePointable> inputRecordFieldNames = inputRecordPointer.getFieldNames();
                    List<IVisitablePointable> inputRecordFieldValues = inputRecordPointer.getFieldValues();
                    List<IVisitablePointable> inputFields = listPointable.getItems();
                    IVisitablePointable namePointable = null;
                    IVisitablePointable valuePointable = null;
                    int numInputRecordFields = inputRecordFieldNames.size();
                    try {
                        // Add original record without duplicate checking
                        for (int i = 0; i < numInputRecordFields; ++i) {
                            IVisitablePointable fnp = inputRecordFieldNames.get(i);
                            IVisitablePointable fvp = inputRecordFieldValues.get(i);
                            int pos = requiredRecordTypeInfo.getFieldIndex(fnp.getByteArray(), fnp.getStartOffset() + 1, fnp.getLength() - 1);
                            if (pos >= 0) {
                                recordBuilder.addField(pos, fvp);
                            } else {
                                recordBuilder.addField(fnp, fvp);
                            }
                            keyEntry.set(fnp.getByteArray(), fnp.getStartOffset(), fnp.getLength());
                            valEntry.set(fvp.getByteArray(), fvp.getStartOffset(), fvp.getLength());
                            hashMap.put(keyEntry, valEntry);
                        }
                        // Get the fields from a list of records
                        for (int i = 0; i < inputFields.size(); i++) {
                            if (!PointableHelper.sameType(ATypeTag.OBJECT, inputFields.get(i))) {
                                throw new AsterixException("Expected list of record, got " + PointableHelper.getTypeTag(inputFields.get(i)));
                            }
                            List<IVisitablePointable> names = ((ARecordVisitablePointable) inputFields.get(i)).getFieldNames();
                            List<IVisitablePointable> values = ((ARecordVisitablePointable) inputFields.get(i)).getFieldValues();
                            // Get name and value of the field to be added
                            // Use loop to account for the cases where users switches the order of the fields
                            IVisitablePointable fieldName;
                            for (int j = 0; j < names.size(); j++) {
                                fieldName = names.get(j);
                                // if fieldName is "field-name" then read the name
                                if (PointableHelper.byteArrayEqual(fieldNamePointable, fieldName)) {
                                    namePointable = values.get(j);
                                } else {
                                    // otherwise the fieldName is "field-value". Thus, read the value
                                    valuePointable = values.get(j);
                                }
                            }
                            if (namePointable == null || valuePointable == null) {
                                throw new InvalidDataFormatException(getIdentifier(), "fields to be added");
                            }
                            // Check that the field being added is a valid field
                            int pos = requiredRecordTypeInfo.getFieldIndex(namePointable.getByteArray(), namePointable.getStartOffset() + 1, namePointable.getLength() - 1);
                            keyEntry.set(namePointable.getByteArray(), namePointable.getStartOffset(), namePointable.getLength());
                            // Check if already in our built record
                            BinaryEntry entry = hashMap.get(keyEntry);
                            if (entry != null) {
                                tempValReference.set(entry.getBuf(), entry.getOffset(), entry.getLength());
                                // If value is not equal throw conflicting duplicate field, otherwise ignore
                                if (!PointableHelper.byteArrayEqual(valuePointable, tempValReference)) {
                                    throw new RuntimeDataException(ErrorCode.DUPLICATE_FIELD_NAME, getIdentifier());
                                }
                            } else {
                                if (pos > -1) {
                                    recordBuilder.addField(pos, valuePointable);
                                } else {
                                    recordBuilder.addField(namePointable, valuePointable);
                                }
                                valEntry.set(valuePointable.getByteArray(), valuePointable.getStartOffset(), valuePointable.getLength());
                                hashMap.put(keyEntry, valEntry);
                            }
                        }
                    } catch (AsterixException e) {
                        throw new HyracksDataException(e);
                    }
                }
            };
        }
    };
}
Also used : BinaryEntry(org.apache.hyracks.data.std.util.BinaryEntry) DataOutput(java.io.DataOutput) TypeMismatchException(org.apache.asterix.runtime.exceptions.TypeMismatchException) IBinaryComparator(org.apache.hyracks.api.dataflow.value.IBinaryComparator) IPointable(org.apache.hyracks.data.std.api.IPointable) IScalarEvaluator(org.apache.hyracks.algebricks.runtime.base.IScalarEvaluator) InvalidDataFormatException(org.apache.asterix.runtime.exceptions.InvalidDataFormatException) ARecordVisitablePointable(org.apache.asterix.om.pointables.ARecordVisitablePointable) AListVisitablePointable(org.apache.asterix.om.pointables.AListVisitablePointable) AsterixException(org.apache.asterix.common.exceptions.AsterixException) VoidPointable(org.apache.hyracks.data.std.primitive.VoidPointable) PointableAllocator(org.apache.asterix.om.pointables.PointableAllocator) RuntimeDataException(org.apache.asterix.common.exceptions.RuntimeDataException) IBinaryHashFunction(org.apache.hyracks.api.dataflow.value.IBinaryHashFunction) RecordBuilder(org.apache.asterix.builders.RecordBuilder) HyracksDataException(org.apache.hyracks.api.exceptions.HyracksDataException) IScalarEvaluatorFactory(org.apache.hyracks.algebricks.runtime.base.IScalarEvaluatorFactory) PointableHelper(org.apache.asterix.runtime.evaluators.functions.PointableHelper) IVisitablePointable(org.apache.asterix.om.pointables.base.IVisitablePointable) ArrayBackedValueStorage(org.apache.hyracks.data.std.util.ArrayBackedValueStorage) IHyracksTaskContext(org.apache.hyracks.api.context.IHyracksTaskContext) IFrameTupleReference(org.apache.hyracks.dataflow.common.data.accessors.IFrameTupleReference) RuntimeRecordTypeInfo(org.apache.asterix.om.types.runtime.RuntimeRecordTypeInfo) BinaryHashMap(org.apache.asterix.runtime.evaluators.functions.BinaryHashMap)

Example 3 with IVisitablePointable

use of org.apache.asterix.om.pointables.base.IVisitablePointable in project asterixdb by apache.

the class AOrderedlistPrinterFactory method createPrinter.

@Override
public IPrinter createPrinter() {
    final PointableAllocator allocator = new PointableAllocator();
    final IAType inputType = orderedlistType == null ? DefaultOpenFieldType.getDefaultOpenFieldType(ATypeTag.ARRAY) : orderedlistType;
    final IVisitablePointable listAccessor = allocator.allocateListValue(inputType);
    final APrintVisitor printVisitor = new APrintVisitor();
    final Pair<PrintStream, ATypeTag> arg = new Pair<>(null, null);
    return new IPrinter() {

        @Override
        public void init() {
            arg.second = inputType.getTypeTag();
        }

        @Override
        public void print(byte[] b, int start, int l, PrintStream ps) throws HyracksDataException {
            listAccessor.set(b, start, l);
            arg.first = ps;
            listAccessor.accept(printVisitor, arg);
        }
    };
}
Also used : PrintStream(java.io.PrintStream) IVisitablePointable(org.apache.asterix.om.pointables.base.IVisitablePointable) ATypeTag(org.apache.asterix.om.types.ATypeTag) APrintVisitor(org.apache.asterix.om.pointables.printer.adm.APrintVisitor) IPrinter(org.apache.hyracks.algebricks.data.IPrinter) PointableAllocator(org.apache.asterix.om.pointables.PointableAllocator) IAType(org.apache.asterix.om.types.IAType) Pair(org.apache.hyracks.algebricks.common.utils.Pair)

Example 4 with IVisitablePointable

use of org.apache.asterix.om.pointables.base.IVisitablePointable in project asterixdb by apache.

the class RecordDeepEqualityChecker method accessRecord.

public boolean accessRecord(IVisitablePointable recPointableLeft, IVisitablePointable recPointableRight, DeepEqualityVisitor visitor) throws HyracksDataException {
    if (recPointableLeft.equals(recPointableRight)) {
        return true;
    }
    this.visitor = visitor;
    hashMap.clear();
    ARecordVisitablePointable recLeft = (ARecordVisitablePointable) recPointableLeft;
    List<IVisitablePointable> fieldNamesLeft = recLeft.getFieldNames();
    ARecordVisitablePointable recRight = (ARecordVisitablePointable) recPointableRight;
    List<IVisitablePointable> fieldNamesRight = recRight.getFieldNames();
    int sizeLeft = fieldNamesLeft.size();
    int sizeRight = fieldNamesRight.size();
    if (sizeLeft != sizeRight) {
        return false;
    }
    // Build phase: Add items into hash map, starting with first record.
    for (int i = 0; i < sizeLeft; i++) {
        IVisitablePointable fieldName = fieldNamesLeft.get(i);
        keyEntry.set(fieldName.getByteArray(), fieldName.getStartOffset(), fieldName.getLength());
        IntegerPointable.setInteger(valEntry.getBuf(), 0, i);
        hashMap.put(keyEntry, valEntry);
    }
    return compareValues(recLeft.getFieldTypeTags(), recLeft.getFieldValues(), fieldNamesRight, recRight.getFieldTypeTags(), recRight.getFieldValues());
}
Also used : ARecordVisitablePointable(org.apache.asterix.om.pointables.ARecordVisitablePointable) IVisitablePointable(org.apache.asterix.om.pointables.base.IVisitablePointable)

Example 5 with IVisitablePointable

use of org.apache.asterix.om.pointables.base.IVisitablePointable in project asterixdb by apache.

the class ARecordVisitablePointable method set.

@Override
public void set(byte[] b, int start, int len) {
    // clear the previous states
    reset();
    super.set(b, start, len);
    boolean isExpanded = false;
    int openPartOffset = 0;
    int recordOffset = start;
    int offsetArrayOffset;
    //advance to either isExpanded or numberOfSchemaFields
    int s = start + 5;
    //inputRecType will never be null.
    if (inputRecType.isOpen()) {
        isExpanded = b[s] == 1;
        //advance either to openPartOffset or numberOfSchemaFields
        s += 1;
        if (isExpanded) {
            openPartOffset = start + AInt32SerializerDeserializer.getInt(b, s);
            //advance to numberOfSchemaFields
            s += 4;
        }
    }
    try {
        if (numberOfSchemaFields > 0) {
            //advance to nullBitMap if hasOptionalFields, or fieldOffsets
            s += 4;
            int nullBitMapOffset = 0;
            boolean hasOptionalFields = NonTaggedFormatUtil.hasOptionalField(inputRecType);
            if (hasOptionalFields) {
                nullBitMapOffset = s;
                offsetArrayOffset = s + (this.numberOfSchemaFields % 4 == 0 ? numberOfSchemaFields / 4 : numberOfSchemaFields / 4 + 1);
            } else {
                offsetArrayOffset = s;
            }
            for (int i = 0; i < numberOfSchemaFields; i++) {
                fieldOffsets[i] = AInt32SerializerDeserializer.getInt(b, offsetArrayOffset) + recordOffset;
                offsetArrayOffset += 4;
            }
            for (int fieldNumber = 0; fieldNumber < numberOfSchemaFields; fieldNumber++) {
                if (hasOptionalFields) {
                    byte b1 = b[nullBitMapOffset + fieldNumber / 4];
                    int p = 1 << (7 - 2 * (fieldNumber % 4));
                    if ((b1 & p) == 0) {
                        // set null value (including type tag inside)
                        fieldValues.add(nullReference);
                        continue;
                    }
                    p = 1 << (7 - 2 * (fieldNumber % 4) - 1);
                    if ((b1 & p) == 0) {
                        // set missing value (including type tag inside)
                        fieldValues.add(missingReference);
                        continue;
                    }
                }
                IAType[] fieldTypes = inputRecType.getFieldTypes();
                int fieldValueLength = 0;
                IAType fieldType = fieldTypes[fieldNumber];
                if (fieldTypes[fieldNumber].getTypeTag() == ATypeTag.UNION) {
                    if (((AUnionType) fieldTypes[fieldNumber]).isUnknownableType()) {
                        fieldType = ((AUnionType) fieldTypes[fieldNumber]).getActualType();
                        typeTag = fieldType.getTypeTag();
                        fieldValueLength = NonTaggedFormatUtil.getFieldValueLength(b, fieldOffsets[fieldNumber], typeTag, false);
                    }
                } else {
                    typeTag = fieldTypes[fieldNumber].getTypeTag();
                    fieldValueLength = NonTaggedFormatUtil.getFieldValueLength(b, fieldOffsets[fieldNumber], typeTag, false);
                }
                // set field value (including the type tag)
                int fstart = dataBos.size();
                dataDos.writeByte(typeTag.serialize());
                dataDos.write(b, fieldOffsets[fieldNumber], fieldValueLength);
                int fend = dataBos.size();
                IVisitablePointable fieldValue = allocator.allocateFieldValue(fieldType);
                fieldValue.set(dataBos.getByteArray(), fstart, fend - fstart);
                fieldValues.add(fieldValue);
            }
        }
        if (isExpanded) {
            int numberOfOpenFields = AInt32SerializerDeserializer.getInt(b, openPartOffset);
            int fieldOffset = openPartOffset + 4 + (8 * numberOfOpenFields);
            for (int i = 0; i < numberOfOpenFields; i++) {
                // set the field name (including a type tag, which is
                // astring)
                int fieldValueLength = NonTaggedFormatUtil.getFieldValueLength(b, fieldOffset, ATypeTag.STRING, false);
                int fnstart = dataBos.size();
                dataDos.writeByte(ATypeTag.SERIALIZED_STRING_TYPE_TAG);
                dataDos.write(b, fieldOffset, fieldValueLength);
                int fnend = dataBos.size();
                IVisitablePointable fieldName = allocator.allocateEmpty();
                fieldName.set(dataBos.getByteArray(), fnstart, fnend - fnstart);
                fieldNames.add(fieldName);
                fieldOffset += fieldValueLength;
                // set the field type tag
                IVisitablePointable fieldTypeTag = allocator.allocateEmpty();
                fieldTypeTag.set(b, fieldOffset, 1);
                fieldTypeTags.add(fieldTypeTag);
                typeTag = EnumDeserializer.ATYPETAGDESERIALIZER.deserialize(b[fieldOffset]);
                // set the field value (already including type tag)
                fieldValueLength = NonTaggedFormatUtil.getFieldValueLength(b, fieldOffset, typeTag, true) + 1;
                // allocate
                IVisitablePointable fieldValueAccessor = allocator.allocateFieldValue(typeTag, b, fieldOffset + 1);
                fieldValueAccessor.set(b, fieldOffset, fieldValueLength);
                fieldValues.add(fieldValueAccessor);
                fieldOffset += fieldValueLength;
            }
        }
    } catch (Exception e) {
        throw new IllegalStateException(e);
    }
}
Also used : IVisitablePointable(org.apache.asterix.om.pointables.base.IVisitablePointable) AUnionType(org.apache.asterix.om.types.AUnionType) HyracksDataException(org.apache.hyracks.api.exceptions.HyracksDataException) IOException(java.io.IOException) IAType(org.apache.asterix.om.types.IAType)

Aggregations

IVisitablePointable (org.apache.asterix.om.pointables.base.IVisitablePointable)30 ATypeTag (org.apache.asterix.om.types.ATypeTag)19 IAType (org.apache.asterix.om.types.IAType)15 PointableAllocator (org.apache.asterix.om.pointables.PointableAllocator)14 Pair (org.apache.hyracks.algebricks.common.utils.Pair)12 PrintStream (java.io.PrintStream)11 IPrinter (org.apache.hyracks.algebricks.data.IPrinter)10 HyracksDataException (org.apache.hyracks.api.exceptions.HyracksDataException)10 ARecordVisitablePointable (org.apache.asterix.om.pointables.ARecordVisitablePointable)6 DataOutput (java.io.DataOutput)5 IScalarEvaluator (org.apache.hyracks.algebricks.runtime.base.IScalarEvaluator)5 IPointable (org.apache.hyracks.data.std.api.IPointable)5 ArrayBackedValueStorage (org.apache.hyracks.data.std.util.ArrayBackedValueStorage)5 IFrameTupleReference (org.apache.hyracks.dataflow.common.data.accessors.IFrameTupleReference)5 IOException (java.io.IOException)4 RecordBuilder (org.apache.asterix.builders.RecordBuilder)4 AListVisitablePointable (org.apache.asterix.om.pointables.AListVisitablePointable)4 APrintVisitor (org.apache.asterix.om.pointables.printer.adm.APrintVisitor)4 IScalarEvaluatorFactory (org.apache.hyracks.algebricks.runtime.base.IScalarEvaluatorFactory)4 IHyracksTaskContext (org.apache.hyracks.api.context.IHyracksTaskContext)4