vrozov commented on a change in pull request #1360: DRILL-6578: Handle query 
cancellation in Parquet reader
URL: https://github.com/apache/drill/pull/1360#discussion_r199673424
 
 

 ##########
 File path: 
exec/java-exec/src/main/java/org/apache/drill/exec/store/parquet/columnreaders/VarLenColumnBulkInput.java
 ##########
 @@ -479,6 +483,17 @@ private void deinitOverflowData() {
     fieldOverflowStateContainer = null;
   }
 
+  private void checkCancellation() {
+    // - The methods hasNext() & next() are usually invoked within a loop
+    // - We need to ensure that bugs do not cause such loops to execute forever
+    // - To do that, will check the interrupted status (e.g., cancellation) to 
break the infinite loop
+    if (Thread.currentThread().isInterrupted()) {
 
 Review comment:
   use `Thread.interruped()`

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


With regards,
Apache Git Services

Reply via email to