[jira] [Commented] (IGNITE-12188) Metric CacheGroupMetrics.IndexBuildCountPartitionsLeft doesn't work correctly if there is more then one cache in cache group

2019-12-05 Thread Aleksey Plekhanov (Jira)


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

Aleksey Plekhanov commented on IGNITE-12188:


[~NSAmelchev], merged to master and ignite-2.8. Thanks for your contribution!

> Metric CacheGroupMetrics.IndexBuildCountPartitionsLeft doesn't work correctly 
> if there is more then one cache in cache group
> 
>
> Key: IGNITE-12188
> URL: https://issues.apache.org/jira/browse/IGNITE-12188
> Project: Ignite
>  Issue Type: Bug
>Affects Versions: 2.8
>Reporter: Aleksey Plekhanov
>Assignee: Amelchev Nikita
>Priority: Major
>  Labels: IEP-35, await
> Fix For: 2.8
>
>  Time Spent: 20m
>  Remaining Estimate: 0h
>
> Initial partitions counter is set to a total number of partitions for cache 
> group but decremented each time partition processed for each cache.
> Reproducer:
> {code:java}
> @Test
> public void testIndexRebuildMetrics() throws Exception {
> IgniteEx ignite = startGrid(new IgniteConfiguration()
> .setConsistentId("ignite")
> .setDataStorageConfiguration(new DataStorageConfiguration()
> .setDefaultDataRegionConfiguration(new 
> DataRegionConfiguration().setPersistenceEnabled(true)))
> .setCacheConfiguration(
> new CacheConfiguration Integer>("c1").setGroupName("grp").setIndexedTypes(Integer.class, 
> Integer.class),
> new CacheConfiguration Integer>("c2").setGroupName("grp").setIndexedTypes(Integer.class, 
> Integer.class)
> ));
> ignite.cluster().active(true);
> for (int i = 0; i < 10_000; i++)
> ignite.cache("c1").put(i, i);
> ignite.cluster().active(false);
> File dir = U.resolveWorkDirectory(U.defaultWorkDirectory(), 
> DFLT_STORE_DIR, false);
> U.delete(new File(dir, "ignite/cacheGroup-grp/index.bin"));
> ignite.cluster().active(true);
> doSleep(1_000L);
> 
> assertTrue(ignite.context().cache().cache("c1").context().group().metrics().getIndexBuildCountPartitionsLeft()
>  >= 0);
> }
> {code}



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Commented] (IGNITE-12188) Metric CacheGroupMetrics.IndexBuildCountPartitionsLeft doesn't work correctly if there is more then one cache in cache group

2019-12-05 Thread Aleksey Plekhanov (Jira)


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

Aleksey Plekhanov commented on IGNITE-12188:


[~NSAmelchev], I've run test locally and got error in 
testIndexRebuildCountPartitionsLeft:
{noformat}
class org.apache.ignite.IgniteException: Cache wasn't start index rebuild yet. 
[cacheName=cache2]class org.apache.ignite.IgniteException: Cache wasn't start 
index rebuild yet. [cacheName=cache2] at 
org.apache.ignite.internal.processors.cache.index.AbstractIndexingCommonTest$BlockingIndexing.stopBlock(AbstractIndexingCommonTest.java:131)
 at 
org.apache.ignite.internal.processors.cache.CacheGroupMetricsWithIndexTest.testIndexRebuildCountPartitionsLeft(CacheGroupMetricsWithIndexTest.java:180){noformat}
Perhaps there is some race. Can you double check this error?

Also, please merge your branch with current master and resolve compilation 
errors. Method cacheGroupMetricsRegistryName from MetricUtils was reverted in 
master.

 

> Metric CacheGroupMetrics.IndexBuildCountPartitionsLeft doesn't work correctly 
> if there is more then one cache in cache group
> 
>
> Key: IGNITE-12188
> URL: https://issues.apache.org/jira/browse/IGNITE-12188
> Project: Ignite
>  Issue Type: Bug
>Affects Versions: 2.8
>Reporter: Aleksey Plekhanov
>Assignee: Amelchev Nikita
>Priority: Major
>  Labels: IEP-35, await
> Fix For: 2.8
>
>  Time Spent: 20m
>  Remaining Estimate: 0h
>
> Initial partitions counter is set to a total number of partitions for cache 
> group but decremented each time partition processed for each cache.
> Reproducer:
> {code:java}
> @Test
> public void testIndexRebuildMetrics() throws Exception {
> IgniteEx ignite = startGrid(new IgniteConfiguration()
> .setConsistentId("ignite")
> .setDataStorageConfiguration(new DataStorageConfiguration()
> .setDefaultDataRegionConfiguration(new 
> DataRegionConfiguration().setPersistenceEnabled(true)))
> .setCacheConfiguration(
> new CacheConfiguration Integer>("c1").setGroupName("grp").setIndexedTypes(Integer.class, 
> Integer.class),
> new CacheConfiguration Integer>("c2").setGroupName("grp").setIndexedTypes(Integer.class, 
> Integer.class)
> ));
> ignite.cluster().active(true);
> for (int i = 0; i < 10_000; i++)
> ignite.cache("c1").put(i, i);
> ignite.cluster().active(false);
> File dir = U.resolveWorkDirectory(U.defaultWorkDirectory(), 
> DFLT_STORE_DIR, false);
> U.delete(new File(dir, "ignite/cacheGroup-grp/index.bin"));
> ignite.cluster().active(true);
> doSleep(1_000L);
> 
> assertTrue(ignite.context().cache().cache("c1").context().group().metrics().getIndexBuildCountPartitionsLeft()
>  >= 0);
> }
> {code}



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Commented] (IGNITE-12188) Metric CacheGroupMetrics.IndexBuildCountPartitionsLeft doesn't work correctly if there is more then one cache in cache group

2019-12-05 Thread Amelchev Nikita (Jira)


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

Amelchev Nikita commented on IGNITE-12188:
--

[~alex_pl], I got a visa from the bot. Despite the falls in the master, I ran 
52k tests. The suite with this test are fine. (cache5)

> Metric CacheGroupMetrics.IndexBuildCountPartitionsLeft doesn't work correctly 
> if there is more then one cache in cache group
> 
>
> Key: IGNITE-12188
> URL: https://issues.apache.org/jira/browse/IGNITE-12188
> Project: Ignite
>  Issue Type: Bug
>Affects Versions: 2.8
>Reporter: Aleksey Plekhanov
>Assignee: Amelchev Nikita
>Priority: Major
>  Labels: IEP-35, await
> Fix For: 2.8
>
>  Time Spent: 20m
>  Remaining Estimate: 0h
>
> Initial partitions counter is set to a total number of partitions for cache 
> group but decremented each time partition processed for each cache.
> Reproducer:
> {code:java}
> @Test
> public void testIndexRebuildMetrics() throws Exception {
> IgniteEx ignite = startGrid(new IgniteConfiguration()
> .setConsistentId("ignite")
> .setDataStorageConfiguration(new DataStorageConfiguration()
> .setDefaultDataRegionConfiguration(new 
> DataRegionConfiguration().setPersistenceEnabled(true)))
> .setCacheConfiguration(
> new CacheConfiguration Integer>("c1").setGroupName("grp").setIndexedTypes(Integer.class, 
> Integer.class),
> new CacheConfiguration Integer>("c2").setGroupName("grp").setIndexedTypes(Integer.class, 
> Integer.class)
> ));
> ignite.cluster().active(true);
> for (int i = 0; i < 10_000; i++)
> ignite.cache("c1").put(i, i);
> ignite.cluster().active(false);
> File dir = U.resolveWorkDirectory(U.defaultWorkDirectory(), 
> DFLT_STORE_DIR, false);
> U.delete(new File(dir, "ignite/cacheGroup-grp/index.bin"));
> ignite.cluster().active(true);
> doSleep(1_000L);
> 
> assertTrue(ignite.context().cache().cache("c1").context().group().metrics().getIndexBuildCountPartitionsLeft()
>  >= 0);
> }
> {code}



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Commented] (IGNITE-12188) Metric CacheGroupMetrics.IndexBuildCountPartitionsLeft doesn't work correctly if there is more then one cache in cache group

2019-12-05 Thread Ignite TC Bot (Jira)


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

Ignite TC Bot commented on IGNITE-12188:


{panel:title=Branch: [pull/7079/head] Base: [master] : No blockers 
found!|borderStyle=dashed|borderColor=#ccc|titleBGColor=#D6F7C1}{panel}
[TeamCity *--> Run :: All* 
Results|https://ci.ignite.apache.org/viewLog.html?buildId=4813910&buildTypeId=IgniteTests24Java8_RunAll]

> Metric CacheGroupMetrics.IndexBuildCountPartitionsLeft doesn't work correctly 
> if there is more then one cache in cache group
> 
>
> Key: IGNITE-12188
> URL: https://issues.apache.org/jira/browse/IGNITE-12188
> Project: Ignite
>  Issue Type: Bug
>Affects Versions: 2.8
>Reporter: Aleksey Plekhanov
>Assignee: Amelchev Nikita
>Priority: Major
>  Labels: IEP-35, await
> Fix For: 2.8
>
>  Time Spent: 20m
>  Remaining Estimate: 0h
>
> Initial partitions counter is set to a total number of partitions for cache 
> group but decremented each time partition processed for each cache.
> Reproducer:
> {code:java}
> @Test
> public void testIndexRebuildMetrics() throws Exception {
> IgniteEx ignite = startGrid(new IgniteConfiguration()
> .setConsistentId("ignite")
> .setDataStorageConfiguration(new DataStorageConfiguration()
> .setDefaultDataRegionConfiguration(new 
> DataRegionConfiguration().setPersistenceEnabled(true)))
> .setCacheConfiguration(
> new CacheConfiguration Integer>("c1").setGroupName("grp").setIndexedTypes(Integer.class, 
> Integer.class),
> new CacheConfiguration Integer>("c2").setGroupName("grp").setIndexedTypes(Integer.class, 
> Integer.class)
> ));
> ignite.cluster().active(true);
> for (int i = 0; i < 10_000; i++)
> ignite.cache("c1").put(i, i);
> ignite.cluster().active(false);
> File dir = U.resolveWorkDirectory(U.defaultWorkDirectory(), 
> DFLT_STORE_DIR, false);
> U.delete(new File(dir, "ignite/cacheGroup-grp/index.bin"));
> ignite.cluster().active(true);
> doSleep(1_000L);
> 
> assertTrue(ignite.context().cache().cache("c1").context().group().metrics().getIndexBuildCountPartitionsLeft()
>  >= 0);
> }
> {code}



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Commented] (IGNITE-12188) Metric CacheGroupMetrics.IndexBuildCountPartitionsLeft doesn't work correctly if there is more then one cache in cache group

2019-12-04 Thread Aleksey Plekhanov (Jira)


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

Aleksey Plekhanov commented on IGNITE-12188:


[~NSAmelchev], looks good to me. Please request bot visa after last changes.

> Metric CacheGroupMetrics.IndexBuildCountPartitionsLeft doesn't work correctly 
> if there is more then one cache in cache group
> 
>
> Key: IGNITE-12188
> URL: https://issues.apache.org/jira/browse/IGNITE-12188
> Project: Ignite
>  Issue Type: Bug
>Affects Versions: 2.8
>Reporter: Aleksey Plekhanov
>Assignee: Amelchev Nikita
>Priority: Major
>  Labels: IEP-35, await
> Fix For: 2.8
>
>  Time Spent: 20m
>  Remaining Estimate: 0h
>
> Initial partitions counter is set to a total number of partitions for cache 
> group but decremented each time partition processed for each cache.
> Reproducer:
> {code:java}
> @Test
> public void testIndexRebuildMetrics() throws Exception {
> IgniteEx ignite = startGrid(new IgniteConfiguration()
> .setConsistentId("ignite")
> .setDataStorageConfiguration(new DataStorageConfiguration()
> .setDefaultDataRegionConfiguration(new 
> DataRegionConfiguration().setPersistenceEnabled(true)))
> .setCacheConfiguration(
> new CacheConfiguration Integer>("c1").setGroupName("grp").setIndexedTypes(Integer.class, 
> Integer.class),
> new CacheConfiguration Integer>("c2").setGroupName("grp").setIndexedTypes(Integer.class, 
> Integer.class)
> ));
> ignite.cluster().active(true);
> for (int i = 0; i < 10_000; i++)
> ignite.cache("c1").put(i, i);
> ignite.cluster().active(false);
> File dir = U.resolveWorkDirectory(U.defaultWorkDirectory(), 
> DFLT_STORE_DIR, false);
> U.delete(new File(dir, "ignite/cacheGroup-grp/index.bin"));
> ignite.cluster().active(true);
> doSleep(1_000L);
> 
> assertTrue(ignite.context().cache().cache("c1").context().group().metrics().getIndexBuildCountPartitionsLeft()
>  >= 0);
> }
> {code}



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Commented] (IGNITE-12188) Metric CacheGroupMetrics.IndexBuildCountPartitionsLeft doesn't work correctly if there is more then one cache in cache group

2019-12-04 Thread Amelchev Nikita (Jira)


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

Amelchev Nikita commented on IGNITE-12188:
--

[~alex_pl], I have fixed the metric. Could you take a look, please?

> Metric CacheGroupMetrics.IndexBuildCountPartitionsLeft doesn't work correctly 
> if there is more then one cache in cache group
> 
>
> Key: IGNITE-12188
> URL: https://issues.apache.org/jira/browse/IGNITE-12188
> Project: Ignite
>  Issue Type: Bug
>Affects Versions: 2.8
>Reporter: Aleksey Plekhanov
>Assignee: Amelchev Nikita
>Priority: Major
>  Labels: IEP-35, await
> Fix For: 2.8
>
>  Time Spent: 20m
>  Remaining Estimate: 0h
>
> Initial partitions counter is set to a total number of partitions for cache 
> group but decremented each time partition processed for each cache.
> Reproducer:
> {code:java}
> @Test
> public void testIndexRebuildMetrics() throws Exception {
> IgniteEx ignite = startGrid(new IgniteConfiguration()
> .setConsistentId("ignite")
> .setDataStorageConfiguration(new DataStorageConfiguration()
> .setDefaultDataRegionConfiguration(new 
> DataRegionConfiguration().setPersistenceEnabled(true)))
> .setCacheConfiguration(
> new CacheConfiguration Integer>("c1").setGroupName("grp").setIndexedTypes(Integer.class, 
> Integer.class),
> new CacheConfiguration Integer>("c2").setGroupName("grp").setIndexedTypes(Integer.class, 
> Integer.class)
> ));
> ignite.cluster().active(true);
> for (int i = 0; i < 10_000; i++)
> ignite.cache("c1").put(i, i);
> ignite.cluster().active(false);
> File dir = U.resolveWorkDirectory(U.defaultWorkDirectory(), 
> DFLT_STORE_DIR, false);
> U.delete(new File(dir, "ignite/cacheGroup-grp/index.bin"));
> ignite.cluster().active(true);
> doSleep(1_000L);
> 
> assertTrue(ignite.context().cache().cache("c1").context().group().metrics().getIndexBuildCountPartitionsLeft()
>  >= 0);
> }
> {code}



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Commented] (IGNITE-12188) Metric CacheGroupMetrics.IndexBuildCountPartitionsLeft doesn't work correctly if there is more then one cache in cache group

2019-12-03 Thread Aleksey Plekhanov (Jira)


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

Aleksey Plekhanov commented on IGNITE-12188:


[~NSAmelchev], yes we should get a fully working metric by this ticket. 

> Metric CacheGroupMetrics.IndexBuildCountPartitionsLeft doesn't work correctly 
> if there is more then one cache in cache group
> 
>
> Key: IGNITE-12188
> URL: https://issues.apache.org/jira/browse/IGNITE-12188
> Project: Ignite
>  Issue Type: Bug
>Affects Versions: 2.8
>Reporter: Aleksey Plekhanov
>Assignee: Amelchev Nikita
>Priority: Major
>  Labels: IEP-35, await
> Fix For: 2.8
>
>  Time Spent: 20m
>  Remaining Estimate: 0h
>
> Initial partitions counter is set to a total number of partitions for cache 
> group but decremented each time partition processed for each cache.
> Reproducer:
> {code:java}
> @Test
> public void testIndexRebuildMetrics() throws Exception {
> IgniteEx ignite = startGrid(new IgniteConfiguration()
> .setConsistentId("ignite")
> .setDataStorageConfiguration(new DataStorageConfiguration()
> .setDefaultDataRegionConfiguration(new 
> DataRegionConfiguration().setPersistenceEnabled(true)))
> .setCacheConfiguration(
> new CacheConfiguration Integer>("c1").setGroupName("grp").setIndexedTypes(Integer.class, 
> Integer.class),
> new CacheConfiguration Integer>("c2").setGroupName("grp").setIndexedTypes(Integer.class, 
> Integer.class)
> ));
> ignite.cluster().active(true);
> for (int i = 0; i < 10_000; i++)
> ignite.cache("c1").put(i, i);
> ignite.cluster().active(false);
> File dir = U.resolveWorkDirectory(U.defaultWorkDirectory(), 
> DFLT_STORE_DIR, false);
> U.delete(new File(dir, "ignite/cacheGroup-grp/index.bin"));
> ignite.cluster().active(true);
> doSleep(1_000L);
> 
> assertTrue(ignite.context().cache().cache("c1").context().group().metrics().getIndexBuildCountPartitionsLeft()
>  >= 0);
> }
> {code}



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Commented] (IGNITE-12188) Metric CacheGroupMetrics.IndexBuildCountPartitionsLeft doesn't work correctly if there is more then one cache in cache group

2019-12-02 Thread Amelchev Nikita (Jira)


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

Amelchev Nikita commented on IGNITE-12188:
--

[~alex_pl], HI, thanks for taking a look.

Yes, that didn't work before. Moreover, this metric will not be reseted when 
{{parallelism lvl=1}} or {{thread idx=0}}, see 
{{SchemaIndexCacheVisitorImpl#visit}} (There is no handler for exceptions from 
{{processPartitions}} in init thread).

Should we fix this in this issue?

> Metric CacheGroupMetrics.IndexBuildCountPartitionsLeft doesn't work correctly 
> if there is more then one cache in cache group
> 
>
> Key: IGNITE-12188
> URL: https://issues.apache.org/jira/browse/IGNITE-12188
> Project: Ignite
>  Issue Type: Bug
>Affects Versions: 2.8
>Reporter: Aleksey Plekhanov
>Assignee: Amelchev Nikita
>Priority: Major
>  Labels: IEP-35, await
> Fix For: 2.8
>
>  Time Spent: 20m
>  Remaining Estimate: 0h
>
> Initial partitions counter is set to a total number of partitions for cache 
> group but decremented each time partition processed for each cache.
> Reproducer:
> {code:java}
> @Test
> public void testIndexRebuildMetrics() throws Exception {
> IgniteEx ignite = startGrid(new IgniteConfiguration()
> .setConsistentId("ignite")
> .setDataStorageConfiguration(new DataStorageConfiguration()
> .setDefaultDataRegionConfiguration(new 
> DataRegionConfiguration().setPersistenceEnabled(true)))
> .setCacheConfiguration(
> new CacheConfiguration Integer>("c1").setGroupName("grp").setIndexedTypes(Integer.class, 
> Integer.class),
> new CacheConfiguration Integer>("c2").setGroupName("grp").setIndexedTypes(Integer.class, 
> Integer.class)
> ));
> ignite.cluster().active(true);
> for (int i = 0; i < 10_000; i++)
> ignite.cache("c1").put(i, i);
> ignite.cluster().active(false);
> File dir = U.resolveWorkDirectory(U.defaultWorkDirectory(), 
> DFLT_STORE_DIR, false);
> U.delete(new File(dir, "ignite/cacheGroup-grp/index.bin"));
> ignite.cluster().active(true);
> doSleep(1_000L);
> 
> assertTrue(ignite.context().cache().cache("c1").context().group().metrics().getIndexBuildCountPartitionsLeft()
>  >= 0);
> }
> {code}



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Commented] (IGNITE-12188) Metric CacheGroupMetrics.IndexBuildCountPartitionsLeft doesn't work correctly if there is more then one cache in cache group

2019-12-02 Thread Aleksey Plekhanov (Jira)


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

Aleksey Plekhanov commented on IGNITE-12188:


[~NSAmelchev], There is still the problem with 
{{cctx.group().metrics().setIndexBuildCountPartitionsLeft(0);}}

usage. If any error occurred during index rebuild, the metric value becomes 
negative.

> Metric CacheGroupMetrics.IndexBuildCountPartitionsLeft doesn't work correctly 
> if there is more then one cache in cache group
> 
>
> Key: IGNITE-12188
> URL: https://issues.apache.org/jira/browse/IGNITE-12188
> Project: Ignite
>  Issue Type: Bug
>Affects Versions: 2.8
>Reporter: Aleksey Plekhanov
>Assignee: Amelchev Nikita
>Priority: Major
>  Labels: IEP-35, await
> Fix For: 2.8
>
>  Time Spent: 20m
>  Remaining Estimate: 0h
>
> Initial partitions counter is set to a total number of partitions for cache 
> group but decremented each time partition processed for each cache.
> Reproducer:
> {code:java}
> @Test
> public void testIndexRebuildMetrics() throws Exception {
> IgniteEx ignite = startGrid(new IgniteConfiguration()
> .setConsistentId("ignite")
> .setDataStorageConfiguration(new DataStorageConfiguration()
> .setDefaultDataRegionConfiguration(new 
> DataRegionConfiguration().setPersistenceEnabled(true)))
> .setCacheConfiguration(
> new CacheConfiguration Integer>("c1").setGroupName("grp").setIndexedTypes(Integer.class, 
> Integer.class),
> new CacheConfiguration Integer>("c2").setGroupName("grp").setIndexedTypes(Integer.class, 
> Integer.class)
> ));
> ignite.cluster().active(true);
> for (int i = 0; i < 10_000; i++)
> ignite.cache("c1").put(i, i);
> ignite.cluster().active(false);
> File dir = U.resolveWorkDirectory(U.defaultWorkDirectory(), 
> DFLT_STORE_DIR, false);
> U.delete(new File(dir, "ignite/cacheGroup-grp/index.bin"));
> ignite.cluster().active(true);
> doSleep(1_000L);
> 
> assertTrue(ignite.context().cache().cache("c1").context().group().metrics().getIndexBuildCountPartitionsLeft()
>  >= 0);
> }
> {code}



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Commented] (IGNITE-12188) Metric CacheGroupMetrics.IndexBuildCountPartitionsLeft doesn't work correctly if there is more then one cache in cache group

2019-11-26 Thread Amelchev Nikita (Jira)


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

Amelchev Nikita commented on IGNITE-12188:
--

[~alex_pl], Hi, I have fixed the metric.
Could you take a look, please?

> Metric CacheGroupMetrics.IndexBuildCountPartitionsLeft doesn't work correctly 
> if there is more then one cache in cache group
> 
>
> Key: IGNITE-12188
> URL: https://issues.apache.org/jira/browse/IGNITE-12188
> Project: Ignite
>  Issue Type: Bug
>Affects Versions: 2.8
>Reporter: Aleksey Plekhanov
>Assignee: Amelchev Nikita
>Priority: Major
>  Labels: IEP-35, await
> Fix For: 2.8
>
>  Time Spent: 20m
>  Remaining Estimate: 0h
>
> Initial partitions counter is set to a total number of partitions for cache 
> group but decremented each time partition processed for each cache.
> Reproducer:
> {code:java}
> @Test
> public void testIndexRebuildMetrics() throws Exception {
> IgniteEx ignite = startGrid(new IgniteConfiguration()
> .setConsistentId("ignite")
> .setDataStorageConfiguration(new DataStorageConfiguration()
> .setDefaultDataRegionConfiguration(new 
> DataRegionConfiguration().setPersistenceEnabled(true)))
> .setCacheConfiguration(
> new CacheConfiguration Integer>("c1").setGroupName("grp").setIndexedTypes(Integer.class, 
> Integer.class),
> new CacheConfiguration Integer>("c2").setGroupName("grp").setIndexedTypes(Integer.class, 
> Integer.class)
> ));
> ignite.cluster().active(true);
> for (int i = 0; i < 10_000; i++)
> ignite.cache("c1").put(i, i);
> ignite.cluster().active(false);
> File dir = U.resolveWorkDirectory(U.defaultWorkDirectory(), 
> DFLT_STORE_DIR, false);
> U.delete(new File(dir, "ignite/cacheGroup-grp/index.bin"));
> ignite.cluster().active(true);
> doSleep(1_000L);
> 
> assertTrue(ignite.context().cache().cache("c1").context().group().metrics().getIndexBuildCountPartitionsLeft()
>  >= 0);
> }
> {code}



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Commented] (IGNITE-12188) Metric CacheGroupMetrics.IndexBuildCountPartitionsLeft doesn't work correctly if there is more then one cache in cache group

2019-11-26 Thread Ignite TC Bot (Jira)


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

Ignite TC Bot commented on IGNITE-12188:


{panel:title=Branch: [pull/7079/head] Base: [master] : No blockers 
found!|borderStyle=dashed|borderColor=#ccc|titleBGColor=#D6F7C1}{panel}
[TeamCity *--> Run :: All* 
Results|https://ci.ignite.apache.org/viewLog.html?buildId=4794958&buildTypeId=IgniteTests24Java8_RunAll]

> Metric CacheGroupMetrics.IndexBuildCountPartitionsLeft doesn't work correctly 
> if there is more then one cache in cache group
> 
>
> Key: IGNITE-12188
> URL: https://issues.apache.org/jira/browse/IGNITE-12188
> Project: Ignite
>  Issue Type: Bug
>Affects Versions: 2.8
>Reporter: Aleksey Plekhanov
>Assignee: Amelchev Nikita
>Priority: Major
>  Labels: IEP-35, await
> Fix For: 2.8
>
>  Time Spent: 20m
>  Remaining Estimate: 0h
>
> Initial partitions counter is set to a total number of partitions for cache 
> group but decremented each time partition processed for each cache.
> Reproducer:
> {code:java}
> @Test
> public void testIndexRebuildMetrics() throws Exception {
> IgniteEx ignite = startGrid(new IgniteConfiguration()
> .setConsistentId("ignite")
> .setDataStorageConfiguration(new DataStorageConfiguration()
> .setDefaultDataRegionConfiguration(new 
> DataRegionConfiguration().setPersistenceEnabled(true)))
> .setCacheConfiguration(
> new CacheConfiguration Integer>("c1").setGroupName("grp").setIndexedTypes(Integer.class, 
> Integer.class),
> new CacheConfiguration Integer>("c2").setGroupName("grp").setIndexedTypes(Integer.class, 
> Integer.class)
> ));
> ignite.cluster().active(true);
> for (int i = 0; i < 10_000; i++)
> ignite.cache("c1").put(i, i);
> ignite.cluster().active(false);
> File dir = U.resolveWorkDirectory(U.defaultWorkDirectory(), 
> DFLT_STORE_DIR, false);
> U.delete(new File(dir, "ignite/cacheGroup-grp/index.bin"));
> ignite.cluster().active(true);
> doSleep(1_000L);
> 
> assertTrue(ignite.context().cache().cache("c1").context().group().metrics().getIndexBuildCountPartitionsLeft()
>  >= 0);
> }
> {code}



--
This message was sent by Atlassian Jira
(v8.3.4#803005)