public void tryStoreVectorizedKey(HiveKey key, boolean partColsIsNull, int batchIndex) throws HiveException, IOException { _tryStoreKey(key, partColsIsNull, batchIndex); if ( partColsIsNull ) { indexesWithNullPartKey.add(batchIndex); } batchIndexToResult[batchIndex] = key.hashCode(); }
public void tryStoreVectorizedKey(HiveKey key, boolean partColsIsNull, int batchIndex) throws HiveException, IOException { _tryStoreKey(key, partColsIsNull, batchIndex); if ( partColsIsNull ) { indexesWithNullPartKey.add(batchIndex); } batchIndexToResult[batchIndex] = key.hashCode(); }
protected void collect(HiveKey keyWritable, BytesWritable valueWritable) throws HiveException, IOException { if (reducerHash != null) { // NOTE: partColsIsNull is only used for PTF, which isn't supported yet. final int firstIndex = reducerHash.tryStoreKey(keyWritable, /* partColsIsNull */ false); if (firstIndex == TopNHash.EXCLUDE) { return; // Nothing to do. } if (firstIndex == TopNHash.FORWARD) { doCollect(keyWritable, valueWritable); } else { Preconditions.checkState(firstIndex >= 0); reducerHash.storeValue(firstIndex, keyWritable.hashCode(), valueWritable, false); } } else { doCollect(keyWritable, valueWritable); } }
public static HiveKey copyHiveKey(HiveKey key) { HiveKey copy = new HiveKey(); copy.setDistKeyLength(key.getDistKeyLength()); copy.setHashCode(key.hashCode()); copy.set(key); return copy; }
public static HiveKey copyHiveKey(HiveKey key) { HiveKey copy = new HiveKey(); copy.setDistKeyLength(key.getDistKeyLength()); copy.setHashCode(key.hashCode()); copy.set(key); return copy; }
public void write(Kryo kryo, Output output, HiveKey object) { output.writeVarInt(object.getLength(), true); output.write(object.getBytes(), 0, object.getLength()); output.writeVarInt(object.hashCode(), false); }
private void writeHiveKey(Output output, HiveKey hiveKey) { int size = hiveKey.getLength(); output.writeInt(size); output.writeBytes(hiveKey.getBytes(), 0, size); output.writeInt(hiveKey.hashCode()); output.writeInt(hiveKey.getDistKeyLength()); }
private void writeHiveKey(Output output, HiveKey hiveKey) { int size = hiveKey.getLength(); output.writeInt(size); output.writeBytes(hiveKey.getBytes(), 0, size); output.writeInt(hiveKey.hashCode()); output.writeInt(hiveKey.getDistKeyLength()); }
return EXCLUDE; // short-circuit quickly - eat all rows Key pk = new Key(partColsIsNull, key.hashCode()); TopNHash partHeap = partitionHeaps.get(pk); if ( partHeap == null ) {
keys[index] = Arrays.copyOf(key.getBytes(), key.getLength()); distKeyLengths[index] = key.getDistKeyLength(); hashes[index] = key.hashCode(); if (null != indexes.store(index)) {
keys[index] = Arrays.copyOf(key.getBytes(), key.getLength()); distKeyLengths[index] = key.getDistKeyLength(); hashes[index] = key.hashCode(); if (null != indexes.store(index)) {
return EXCLUDE; // short-circuit quickly - eat all rows Key pk = new Key(partColsIsNull, key.hashCode()); TopNHash partHeap = partitionHeaps.get(pk); if ( partHeap == null ) {
keys[index] = Arrays.copyOf(key.getBytes(), key.getLength()); distKeyLengths[index] = key.getDistKeyLength(); hashes[index] = key.hashCode(); Integer collisionIndex = indexes.store(index); if (null != collisionIndex) {
keys[index] = Arrays.copyOf(key.getBytes(), key.getLength()); distKeyLengths[index] = key.getDistKeyLength(); hashes[index] = key.hashCode(); Integer collisionIndex = indexes.store(index); if (null != collisionIndex) {
reducerHash.storeValue(firstIndex, firstKey.hashCode(), value, false);
reducerHash.storeValue(firstIndex, firstKey.hashCode(), value, false);
public void tryStoreVectorizedKey(HiveKey key, boolean partColsIsNull, int batchIndex) throws HiveException, IOException { _tryStoreKey(key, partColsIsNull, batchIndex); if ( partColsIsNull ) { indexesWithNullPartKey.add(batchIndex); } batchIndexToResult[batchIndex] = key.hashCode(); }
public static HiveKey copyHiveKey(HiveKey key) { HiveKey copy = new HiveKey(); copy.setDistKeyLength(key.getDistKeyLength()); copy.setHashCode(key.hashCode()); copy.set(key); return copy; }
public void write(Kryo kryo, Output output, HiveKey object) { output.writeVarInt(object.getLength(), true); output.write(object.getBytes(), 0, object.getLength()); output.writeVarInt(object.hashCode(), false); }
private void writeHiveKey(Output output, HiveKey hiveKey) { int size = hiveKey.getLength(); output.writeInt(size); output.writeBytes(hiveKey.getBytes(), 0, size); output.writeInt(hiveKey.hashCode()); output.writeInt(hiveKey.getDistKeyLength()); }