Hi Alex!

This is a known issue.
You can track its progress here:
https://issues.apache.org/jira/browse/IGNITE-6564

You can use IgniteCache#size()
<https://ignite.apache.org/releases/latest/javadoc/org/apache/ignite/IgniteCache.html#size(org.apache.ignite.cache.CachePeekMode...)>
method as a workaround, but it implies higher overhead, so don't call this
method too often.

Denis

вт, 2 янв. 2018 г. в 13:35, AlexLM <[email protected]>:

> Hello,
>
> I try to get the number of entries on 3 nodes inside a cluster. but when i
> am doing :
>
> Ignition.ignite().cache(CACHE_NAME).metrics().size()
>
> I only get the size of the local cache, however i was thinking that
> metrics() method returned the whole cluster statistics.
>
> The ignite-config is the following :
>
> <bean name="cacheConf"
> class="org.apache.ignite.configuration.CacheConfiguration">
>         <property name="name" value="cache" />
>         <property name="cacheMode" value="PARTITIONED" />
>         <property name="backups" value="1" />
>         <property name="rebalanceMode" value="SYNC"/>
>         <property name="statisticsEnabled" value="true"/>
>         <property name="expiryPolicyFactory">
>                 <bean id="expiryPolicy"
> class="javax.cache.expiry.TouchedExpiryPolicy"
>                         factory-method="factoryOf">
>                         <constructor-arg>
>                                 <bean class="javax.cache.expiry.Duration">
>                                         <constructor-arg value="SECONDS" />
>                                         <constructor-arg value="600" />
>                                 </bean>
>                         </constructor-arg>
>                 </bean>
>         </property>
> </bean>
>
> Appreciate your help, thanks !
>
> AlexLM
>
>
>
>
> --
> Sent from: http://apache-ignite-users.70518.x6.nabble.com/
>

Reply via email to