Uploaded image for project: 'Apache Drill'
  1. Apache Drill
  2. DRILL-6770

Queries on MapR-DB JSON tables fail with UnsupportedOperationException: Getting number of rows for tablet not supported

    XMLWordPrintableJSON

Details

    Description

      Create a simple MapR-DB JSON table

      $ mapr dbshell 
      MapR-DB Shell
      maprdb root:> create /tmp/t1
      Table /tmp/t1 created.
      
      maprdb root:> insert /tmp/t1 --id '1' --v '{"a":1}'
      Document with id: "1" inserted.
      
      maprdb root:> find /tmp/t1
      {"_id":"1","a":1}
      1 document(s) found.
      

      Querying this from Drill fails:

      > select * from mfs.`/tmp/t1`;
      Error: SYSTEM ERROR: UnsupportedOperationException: Getting number of rows for tablet not supported
      

      Stack Trace:

        (org.apache.drill.exec.work.foreman.ForemanException) Unexpected exception during fragment initialization: Error while applying rule DrillTableRule, args [rel#1400499:EnumerableTableScan.ENUMERABLE.ANY([]).[](table=[mfs, /tmp/t1])]
          org.apache.drill.exec.work.foreman.Foreman.run():300
          java.util.concurrent.ThreadPoolExecutor.runWorker():1149
          java.util.concurrent.ThreadPoolExecutor$Worker.run():624
          java.lang.Thread.run():748
        Caused By (java.lang.RuntimeException) Error while applying rule DrillTableRule, args [rel#1400499:EnumerableTableScan.ENUMERABLE.ANY([]).[](table=[mfs, /tmp/t1])]
          org.apache.calcite.plan.volcano.VolcanoRuleCall.onMatch():236
          org.apache.calcite.plan.volcano.VolcanoPlanner.findBestExp():648
          org.apache.calcite.tools.Programs$RuleSetProgram.run():339
          org.apache.drill.exec.planner.sql.handlers.DefaultSqlHandler.transform():425
          org.apache.drill.exec.planner.sql.handlers.DefaultSqlHandler.transform():365
          org.apache.drill.exec.planner.sql.handlers.DefaultSqlHandler.convertToRawDrel():252
          org.apache.drill.exec.planner.sql.handlers.DefaultSqlHandler.convertToDrel():314
          org.apache.drill.exec.planner.sql.handlers.DefaultSqlHandler.getPlan():179
          org.apache.drill.exec.planner.sql.DrillSqlWorker.getQueryPlan():145
          org.apache.drill.exec.planner.sql.DrillSqlWorker.getPlan():83
          org.apache.drill.exec.work.foreman.Foreman.runSQL():584
          org.apache.drill.exec.work.foreman.Foreman.run():272
          java.util.concurrent.ThreadPoolExecutor.runWorker():1149
          java.util.concurrent.ThreadPoolExecutor$Worker.run():624
          java.lang.Thread.run():748
        Caused By (org.apache.drill.common.exceptions.DrillRuntimeException) Error getting region info for table: maprfs:///tmp/t1
          org.apache.drill.exec.store.mapr.db.json.JsonTableGroupScan.init():161
          org.apache.drill.exec.store.mapr.db.json.JsonTableGroupScan.<init>():83
          org.apache.drill.exec.store.mapr.db.MapRDBFormatPlugin.getGroupScan():81
          org.apache.drill.exec.store.dfs.FileSystemPlugin.getPhysicalScan():170
          org.apache.drill.exec.store.AbstractStoragePlugin.getPhysicalScan():117
          org.apache.drill.exec.store.AbstractStoragePlugin.getPhysicalScan():112
          org.apache.drill.exec.planner.logical.DrillTable.getGroupScan():99
          org.apache.drill.exec.planner.logical.DrillScanRel.<init>():90
          org.apache.drill.exec.planner.logical.DrillScanRel.<init>():70
          org.apache.drill.exec.planner.logical.DrillScanRel.<init>():63
          org.apache.drill.exec.planner.logical.DrillScanRule.onMatch():38
          org.apache.calcite.plan.volcano.VolcanoRuleCall.onMatch():212
          org.apache.calcite.plan.volcano.VolcanoPlanner.findBestExp():648
          org.apache.calcite.tools.Programs$RuleSetProgram.run():339
          org.apache.drill.exec.planner.sql.handlers.DefaultSqlHandler.transform():425
          org.apache.drill.exec.planner.sql.handlers.DefaultSqlHandler.transform():365
          org.apache.drill.exec.planner.sql.handlers.DefaultSqlHandler.convertToRawDrel():252
          org.apache.drill.exec.planner.sql.handlers.DefaultSqlHandler.convertToDrel():314
          org.apache.drill.exec.planner.sql.handlers.DefaultSqlHandler.getPlan():179
          org.apache.drill.exec.planner.sql.DrillSqlWorker.getQueryPlan():145
          org.apache.drill.exec.planner.sql.DrillSqlWorker.getPlan():83
          org.apache.drill.exec.work.foreman.Foreman.runSQL():584
          org.apache.drill.exec.work.foreman.Foreman.run():272
          java.util.concurrent.ThreadPoolExecutor.runWorker():1149
          java.util.concurrent.ThreadPoolExecutor$Worker.run():624
          java.lang.Thread.run():748
        Caused By (java.lang.UnsupportedOperationException) Getting number of rows for tablet not supported
          com.mapr.db.impl.TabletInfoImpl.getEstimatedNumRows():71
          org.apache.drill.exec.store.mapr.db.json.JsonTableGroupScan.init():155
          org.apache.drill.exec.store.mapr.db.json.JsonTableGroupScan.<init>():83
          org.apache.drill.exec.store.mapr.db.MapRDBFormatPlugin.getGroupScan():81
          org.apache.drill.exec.store.dfs.FileSystemPlugin.getPhysicalScan():170
          org.apache.drill.exec.store.AbstractStoragePlugin.getPhysicalScan():117
          org.apache.drill.exec.store.AbstractStoragePlugin.getPhysicalScan():112
          org.apache.drill.exec.planner.logical.DrillTable.getGroupScan():99
          org.apache.drill.exec.planner.logical.DrillScanRel.<init>():90
          org.apache.drill.exec.planner.logical.DrillScanRel.<init>():70
          org.apache.drill.exec.planner.logical.DrillScanRel.<init>():63
          org.apache.drill.exec.planner.logical.DrillScanRule.onMatch():38
          org.apache.calcite.plan.volcano.VolcanoRuleCall.onMatch():212
          org.apache.calcite.plan.volcano.VolcanoPlanner.findBestExp():648
          org.apache.calcite.tools.Programs$RuleSetProgram.run():339
          org.apache.drill.exec.planner.sql.handlers.DefaultSqlHandler.transform():425
          org.apache.drill.exec.planner.sql.handlers.DefaultSqlHandler.transform():365
          org.apache.drill.exec.planner.sql.handlers.DefaultSqlHandler.convertToRawDrel():252
          org.apache.drill.exec.planner.sql.handlers.DefaultSqlHandler.convertToDrel():314
          org.apache.drill.exec.planner.sql.handlers.DefaultSqlHandler.getPlan():179
          org.apache.drill.exec.planner.sql.DrillSqlWorker.getQueryPlan():145
          org.apache.drill.exec.planner.sql.DrillSqlWorker.getPlan():83
          org.apache.drill.exec.work.foreman.Foreman.runSQL():584
          org.apache.drill.exec.work.foreman.Foreman.run():272
          java.util.concurrent.ThreadPoolExecutor.runWorker():1149
          java.util.concurrent.ThreadPoolExecutor$Worker.run():624
          java.lang.Thread.run():748 (state=,code=0)
      

      Attachments

        Issue Links

          Activity

            People

              gparai Gautam Parai
              agirish Abhishek Girish
              Aman Sinha Aman Sinha
              Votes:
              0 Vote for this issue
              Watchers:
              6 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: