drill-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From rahul challapalli <challapallira...@gmail.com>
Subject Re: Aggregate queries in drill
Date Fri, 07 Aug 2015 07:53:04 GMT
Sudip,

In your case, I would assume that you would construct something similar to
the below :

    1. Create your own optimizer rule (SolrPushAggIntoScan). Take a look at
PruneScanRule. You should gather the LogicalAggregate and DrillScanRel
objects from the RelOptRuleCall. Now from a high level you need to
re-create the group scan with the aggregate information. Most likely you
might to need to use an expression visitor in your SolrPushAggIntoScan
class to figure out what aggregate functions you want to push into the scan
    2. Now add your new rule(s) to the StoragePlugin.getOptimizerRules()
method.

- Rahul


On Thu, Aug 6, 2015 at 10:00 PM, Sudip Mukherjee <smukherjee@commvault.com>
wrote:

> Hi ,
>
> I am trying to make basic storage plugin for solr with drill. Is there a
> way I could get the aggregate function information via expression visitor
> in the plugin code so that I can optimize the Solr query as much as I can.
> For example, for a count query I would just return the numFound from solr
> response with rows =0.
> Source code : https://github.com/apache/drill/pull/100
>
> Could someone please help me on this?
>
> Thanks,
> Sudip Mukherjee
>
>
>
>
> ***************************Legal Disclaimer***************************
> "This communication may contain confidential and privileged material for
> the
> sole use of the intended recipient. Any unauthorized review, use or
> distribution
> by others is strictly prohibited. If you have received the message by
> mistake,
> please advise the sender by reply email and delete the message. Thank you."
> **********************************************************************

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message