[jira] [Created] (GEODE-2872) totalHitCount and totalMissCount incorrect for Partitioned Regions

2017-05-03 Thread Srikanth Manvi (JIRA)
Srikanth Manvi created GEODE-2872:
-

 Summary: totalHitCount and totalMissCount incorrect for 
Partitioned Regions
 Key: GEODE-2872
 URL: https://issues.apache.org/jira/browse/GEODE-2872
 Project: Geode
  Issue Type: Bug
  Components: jmx
Reporter: Srikanth Manvi


The totalHitCount and totalMissCount values jump by 2 for each hit/miss 
operation instead of jumping by 1.

Below are the steps:
- Create a partitioned region with statistics enabled.
-  run _gfsh>show metrics_ and note the values of _totalHitCount_ and 
_totalMissCount_
- Put an entry into the region retrieve it using  _get_ and check the 
_totalHitCount_. The value would have doubled.
- Run a _get_ on a key that is not in the region, and check the 
_totalMissCount_, it would have doubled.


For a Partitioned region
{code}
gfsh>create region --name=Customer_Partition --enable-statistics=true 
--type=PARTITION
   Member | Status
- | ---
geode-server2 | Region "/Customer_Partition" created on "geode-server2"

gfsh>show metrics

Cluster-wide Metrics

Category  |Metric | Value
- | - | -
cluster   | totalHeapSize | 10923
cache | totalRegionEntryCount | 0
  | totalRegionCount  | 3
  | totalMissCount| 1
  | totalHitCount | 5
diskstore | totalDiskUsage| 0
  | diskReadsRate | 0
  | diskWritesRate| 0
  | flushTimeAvgLatency   | 0
  | totalBackupInProgress | 0
query | activeCQCount | 0
  | queryRequestRate  | 0

gfsh>get --key=404 --region=/Customer_Partition
Result  : false
Key Class   : java.lang.String
Key : 404
Value Class : java.lang.String
Value   : 


gfsh>show metrics

Cluster-wide Metrics

Category  |Metric | Value
- | - | -
cluster   | totalHeapSize | 10923
cache | totalRegionEntryCount | 0
  | totalRegionCount  | 3
  | totalMissCount| 3
  | totalHitCount | 5
diskstore | totalDiskUsage| 0
  | diskReadsRate | 0
  | diskWritesRate| 0
  | flushTimeAvgLatency   | 0
  | totalBackupInProgress | 0
query | activeCQCount | 0
  | queryRequestRate  | 0

gfsh>put --key=1 --value="1" --region=/Customer_Partition
Result  : true
Key Class   : java.lang.String
Key : 1
Value Class : java.lang.String
Old Value   : 


gfsh>get --key=1 --region=/Customer_Partition
Result  : true
Key Class   : java.lang.String
Key : 1
Value Class : java.lang.String
Value   : 1

gfsh>show metrics

Cluster-wide Metrics

Category  |Metric | Value
- | - | -
cluster   | totalHeapSize | 10923
cache | totalRegionEntryCount | 1
  | totalRegionCount  | 3
  | totalMissCount| 3
  | totalHitCount | 7
diskstore | totalDiskUsage| 0
  | diskReadsRate | 0
  | diskWritesRate| 0
  | flushTimeAvgLatency   | 0
  | totalBackupInProgress | 0
query | activeCQCount | 0
  | queryRequestRate  | 0
{code}

Version info - 

{code}
gfsh>version --full
Build-Date: 2017-03-27 21:52:42 -0700
Build-Id: abaker 0
Build-Java-Version: 1.8.0_121
Build-Platform: Mac OS X 10.12.3 x86_64
Product-Name: Apache Geode
Product-Version: 1.1.1
Source-Date: 2017-03-27 21:36:40 -0700
Source-Repository: release/1.1.1
Source-Revision: e2081044ea0afca1cb38d62c7f34e7363b45ad97
Native version: native code unavailable
Running on: /10.8.4.198, 8 cpu(s), x86_64 Mac OS X 10.11.6
{code}



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)


[jira] [Commented] (GEODE-2676) RegionMBean statistics wrong on partitioned regions

2017-05-03 Thread Srikanth Manvi (JIRA)

[ 
https://issues.apache.org/jira/browse/GEODE-2676?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15995031#comment-15995031
 ] 

Srikanth Manvi commented on GEODE-2676:
---

On the geode mailing list I was told the below might be relevant for this story.
I see a NPE when I run gfsh show metrics command by passing a member  Ex: 
{code}gfsh>show metrics --region=/Customer_Partition 
--member=geode-server2{code}. There is no problem when we dont pass 
`--member=geode-server2`

{noformat}
gfsh>show metrics --region=/Customer_Partition --member=geode-server2
Could not process command due to GemFire error. 
#SBjava.lang.NullPointerException
at com.sun.proxy.$Proxy81.getMissCount(Unknown Source)
at 
org.apache.geode.management.internal.cli.commands.MiscellaneousCommands.getRegionMetricsFromMember(MiscellaneousCommands.java:1970)
at 
org.apache.geode.management.internal.cli.commands.MiscellaneousCommands.showMetrics(MiscellaneousCommands.java:1200)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at 
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at 
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:497)
at 
org.springframework.util.ReflectionUtils.invokeMethod(ReflectionUtils.java:216)
at 
org.apache.geode.management.internal.cli.remote.RemoteExecutionStrategy.execute(RemoteExecutionStrategy.java:91)
at 
org.apache.geode.management.internal.cli.remote.CommandProcessor.executeCommand(CommandProcessor.java:117)
at 
org.apache.geode.management.internal.cli.remote.CommandStatementImpl.process(CommandStatementImpl.java:71)
at 
org.apache.geode.management.internal.cli.remote.MemberCommandService.processCommand(MemberCommandService.java:52)
at 
org.apache.geode.management.internal.beans.MemberMBeanBridge.processCommand(MemberMBeanBridge.java:1639)
at 
org.apache.geode.management.internal.beans.MemberMBean.processCommand(MemberMBean.java:404)
at 
org.apache.geode.management.internal.beans.MemberMBean.processCommand(MemberMBean.java:397)
at sun.reflect.GeneratedMethodAccessor298.invoke(Unknown Source)
at 
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:497)
at sun.reflect.misc.Trampoline.invoke(MethodUtil.java:71)
at sun.reflect.GeneratedMethodAccessor10.invoke(Unknown Source)
at 
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:497)
at sun.reflect.misc.MethodUtil.invoke(MethodUtil.java:275)
at 
com.sun.jmx.mbeanserver.ConvertingMethod.invokeWithOpenReturn(ConvertingMethod.java:193)
at 
com.sun.jmx.mbeanserver.ConvertingMethod.invokeWithOpenReturn(ConvertingMethod.java:175)
at 
com.sun.jmx.mbeanserver.MXBeanIntrospector.invokeM2(MXBeanIntrospector.java:117)
at 
com.sun.jmx.mbeanserver.MXBeanIntrospector.invokeM2(MXBeanIntrospector.java:54)
at 
com.sun.jmx.mbeanserver.MBeanIntrospector.invokeM(MBeanIntrospector.java:237)
at com.sun.jmx.mbeanserver.PerInterface.invoke(PerInterface.java:138)
at com.sun.jmx.mbeanserver.MBeanSupport.invoke(MBeanSupport.java:252)
at 
com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.invoke(DefaultMBeanServerInterceptor.java:819)
at com.sun.jmx.mbeanserver.JmxMBeanServer.invoke(JmxMBeanServer.java:801)
at 
javax.management.remote.rmi.RMIConnectionImpl.doOperation(RMIConnectionImpl.java:1468)
at 
javax.management.remote.rmi.RMIConnectionImpl.access$300(RMIConnectionImpl.java:76)
at 
javax.management.remote.rmi.RMIConnectionImpl$PrivilegedOperation.run(RMIConnectionImpl.java:1309)
at 
javax.management.remote.rmi.RMIConnectionImpl.doPrivilegedOperation(RMIConnectionImpl.java:1401)
at 
javax.management.remote.rmi.RMIConnectionImpl.invoke(RMIConnectionImpl.java:829)
at sun.reflect.GeneratedMethodAccessor76.invoke(Unknown Source)
at 
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:497)
at sun.rmi.server.UnicastServerRef.dispatch(UnicastServerRef.java:323)
at sun.rmi.transport.Transport$1.run(Transport.java:200)
at sun.rmi.transport.Transport$1.run(Transport.java:197)
at java.security.AccessController.doPrivileged(Native Method)
at sun.rmi.transport.Transport.serviceCall(Transport.java:196)
at sun.rmi.transport.tcp.TCPTransport.handleMessages(TCPTransport.java:568)
at 
sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run0(TCPTransport.java:826)
at 
sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.lambda$run$256(TCPTransport.java:683)
at java.security.AccessController.doPrivileged(Native Method)
at 

[jira] [Assigned] (GEODE-2622) Fix failures in GMSMembershipManagerJUnitTest caused by upgrading to mockito 2.7.11

2017-03-08 Thread Srikanth Manvi (JIRA)

 [ 
https://issues.apache.org/jira/browse/GEODE-2622?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Srikanth Manvi reassigned GEODE-2622:
-

Assignee: Srikanth Manvi

> Fix failures in GMSMembershipManagerJUnitTest caused by upgrading to mockito 
> 2.7.11
> ---
>
> Key: GEODE-2622
> URL: https://issues.apache.org/jira/browse/GEODE-2622
> Project: Geode
>  Issue Type: Sub-task
>  Components: tests
>Reporter: Kirk Lund
>Assignee: Srikanth Manvi
>
> These tests fail on branch feature/GEODE-2558:
> * GMSMembershipManagerJUnitTest.testDirectChannelSend
> * GMSMembershipManagerJUnitTest.testDirectChannelSendAllRecipients
> * 
> GMSMembershipManagerJUnitTest.testDirectChannelSendFailureDueToForcedDisconnect
> * GMSMembershipManagerJUnitTest.testDirectChannelSendFailureToOneRecipient



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)


[jira] [Commented] (GEODE-2558) Upgrade mockito dependency

2017-03-02 Thread Srikanth Manvi (JIRA)

[ 
https://issues.apache.org/jira/browse/GEODE-2558?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15893071#comment-15893071
 ] 

Srikanth Manvi commented on GEODE-2558:
---

Hi [~klund],

Has work started on this ? I would love to contribute on this, with someones 
guidance.

> Upgrade mockito dependency
> --
>
> Key: GEODE-2558
> URL: https://issues.apache.org/jira/browse/GEODE-2558
> Project: Geode
>  Issue Type: Wish
>  Components: build, tests
>Reporter: Kirk Lund
>
> Mockito should be upgrade from 1.x to 2.x.
> 1.10.19 (Dec, 2014) <-- current version
> 2.7.11 (Feb 2017)
> This requires updating Powermock as well.
> Changes to dependency-versions.properties:
> {noformat}
> -mockito-core.version = 1.10.19
> +mockito-core.version = 2.7.11
> ...
> -powermock.version = 1.6.6
> +powermock.version = 1.7.0RC2
> {noformat}
> The upgrade from Mockito 1.x to 2.x includes breaking APIs. Even after 
> updating the APIs to compile, I still see a number of unit tests that use 
> Mockito failing. These tests span all of the components in Geode so it's a 
> non-trivial upgrade.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)


[jira] [Commented] (GEODE-2526) Enhance log statement in StatsArchiveReader

2017-02-22 Thread Srikanth Manvi (JIRA)

[ 
https://issues.apache.org/jira/browse/GEODE-2526?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15879774#comment-15879774
 ] 

Srikanth Manvi commented on GEODE-2526:
---

Created this review request https://reviews.apache.org/r/56964/

> Enhance log statement in StatsArchiveReader
> ---
>
> Key: GEODE-2526
> URL: https://issues.apache.org/jira/browse/GEODE-2526
> Project: Geode
>  Issue Type: New Feature
>  Components: statistics
>Reporter: Srikanth Manvi
>Assignee: Srikanth Manvi
>Priority: Trivial
>
> Rarely stats files are corrupted due to missing ResourceType info in the gfs 
> file. In those cases the gfs files cannot be opened in VSD tool as the tool 
> throws an error while loading.
> The log statement in the method 
> StatsArchiveReader.java(readResourceInstanceCreateToken())  prints out only 
> the missing ResourceTypeId which appears to be dynamically created. 
> If the log message can be enhanced to include the resourceName as well, it 
> will be valuable to know the name of ResourceType that is actually missing in 
> the stats file. 
> There is a [stats-cleaner | https://github.com/smanvi-pivotal/stats-cleaner] 
> utility which takes in a corrupted stats files, name and id of the missing 
> ResourceType in the corrupted file and outputs a new .gfs file by filling in 
> the missing resource info. The new file can then be loaded and analyzed in 
> VSD.
>  
> For the [stats-cleaner | https://github.com/smanvi-pivotal/stats-cleaner] 
> utility to be usable one needs to know the actual name of missing 
> resourceType, hence this New feature request.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)


[jira] [Updated] (GEODE-2526) Enhance log statement in StatsArchiveReader

2017-02-22 Thread Srikanth Manvi (JIRA)

 [ 
https://issues.apache.org/jira/browse/GEODE-2526?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Srikanth Manvi updated GEODE-2526:
--
Priority: Trivial  (was: Major)

> Enhance log statement in StatsArchiveReader
> ---
>
> Key: GEODE-2526
> URL: https://issues.apache.org/jira/browse/GEODE-2526
> Project: Geode
>  Issue Type: New Feature
>  Components: statistics
>Reporter: Srikanth Manvi
>Assignee: Srikanth Manvi
>Priority: Trivial
>
> Rarely stats files are corrupted due to missing ResourceType info in the gfs 
> file. In those cases the gfs files cannot be opened in VSD tool as the tool 
> throws an error while loading.
> The log statement in the method 
> StatsArchiveReader.java(readResourceInstanceCreateToken())  prints out only 
> the missing ResourceTypeId which appears to be dynamically created. 
> If the log message can be enhanced to include the resourceName as well, it 
> will be valuable to know the name of ResourceType that is actually missing in 
> the stats file. 
> There is a [stats-cleaner | https://github.com/smanvi-pivotal/stats-cleaner] 
> utility which takes in a corrupted stats files, name and id of the missing 
> ResourceType in the corrupted file and outputs a new .gfs file by filling in 
> the missing resource info. The new file can then be loaded and analyzed in 
> VSD.
>  
> For the [stats-cleaner | https://github.com/smanvi-pivotal/stats-cleaner] 
> utility to be usable one needs to know the actual name of missing 
> resourceType, hence this New feature request.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)


[jira] [Assigned] (GEODE-2526) Enhance log statement in StatsArchiveReader

2017-02-22 Thread Srikanth Manvi (JIRA)

 [ 
https://issues.apache.org/jira/browse/GEODE-2526?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Srikanth Manvi reassigned GEODE-2526:
-

Assignee: Srikanth Manvi

> Enhance log statement in StatsArchiveReader
> ---
>
> Key: GEODE-2526
> URL: https://issues.apache.org/jira/browse/GEODE-2526
> Project: Geode
>  Issue Type: New Feature
>  Components: statistics
>Reporter: Srikanth Manvi
>Assignee: Srikanth Manvi
>
> Rarely stats files are corrupted due to missing ResourceType info in the gfs 
> file. In those cases the gfs files cannot be opened in VSD tool as the tool 
> throws an error while loading.
> The log statement in the method 
> StatsArchiveReader.java(readResourceInstanceCreateToken())  prints out only 
> the missing ResourceTypeId which appears to be dynamically created. 
> If the log message can be enhanced to include the resourceName as well, it 
> will be valuable to know the name of ResourceType that is actually missing in 
> the stats file. 
> There is a [stats-cleaner | https://github.com/smanvi-pivotal/stats-cleaner] 
> utility which takes in a corrupted stats files, name and id of the missing 
> ResourceType in the corrupted file and outputs a new .gfs file by filling in 
> the missing resource info. The new file can then be loaded and analyzed in 
> VSD.
>  
> For the [stats-cleaner | https://github.com/smanvi-pivotal/stats-cleaner] 
> utility to be usable one needs to know the actual name of missing 
> resourceType, hence this New feature request.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)