[GitHub] [carbondata] niuge01 commented on a change in pull request #3421: [CARBONDATA-3557] Support write Flink streaming data to Carbon

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

[GitHub] [carbondata] niuge01 commented on a change in pull request #3421: [CARBONDATA-3557] Support write Flink streaming data to Carbon

GitBox
niuge01 commented on a change in pull request #3421: [CARBONDATA-3557] Support write Flink streaming data to Carbon
URL: https://github.com/apache/carbondata/pull/3421#discussion_r339421585
 
 

 ##########
 File path: core/src/main/java/org/apache/carbondata/core/indexstore/blockletindex/BlockDataMap.java
 ##########
 @@ -635,8 +637,12 @@ protected short getBlockletNumOfEntry(int index) {
       // dummy value
       return 0;
     } else {
-      return ByteBuffer.wrap(getBlockletRowCountForEachBlock()).getShort(
-          index * CarbonCommonConstants.SHORT_SIZE_IN_BYTE);
+      final byte[] bytes = getBlockletRowCountForEachBlock();
+      if (bytes.length == 0) {
+        return 0;
 
 Review comment:
   OK

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[hidden email]


With regards,
Apache Git Services