Uploaded image for project: 'Geode'
  1. Geode
  2. GEODE-2872

totalHitCount and totalMissCount incorrect for Partitioned Regions

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • None
    • 1.10.0
    • jmx, regions

    Description

      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

      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       : <NULL>
      
      
      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   : <NULL>
      
      
      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
      

      Version info -

      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
      

      Attachments

        Issue Links

          Activity

            People

              mkevo Mario Kevo
              manvsri Srikanth Manvi
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: