[ 
https://issues.apache.org/jira/browse/IGNITE-10643?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16717437#comment-16717437
 ] 

ASF GitHub Bot commented on IGNITE-10643:
-----------------------------------------

GitHub user ygerzhedovich opened a pull request:

    https://github.com/apache/ignite/pull/5641

    IGNITE-10643

    

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/gridgain/apache-ignite ignite-10643

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/ignite/pull/5641.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #5641
    
----
commit 77eb9f3e89857e859b7f1c7db68f9c57d553db06
Author: Yury Gerzhedovich <ygerzhedovich@...>
Date:   2018-12-11T15:17:46Z

    IGNITE-10643: GridCacheContextInfo should not use isCacheContextInited() 
method to calculate constant properties

----


> GridCacheContextInfo should not use isCacheContextInited() method to 
> calculate constant properties
> --------------------------------------------------------------------------------------------------
>
>                 Key: IGNITE-10643
>                 URL: https://issues.apache.org/jira/browse/IGNITE-10643
>             Project: Ignite
>          Issue Type: Bug
>          Components: sql
>            Reporter: Vladimir Ozerov
>            Assignee: Yury Gerzhedovich
>            Priority: Major
>              Labels: iep-24
>             Fix For: 2.8
>
>
> This appears to be a regression from IGNITE-6173. Current method 
> {{isCacheContextInited}} is used to determine several properties (config, 
> name, customAffinityMapper, groupId, cacheId, affinityNode). This is wrong, 
> as all of these properties are "constant" and can be deduced form 
> configuration.
> One specific case when it breaks Ignite is {{customAffinityMapper}}. It is 
> used to determine affinity key field in {{GridH2Table}} which will be used 
> later on for partition pruning. However, when table is created on a client 
> node and context is not initialized yet, it will return "false", and 
> incorrect affinity key will be calculated in 
> {{QueryUtils.typeForQueryEntity}} and in {{GridH2Table}} later on. Finally, 
> when query is executed, incorrect partition might be derived from it leading 
> to incorrect query result.
> Solution: make all mentioned methods independent of cache state.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to