DRILL-6381: (Part 4) Enhance MapR-DB plugin to support querying secondary indexes
1. Implementation of the index descriptor for MapR-DB.
2. MapR-DB specific costing for covering and non-covering indexes.
3. Discovery componenent to discover the indexes available for a MapR-DB table including CAST functional indexes.
4. Utility functions to build a canonical index descriptor.
5. Statistics: fetch and initialize statistcs from MapR-DB for a query condition. Maintain a query-scoped cache for the statistics. Utility functions to compute selectivity.
6. Range Partitioning: partitioning function that takes into account the tablet map to find out where a particular rowkey belongs.
7. Restricted Scan: support doing restricted (i.e skip) scan through lookups on the rowkey. Added a group-scan and record reader for this.
8. MD-3726: Simple Order by queries (without limit) when an index is used are showing regression.
9. MD-3995: Do not pushdown limit 0 past project with CONVERT_FROMJSON
10. MD-4259 : Account for limit during hashcode computation
Co-authored-by: Aman Sinha <asinha@maprtech.com>
Co-authored-by: chunhui-shi <cshi@maprtech.com>
Co-authored-by: Gautam Parai <gparai@maprtech.com>
Co-authored-by: Padma Penumarthy <ppenumar97@yahoo.com>
Co-authored-by: Hanumath Rao Maduri <hmaduri@maprtech.com>
Conflicts:
contrib/format-maprdb/src/main/java/org/apache/drill/exec/store/mapr/db/MapRDBFormatMatcher.java
contrib/format-maprdb/src/main/java/org/apache/drill/exec/store/mapr/db/MapRDBPushProjectIntoScan.java
contrib/format-maprdb/src/main/java/org/apache/drill/exec/store/mapr/db/json/JsonTableGroupScan.java
exec/java-exec/src/main/java/org/apache/drill/exec/planner/index/rules/DbScanSortRemovalRule.java
exec/java-exec/src/main/java/org/apache/drill/exec/planner/physical/SortPrel.java
exec/java-exec/src/main/java/org/apache/drill/exec/planner/physical/TopNPrel.java
Fix additional compilation issues.