Github user gparai commented on a diff in the pull request:

    https://github.com/apache/drill/pull/817#discussion_r112072733
  
    --- Diff: 
contrib/format-maprdb/src/main/java/org/apache/drill/exec/store/mapr/db/json/JsonTableGroupScan.java
 ---
    @@ -106,7 +115,11 @@ private void init() {
           Configuration conf = new Configuration();
           Table t = MapRDB.getTable(scanSpec.getTableName());
           TabletInfo[] tabletInfos = t.getTabletInfos(scanSpec.getCondition());
    -      tableStats = new MapRDBTableStats(conf, scanSpec.getTableName());
    +
    +      // Fetch tableStats only once and cache it.
    +      if (tableStats == null) {
    --- End diff --
    
    This can probably be removed if we call clone(). However, it may be a 
useful check if we end up calling it from some other code-paths. Maybe add some 
logging to ensure we are not recreating the tableStats?


---
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 [email protected] or file a JIRA ticket
with INFRA.
---

Reply via email to