You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@ignite.apache.org by "Sergi Vladykin (JIRA)" <ji...@apache.org> on 2017/01/13 09:43:26 UTC
[jira] [Closed] (IGNITE-3326) Map-reduce query waits for
rebalancing forever when it's disabled.
[ https://issues.apache.org/jira/browse/IGNITE-3326?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Sergi Vladykin closed IGNITE-3326.
----------------------------------
> Map-reduce query waits for rebalancing forever when it's disabled.
> ------------------------------------------------------------------
>
> Key: IGNITE-3326
> URL: https://issues.apache.org/jira/browse/IGNITE-3326
> Project: Ignite
> Issue Type: Bug
> Reporter: Alexei Scherbakov
> Assignee: Sergi Vladykin
> Priority: Minor
>
> The code below doesn't print anything:
> {code}
> public static void main(String[] args) throws IgniteException {
> Ignite start = Ignition.start(new IgniteConfiguration());
> CacheConfiguration<Integer, Person> cfg = new CacheConfiguration<>();
> cfg.setRebalanceMode(CacheRebalanceMode.NONE);
> cfg.setCacheMode(CacheMode.PARTITIONED);
> cfg.setName("test");
> cfg.setIndexedTypes(Integer.class, Person.class);
> IgniteCache<Integer, Person> cache = start.createCache(cfg);
> cache.put(1, new Person(1L, "Test 1", "Test 1"));
> cache.put(2, new Person(1L, "Test 2", "Test 2"));
> cache.put(3, new Person(1L, "Test 3", "Test 3"));
> QueryCursor<Cache.Entry<Integer, Person>> query = cache.query(new SqlQuery<Integer, Person>(Person.class, "_key >= 0"));
> List<Cache.Entry<Integer, Person>> all = query.getAll();
> System.out.println(all);
> }
> {code}
> Suggested fix: disable reservation if rebalancing is disabled.
> In GridMapQueryExecutor.reservePartitions add
> if (cctx.isLocal() || !cctx.rebalanceEnabled())
> continue;
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)