ignite-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Alexei Scherbakov (JIRA)" <j...@apache.org>
Subject [jira] [Created] (IGNITE-3326) Map-reduce query waits for rebalancing forever when it's disabled.
Date Thu, 16 Jun 2016 11:17:05 GMT
Alexei Scherbakov created IGNITE-3326:
-----------------------------------------

             Summary: 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
            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)

Mime
View raw message