You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@kylin.apache.org by Huang Hua <hu...@mininglamp.com> on 2015/08/15 14:38:22 UTC

答复: [jira] [Updated] (KYLIN-949) Query cache doesn't work properly for prepareStatement queries

Thanks a lot, Hongbin! So it is now fixed in 0.7.3 as well as 0.8?

> -----邮件原件-----
> 发件人: dev-return-3694-
> huanghua=mininglamp.com@kylin.incubator.apache.org [mailto:dev-return-
> 3694-huanghua=mininglamp.com@kylin.incubator.apache.org] 代表 hongbin
> ma
> 发送时间: 2015年8月14日 18:12
> 收件人: dev
> 主题: Re: [jira] [Updated] (KYLIN-949) Query cache doesn't work properly for
> prepareStatement queries
> 
> thanks Hua!
> 
> I have applied you patch in 0.7 staging, and cherry-picked it to 0.8 branch
> 
> On Fri, Aug 14, 2015 at 5:31 PM, Huang Hua (JIRA) <ji...@apache.org> wrote:
> 
> >
> >      [
> > https://issues.apache.org/jira/browse/KYLIN-
> 949?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
> > ]
> >
> > Huang Hua updated KYLIN-949:
> > ----------------------------
> >     Attachment: fix_kylin_949.patch
> >
> > Here is my patch to fix the bug, which basically adds hashcode() and
> > equals() implementations in PrepareSqlRequest.
> >
> > > Query cache doesn't work properly for prepareStatement queries
> > > --------------------------------------------------------------
> > >
> > >                 Key: KYLIN-949
> > >                 URL: https://issues.apache.org/jira/browse/KYLIN-949
> > >             Project: Kylin
> > >          Issue Type: Bug
> > >          Components: REST Service
> > >    Affects Versions: v0.7.2, v0.7.1
> > >            Reporter: Huang Hua
> > >            Assignee: Zhong,Jason
> > >         Attachments: fix_kylin_949.patch
> > >
> > >
> > > There is a bug in searchQueryInCache() method, for PrepareSqlRequest,
> > the cache logic is wrong which returns the same result for any
> > PrepareSqlRequest with same sql no matter what the actual params are.
> > > For example, using "select LEAF_CATEG_ID from KYLIN_SALES where
> > LEAF_CATEG_ID = ? group by LEAF_CATEG_ID;" with params=[65] to fire
> > request, and kylin will return 65. Let's suppose that query is cached(we
> > can modify kylin settings to enable it to cache every query).
> > > And then using the same sql but with params=[130], which returns 65
> > instead of 130.
> >
> >
> >
> > --
> > This message was sent by Atlassian JIRA
> > (v6.3.4#6332)
> >
> 
> 
> 
> --
> Regards,
> 
> *Bin Mahone | 马洪宾*
> Apache Kylin: http://kylin.io
> Github: https://github.com/binmahone



Re: 答复: [jira] [Updated] (KYLIN-949) Query cache doesn't work properly for prepareStatement queries

Posted by Luke Han <lu...@gmail.com>.
Next time,  please update such activities in JIRA for well tracking.
There's nothing be update there which confusing release process.

Thanks:)




Best Regards!
---------------------

Luke Han

On Mon, Aug 17, 2015 at 9:44 AM, hongbin ma <ma...@apache.org> wrote:

> should be:)
>
> On Sat, Aug 15, 2015 at 8:38 PM, Huang Hua <hu...@mininglamp.com>
> wrote:
>
> > Thanks a lot, Hongbin! So it is now fixed in 0.7.3 as well as 0.8?
> >
> > > -----邮件原件-----
> > > 发件人: dev-return-3694-
> > > huanghua=mininglamp.com@kylin.incubator.apache.org [mailto:dev-return-
> > > 3694-huanghua=mininglamp.com@kylin.incubator.apache.org] 代表 hongbin
> > > ma
> > > 发送时间: 2015年8月14日 18:12
> > > 收件人: dev
> > > 主题: Re: [jira] [Updated] (KYLIN-949) Query cache doesn't work properly
> > for
> > > prepareStatement queries
> > >
> > > thanks Hua!
> > >
> > > I have applied you patch in 0.7 staging, and cherry-picked it to 0.8
> > branch
> > >
> > > On Fri, Aug 14, 2015 at 5:31 PM, Huang Hua (JIRA) <ji...@apache.org>
> > wrote:
> > >
> > > >
> > > >      [
> > > > https://issues.apache.org/jira/browse/KYLIN-
> > > 949?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
> > > > ]
> > > >
> > > > Huang Hua updated KYLIN-949:
> > > > ----------------------------
> > > >     Attachment: fix_kylin_949.patch
> > > >
> > > > Here is my patch to fix the bug, which basically adds hashcode() and
> > > > equals() implementations in PrepareSqlRequest.
> > > >
> > > > > Query cache doesn't work properly for prepareStatement queries
> > > > > --------------------------------------------------------------
> > > > >
> > > > >                 Key: KYLIN-949
> > > > >                 URL:
> https://issues.apache.org/jira/browse/KYLIN-949
> > > > >             Project: Kylin
> > > > >          Issue Type: Bug
> > > > >          Components: REST Service
> > > > >    Affects Versions: v0.7.2, v0.7.1
> > > > >            Reporter: Huang Hua
> > > > >            Assignee: Zhong,Jason
> > > > >         Attachments: fix_kylin_949.patch
> > > > >
> > > > >
> > > > > There is a bug in searchQueryInCache() method, for
> PrepareSqlRequest,
> > > > the cache logic is wrong which returns the same result for any
> > > > PrepareSqlRequest with same sql no matter what the actual params are.
> > > > > For example, using "select LEAF_CATEG_ID from KYLIN_SALES where
> > > > LEAF_CATEG_ID = ? group by LEAF_CATEG_ID;" with params=[65] to fire
> > > > request, and kylin will return 65. Let's suppose that query is
> > cached(we
> > > > can modify kylin settings to enable it to cache every query).
> > > > > And then using the same sql but with params=[130], which returns 65
> > > > instead of 130.
> > > >
> > > >
> > > >
> > > > --
> > > > This message was sent by Atlassian JIRA
> > > > (v6.3.4#6332)
> > > >
> > >
> > >
> > >
> > > --
> > > Regards,
> > >
> > > *Bin Mahone | 马洪宾*
> > > Apache Kylin: http://kylin.io
> > > Github: https://github.com/binmahone
> >
> >
> >
>
>
> --
> Regards,
>
> *Bin Mahone | 马洪宾*
> Apache Kylin: http://kylin.io
> Github: https://github.com/binmahone
>

Re: 答复: [jira] [Updated] (KYLIN-949) Query cache doesn't work properly for prepareStatement queries

Posted by hongbin ma <ma...@apache.org>.
should be:)

On Sat, Aug 15, 2015 at 8:38 PM, Huang Hua <hu...@mininglamp.com> wrote:

> Thanks a lot, Hongbin! So it is now fixed in 0.7.3 as well as 0.8?
>
> > -----邮件原件-----
> > 发件人: dev-return-3694-
> > huanghua=mininglamp.com@kylin.incubator.apache.org [mailto:dev-return-
> > 3694-huanghua=mininglamp.com@kylin.incubator.apache.org] 代表 hongbin
> > ma
> > 发送时间: 2015年8月14日 18:12
> > 收件人: dev
> > 主题: Re: [jira] [Updated] (KYLIN-949) Query cache doesn't work properly
> for
> > prepareStatement queries
> >
> > thanks Hua!
> >
> > I have applied you patch in 0.7 staging, and cherry-picked it to 0.8
> branch
> >
> > On Fri, Aug 14, 2015 at 5:31 PM, Huang Hua (JIRA) <ji...@apache.org>
> wrote:
> >
> > >
> > >      [
> > > https://issues.apache.org/jira/browse/KYLIN-
> > 949?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
> > > ]
> > >
> > > Huang Hua updated KYLIN-949:
> > > ----------------------------
> > >     Attachment: fix_kylin_949.patch
> > >
> > > Here is my patch to fix the bug, which basically adds hashcode() and
> > > equals() implementations in PrepareSqlRequest.
> > >
> > > > Query cache doesn't work properly for prepareStatement queries
> > > > --------------------------------------------------------------
> > > >
> > > >                 Key: KYLIN-949
> > > >                 URL: https://issues.apache.org/jira/browse/KYLIN-949
> > > >             Project: Kylin
> > > >          Issue Type: Bug
> > > >          Components: REST Service
> > > >    Affects Versions: v0.7.2, v0.7.1
> > > >            Reporter: Huang Hua
> > > >            Assignee: Zhong,Jason
> > > >         Attachments: fix_kylin_949.patch
> > > >
> > > >
> > > > There is a bug in searchQueryInCache() method, for PrepareSqlRequest,
> > > the cache logic is wrong which returns the same result for any
> > > PrepareSqlRequest with same sql no matter what the actual params are.
> > > > For example, using "select LEAF_CATEG_ID from KYLIN_SALES where
> > > LEAF_CATEG_ID = ? group by LEAF_CATEG_ID;" with params=[65] to fire
> > > request, and kylin will return 65. Let's suppose that query is
> cached(we
> > > can modify kylin settings to enable it to cache every query).
> > > > And then using the same sql but with params=[130], which returns 65
> > > instead of 130.
> > >
> > >
> > >
> > > --
> > > This message was sent by Atlassian JIRA
> > > (v6.3.4#6332)
> > >
> >
> >
> >
> > --
> > Regards,
> >
> > *Bin Mahone | 马洪宾*
> > Apache Kylin: http://kylin.io
> > Github: https://github.com/binmahone
>
>
>


-- 
Regards,

*Bin Mahone | 马洪宾*
Apache Kylin: http://kylin.io
Github: https://github.com/binmahone