Github user ravipesala commented on a diff in the pull request:
https://github.com/apache/carbondata/pull/2209#discussion_r184919017
--- Diff:
processing/src/main/java/org/apache/carbondata/processing/datatypes/PrimitiveDataType.java
---
@@ -245,6 +312,28 @@ public void parseAndBitPack(ByteBuffer byteArrayInput,
DataOutputStream dataOutp
dataOutputStream.write(v);
}
+ @Override
+ public int parseComplexValue(ByteBuffer byteArrayInput, DataOutputStream
dataOutputStream,
+ KeyGenerator[] generator, Boolean[][]
complexDictionaryIndentification, int startOffset)
+ throws IOException, KeyGenException {
+ if (!this.isDictionary) {
+ int sizeOfData = byteArrayInput.getInt();
+ startOffset += Integer.SIZE / Byte.SIZE;
--- End diff --
No need to calculate every time , just use 4 and add comment , Do it in all
places
---