drill-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From parthchandra <...@git.apache.org>
Subject [GitHub] drill pull request #611: Drill-4800: Improve parquet reader performance
Date Fri, 04 Nov 2016 22:12:46 GMT
Github user parthchandra commented on a diff in the pull request:

    https://github.com/apache/drill/pull/611#discussion_r86607815
  
    --- Diff: exec/java-exec/src/main/java/org/apache/drill/exec/store/parquet/columnreaders/ColumnReader.java
---
    @@ -258,4 +295,74 @@ public static int readIntLittleEndian(DrillBuf in, int offset) {
         return ((ch1 << 24) + (ch2 << 16) + (ch3 << 8) + (ch4 <<
0));
       }
     
    +  private class ColumnReaderProcessPagesTask implements Callable<Long> {
    +
    +    private final ColumnReader parent = ColumnReader.this;
    +    private final long recordsToReadInThisPass;
    +
    +    public ColumnReaderProcessPagesTask(long recordsToReadInThisPass){
    +      this.recordsToReadInThisPass = recordsToReadInThisPass;
    +    }
    +
    +    @Override public Long call() throws IOException{
    +
    +      String oldname = Thread.currentThread().getName();
    +      Thread.currentThread().setName(oldname+"Decode-"+this.parent.columnChunkMetaData.toString());
    +
    +      this.parent.processPages(recordsToReadInThisPass);
    +
    +      Thread.currentThread().setName(oldname);
    +      return recordsToReadInThisPass;
    +    }
    +
    +  }
    +
    +  /*
    +  private class ColumnReaderDetermineSizeTask implements Callable<Boolean> {
    +
    +    private final ColumnReader parent = ColumnReader.this;
    +    private final long recordsReadInCurrentPass;
    +    private final Integer lengthVarFieldsInCurrentRecord;
    +
    +    public ColumnReaderDetermineSizeTask(long recordsReadInCurrentPass, Integer lengthVarFieldsInCurrentRecord){
    +      this.recordsReadInCurrentPass = recordsReadInCurrentPass;
    +      this.lengthVarFieldsInCurrentRecord = lengthVarFieldsInCurrentRecord;
    +    }
    +
    +    @Override public Boolean call() throws IOException{
    +
    +      String oldname = Thread.currentThread().getName();
    +      Thread.currentThread().setName(oldname+"Decode-"+this.parent.columnChunkMetaData.toString());
    +
    +      boolean b = this.parent.determineSize(recordsReadInCurrentPass, lengthVarFieldsInCurrentRecord);
    +
    +      Thread.currentThread().setName(oldname);
    +      return b;
    +    }
    +
    +  }
    +  */
    +
    +  private class ColumnReaderReadRecordsTask implements Callable<Integer> {
    +
    +    private final ColumnReader parent = ColumnReader.this;
    +    private final int recordsToRead;
    +
    +    public ColumnReaderReadRecordsTask(int recordsToRead){
    +      this.recordsToRead = recordsToRead;
    +    }
    +
    +    @Override public Integer call() throws IOException{
    +
    +      String oldname = Thread.currentThread().getName();
    --- End diff --
    
    Done


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

Mime
View raw message